tstaskmonitor/server/inc/tsfswmonitor.h
changeset 94 dbb8300717f7
child 83 156f692b1687
equal deleted inserted replaced
93:82b66994846c 94:dbb8300717f7
       
     1 /*
       
     2 * Copyright (c) 2008 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:  Monitor for server
       
    15  *
       
    16 */
       
    17 
       
    18 
       
    19 #ifndef TSFSWMONITOR_H
       
    20 #define TSFSWMONITOR_H
       
    21 #define __E32SVR_H__
       
    22 
       
    23 #include <e32event.h>
       
    24 #include <e32debug.h>
       
    25 #include <w32std.h>
       
    26 
       
    27 class MTsFswTaskListObserver;
       
    28 class MTsFswResourceObserver;
       
    29 
       
    30 /**
       
    31  * Monitor for the fsw server.
       
    32  * Reimplements HandleWsEventL from base class to get notifications about
       
    33  * window group changes.
       
    34  */
       
    35 class CTsFswMonitor : public CActive
       
    36     {
       
    37 public:
       
    38     ~CTsFswMonitor();
       
    39     
       
    40     
       
    41 
       
    42 static CTsFswMonitor* NewL(MTsFswTaskListObserver& aTaskListObserver);
       
    43 static CTsFswMonitor* NewLC(MTsFswTaskListObserver& aTaskListObserver);
       
    44 
       
    45 protected:
       
    46     CTsFswMonitor(MTsFswTaskListObserver& aTaskListObserver);
       
    47     void ConstructL();
       
    48     
       
    49     // from CActive
       
    50     void RunL();
       
    51     TInt RunError( TInt aError );
       
    52     void DoCancel();
       
    53 
       
    54 
       
    55 private:
       
    56     void Subscribe();        
       
    57     void ConstractObserverL();
       
    58 private:
       
    59     MTsFswTaskListObserver* iTaskListObserver; // not own
       
    60     
       
    61     // window server session
       
    62     RWsSession iWsSession;
       
    63     /**
       
    64        * Window group.
       
    65        */
       
    66    RWindowGroup iWg;
       
    67     };
       
    68 
       
    69 #endif //TSFSWMONITOR_H