-rw-r--r-- | noncore/graphics/opie-eye/gui/imageview.cpp | 3 | ||||
-rw-r--r-- | noncore/graphics/opie-eye/gui/mainwindow.cpp | 24 |
2 files changed, 12 insertions, 15 deletions
diff --git a/noncore/graphics/opie-eye/gui/imageview.cpp b/noncore/graphics/opie-eye/gui/imageview.cpp index be58c72..ebdfc60 100644 --- a/noncore/graphics/opie-eye/gui/imageview.cpp +++ b/noncore/graphics/opie-eye/gui/imageview.cpp | |||
@@ -37,8 +37,9 @@ void ImageView::setMenuActions(QActionGroup*hGroup,QActionGroup*nextprevGroup, Q | |||
37 | } | 37 | } |
38 | 38 | ||
39 | ImageView::~ImageView() | 39 | ImageView::~ImageView() |
40 | { | 40 | { |
41 | odebug << "Destructor imageview" << oendl; | ||
41 | delete m_viewManager; | 42 | delete m_viewManager; |
42 | } | 43 | } |
43 | 44 | ||
44 | Opie::Core::OKeyConfigManager* ImageView::manager() | 45 | Opie::Core::OKeyConfigManager* ImageView::manager() |
@@ -76,13 +77,15 @@ void ImageView::nextSlide() | |||
76 | { | 77 | { |
77 | if (!m_slideTimer) { | 78 | if (!m_slideTimer) { |
78 | return; | 79 | return; |
79 | } | 80 | } |
81 | #if 0 | ||
80 | if (isHidden()) { | 82 | if (isHidden()) { |
81 | delete m_slideTimer; | 83 | delete m_slideTimer; |
82 | m_slideTimer = 0; | 84 | m_slideTimer = 0; |
83 | return; | 85 | return; |
84 | } | 86 | } |
87 | #endif | ||
85 | emit dispNext(); | 88 | emit dispNext(); |
86 | m_slideTimer->start(m_slideValue*1000,true); | 89 | m_slideTimer->start(m_slideValue*1000,true); |
87 | } | 90 | } |
88 | void ImageView::initKeys() | 91 | void ImageView::initKeys() |
diff --git a/noncore/graphics/opie-eye/gui/mainwindow.cpp b/noncore/graphics/opie-eye/gui/mainwindow.cpp index 5eb065f..6660eb2 100644 --- a/noncore/graphics/opie-eye/gui/mainwindow.cpp +++ b/noncore/graphics/opie-eye/gui/mainwindow.cpp | |||
@@ -213,18 +213,12 @@ void PMainWindow::slotConfig() { | |||
213 | delete keyWid; | 213 | delete keyWid; |
214 | 214 | ||
215 | m_stack->raiseWidget(w); | 215 | m_stack->raiseWidget(w); |
216 | if (remdisp) { | 216 | if (remdisp) { |
217 | m_disp->disconnect(this, SLOT(slotReturn())); | 217 | m_disp->hide(); |
218 | m_disp->setDestructiveClose(); | ||
219 | m_stack->removeWidget(m_disp); | ||
220 | m_disp = 0; | ||
221 | } | 218 | } |
222 | if (reminfo) { | 219 | if (reminfo) { |
223 | m_info->disconnect(this, SLOT(slotReturn())); | 220 | m_info->hide(); |
224 | m_info->setDestructiveClose(); | ||
225 | m_stack->removeWidget(m_info); | ||
226 | m_info = 0; | ||
227 | } | 221 | } |
228 | } | 222 | } |
229 | 223 | ||
230 | /* | 224 | /* |
@@ -287,16 +281,11 @@ void PMainWindow::slotFullScreenButton(bool current) | |||
287 | if (autoSave) { | 281 | if (autoSave) { |
288 | m_cfg->writeEntry("fullscreen",current); | 282 | m_cfg->writeEntry("fullscreen",current); |
289 | } | 283 | } |
290 | if (!m_disp) return; | 284 | if (!m_disp) return; |
291 | 285 | if (m_disp->isVisible()) { | |
292 | if (m_disp->isHidden()) { | 286 | setupViewWindow(current, true); |
293 | /* it must get some setups for switch we can just do if the window is visible. | ||
294 | so we must delete the imageview window and re-create it when displaying new | ||
295 | image */ | ||
296 | return; | ||
297 | } | 287 | } |
298 | setupViewWindow(current, true); | ||
299 | } | 288 | } |
300 | 289 | ||
301 | void PMainWindow::setupViewWindow(bool current, bool forceDisplay) | 290 | void PMainWindow::setupViewWindow(bool current, bool forceDisplay) |
302 | { | 291 | { |
@@ -368,9 +357,11 @@ void PMainWindow::slotShowInfo( const QString& inf ) { | |||
368 | m_stack->raiseWidget( ImageInfo ); | 357 | m_stack->raiseWidget( ImageInfo ); |
369 | } | 358 | } |
370 | 359 | ||
371 | void PMainWindow::slotDisplay( const QString& inf ) { | 360 | void PMainWindow::slotDisplay( const QString& inf ) { |
361 | bool nwindow = false; | ||
372 | if ( !m_disp ) { | 362 | if ( !m_disp ) { |
363 | nwindow = true; | ||
373 | initDisp(); | 364 | initDisp(); |
374 | } | 365 | } |
375 | m_disp->setImage( inf ); | 366 | m_disp->setImage( inf ); |
376 | if (m_stack->mode() == Opie::Ui::OWidgetStack::SmallScreen) { | 367 | if (m_stack->mode() == Opie::Ui::OWidgetStack::SmallScreen) { |
@@ -384,8 +375,11 @@ void PMainWindow::slotDisplay( const QString& inf ) { | |||
384 | m_aStartSlide->setEnabled(false); | 375 | m_aStartSlide->setEnabled(false); |
385 | fsButton->hide(); | 376 | fsButton->hide(); |
386 | } | 377 | } |
387 | } | 378 | } |
379 | if (!nwindow && m_disp->fullScreen()!=m_aFullScreen->isOn()) { | ||
380 | slotFullScreenToggled(m_aFullScreen->isOn()); | ||
381 | } | ||
388 | if (m_disp->fullScreen()) { | 382 | if (m_disp->fullScreen()) { |
389 | qwsDisplay()->requestFocus( m_disp->winId(), TRUE); | 383 | qwsDisplay()->requestFocus( m_disp->winId(), TRUE); |
390 | } else { | 384 | } else { |
391 | m_stack->raiseWidget( ImageDisplay ); | 385 | m_stack->raiseWidget( ImageDisplay ); |