psln/PslnLibraryLoaders/inc/pslnwallpaperutilsloader.h
changeset 37 89c890c70182
parent 34 6b5204869ed5
child 45 667edd0b8678
equal deleted inserted replaced
34:6b5204869ed5 37:89c890c70182
     1 /*
       
     2 * Copyright (c) 2006-2007 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:  Loads AknsWallpaperUtils dynamically.
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 #ifndef C_PSLNWALLPAPERUTILSLOADER
       
    20 #define C_PSLNWALLPAPERUTILSLOADER
       
    21 
       
    22 #include <e32base.h>
       
    23 #include <coemain.h>
       
    24 
       
    25 /**
       
    26 *  Interface class for wallpaper utils library.
       
    27 *  
       
    28 *  @lib PslnWallpaperUtilsLoader.lib
       
    29 *  @since Series 60 3.1
       
    30 */
       
    31 class MPslnWallpaperUtilsLoader
       
    32     {
       
    33     public:
       
    34         
       
    35         /**
       
    36         * Pure virtual method for setting Idle wallpaper.
       
    37         * @param aFilename filename of image.
       
    38         * @param aCoeEnv coe environment.
       
    39         * @param aWaitNoteTextResourceID wait note text if any.
       
    40         * @param aWaitNoteResourceID resource ID for wait note, if any.
       
    41         * @return error code, or KErrNone.
       
    42         */
       
    43         virtual TInt SetIdleWallpaper( 
       
    44             const TDesC& aFilename, 
       
    45             CCoeEnv* aCoeEnv, 
       
    46             TInt aWaitNoteTextResourceID = 0, 
       
    47             TInt aWaitNoteResourceID = 0 ) = 0;
       
    48 
       
    49     };
       
    50 
       
    51 /**
       
    52 *  This class is for dynamically loading AknsWallpaperUtils.dll that 
       
    53 *  enables setting of wallpaper.
       
    54 *
       
    55 *  @lib PslnWallpaperUtilsLoader.lib
       
    56 *  @since Series 60 3.1
       
    57 */
       
    58 class CPslnWallpaperUtilsLoader : public CBase, public MPslnWallpaperUtilsLoader
       
    59     {
       
    60 public:
       
    61     /**
       
    62     * Two-phased constructor.
       
    63     * @return new instance of CPslnWallpaperUtilsLoader.
       
    64     */
       
    65     static CPslnWallpaperUtilsLoader* NewL();
       
    66     
       
    67     /**
       
    68     * Destructor.
       
    69     */
       
    70     virtual ~CPslnWallpaperUtilsLoader();
       
    71 
       
    72     /**
       
    73     * Sets Idle wallpaper.
       
    74     * @param aFilename filename of image.
       
    75     * @param aCoeEnv coe environment.
       
    76     * @param aWaitNoteTextResourceID wait note text if any.
       
    77     * @param aWaitNoteResourceID resource ID for wait note, if any.
       
    78     * @return error code, or KErrNone.
       
    79     */
       
    80     TInt SetIdleWallpaper( 
       
    81         const TDesC& aFilename, 
       
    82         CCoeEnv* aCoeEnv, 
       
    83         TInt aWaitNoteTextResourceID = 0, 
       
    84         TInt aWaitNoteResourceID = 0 );
       
    85 
       
    86 private:
       
    87 
       
    88     /**
       
    89     * C++ default constructor.
       
    90     */
       
    91     CPslnWallpaperUtilsLoader();
       
    92 
       
    93     };
       
    94 
       
    95 // Environment gate function
       
    96 IMPORT_C TAny* GateFunction();
       
    97 
       
    98 #endif // C_PSLNWALLPAPERUTILSLOADER
       
    99             
       
   100 // End of File