calendarwidgetplugin/src/calendarwidgetplugin.cpp
changeset 0 db1bf15cefff
equal deleted inserted replaced
-1:000000000000 0:db1bf15cefff
       
     1 /*
       
     2 * Copyright (c) 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:  Homescreen widget plugin
       
    15 *
       
    16 */
       
    17 
       
    18 // System includes
       
    19 #include <qserviceinterfacedescriptor.h>
       
    20 #include <qabstractsecuritysession.h>
       
    21 #include <qservicecontext.h>
       
    22 
       
    23 // User includes
       
    24 #include "calendarwidgetplugin.h"
       
    25 #include "calendarwidget.h"
       
    26 
       
    27 // ======== MEMBER FUNCTIONS ========
       
    28 
       
    29 /*!
       
    30     ?Qt_style_documentation
       
    31 */
       
    32 QObject *CalendarWidgetPlugin::createInstance(const QServiceInterfaceDescriptor &descriptor,
       
    33                                                QServiceContext *context,
       
    34                                                QAbstractSecuritySession *session)
       
    35 {
       
    36     Q_UNUSED(context);
       
    37     Q_UNUSED(session);
       
    38 
       
    39     if (descriptor.interfaceName() == QLatin1String("com.nokia.symbian.IHomeScreenWidget")) {
       
    40         return new CalendarWidget();
       
    41     } else {
       
    42         return 0;
       
    43     }
       
    44 }
       
    45 
       
    46 Q_EXPORT_PLUGIN2(calendarwidgetplugin, CalendarWidgetPlugin)
       
    47