author | mickeyl <mickeyl> | 2004-04-07 13:36:16 (UTC) |
---|---|---|
committer | mickeyl <mickeyl> | 2004-04-07 13:36:16 (UTC) |
commit | 4f1d28a25ce6180850c3d26bac9b638f0f25532b (patch) (unidiff) | |
tree | 59b4879b1065086c9a2e28f16f7d48540c8a9456 /core/launcher/launcher.cpp | |
parent | 8af35b63a277ec14dcc4a0a6ca5bbe228e276b98 (diff) | |
download | opie-4f1d28a25ce6180850c3d26bac9b638f0f25532b.zip opie-4f1d28a25ce6180850c3d26bac9b638f0f25532b.tar.gz opie-4f1d28a25ce6180850c3d26bac9b638f0f25532b.tar.bz2 |
use Opie debugging framework
-rw-r--r-- | core/launcher/launcher.cpp | 37 |
1 files changed, 17 insertions, 20 deletions
diff --git a/core/launcher/launcher.cpp b/core/launcher/launcher.cpp index 5d0c778..bf2287d 100644 --- a/core/launcher/launcher.cpp +++ b/core/launcher/launcher.cpp | |||
@@ -15,26 +15,38 @@ | |||
15 | ** | 15 | ** |
16 | ** Contact info@trolltech.com if any conditions of this licensing are | 16 | ** Contact info@trolltech.com if any conditions of this licensing are |
17 | ** not clear to you. | 17 | ** not clear to you. |
18 | ** | 18 | ** |
19 | **********************************************************************/ | 19 | **********************************************************************/ |
20 | 20 | ||
21 | #include "startmenu.h" | ||
22 | #include "taskbar.h" | ||
23 | #include "serverinterface.h" | ||
24 | #include "launcherview.h" | ||
25 | #include "launcher.h" | ||
26 | #include "server.h" | ||
27 | |||
28 | /* OPIE */ | ||
29 | #include <opie2/odebug.h> | ||
21 | #include <qtopia/global.h> | 30 | #include <qtopia/global.h> |
22 | #ifdef Q_WS_QWS | 31 | #ifdef Q_WS_QWS |
23 | #include <qtopia/qcopenvelope_qws.h> | 32 | #include <qtopia/qcopenvelope_qws.h> |
24 | #endif | 33 | #endif |
25 | #include <qtopia/resource.h> | 34 | #include <qtopia/resource.h> |
26 | #include <qtopia/applnk.h> | 35 | #include <qtopia/applnk.h> |
27 | #include <qtopia/config.h> | 36 | #include <qtopia/config.h> |
28 | #include <qtopia/qpeapplication.h> | 37 | #include <qtopia/qpeapplication.h> |
29 | #include <qtopia/mimetype.h> | 38 | #include <qtopia/mimetype.h> |
30 | #include <qtopia/private/categories.h> | 39 | #include <qtopia/private/categories.h> |
31 | //#include <qtopia/custom.h> | 40 | #define QTOPIA_INTERNAL_FSLP |
41 | #include <qtopia/lnkproperties.h> | ||
32 | 42 | ||
43 | /* QT */ | ||
33 | #include <qdir.h> | 44 | #include <qdir.h> |
34 | #ifdef Q_WS_QWS | 45 | #ifdef Q_WS_QWS |
46 | #include <qkeyboard_qws.h> | ||
35 | #include <qwindowsystem_qws.h> | 47 | #include <qwindowsystem_qws.h> |
36 | #endif | 48 | #endif |
37 | #include <qtimer.h> | 49 | #include <qtimer.h> |
38 | #include <qcombobox.h> | 50 | #include <qcombobox.h> |
39 | #include <qvbox.h> | 51 | #include <qvbox.h> |
40 | #include <qlayout.h> | 52 | #include <qlayout.h> |
@@ -47,37 +59,22 @@ | |||
47 | #include <qframe.h> | 59 | #include <qframe.h> |
48 | #include <qpainter.h> | 60 | #include <qpainter.h> |
49 | #include <qlabel.h> | 61 | #include <qlabel.h> |
50 | #include <qtextstream.h> | 62 | #include <qtextstream.h> |
51 | #include <qpopupmenu.h> | 63 | #include <qpopupmenu.h> |
52 | 64 | ||
53 | #include "startmenu.h" | 65 | /* STD */ |
54 | #include "taskbar.h" | ||
55 | |||
56 | #include "serverinterface.h" | ||
57 | #include "launcherview.h" | ||
58 | #include "launcher.h" | ||
59 | #include "server.h" | ||
60 | |||
61 | #define QTOPIA_INTERNAL_FSLP | ||
62 | #include <qtopia/lnkproperties.h> | ||
63 | #include <stdlib.h> | 66 | #include <stdlib.h> |
64 | #include <assert.h> | 67 | #include <assert.h> |
65 | |||
66 | #if defined(_OS_LINUX_) || defined(Q_OS_LINUX) | 68 | #if defined(_OS_LINUX_) || defined(Q_OS_LINUX) |
67 | #include <unistd.h> | 69 | #include <unistd.h> |
68 | #include <stdio.h> | 70 | #include <stdio.h> |
69 | #include <sys/vfs.h> | 71 | #include <sys/vfs.h> |
70 | #include <mntent.h> | 72 | #include <mntent.h> |
71 | #endif | 73 | #endif |
72 | 74 | ||
73 | #ifdef Q_WS_QWS | ||
74 | #include <qkeyboard_qws.h> | ||
75 | #include <qpe/lnkproperties.h> | ||
76 | #endif | ||
77 | |||
78 | 75 | ||
79 | static bool isVisibleWindow( int ); | 76 | static bool isVisibleWindow( int ); |
80 | //=========================================================================== | 77 | //=========================================================================== |
81 | 78 | ||
82 | LauncherTabWidget::LauncherTabWidget( Launcher* parent ) : | 79 | LauncherTabWidget::LauncherTabWidget( Launcher* parent ) : |
83 | QVBox( parent ), docview( 0 ) | 80 | QVBox( parent ), docview( 0 ) |
@@ -225,13 +222,13 @@ LauncherView* LauncherTabWidget::newView( const QString& id, const QPixmap& pm, | |||
225 | LauncherTab *tab = new LauncherTab( id, view, pm, label ); | 222 | LauncherTab *tab = new LauncherTab( id, view, pm, label ); |
226 | categoryBar->insertTab( tab, n-1 ); | 223 | categoryBar->insertTab( tab, n-1 ); |
227 | 224 | ||
228 | if ( id == "Documents" ) | 225 | if ( id == "Documents" ) |
229 | docview = view; | 226 | docview = view; |
230 | 227 | ||
231 | qDebug("inserting %s at %d", id.latin1(), n-1 ); | 228 | odebug << "inserting " << id << " at " << n-1 << "" << oendl; |
232 | 229 | ||
233 | Config cfg("Launcher"); | 230 | Config cfg("Launcher"); |
234 | setTabAppearance( tab, cfg ); | 231 | setTabAppearance( tab, cfg ); |
235 | 232 | ||
236 | cfg.setGroup( "GUI" ); | 233 | cfg.setGroup( "GUI" ); |
237 | view->setBusyIndicatorType( cfg.readEntry( "BusyType", QString::null ) ); | 234 | view->setBusyIndicatorType( cfg.readEntry( "BusyType", QString::null ) ); |
@@ -410,13 +407,13 @@ void LauncherTabWidget::launcherMessage( const QCString &msg, const QByteArray & | |||
410 | stream >> weight; | 407 | stream >> weight; |
411 | int italic; | 408 | int italic; |
412 | stream >> italic; | 409 | stream >> italic; |
413 | if ( view(id) ) { | 410 | if ( view(id) ) { |
414 | if ( !fam.isEmpty() ) { | 411 | if ( !fam.isEmpty() ) { |
415 | view(id)->setViewFont( QFont(fam, size, weight, italic!=0) ); | 412 | view(id)->setViewFont( QFont(fam, size, weight, italic!=0) ); |
416 | qDebug( "setFont: %s, %d, %d, %d", fam.latin1(), size, weight, italic ); | 413 | odebug << "setFont: " << fam << ", " << size << ", " << weight << ", " << italic << "" << oendl; |
417 | } else { | 414 | } else { |
418 | view(id)->clearViewFont(); | 415 | view(id)->clearViewFont(); |
419 | } | 416 | } |
420 | } | 417 | } |
421 | }else if ( msg == "setBusyIndicatorType(QString)" ) { | 418 | }else if ( msg == "setBusyIndicatorType(QString)" ) { |
422 | QString type; | 419 | QString type; |
@@ -681,13 +678,13 @@ void Launcher::applicationAdded( const QString& type, const AppLnk& app ) | |||
681 | void Launcher::applicationRemoved( const QString& type, const AppLnk& app ) | 678 | void Launcher::applicationRemoved( const QString& type, const AppLnk& app ) |
682 | { | 679 | { |
683 | LauncherView *view = tabs->view( type ); | 680 | LauncherView *view = tabs->view( type ); |
684 | if ( view ) | 681 | if ( view ) |
685 | view->removeLink( app.linkFile() ); | 682 | view->removeLink( app.linkFile() ); |
686 | else | 683 | else |
687 | qWarning("removeAppLnk: No view for %s!", type.latin1() ); | 684 | owarn << "removeAppLnk: No view for " << type << "!" << oendl; |
688 | } | 685 | } |
689 | 686 | ||
690 | void Launcher::allApplicationsRemoved() | 687 | void Launcher::allApplicationsRemoved() |
691 | { | 688 | { |
692 | MimeType::clear(); | 689 | MimeType::clear(); |
693 | for ( QStringList::ConstIterator it=ids.begin(); it!= ids.end(); ++it) | 690 | for ( QStringList::ConstIterator it=ids.begin(); it!= ids.end(); ++it) |