Home · All Namespaces · All Classes

StatusIndicatorMenuDropDownView Class Reference

#include <statusindicatormenudropdownview.h>

Inheritance diagram for StatusIndicatorMenuDropDownView:
Inheritance graph
[legend]
Collaboration diagram for StatusIndicatorMenuDropDownView:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 StatusIndicatorMenuDropDownView (StatusIndicatorMenu *controller)
virtual ~StatusIndicatorMenuDropDownView ()

Static Public Attributes

static const int VIEW_INITIALIZATION_DELAY = 30 * 1000
 Delay for the initialization of the view (in milliseconds).

Protected Member Functions

virtual void applyStyle ()
 REIMPLEMENTATION

Detailed Description

Definition at line 107 of file statusindicatormenudropdownview.h.


Constructor & Destructor Documentation

StatusIndicatorMenuDropDownView::StatusIndicatorMenuDropDownView ( StatusIndicatorMenu controller  ) 

Constructs a view for a notification area.

Parameters:
controller the controller of this StatusIndicatorMenuDropDownView

Definition at line 84 of file statusindicatormenudropdownview.cpp.

00084                                                                                                 :
00085     MSceneWindowView(controller),
00086     controller(controller),
00087     statusBar(new MStatusBar),
00088     settingsPluginsExtensionArea(NULL),
00089     statusIndicatorExtensionArea(NULL),
00090     pannableViewport(NULL),
00091     closeButtonOverlay(NULL),
00092     backgroundWidget(new MWidgetController)
00093 {
00094     // Show status bar
00095     controller->sceneManager()->appearSceneWindowNow(statusBar);
00096 
00097     // Create close button overlay
00098     closeButtonOverlay = createCloseButtonOverlay();
00099 
00100     // Create the pannable area background widget
00101     backgroundWidget->setView(new MWidgetView(backgroundWidget));
00102     backgroundWidget->setObjectName("StatusIndicatorMenuWindowBackground");
00103 
00104     connect(controller, SIGNAL(hideRequested()), this, SLOT(resetViewport()));
00105     connect(controller, SIGNAL(displayEntered()), SLOT(ensureIsViewable()));
00106 
00107     // Schedule the view to be initialized
00108     QTimer::singleShot(VIEW_INITIALIZATION_DELAY, this, SLOT(ensureIsViewable()));
00109 }

StatusIndicatorMenuDropDownView::~StatusIndicatorMenuDropDownView (  )  [virtual]

Destroys the notification area view.

Definition at line 112 of file statusindicatormenudropdownview.cpp.

00113 {
00114     delete backgroundWidget;
00115     delete statusBar;
00116     delete closeButtonOverlay;
00117     delete pannableViewport;
00118     delete topRowWidget;
00119 }


Member Function Documentation

void StatusIndicatorMenuDropDownView::applyStyle (  )  [protected, virtual]

REIMPLEMENTATION

Definition at line 309 of file statusindicatormenudropdownview.cpp.

00310 {
00311     MWidgetView::applyStyle();
00312 
00313     if (pannableViewport == NULL) {
00314         QGraphicsAnchorLayout *backgroundLayout = new QGraphicsAnchorLayout;
00315         backgroundLayout->setContentsMargins(0, 0, 0, 0);
00316         backgroundLayout->setSpacing(0);
00317         backgroundLayout->addCornerAnchors(backgroundWidget, Qt::TopLeftCorner, backgroundLayout, Qt::TopLeftCorner);
00318         backgroundLayout->setMaximumHeight(0);
00319 
00320         // Put all the stuff into the scene window layout
00321         pannableViewport = createPannableArea();
00322         topRowWidget = createTopRow();
00323         QGraphicsLinearLayout *layout = new QGraphicsLinearLayout(Qt::Vertical);
00324         layout->setContentsMargins(0, 0, 0, 0);
00325         layout->setSpacing(0);
00326         layout->addItem(topRowWidget);
00327         layout->addItem(backgroundLayout);
00328         layout->addItem(pannableViewport);
00329         controller->setLayout(layout);
00330     }
00331 }


Member Data Documentation

Delay for the initialization of the view (in milliseconds).

Definition at line 126 of file statusindicatormenudropdownview.h.


The documentation for this class was generated from the following files:

Copyright © 2010 Nokia Corporation Generated on Wed Nov 10 16:05:13 2010
Doxygen 1.6.1
MeeGo Touch