mpviewplugins/mpmediawallviewplugin/tsrc/unittest_mpmediawallview/stub/inc/hbmessagebox.h
changeset 55 f3930dda3342
equal deleted inserted replaced
51:560ce2306a17 55:f3930dda3342
       
     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: hbmessagebox stub for testing mpmediawallview
       
    15 *
       
    16 */
       
    17 
       
    18 #ifndef HBMESSAGEBOX_H
       
    19 #define HBMESSAGEBOX_H
       
    20 
       
    21 #include <QObject>
       
    22 #include <qglobal.h>
       
    23 #include <QMetaObject>
       
    24 #include <hbicon.h>
       
    25 
       
    26 //  FORWARD DECLARATIONS
       
    27 class QGraphicsItem;
       
    28 class HbIcon;
       
    29 
       
    30 /*!
       
    31      Stub HbMessageBox class.
       
    32  */
       
    33 class HbMessageBox : public QObject
       
    34 {
       
    35     Q_OBJECT
       
    36 
       
    37 public: // Data types
       
    38 
       
    39     enum MessageBoxType {
       
    40         MessageTypeNone,
       
    41         MessageTypeInformation,
       
    42         MessageTypeQuestion,
       
    43         MessageTypeWarning
       
    44     };
       
    45 
       
    46 public:
       
    47 
       
    48     HbMessageBox(const QString &text, MessageBoxType type = MessageTypeNone, QGraphicsItem *parent = 0)
       
    49     {
       
    50         Q_UNUSED(text);
       
    51         Q_UNUSED(type);
       
    52         Q_UNUSED(parent);
       
    53         mMessageDisplayed = false;
       
    54     }
       
    55 
       
    56     ~HbMessageBox()
       
    57     {
       
    58     }
       
    59 
       
    60     void setAttribute(Qt::WidgetAttribute att, bool on = true)
       
    61     {
       
    62         Q_UNUSED(att);
       
    63         Q_UNUSED(on);
       
    64     }
       
    65 
       
    66     void setIcon(const HbIcon &icon)
       
    67     {
       
    68         Q_UNUSED(icon);
       
    69     }
       
    70 
       
    71     void show()
       
    72     {
       
    73         mMessageDisplayed = true;
       
    74     }
       
    75 
       
    76 public:
       
    77     bool    mMessageDisplayed;
       
    78 };
       
    79 
       
    80 #endif // HBMESSAGEBOX_H
       
    81