From 64d9b66f8f115b249a18b08d41eeb034cb5763d9 Mon Sep 17 00:00:00 2001 From: Akos Polster Date: Fri, 28 Jan 2011 22:09:02 +0100 Subject: [PATCH] Smoothen switch between full screen/normal view on Maemo. --- mainwindow.cpp | 8 ++++++-- widgets/listwindow.cpp | 2 +- widgets/mainbase.cpp | 2 ++ 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/mainwindow.cpp b/mainwindow.cpp index 583928e..4ab3b90 100755 --- a/mainwindow.cpp +++ b/mainwindow.cpp @@ -81,7 +81,7 @@ MainWindow::MainWindow(QWidget *parent): rotateAction = addToolBarAction(this, SLOT(rotate()), "rotate", tr("Rotate"), true); - // addToolBarSpace(); + addToolBarSpace(); fullScreenAction = addToolBarAction(this, SLOT(showBig()), "view-fullscreen", tr("Full screen"), true); @@ -198,7 +198,11 @@ void MainWindow::showBig() leaveBookView(); fullScreenWindow->takeBookView(view, prog, prev, next); +#ifdef Q_WS_MAEMO_5 + fullScreenWindow->raise(); +#else hide(); +#endif fullScreenWindow->showFullScreen(); } @@ -230,7 +234,7 @@ void MainWindow::rotate() void MainWindow::showDevTools() { - (new DevTools())->exec(); + (new DevTools(this))->exec(); } void MainWindow::showBookmarks() diff --git a/widgets/listwindow.cpp b/widgets/listwindow.cpp index 76a7819..5e6fa34 100644 --- a/widgets/listwindow.cpp +++ b/widgets/listwindow.cpp @@ -129,7 +129,7 @@ void ListWindow::addItemButton(const QString &title, QObject *receiver, Q_UNUSED(title); Q_UNUSED(receiver); Q_UNUSED(slot); - Q_UNUSED(iconPath); + Q_UNUSED(iconName); #else QAction *toolBarAction = addToolBarAction(receiver, slot, iconName, title, true); diff --git a/widgets/mainbase.cpp b/widgets/mainbase.cpp index c9a4d54..4694de2 100755 --- a/widgets/mainbase.cpp +++ b/widgets/mainbase.cpp @@ -92,10 +92,12 @@ QAction *MainBase::addToolBarAction(QObject *receiver, void MainBase::addToolBarSpace() { +#ifndef Q_OS_SYMBIAN addToolBar(); QFrame *frame = new QFrame(toolBar); frame->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Fixed); toolBar->addWidget(frame); +#endif } int MainBase::toolBarHeight() -- 1.7.9.5