summaryrefslogtreecommitdiff
path: root/core/launcher/documentlist.cpp
authormickeyl <mickeyl>2003-11-17 15:16:13 (UTC)
committer mickeyl <mickeyl>2003-11-17 15:16:13 (UTC)
commitc4a6e9c529ea6bcb1c9a42fee33a70300f116c98 (patch) (side-by-side diff)
tree1ee68a2035b0218ba99662db1dff4c4067064cde /core/launcher/documentlist.cpp
parent725e2723291fe1d71ca68cb59cec83428d40b8af (diff)
downloadopie-c4a6e9c529ea6bcb1c9a42fee33a70300f116c98.zip
opie-c4a6e9c529ea6bcb1c9a42fee33a70300f116c98.tar.gz
opie-c4a6e9c529ea6bcb1c9a42fee33a70300f116c98.tar.bz2
This patch makes the famous Documents Tab customizably optional.
Note that the document tab is so tight coupled to the rest of the launcher that it proved impossible for me to remove the tab as is. However I could make all the scanning and the displaying optional. The customization can be done via the launcher settings applications - a new doc tab category has been added. Further customization can be added to that tab. I also added a doc tab settings application for use with the "first usage wizard"
Diffstat (limited to 'core/launcher/documentlist.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--core/launcher/documentlist.cpp17
1 files changed, 16 insertions, 1 deletions
diff --git a/core/launcher/documentlist.cpp b/core/launcher/documentlist.cpp
index 7f9366e..dcea4b9 100644
--- a/core/launcher/documentlist.cpp
+++ b/core/launcher/documentlist.cpp
@@ -21,6 +21,7 @@
#include "serverinterface.h"
#include "launcherglobal.h"
+#include <qtopia/config.h>
#include <qtopia/mimetype.h>
#include <qtopia/resource.h>
#include <qtopia/global.h>
@@ -104,7 +105,21 @@ DocumentList::DocumentList( ServerInterface *serverGui, bool scanDocs,
void DocumentList::startInitialScan()
{
reloadAppLnks();
- reloadDocLnks();
+
+ Config cfg( "Launcher" );
+ cfg.setGroup( "DocTab" );
+ bool docTabEnabled = cfg.readBoolEntry( "Enable", true );
+ if ( docTabEnabled )
+ reloadDocLnks();
+ else
+ {
+ if ( d->sendDocLnks && d->serverGui )
+ {
+ d->serverGui->documentScanningProgress( 0 );
+ d->serverGui->allDocumentsRemoved();
+ }
+ }
+
}
DocumentList::~DocumentList()