Diffstat (limited to 'noncore/graphics/opie-eye/gui/mainwindow.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | noncore/graphics/opie-eye/gui/mainwindow.cpp | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/noncore/graphics/opie-eye/gui/mainwindow.cpp b/noncore/graphics/opie-eye/gui/mainwindow.cpp index 5ba4c8e..4852bf6 100644 --- a/noncore/graphics/opie-eye/gui/mainwindow.cpp +++ b/noncore/graphics/opie-eye/gui/mainwindow.cpp | |||
@@ -105,21 +105,20 @@ PMainWindow::PMainWindow(QWidget* wid, const char* name, WFlags style) | |||
105 | prevButton = new QToolButton(bar); | 105 | prevButton = new QToolButton(bar); |
106 | prevButton->setIconSet( Resource::loadIconSet( "back" ) ); | 106 | prevButton->setIconSet( Resource::loadIconSet( "back" ) ); |
107 | connect(prevButton,SIGNAL(clicked()),m_view,SLOT(slotShowPrev())); | 107 | connect(prevButton,SIGNAL(clicked()),m_view,SLOT(slotShowPrev())); |
108 | prevButton->hide(); | ||
109 | 108 | ||
110 | nextButton = new QToolButton(bar); | 109 | nextButton = new QToolButton(bar); |
111 | nextButton->setIconSet( Resource::loadIconSet( "forward" ) ); | 110 | nextButton->setIconSet( Resource::loadIconSet( "forward" ) ); |
112 | connect(nextButton,SIGNAL(clicked()),m_view,SLOT(slotShowNext())); | 111 | connect(nextButton,SIGNAL(clicked()),m_view,SLOT(slotShowNext())); |
113 | nextButton->hide(); | ||
114 | 112 | ||
115 | rotateButton = new QToolButton(bar); | 113 | rotateButton = new QToolButton(bar); |
116 | rotateButton->setIconSet( Resource::loadIconSet( "rotate" ) ); | 114 | rotateButton->setIconSet( Resource::loadIconSet( "rotate" ) ); |
117 | rotateButton->setToggleButton(true); | 115 | rotateButton->setToggleButton(true); |
118 | 116 | ||
119 | odebug << "Mode = " << m_stack->mode() << oendl; | ||
120 | if (m_stack->mode() == Opie::Ui::OWidgetStack::SmallScreen) { | 117 | if (m_stack->mode() == Opie::Ui::OWidgetStack::SmallScreen) { |
121 | rotateButton->setOn(true); | 118 | rotateButton->setOn(true); |
122 | autoRotate = true; | 119 | autoRotate = true; |
120 | prevButton->hide(); | ||
121 | nextButton->hide(); | ||
123 | } else { | 122 | } else { |
124 | rotateButton->setOn(false); | 123 | rotateButton->setOn(false); |
125 | autoRotate = false; | 124 | autoRotate = false; |
@@ -299,11 +298,13 @@ void PMainWindow::slotShowInfo( const QString& inf ) { | |||
299 | initInfo(); | 298 | initInfo(); |
300 | } | 299 | } |
301 | m_info->setPath( inf ); | 300 | m_info->setPath( inf ); |
301 | if (m_stack->mode() == Opie::Ui::OWidgetStack::SmallScreen) { | ||
302 | prevButton->hide(); | 302 | prevButton->hide(); |
303 | nextButton->hide(); | 303 | nextButton->hide(); |
304 | upButton->hide(); | 304 | upButton->hide(); |
305 | fsButton->hide(); | 305 | fsButton->hide(); |
306 | viewModeButton->hide(); | 306 | viewModeButton->hide(); |
307 | } | ||
307 | m_stack->raiseWidget( ImageInfo ); | 308 | m_stack->raiseWidget( ImageInfo ); |
308 | } | 309 | } |
309 | 310 | ||
@@ -312,11 +313,13 @@ void PMainWindow::slotDisplay( const QString& inf ) { | |||
312 | initDisp(); | 313 | initDisp(); |
313 | } | 314 | } |
314 | m_disp->setImage( inf ); | 315 | m_disp->setImage( inf ); |
316 | if (m_stack->mode() == Opie::Ui::OWidgetStack::SmallScreen) { | ||
315 | prevButton->show(); | 317 | prevButton->show(); |
316 | nextButton->show(); | 318 | nextButton->show(); |
317 | upButton->hide(); | 319 | upButton->hide(); |
318 | fsButton->hide(); | 320 | fsButton->hide(); |
319 | viewModeButton->hide(); | 321 | viewModeButton->hide(); |
322 | } | ||
320 | m_stack->raiseWidget( ImageDisplay ); | 323 | m_stack->raiseWidget( ImageDisplay ); |
321 | } | 324 | } |
322 | 325 | ||
@@ -341,11 +344,13 @@ void PMainWindow::closeEvent( QCloseEvent* ev ) { | |||
341 | } | 344 | } |
342 | 345 | ||
343 | void PMainWindow::raiseIconView() { | 346 | void PMainWindow::raiseIconView() { |
347 | if (m_stack->mode() == Opie::Ui::OWidgetStack::SmallScreen) { | ||
344 | prevButton->hide(); | 348 | prevButton->hide(); |
345 | nextButton->hide(); | 349 | nextButton->hide(); |
346 | upButton->show(); | 350 | upButton->show(); |
347 | fsButton->show(); | 351 | fsButton->show(); |
348 | viewModeButton->show(); | 352 | viewModeButton->show(); |
353 | } | ||
349 | m_stack->raiseWidget( IconView ); | 354 | m_stack->raiseWidget( IconView ); |
350 | } | 355 | } |
351 | 356 | ||