videofeeds/hgvodui/inc/vcxhgvodinformationpopup.h
changeset 0 96612d01cf9f
equal deleted inserted replaced
-1:000000000000 0:96612d01cf9f
       
     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 the License "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:  Shows the information label in UI.*
       
    15 */
       
    16 
       
    17 
       
    18 
       
    19 #ifndef C_VCXHGVODINFORMATIONPOPUP_H
       
    20 #define C_VCXHGVODINFORMATIONPOPUP_H
       
    21 
       
    22 //  INCLUDES
       
    23 #include <AknUtils.h> 
       
    24 #include <AknInfoPopupNoteController.h>
       
    25 #include "CIptvTimer.h"
       
    26 #include "MIptvTimerObserver.h"
       
    27 
       
    28 // FORWARD DECLARATIONS
       
    29 class CVcxNsUiEngine;
       
    30 class CAknInfoPopupNoteController;
       
    31 class CAknView; 
       
    32                                             
       
    33 // CLASS DECLARATION
       
    34 
       
    35 /**
       
    36  * CVcxHgVodInformationPopup class 
       
    37  * utilizes CAknInfoPopup class that shows the information
       
    38  * label in UI
       
    39  */
       
    40 NONSHARABLE_CLASS ( CVcxHgVodInformationPopup ) : public CBase,
       
    41                                   public MIptvTimerObserver, 
       
    42                                   public MAknInfoPopupNoteObserver
       
    43     {    
       
    44 
       
    45 public:  // Constructors and destructor
       
    46 
       
    47     /**
       
    48     * Two-phased constructor.
       
    49     */
       
    50     static CVcxHgVodInformationPopup* NewL( CAknView& aParentView, 
       
    51                                             CVcxNsUiEngine& aUiEngine );
       
    52     
       
    53     /**
       
    54      * Destructor.
       
    55      */
       
    56     virtual ~CVcxHgVodInformationPopup();
       
    57 
       
    58     /** 
       
    59      * Shows given data in popup. 
       
    60      * 
       
    61      */
       
    62     void ShowL();
       
    63 
       
    64     /**
       
    65      * Hides popup 
       
    66      */
       
    67     void Hide();
       
    68     
       
    69     /**
       
    70      * Set text to info control
       
    71      */
       
    72     void SetTextL( const TDesC& aText );
       
    73 
       
    74     /**
       
    75      * Called when internal timer expires.
       
    76      *
       
    77      * @param aTimer Timer that expired.
       
    78      */    
       
    79     void TimerExpired( CIptvTimer* aTimer );
       
    80     
       
    81     /**
       
    82      * Handles the foreground event.
       
    83      * @param aForeground Is foreground state gained or not.
       
    84      */
       
    85     void HandleForegroundEventL( TBool aForeground );
       
    86 
       
    87     /**
       
    88      * Layout/orientation has been changed.
       
    89      */
       
    90     void HandleSizeChange();
       
    91 
       
    92 private:
       
    93     
       
    94     CVcxHgVodInformationPopup( CAknView& aParentView, 
       
    95                                CVcxNsUiEngine& aUiEngine );
       
    96 
       
    97     void ConstructL();
       
    98 
       
    99     /**
       
   100      * Creates internal popup note control.
       
   101      *
       
   102      * @return ETrue if control was created.
       
   103      */    
       
   104     TBool CreateControlL();
       
   105 
       
   106     /**
       
   107      * Deletes internal popup note control.
       
   108      */
       
   109     void DeleteControl(); 
       
   110 
       
   111   
       
   112     
       
   113 //From MAknInfoPopupNoteObserver
       
   114 
       
   115      /**
       
   116      * From MAknInfoPopupNoteObserver
       
   117      * Handles events reported from info popup note.
       
   118      * 
       
   119      */
       
   120      void HandleInfoPopupNoteEvent( CAknInfoPopupNoteController* aController,
       
   121                                     TAknInfoPopupNoteEvent aEvent );
       
   122 
       
   123 
       
   124 private:    // Data
       
   125 	
       
   126     //Reference to parent view class
       
   127 	CAknView&                           iParentView;
       
   128     
       
   129     //Reference to application ui class
       
   130     CVcxNsUiEngine&                      iUiEngine;
       
   131     
       
   132     //Pointer to popup note controller class ( from avkon )
       
   133     CAknInfoPopupNoteController*        iPopupController;
       
   134     
       
   135     //Text to be shown in ui
       
   136 	HBufC*			                    iPopupText;
       
   137 	
       
   138     //
       
   139 	CIptvTimer*                         iTimer;
       
   140 
       
   141 	// Top right corner of parent rect.
       
   142 	TPoint iTopRight;
       
   143     };
       
   144 
       
   145 #endif  // C_VCXHGVODINFORMATIONPOPUP_H   
       
   146