photosgallery/viewframework/plugins/metadataviewplugin/src/glxmetadataviewplugin.cpp
changeset 0 4e91876724a2
equal deleted inserted replaced
-1:000000000000 0:4e91876724a2
       
     1 /*
       
     2 * Copyright (c) 2008-2009 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 : Implementation of metadata view plugin
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 
       
    20 // INCLUDE FILES
       
    21 
       
    22 #include "glxmetadataviewplugin.h"
       
    23 
       
    24 #include <glxcommandhandlerback.h>                     // For CGlxCommandHandlerBack
       
    25 #include <glxcommandhandlerhelp.h>
       
    26 #include <mpxcollectionpath.h>
       
    27 #include <mpxcollectionutility.h>
       
    28 
       
    29 #include "glxmetadataview.h"
       
    30 
       
    31 // ======== MEMBER FUNCTIONS ========
       
    32 
       
    33 // ---------------------------------------------------------------------------
       
    34 // C++ default constructor can NOT contain any code, that
       
    35 // might leave.
       
    36 // ---------------------------------------------------------------------------
       
    37 //
       
    38 CGlxMetadataViewPlugin::CGlxMetadataViewPlugin()
       
    39     {
       
    40     // Do nothing
       
    41     }
       
    42 
       
    43 // ---------------------------------------------------------------------------
       
    44 // Symbian 2nd phase constructor can leave.
       
    45 // ---------------------------------------------------------------------------
       
    46 //
       
    47 void CGlxMetadataViewPlugin::ConstructL()
       
    48     {
       
    49     // Do nothing
       
    50     }
       
    51 
       
    52 // ---------------------------------------------------------------------------
       
    53 // Two-phased constructor.
       
    54 // ---------------------------------------------------------------------------
       
    55 //
       
    56 CGlxMetadataViewPlugin* CGlxMetadataViewPlugin::NewL()
       
    57     {
       
    58     CGlxMetadataViewPlugin* self = new ( ELeave ) CGlxMetadataViewPlugin();
       
    59     CleanupStack::PushL( self );
       
    60     self->ConstructL();
       
    61     CleanupStack::Pop( self );
       
    62     return self;
       
    63     }
       
    64 
       
    65 // ---------------------------------------------------------------------------
       
    66 // Destructor
       
    67 // ---------------------------------------------------------------------------
       
    68 //
       
    69 CGlxMetadataViewPlugin::~CGlxMetadataViewPlugin()
       
    70     {
       
    71     // Do nothing
       
    72     }
       
    73 
       
    74 // ---------------------------------------------------------------------------
       
    75 // From CMPXAknViewPlugin
       
    76 // Construct Avkon view.
       
    77 // ---------------------------------------------------------------------------
       
    78 //
       
    79 CAknView* CGlxMetadataViewPlugin::ConstructViewLC()
       
    80     {
       
    81     /*Create view it self medialist provider ? */   
       
    82 	CGlxMetadataView* view = CGlxMetadataView::NewLC(NULL);    
       
    83 	
       
    84 	// add command handlers
       
    85 	view->AddCommandHandlerL(CGlxCommandHandlerBack::NewPreviousViewCommandHandlerL(view));
       
    86 	
       
    87 	TGlxHelpContext helpInfo;
       
    88 	helpInfo.iBrowseContext = LGAL_HLP_DETAILS_VIEW;
       
    89 	view->AddCommandHandlerL(CGlxCommandHandlerHelp::NewL(helpInfo)); 
       
    90     
       
    91     return view;
       
    92     }
       
    93 
       
    94 //  End of File