-rw-r--r-- | libopie2/opieui/big-screen/owidgetstack.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/libopie2/opieui/big-screen/owidgetstack.cpp b/libopie2/opieui/big-screen/owidgetstack.cpp index 00194b4..ac46cca 100644 --- a/libopie2/opieui/big-screen/owidgetstack.cpp +++ b/libopie2/opieui/big-screen/owidgetstack.cpp @@ -308,9 +308,9 @@ void OWidgetStack::hideWidget( QWidget* wid) { raiseWidget( wid ); } -bool OWidgetStack::eventFilter( QObject* obj, QEvent* e) { +bool OWidgetStack::eventFilter( QObject*, QEvent* e) { if ( e->type() == QEvent::Resize && !m_forced ) { QResizeEvent *res = static_cast<QResizeEvent*>( e ); QSize size = res->size(); if ( size.width() >= mode_size ) @@ -387,8 +387,10 @@ void OWidgetStack::switchStack() { } m_mode = SmallScreen; m_stack = new QWidgetStack(this); + m_stack->setGeometry( frameRect() ); + m_stack->show(); connect(m_stack, SIGNAL(aboutToShow(QWidget*) ), this, SIGNAL(aboutToShow(QWidget*) ) ); connect(m_stack, SIGNAL(aboutToShow(int) ), @@ -401,8 +403,11 @@ void OWidgetStack::switchStack() { QMap<int, QWidget*>::Iterator it = m_list.begin(); for ( ; it != m_list.end(); ++it ) m_stack->addWidget( it.data(), it.key() ); + if ( m_mWidget ) + m_stack->raiseWidget( m_mWidget ); + } /* |