author | mickeyl <mickeyl> | 2003-11-20 01:31:27 (UTC) |
---|---|---|
committer | mickeyl <mickeyl> | 2003-11-20 01:31:27 (UTC) |
commit | ae9e1ed9cc9e65c1ffb28f3b75ff499e18c6b31a (patch) (unidiff) | |
tree | eb25cce124b37363bbd3b7b757d2c92dc94bee19 /core/launcher/launcher.cpp | |
parent | d8c2766507a807c72a350bf73c2908e4fa021262 (diff) | |
download | opie-ae9e1ed9cc9e65c1ffb28f3b75ff499e18c6b31a.zip opie-ae9e1ed9cc9e65c1ffb28f3b75ff499e18c6b31a.tar.gz opie-ae9e1ed9cc9e65c1ffb28f3b75ff499e18c6b31a.tar.bz2 |
rework optional doc-tab patch to be less intrusive and more sane
-rw-r--r-- | core/launcher/launcher.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/core/launcher/launcher.cpp b/core/launcher/launcher.cpp index b312672..344cd46 100644 --- a/core/launcher/launcher.cpp +++ b/core/launcher/launcher.cpp | |||
@@ -152,6 +152,7 @@ void LauncherTabWidget::createDocLoadingWidget() | |||
152 | textLabel->setText( tr( "<b>The Documents Tab<p>has been disabled.<p>" | 152 | textLabel->setText( tr( "<b>The Documents Tab<p>has been disabled.<p>" |
153 | "Use Settings->Launcher->DocTab<p>to reenable it.</b></center>" ) ); | 153 | "Use Settings->Launcher->DocTab<p>to reenable it.</b></center>" ) ); |
154 | docLoadingWidgetProgress->hide(); | 154 | docLoadingWidgetProgress->hide(); |
155 | docLoadingWidgetEnabled = true; | ||
155 | } | 156 | } |
156 | 157 | ||
157 | QWidget *space2 = new QWidget( docLoadingVBox ); | 158 | QWidget *space2 = new QWidget( docLoadingVBox ); |
@@ -501,6 +502,13 @@ Launcher::~Launcher() | |||
501 | destroyGUI(); | 502 | destroyGUI(); |
502 | } | 503 | } |
503 | 504 | ||
505 | bool Launcher::requiresDocuments() const | ||
506 | { | ||
507 | Config cfg( "Launcher" ); | ||
508 | cfg.setGroup( "DocTab" ); | ||
509 | return cfg.readBoolEntry( "Enable", true ); | ||
510 | } | ||
511 | |||
504 | void Launcher::makeVisible() | 512 | void Launcher::makeVisible() |
505 | { | 513 | { |
506 | showMaximized(); | 514 | showMaximized(); |
@@ -749,14 +757,6 @@ void Launcher::applicationScanningProgress( int percent ) | |||
749 | 757 | ||
750 | void Launcher::documentScanningProgress( int percent ) | 758 | void Launcher::documentScanningProgress( int percent ) |
751 | { | 759 | { |
752 | if ( !docTabEnabled ) | ||
753 | { | ||
754 | qDebug( "Launcher: document tab disabled!" ); | ||
755 | tabs->setLoadingProgress( 100 ); | ||
756 | tabs->setLoadingWidgetEnabled( TRUE ); | ||
757 | return; | ||
758 | } | ||
759 | |||
760 | switch ( percent ) { | 760 | switch ( percent ) { |
761 | case 0: { | 761 | case 0: { |
762 | tabs->setLoadingProgress( 0 ); | 762 | tabs->setLoadingProgress( 0 ); |