homescreenapp/stateplugins/hshomescreenstateplugin/tsrc/t_hshomescreenstateplugin/inc/testwidget.h
changeset 96 458d8c8d9580
equal deleted inserted replaced
92:6727c5d0afc7 96:458d8c8d9580
       
     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 #ifndef HOMESCREEN_TEST_TESTWIDGET_H
       
    19 #define HOMESCREEN_TEST_TESTWIDGET_H
       
    20 
       
    21 #include <HbWidget>
       
    22 
       
    23 class TestWidget : public HbWidget
       
    24 {
       
    25     Q_OBJECT
       
    26 
       
    27 public:
       
    28     TestWidget(QGraphicsItem *parent = 0, Qt::WindowFlags flags = 0);
       
    29     ~TestWidget();
       
    30 
       
    31 signals:
       
    32     void finished();
       
    33 
       
    34 public slots:
       
    35     void onInitialize();
       
    36     void onShow();
       
    37     void onHide();
       
    38 
       
    39 public:
       
    40     QRectF boundingRect() const;
       
    41     QPainterPath shape() const;
       
    42     void setSucceeded() { emit finished(); }
       
    43 
       
    44 protected:
       
    45     void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget);
       
    46 
       
    47 private:
       
    48     friend class HomeScreenStatePluginTest;
       
    49 };
       
    50 
       
    51 #endif