idlefw/plugins/devicestatus/inc/aivhzpublisher.h
branchRCL_3
changeset 30 a5a39a295112
equal deleted inserted replaced
29:0efa10d348c0 30:a5a39a295112
       
     1 /*
       
     2 * Copyright (c) 2005-2006 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:  Viag Home Zone (VHZ) publisher.
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 #ifndef C_AIVHZPUBLISHER_H
       
    20 #define C_AIVHZPUBLISHER_H
       
    21 
       
    22 // System includes
       
    23 #include <e32base.h>
       
    24 #include <aidevicestatuscontentmodel.h>
       
    25 
       
    26 // User includes
       
    27 #include "aidevicestatuspublisher.h"
       
    28 #include "ainetworkinfoobserver.h"
       
    29 
       
    30 // Forward declarations
       
    31 class MAiDeviceStatusContentObserver;
       
    32 class CHsContentPublisher;
       
    33 class CAiNetworkInfoListener;
       
    34 
       
    35 /**
       
    36  *  @ingroup group_devicestatusplugin
       
    37  *
       
    38  *  Viag Home Zone (VHZ) publisher.
       
    39  *
       
    40  *  Observes network info changes and publishes zone name
       
    41  *  when phone arrives to home or city zone.
       
    42  *
       
    43  *  @since S60 3.2
       
    44  */
       
    45 NONSHARABLE_CLASS( CAiVHZPublisher ) : public CBase, 
       
    46     public MAiDeviceStatusPublisher,
       
    47     public MAiNetworkInfoObserver
       
    48     {
       
    49 public:
       
    50 
       
    51     static CAiVHZPublisher* NewL();
       
    52 
       
    53     virtual ~CAiVHZPublisher();
       
    54 
       
    55 protected:
       
    56 
       
    57 // from base class MAiDeviceStatusPublisher
       
    58 
       
    59     void ResumeL();
       
    60     void Subscribe( MAiContentObserver& aObserver, 
       
    61                     CHsContentPublisher& aExtension,
       
    62                     MAiPublishPrioritizer& aPrioritizer,
       
    63                     MAiPublisherBroadcaster& aBroadcaster );
       
    64     void RefreshL( TBool aClean );
       
    65     TBool RefreshL( TInt aContentId, TBool aClean );
       
    66 
       
    67 //from base class MAiNetworkInfoObserver
       
    68 
       
    69     void HandleNetworkInfoChange( const MNWMessageObserver::TNWMessages& aMessage, 
       
    70     							  const TNWInfo& aInfo, 
       
    71     							  const TBool aShowOpInd );
       
    72 
       
    73 
       
    74 private:
       
    75 
       
    76     CAiVHZPublisher();
       
    77 
       
    78     void ConstructL();
       
    79 
       
    80 private: // data
       
    81 
       
    82     /**
       
    83      * Content observer.
       
    84      * Not own.
       
    85      */
       
    86     MAiContentObserver* iContentObserver;
       
    87 
       
    88     /**
       
    89      * Property extension.
       
    90      * Not own.
       
    91      */
       
    92     CHsContentPublisher* iExtension;
       
    93 
       
    94     /**
       
    95      * Network info listener.
       
    96      * Not own.
       
    97      */
       
    98     CAiNetworkInfoListener* iListener;
       
    99     
       
   100     /**
       
   101      * Flag to indiate whether vhz is in navi or mainpane.
       
   102      */    
       
   103      TBool iVhzInMainpane;
       
   104 
       
   105     };
       
   106 
       
   107 
       
   108 #endif // C_AIVHZPUBLISHER_H