mpx/mpxviewframeworkqt/tsrc/simpleviewpluginsrc/simpleviewplugin.cpp
changeset 64 92dbd2a406d9
equal deleted inserted replaced
61:3b098142db83 64:92dbd2a406d9
       
     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: 
       
    15 *
       
    16 */
       
    17 
       
    18 #include "simpleviewplugin.h"
       
    19 #include "simpleview.h"
       
    20 
       
    21 #include <xqplugin.h>
       
    22 
       
    23 /*
       
    24 #ifndef SIMPLE_VIEW_NO
       
    25 #define SIMPLE_VIEW_NO 0;
       
    26 #endif
       
    27 */
       
    28 
       
    29 SimpleViewPlugin::SimpleViewPlugin() : MpxViewPlugin(), viewInstance(0)
       
    30 {
       
    31 }
       
    32     
       
    33 SimpleViewPlugin::~SimpleViewPlugin()
       
    34 {
       
    35     delete viewInstance;
       
    36 }
       
    37 
       
    38 MpxViewPlugin *SimpleViewPlugin::viewPlugin()
       
    39 {
       
    40     return this;
       
    41 }
       
    42 
       
    43 void SimpleViewPlugin::createView()  
       
    44 {
       
    45 }
       
    46 
       
    47 void SimpleViewPlugin::destroyView() 
       
    48 {
       
    49 }
       
    50 
       
    51 void SimpleViewPlugin::activateView()
       
    52 {
       
    53 }
       
    54 
       
    55 void SimpleViewPlugin::deactivateView()
       
    56 {
       
    57 }
       
    58 
       
    59 QGraphicsWidget* SimpleViewPlugin::getView()
       
    60 {
       
    61     if (viewInstance==0) {
       
    62         viewInstance = new SimpleView(QString("Simpleview#%1").arg(SIMPLE_VIEW_NO));
       
    63     }
       
    64     return viewInstance;
       
    65 }
       
    66 
       
    67 void SimpleViewPlugin::orientationChange(Qt::Orientation orientation)
       
    68 {
       
    69 }
       
    70 
       
    71 void SimpleViewPlugin::back()
       
    72 {
       
    73 }
       
    74 
       
    75 XQ_EXPORT_PLUGIN2(SVIEW_PLUGIN_ID, SimpleViewPlugin);