clock2/clockui/adtupdater/src/adtupdaterappui.cpp
branchRCL_3
changeset 86 ed599363c2d7
parent 78 356f28cd5ca0
equal deleted inserted replaced
78:356f28cd5ca0 86:ed599363c2d7
    25 #include "clock_debug.h"
    25 #include "clock_debug.h"
    26 
    26 
    27 // Constants
    27 // Constants
    28 const TInt KOrdinalPosition( 0 );
    28 const TInt KOrdinalPosition( 0 );
    29 const TInt KOrdinalPriority( 0 );
    29 const TInt KOrdinalPriority( 0 );
    30 
       
    31 // Uid of phoneapp
       
    32 const TUid KPhoneUid  = {0x100058B3};
       
    33 
       
    34 
    30 
    35 // Literals
    31 // Literals
    36 
    32 
    37 // ---------------------------------------------------------
    33 // ---------------------------------------------------------
    38 // CAdtUpdaterAppUi::CAdtUpdaterAppUi
    34 // CAdtUpdaterAppUi::CAdtUpdaterAppUi
   166         }
   162         }
   167     return EFalse;
   163     return EFalse;
   168     }
   164     }
   169 
   165 
   170 // ---------------------------------------------------------
   166 // ---------------------------------------------------------
   171 // CAdtUpdaterAppUi::IsHighPriorityWindowActive
       
   172 // rest of the details are commented in the header
       
   173 // ---------------------------------------------------------
       
   174 //
       
   175 TBool CAdtUpdaterAppUi::IsHighPriorityWindowActive()
       
   176     {
       
   177     __PRINTS( "CCAdtUpdaterAppUi::IsHighPriorityWindowActive - Entry" );
       
   178     // Gets the window group id of the app coming in foreground
       
   179     TInt activeWgId = iCoeEnv->WsSession().GetFocusWindowGroup();
       
   180     TApaTaskList taskList(iCoeEnv->WsSession());
       
   181     
       
   182     //In future, if any other high priority window will be there, then 
       
   183     //add that particular UID in the below check.
       
   184     //Note: Key Lock and alarm are not handled here as these windows already 
       
   185     //have high priority than CDT. In callui window group, the window - when
       
   186     //call is answered, has a low priority, that's why callui is handled here.
       
   187     __PRINTS( "CCAdtUpdaterAppUi::IsHighPriorityWindowActive - Exit" );
       
   188     if(activeWgId == taskList.FindApp(KPhoneUid).WgId())
       
   189         {
       
   190         return ETrue;
       
   191         }
       
   192     return EFalse;
       
   193     }
       
   194 // ---------------------------------------------------------
       
   195 // CAdtUpdaterAppUi::ToggleAppViewL
   167 // CAdtUpdaterAppUi::ToggleAppViewL
   196 // rest of the details are commented in the header
   168 // rest of the details are commented in the header
   197 // ---------------------------------------------------------
   169 // ---------------------------------------------------------
   198 //
   170 //
   199 void CAdtUpdaterAppUi::ToggleAppViewL( TBool aForeground )
   171 void CAdtUpdaterAppUi::ToggleAppViewL( TBool aForeground )