organizer_plat/calendar_common_utils_api/inc/CalenStatusPaneUtils.h
changeset 0 f979ecb2b13e
child 48 bf573002ff72
equal deleted inserted replaced
-1:000000000000 0:f979ecb2b13e
       
     1 /*
       
     2 * Copyright (c) 2002, 2003 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:  
       
    15  *
       
    16 */
       
    17 
       
    18 // System includes
       
    19 #include <badesca.h>
       
    20 
       
    21 // User includes
       
    22 #include "calenconstants.h"
       
    23 
       
    24 // Forward declaration
       
    25 class CCalenStatusPaneUtilsImpl;
       
    26 class CEikStatusPane;
       
    27 class CAknNavigationDecorator;
       
    28 
       
    29 /**
       
    30  * @class CCalenStatusPaneUtils 
       
    31  * @brief Utility class for accessing the status pane of the calendar
       
    32  */
       
    33 NONSHARABLE_CLASS( CCalenStatusPaneUtils ) : public CBase
       
    34     {
       
    35     public:			// Constructor and destructor
       
    36 	
       
    37 		/**
       
    38 		 * @brief First phase constructor
       
    39 		 *
       
    40 		 * @param aStatusPane The status pane
       
    41 		 * @return CCalenStatusPaneUtils* Pointer to an object of type CCalenStatusPaneUtils
       
    42 		 */
       
    43         IMPORT_C static CCalenStatusPaneUtils* NewL( CEikStatusPane* aStatusPane );
       
    44 		
       
    45 		/**
       
    46 		 * @brief Virtual destructor
       
    47 		 */
       
    48         IMPORT_C virtual ~CCalenStatusPaneUtils();
       
    49 
       
    50     public:
       
    51 	
       
    52 		/**
       
    53 		 * @brief Sets the title for the status pane
       
    54 		 *
       
    55 		 * @param aText The text to be set, of type TDes
       
    56 		 */
       
    57         IMPORT_C void SetTitleTextL( TDes& aText );
       
    58         
       
    59 		/**
       
    60 		 * @brief Sets the title for the status pane
       
    61 		 *
       
    62 		 * @param aText The text to be set, of type HBufC
       
    63 		 */
       
    64         IMPORT_C void SetTitleText( HBufC* aText );
       
    65         
       
    66 		/**
       
    67 		 * @brief Sets if the title text has to be underlined or not
       
    68 		 *
       
    69 		 * @param aUnderline ETrue if the text has to be underlined, EFalse otherwise
       
    70 		 */
       
    71         IMPORT_C void UnderLineTitleText( TBool aUnderline );
       
    72         
       
    73 		/**
       
    74 		 * @brief Sets the current day in the navi pane 
       
    75 		 * and returns the decorator that can be set to the navi pane control
       
    76 		 *
       
    77 		 * @param aActiveDay The day to be displayed in the navi pane
       
    78 		 * @return CAknNavigationDecorator* The navi pane decorator
       
    79 		 */
       
    80         IMPORT_C CAknNavigationDecorator* ShowNaviPaneL( const TTime& aActiveDay );
       
    81 
       
    82 		/**
       
    83 		 * @brief Hides the navi pane
       
    84 		 */
       
    85         IMPORT_C void HideNaviPane();
       
    86         
       
    87 		/**
       
    88 		 * @brief Gets the month name in aName, based on the active time
       
    89 		 *
       
    90 		 * @param aName The month name
       
    91 		 * @param aTime The active time
       
    92 		 */
       
    93         IMPORT_C void MonthNameByActiveTime( TDes& aName, const TTime& aTime );
       
    94         
       
    95 		/**
       
    96 		 * @brief Gets the day name in aName, based on the active time
       
    97 		 *
       
    98 		 * @param aName The day name
       
    99 		 * @param aTime The active time
       
   100 		 */
       
   101         IMPORT_C void DayNameByActiveTime( TDes& aName, const TTime& aTime );
       
   102         
       
   103 		/**
       
   104 		 * @brief Returns the week name based on the active time
       
   105 		 *
       
   106 		 * @param aTime The active time
       
   107 		 * @param aDayFormat The day of the week
       
   108 		 * @param aType The calendar week title
       
   109 		 * @return HBufC* The week name
       
   110 		 */
       
   111         IMPORT_C HBufC* WeekNameByActiveTimeL( const TTime& aTime, TDay aDayFormat, TCalenWeekTitle aType );
       
   112 
       
   113 		/**
       
   114 		 * @brief Refreshes the status pane
       
   115 		 */
       
   116         IMPORT_C void RefreshStatusPane();
       
   117 		
       
   118     private:
       
   119 	
       
   120 		/**
       
   121 		 * @brief Default C++ constructor. Hidden, use NewL instead
       
   122 		 */
       
   123         CCalenStatusPaneUtils();
       
   124 		
       
   125 		/**
       
   126 		 * @brief Second phase constructor
       
   127 		 *
       
   128 		 * @param aStatusPane The status pane
       
   129 		 */
       
   130         void ConstructL( CEikStatusPane* aStatusPane );
       
   131             
       
   132     private:		// Data 
       
   133         
       
   134 		/**
       
   135 		 * @var iStatusPaneUtils
       
   136 		 *
       
   137 		 * @brief The pointer to the actual implementation
       
   138 		 */
       
   139         CCalenStatusPaneUtilsImpl*		iStatusPaneUtils;
       
   140     };
       
   141 
       
   142 // End of file