summaryrefslogtreecommitdiff
authormickeyl <mickeyl>2004-04-07 13:36:16 (UTC)
committer mickeyl <mickeyl>2004-04-07 13:36:16 (UTC)
commit4f1d28a25ce6180850c3d26bac9b638f0f25532b (patch) (side-by-side diff)
tree59b4879b1065086c9a2e28f16f7d48540c8a9456
parent8af35b63a277ec14dcc4a0a6ca5bbe228e276b98 (diff)
downloadopie-4f1d28a25ce6180850c3d26bac9b638f0f25532b.zip
opie-4f1d28a25ce6180850c3d26bac9b638f0f25532b.tar.gz
opie-4f1d28a25ce6180850c3d26bac9b638f0f25532b.tar.bz2
use Opie debugging framework
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--core/launcher/applauncher.cpp83
-rw-r--r--core/launcher/documentlist.cpp46
-rw-r--r--core/launcher/firstuse.cpp44
-rw-r--r--core/launcher/inputmethods.cpp34
-rw-r--r--core/launcher/irserver.cpp16
-rw-r--r--core/launcher/launcher.cpp37
-rw-r--r--core/launcher/launcherview.cpp9
-rw-r--r--core/launcher/main.cpp42
-rw-r--r--core/launcher/packageslave.cpp26
-rw-r--r--core/launcher/qcopbridge.cpp23
-rw-r--r--core/launcher/qprocess.cpp14
-rw-r--r--core/launcher/qprocess_unix.cpp93
-rw-r--r--core/launcher/runningappbar.cpp24
-rw-r--r--core/launcher/screensaver.cpp2
-rw-r--r--core/launcher/server.cpp32
-rw-r--r--core/launcher/serverapp.cpp26
-rw-r--r--core/launcher/suspendmonitor.cpp2
-rw-r--r--core/launcher/systray.cpp18
-rw-r--r--core/launcher/taskbar.cpp7
-rw-r--r--core/launcher/transferserver.cpp107
20 files changed, 334 insertions, 351 deletions
diff --git a/core/launcher/applauncher.cpp b/core/launcher/applauncher.cpp
index 5a5517c..7000346 100644
--- a/core/launcher/applauncher.cpp
+++ b/core/launcher/applauncher.cpp
@@ -29,5 +29,20 @@
#endif
+
+#include "applauncher.h"
+#include "documentlist.h"
+
+/* OPIE */
+#include <opie2/odebug.h>
#include <opie2/oglobal.h>
+#include <qtopia/qcopenvelope_qws.h>
+#include <qtopia/qpeapplication.h>
+using namespace Opie::Core;
-#ifndef Q_OS_WIN32
+/* QT */
+#include <qtimer.h>
+#include <qwindowsystem_qws.h>
+#include <qmessagebox.h>
+#include <qfileinfo.h>
+
+/* STD */
#include <sys/stat.h>
@@ -39,8 +54,2 @@
#include <errno.h>
-#else
-#include <process.h>
-#include <windows.h>
-#include <winbase.h>
-#endif
-
#include <signal.h>
@@ -49,14 +58,2 @@
-#include <qtimer.h>
-#include <qwindowsystem_qws.h>
-#include <qmessagebox.h>
-#include <qfileinfo.h>
-
-#include <qtopia/qcopenvelope_qws.h>
-#include <qtopia/qpeapplication.h>
-
-#include "applauncher.h"
-#include "documentlist.h"
-
-using namespace Opie::Core;
const int AppLauncher::RAISE_TIMEOUT_MS = 5000;
@@ -129,3 +126,3 @@ void AppLauncher::newQcopChannel(const QString& channelName)
{
-// qDebug("channel %s added", channelName.data() );
+// odebug << "channel " << channelName.data() << " added" << oendl;
QString prefix("QPE/Application/");
@@ -143,3 +140,3 @@ void AppLauncher::newQcopChannel(const QString& channelName)
} else if (channelName.startsWith("QPE/QuickLauncher-")) {
- qDebug("Registered %s", channelName.latin1());
+ odebug << "Registered " << channelName << "" << oendl;
int pid = channelName.mid(18).toInt();
@@ -182,3 +179,3 @@ void AppLauncher::received(const QCString& msg, const QByteArray& data)
if ( !waitingHeartbeat.contains( appName ) && appKillerName != appName ) {
- //qDebug( "Raising: %s", appName.latin1() );
+ //odebug << "Raising: " << appName << "" << oendl;
QCString channel = "QPE/Application/";
@@ -219,3 +216,3 @@ void AppLauncher::received(const QCString& msg, const QByteArray& data)
stream >> appName;
- qDebug("Got a heartbeat from %s", appName.latin1());
+ odebug << "Got a heartbeat from " << appName << "" << oendl;
QMap<QString,int>::Iterator it = waitingHeartbeat.find(appName);
@@ -242,3 +239,3 @@ void AppLauncher::signalHandler(int)
/* if (pid == 0 || &status == 0 ) {
- qDebug("hmm, could not get return value from signal");
+ odebug << "hmm, could not get return value from signal" << oendl;
}
@@ -247,3 +244,3 @@ void AppLauncher::signalHandler(int)
#else
- qDebug("Unhandled signal see by AppLauncher::signalHandler(int)");
+ odebug << "Unhandled signal see by AppLauncher::signalHandler(int)" << oendl;
#endif
@@ -275,3 +272,3 @@ void AppLauncher::timerEvent( QTimerEvent *e )
- // qDebug("Checking in on %s", appKillerName.latin1());
+ // odebug << "Checking in on " << appKillerName << "" << oendl;
@@ -286,3 +283,3 @@ void AppLauncher::timerEvent( QTimerEvent *e )
if (appKillerBox->exec() == QMessageBox::Yes) {
- // qDebug("Killing the app!!! Bwuhahahaha!");
+ // odebug << "Killing the app!!! Bwuhahahaha!" << oendl;
int pid = pidForName(appKillerName);
@@ -317,3 +314,3 @@ void AppLauncher::sigStopped(int sigPid, int sigStatus)
if ( sigPid == qlPid ) {
- qDebug( "quicklauncher stopped" );
+ odebug << "quicklauncher stopped" << oendl;
qlPid = 0;
@@ -325,5 +322,5 @@ void AppLauncher::sigStopped(int sigPid, int sigStatus)
if ( sigPid == -1 )
- qDebug("non-qtopia application exited (disregarded)");
+ odebug << "non-qtopia application exited (disregarded)" << oendl;
else
- qDebug("==== no pid matching %d in list, definite bug", sigPid);
+ odebug << "==== no pid matching " << sigPid << " in list, definite bug" << oendl;
*/
@@ -371,3 +368,3 @@ void AppLauncher::sigStopped(int sigPid, int sigStatus)
for (it = runningApps.begin(); it != runningApps.end(); ++it) {
- qDebug("running according to internal list: %s, with pid %d", (*it).data(), it.key() );
+ odebug << "running according to internal list: " << (*it).data() << ", with pid " << it.key() << "" << oendl;
}
@@ -405,3 +402,3 @@ void AppLauncher::sigStopped(int sigPid, int sigStatus)
emit terminated(sigPid, appName);
- qWarning("Re executing obmitted for %s", appName.latin1() );
+ owarn << "Re executing obmitted for " << appName << "" << oendl;
// execute( appName, QString::null );
@@ -419,3 +416,3 @@ void AppLauncher::sigStopped(int sigPid, int sigStatus)
{
- qDebug("Unhandled signal : AppLauncher::sigStopped(int sigPid, int sigStatus)");
+ odebug << "Unhandled signal : AppLauncher::sigStopped(int sigPid, int sigStatus)" << oendl;
}
@@ -430,3 +427,3 @@ bool AppLauncher::isRunning(const QString &app)
if ( t == -1 ) {
- qDebug("appLauncher bug, %s believed running, but pid %d is not existing", app.data(), it.key() );
+ odebug << "appLauncher bug, " << app.data() << " believed running, but pid " << it.key() << " is not existing" << oendl;
runningApps.remove( it.key() );
@@ -483,3 +480,3 @@ bool AppLauncher::execute(const QString &c, const QString &docParam, bool noRais
{
- qWarning("AppLauncher::execute '%s' '%s'", (const char*) c, (const char*) docParam );
+ owarn << "AppLauncher::execute '" << c << "' '" << docParam << "'" << oendl;
// Convert the command line in to a list of arguments
@@ -550,3 +547,3 @@ bool AppLauncher::execute(const QString &c, const QString &docParam, bool noRais
#endif /* Q_OS_MACX */
- qDebug( "Quick launching: %s", args[0] );
+ odebug << "Quick launching: " << args[0] << "" << oendl;
if ( getuid() == 0 )
@@ -586,3 +583,3 @@ bool AppLauncher::execute(const QString &c, const QString &docParam, bool noRais
if (!proc->start()){
- qDebug("Unable to start application %s", args[0]);
+ odebug << "Unable to start application " << args[0] << "" << oendl;
}else{
@@ -596,3 +593,3 @@ bool AppLauncher::execute(const QString &c, const QString &docParam, bool noRais
}else{
- qDebug("Unable to read process inforation #1 for %s", args[0]);
+ odebug << "Unable to read process inforation #1 for " << args[0] << "" << oendl;
}
@@ -600,3 +597,3 @@ bool AppLauncher::execute(const QString &c, const QString &docParam, bool noRais
}else{
- qDebug("Unable to create process for application %s", args[0]);
+ odebug << "Unable to create process for application " << args[0] << "" << oendl;
return FALSE;
@@ -680,3 +677,3 @@ void AppLauncher::processExited()
#ifdef Q_OS_WIN32
- qDebug("AppLauncher::processExited()");
+ odebug << "AppLauncher::processExited()" << oendl;
bool found = FALSE;
@@ -684,3 +681,3 @@ void AppLauncher::processExited()
if (!proc){
- qDebug("Interanl error NULL proc");
+ odebug << "Interanl error NULL proc" << oendl;
return;
@@ -689,3 +686,3 @@ void AppLauncher::processExited()
QString appName = proc->arguments()[0];
- qDebug("Removing application %s", appName.latin1());
+ odebug << "Removing application " << appName << "" << oendl;
runningAppsProc.remove(proc);
@@ -716,3 +713,3 @@ void AppLauncher::processExited()
}else{
- qDebug("Internal error application %s not listed as running", appName.latin1());
+ odebug << "Internal error application " << appName << " not listed as running" << oendl;
}
diff --git a/core/launcher/documentlist.cpp b/core/launcher/documentlist.cpp
index 3e0a96c..92b8c25 100644
--- a/core/launcher/documentlist.cpp
+++ b/core/launcher/documentlist.cpp
@@ -23,4 +23,5 @@
+/* OPIE */
#include <opie2/oglobal.h>
-
+#include <opie2/odebug.h>
#include <qtopia/config.h>
@@ -35,3 +36,5 @@
#endif
+using namespace Opie::Core;
+/* QT */
#include <qtimer.h>
@@ -49,3 +52,2 @@
-using namespace Opie::Core;
AppLnkSet *DocumentList::appLnkSet = 0;
@@ -110,3 +112,3 @@ DocumentList::DocumentList( ServerInterface *serverGui, bool /*scanDocs*/,
d->scanDocs = cfg.readBoolEntry( "Enable", true );
- qDebug( "DocumentList::DocumentList() : scanDocs = %d", d->scanDocs );
+ odebug << "DocumentList::DocumentList() : scanDocs = " << d->scanDocs << "" << oendl;
@@ -143,3 +145,3 @@ void DocumentList::pause()
{
- //qDebug("pause %i", d->tid);
+ //odebug << "pause " << d->tid << "" << oendl;
killTimer( d->tid );
@@ -153,3 +155,3 @@ void DocumentList::resume()
d->tid = startTimer( 20 );
- //qDebug("resumed %i", d->tid);
+ //odebug << "resumed " << d->tid << "" << oendl;
}
@@ -179,3 +181,3 @@ void DocumentList::rescan()
{
- //qDebug("rescan");
+ //odebug << "rescan" << oendl;
pause();
@@ -234,3 +236,3 @@ void DocumentList::reloadAppLnks()
- //qDebug("adding type %s", (*ittypes).latin1());
+ //odebug << "adding type " << (*ittypes) << "" << oendl;
@@ -243,3 +245,3 @@ void DocumentList::reloadAppLnks()
for ( QStringList::Iterator ittypes=prevTypeList.begin(); ittypes!=prevTypeList.end(); ++ittypes) {
- //qDebug("removing type %s", (*ittypes).latin1());
+ //odebug << "removing type " << (*ittypes) << "" << oendl;
d->serverGui->typeRemoved(*ittypes);
@@ -276,3 +278,3 @@ void DocumentList::linkChanged( QString arg )
{
- //qDebug( "linkchanged( %s )", arg.latin1() );
+ //odebug << "linkchanged( " << arg << " )" << oendl;
@@ -289,3 +291,3 @@ void DocumentList::linkChanged( QString arg )
|| ( doc->fileKnown() && doc->file() == arg ) ) {
- //qDebug( "found old link" );
+ //odebug << "found old link" << oendl;
DocLnk* dl = new DocLnk( arg );
@@ -295,3 +297,3 @@ void DocumentList::linkChanged( QString arg )
// to the new link
- //qDebug( "change case" );
+ //odebug << "change case" << oendl;
if ( d->serverGui )
@@ -302,3 +304,3 @@ void DocumentList::linkChanged( QString arg )
// so we aren't interested in it, so take it away from the list
- //qDebug( "removal case" );
+ //odebug << "removal case" << oendl;
if ( d->serverGui )
@@ -316,3 +318,3 @@ void DocumentList::linkChanged( QString arg )
// Add if it's a link we are interested in
- //qDebug( "add case" );
+ //odebug << "add case" << oendl;
add( *dl );
@@ -380,3 +382,3 @@ void DocumentList::sendAllDocLinks()
- //qDebug( "sending length %d", contents.length() );
+ //odebug << "sending length " << contents.length() << "" << oendl;
#ifndef QT_NO_COP
@@ -385,3 +387,3 @@ void DocumentList::sendAllDocLinks()
#endif
- //qDebug( "================ \n\n%s\n\n===============", contents.latin1() );
+ //odebug << "================ \n\n" << contents << "\n\n===============" << oendl;
@@ -538,3 +540,3 @@ void DocumentListPrivate::estimatedPercentScanned()
- // qDebug( "overallProgress: %f", overallProgress );
+ // odebug << "overallProgress: " << overallProgress << "" << oendl;
@@ -555,3 +557,3 @@ const QString DocumentListPrivate::nextFile()
QDir dir( docPaths[docPathsSearched] );
- // qDebug("now using base path: %s", docPaths[docPathsSearched].latin1() );
+ // odebug << "now using base path: " << docPaths[docPathsSearched] << "" << oendl;
docPathsSearched++;
@@ -589,3 +591,3 @@ const QString DocumentListPrivate::nextFile()
QDir dir( fi->filePath() );
- // qDebug("now going in to path: %s", bn.latin1() );
+ // odebug << "now going in to path: " << bn << "" << oendl;
if ( !dir.exists( ".Qtopia-ignore" ) ) {
@@ -630,3 +632,3 @@ const DocLnk *DocumentListPrivate::iterate()
if ( state == Find ) {
- //qDebug("state Find");
+ //odebug << "state Find" << oendl;
QString file = nextFile();
@@ -652,3 +654,3 @@ const DocLnk *DocumentListPrivate::iterate()
if ( state == RemoveKnownFiles ) {
- //qDebug("state RemoveKnownFiles");
+ //odebug << "state RemoveKnownFiles" << oendl;
const QList<DocLnk> &list = dls.children();
@@ -666,3 +668,3 @@ const DocLnk *DocumentListPrivate::iterate()
if ( state == MakeUnknownFiles ) {
- //qDebug("state MakeUnknownFiles");
+ //odebug << "state MakeUnknownFiles" << oendl;
for (void* c; (c=dit->current()); ++(*dit) ) {
@@ -689,3 +691,3 @@ const DocLnk *DocumentListPrivate::iterate()
- //qDebug("state Done");
+ //odebug << "state Done" << oendl;
return NULL;
diff --git a/core/launcher/firstuse.cpp b/core/launcher/firstuse.cpp
index 4316648..e9e2d83 100644
--- a/core/launcher/firstuse.cpp
+++ b/core/launcher/firstuse.cpp
@@ -31,4 +31,2 @@
#include "serverapp.h"
-//#include <qtopia/custom.h>
-
#include "calibrate.h"
@@ -36,2 +34,4 @@
+/* OPIE */
+#include <opie2/odebug.h>
#include <qtopia/resource.h>
@@ -40,3 +40,5 @@
#include <qtopia/fontmanager.h>
+using namespace Opie::Core;
+/* QT */
#include <qfile.h>
@@ -53,3 +55,3 @@
-
+/* STD */
#include <stdlib.h>
@@ -157,3 +159,3 @@ FirstUse::FirstUse(QWidget* parent, const char * name, WFlags wf) :
#if defined(Q_WS_QWS) && !defined(QT_NO_COP)
- qDebug("Setting up QCop to QPE/System");
+ odebug << "Setting up QCop to QPE/System" << oendl;
QCopChannel* sysChannel = new QCopChannel( "QPE/System", this );
@@ -225,3 +227,3 @@ void FirstUse::nextDialog()
currApp++;
- qDebug( "currApp = %d", currApp );
+ odebug << "currApp = " << currApp << "" << oendl;
if ( settingsTable[currApp].app == 0 ) {
@@ -231,3 +233,3 @@ void FirstUse::nextDialog()
// to nextDialog and exit.
- qDebug( "Waiting for %s to exit", settingsTable[prevApp].app );
+ odebug << "Waiting for " << settingsTable[prevApp].app << " to exit" << oendl;
QCopEnvelope e(QCString("QPE/Application/") + settingsTable[prevApp].app,
@@ -236,3 +238,3 @@ void FirstUse::nextDialog()
} else {
- qDebug( "Done!" );
+ odebug << "Done!" << oendl;
Config config( "qpe" );
@@ -260,3 +262,3 @@ void FirstUse::nextDialog()
if ( prevApp >= 0 && appLauncher->isRunning(settingsTable[prevApp].app) ) {
- qDebug( "Shutdown: %s", settingsTable[prevApp].app );
+ odebug << "Shutdown: " << settingsTable[prevApp].app << "" << oendl;
QCopEnvelope e(QCString("QPE/Application/") + settingsTable[prevApp].app,
@@ -265,3 +267,3 @@ void FirstUse::nextDialog()
} else {
- qDebug( "Startup: %s", settingsTable[currApp].app );
+ odebug << "Startup: " << settingsTable[currApp].app << "" << oendl;
QCopEnvelope e(QCString("QPE/Application/") + settingsTable[currApp].app,
@@ -287,3 +289,3 @@ void FirstUse::previousDialog()
if ( prevApp >= 0 ) {
- qDebug( "Shutdown: %s", settingsTable[prevApp].app );
+ odebug << "Shutdown: " << settingsTable[prevApp].app << "" << oendl;
QCopEnvelope e(QCString("QPE/Application/") + settingsTable[prevApp].app,
@@ -296,3 +298,3 @@ void FirstUse::previousDialog()
} else {
- qDebug( "Startup: %s", settingsTable[currApp].app );
+ odebug << "Startup: " << settingsTable[currApp].app << "" << oendl;
QCopEnvelope e(QCString("QPE/Application/") + settingsTable[currApp].app,
@@ -320,5 +322,5 @@ void FirstUse::terminated( int, const QString &app )
{
- qDebug( "--- terminated: %s", app.latin1() );
+ odebug << "--- terminated: " << app << "" << oendl;
if ( waitForExit != -1 && settingsTable[waitForExit].app == app ) {
- qDebug( "Startup: %s", settingsTable[currApp].app );
+ odebug << "Startup: " << settingsTable[currApp].app << "" << oendl;
if ( settingsTable[waitForExit].app == "language" ) { // No tr
@@ -349,3 +351,3 @@ void FirstUse::newQcopChannel(const QString& channelName)
{
- qDebug("channel %s added", channelName.data() );
+ odebug << "channel " << channelName.data() << " added" << oendl;
QString prefix("QPE/Application/");
@@ -354,3 +356,3 @@ void FirstUse::newQcopChannel(const QString& channelName)
if ( currApp >= 0 && appName == settingsTable[currApp].app ) {
- qDebug( "Application: %s started", settingsTable[currApp].app );
+ odebug << "Application: " << settingsTable[currApp].app << " started" << oendl;
waitingForLaunch = FALSE;
@@ -372,3 +374,3 @@ void FirstUse::reloadLanguages()
QString cl = getenv("LANG");
- qWarning("language message - " + l);
+ owarn << "language message - " + l << oendl;
// setting anyway...
@@ -377,3 +379,3 @@ void FirstUse::reloadLanguages()
else {
- qWarning("and its not null");
+ owarn << "and its not null" << oendl;
setenv( "LANG", l.latin1(), 1 );
@@ -394,5 +396,5 @@ void FirstUse::reloadLanguages()
QString tfn = QPEApplication::qpeDir() + "i18n/"+l+"/qpe.qm";
- qWarning("loading " + tfn);
+ owarn << "loading " + tfn << oendl;
if ( transApp->load(tfn) ) {
- qWarning("installing translator");
+ owarn << "installing translator" << oendl;
qApp->installTranslator( transApp );
@@ -405,5 +407,5 @@ void FirstUse::reloadLanguages()
tfn = QPEApplication::qpeDir() + "i18n/"+l+"/libqpe.qm";
- qWarning("loading " + tfn);
+ owarn << "loading " + tfn << oendl;
if ( transLib->load(tfn) ) {
- qWarning("installing translator library");
+ owarn << "installing translator library" << oendl;
qApp->installTranslator( transLib );
diff --git a/core/launcher/inputmethods.cpp b/core/launcher/inputmethods.cpp
index 19e799a..cef16bf 100644
--- a/core/launcher/inputmethods.cpp
+++ b/core/launcher/inputmethods.cpp
@@ -23,5 +23,9 @@
+/* OPIE */
+#include <opie2/odebug.h>
#include <qtopia/config.h>
#include <qtopia/qpeapplication.h>
+using namespace Opie::Core;
+/* QT */
#include <qpopupmenu.h>
@@ -31,5 +35,3 @@
#include <qdir.h>
-#include <stdlib.h>
#include <qtl.h>
-
#ifdef Q_WS_QWS
@@ -40,10 +42,4 @@
-/* ### SingleFloppy if someone is interested? */
-#if 0
-#ifdef QT_NO_COMPONENT
-#include "../plugins/inputmethods/handwriting/handwritingimpl.h"
-#include "../plugins/inputmethods/keyboard/keyboardimpl.h"
-#include "../3rdparty/plugins/inputmethods/pickboard/pickboardimpl.h"
-#endif
-#endif
+/* STD */
+#include <stdlib.h>
@@ -264,3 +260,3 @@ void InputMethods::setPreferedHandlers() {
if ( (*it).name() == current ) {
- qWarning("preferred keyboard is %s", current.latin1() );
+ owarn << "preferred keyboard is " << current << "" << oendl;
mkeyboard = &(*it);
@@ -307,9 +303,9 @@ void InputMethods::loadInputMethods()
if (input.widget) {
- //qDebug("its a keyboard");
+ //odebug << "its a keyboard" << oendl;
inputMethodList.append( input );
} else {
- //qDebug("its a real im");
+ //odebug << "its a real im" << oendl;
input.widget = input.extInterface->statusWidget( 0, 0 );
if (input.widget) {
- //qDebug("blah");
+ //odebug << "blah" << oendl;
inputModifierList.append( input );
@@ -543,3 +539,3 @@ void InputMethods::showKbd( bool on )
{
- qDebug( "InputMethods: reading geometry." );
+ odebug << "InputMethods: reading geometry." << oendl;
Config cfg( "Launcher" );
@@ -553,3 +549,3 @@ void InputMethods::showKbd( bool on )
{
- qDebug( "InputMethods: config values ( %d, %d, %d, %d ) are ok.", l, t, w, h );
+ odebug << "InputMethods: config values ( " << l << ", " << t << ", " << w << ", " << h << " ) are ok." << oendl;
left = l;
@@ -561,3 +557,3 @@ void InputMethods::showKbd( bool on )
{
- qDebug( "InputMethods: config values are new or not ok." );
+ odebug << "InputMethods: config values are new or not ok." << oendl;
}
@@ -566,3 +562,3 @@ void InputMethods::showKbd( bool on )
{
- qDebug( "InputMethods: no floating selected." );
+ odebug << "InputMethods: no floating selected." << oendl;
}
@@ -579,3 +575,3 @@ void InputMethods::showKbd( bool on )
QSize siz = mkeyboard->widget->size();
- qDebug( "InputMethods: saving geometry." );
+ odebug << "InputMethods: saving geometry." << oendl;
Config cfg( "Launcher" );
diff --git a/core/launcher/irserver.cpp b/core/launcher/irserver.cpp
index a0e9c16..092eb0c 100644
--- a/core/launcher/irserver.cpp
+++ b/core/launcher/irserver.cpp
@@ -20,5 +20,7 @@
-
#include "irserver.h"
+#include "obexinterface.h"
+/* OPIE */
+#include <opie2/odebug.h>
#include <qtopia/qlibrary.h>
@@ -26,5 +28,3 @@
-
-#include "obexinterface.h"
-
+/* QT */
#include <qdir.h>
@@ -46,6 +46,6 @@ IrServer::IrServer( QObject *parent, const char *name )
QLibrary *trylib = new QLibrary( path + *it );
- //qDebug("trying lib %s", (path + (*it)).latin1() );
+ //odebug << "trying lib " << (path + (*it)) << "" << oendl;
if ( trylib->queryInterface( IID_ObexInterface, (QUnknownInterface**)&obexIface ) == QS_OK ) {
lib = trylib;
- //qDebug("found obex lib" );
+ //odebug << "found obex lib" << oendl;
QString lang = getenv( "LANG" );
@@ -54,3 +54,3 @@ IrServer::IrServer( QObject *parent, const char *name )
QString tfn = QPEApplication::qpeDir()+"/i18n/"+lang+"/"+type+".qm";
- //qDebug("tr fpr obex: %s", tfn.latin1() );
+ //odebug << "tr fpr obex: " << tfn << "" << oendl;
if ( trans->load( tfn ))
@@ -66,3 +66,3 @@ IrServer::IrServer( QObject *parent, const char *name )
if ( !lib )
- qDebug("could not load IR plugin" );
+ odebug << "could not load IR plugin" << oendl;
}
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
@@ -20,2 +20,11 @@
+#include "startmenu.h"
+#include "taskbar.h"
+#include "serverinterface.h"
+#include "launcherview.h"
+#include "launcher.h"
+#include "server.h"
+
+/* OPIE */
+#include <opie2/odebug.h>
#include <qtopia/global.h>
@@ -30,6 +39,9 @@
#include <qtopia/private/categories.h>
-//#include <qtopia/custom.h>
+#define QTOPIA_INTERNAL_FSLP
+#include <qtopia/lnkproperties.h>
+/* QT */
#include <qdir.h>
#ifdef Q_WS_QWS
+#include <qkeyboard_qws.h>
#include <qwindowsystem_qws.h>
@@ -52,15 +64,5 @@
-#include "startmenu.h"
-#include "taskbar.h"
-
-#include "serverinterface.h"
-#include "launcherview.h"
-#include "launcher.h"
-#include "server.h"
-
-#define QTOPIA_INTERNAL_FSLP
-#include <qtopia/lnkproperties.h>
+/* STD */
#include <stdlib.h>
#include <assert.h>
-
#if defined(_OS_LINUX_) || defined(Q_OS_LINUX)
@@ -72,7 +74,2 @@
-#ifdef Q_WS_QWS
-#include <qkeyboard_qws.h>
-#include <qpe/lnkproperties.h>
-#endif
-
@@ -230,3 +227,3 @@ LauncherView* LauncherTabWidget::newView( const QString& id, const QPixmap& pm,
- qDebug("inserting %s at %d", id.latin1(), n-1 );
+ odebug << "inserting " << id << " at " << n-1 << "" << oendl;
@@ -415,3 +412,3 @@ void LauncherTabWidget::launcherMessage( const QCString &msg, const QByteArray &
view(id)->setViewFont( QFont(fam, size, weight, italic!=0) );
- qDebug( "setFont: %s, %d, %d, %d", fam.latin1(), size, weight, italic );
+ odebug << "setFont: " << fam << ", " << size << ", " << weight << ", " << italic << "" << oendl;
} else {
@@ -686,3 +683,3 @@ void Launcher::applicationRemoved( const QString& type, const AppLnk& app )
else
- qWarning("removeAppLnk: No view for %s!", type.latin1() );
+ owarn << "removeAppLnk: No view for " << type << "!" << oendl;
}
diff --git a/core/launcher/launcherview.cpp b/core/launcher/launcherview.cpp
index 6c7d487..71e8753 100644
--- a/core/launcher/launcherview.cpp
+++ b/core/launcher/launcherview.cpp
@@ -22,2 +22,4 @@
+/* OPIE */
+#include <opie2/odebug.h>
#include <qtopia/qpeapplication.h>
@@ -27,4 +29,5 @@
#include <qtopia/resource.h>
-//#include <qtopia/private/palmtoprecord.h>
+using namespace Opie::Core;
+/* QT */
#include <qtimer.h>
@@ -117,3 +120,3 @@ public:
++it;
- //qDebug("%p: hidden (should remove)",l);
+ //odebug << "" << l << ": hidden (should remove)" << oendl;
}
@@ -1031,3 +1034,3 @@ void LauncherView::fontChanged(const QFont&)
{
- qDebug("LauncherView::fontChanged()");
+ odebug << "LauncherView::fontChanged()" << oendl;
icons->hideOrShowItems( FALSE );
diff --git a/core/launcher/main.cpp b/core/launcher/main.cpp
index 3e7e0d2..a86aca6 100644
--- a/core/launcher/main.cpp
+++ b/core/launcher/main.cpp
@@ -23,2 +23,6 @@
#endif
+#ifdef QT_QWS_LOGIN
+#include "../login/qdmdialogimpl.h"
+#endif
+#include "calibrate.h"
#include "server.h"
@@ -28,9 +32,13 @@
+/* OPIE */
+#include <opie2/odebug.h>
+#include <opie2/odevice.h>
#include <opie2/oglobal.h>
-
#include <qtopia/network.h>
-//#include <qtopia/custom.h>
-
+#include <qtopia/alarmserver.h>
+using namespace Opie::Core;
+/* QT */
#include <qdir.h>
+#include <qmessagebox.h>
#ifdef QWS
@@ -39,4 +47,7 @@
#endif
-#include <qtopia/alarmserver.h>
+#ifdef Q_WS_QWS
+#include <qkeyboard_qws.h>
+#endif
+/* STD */
#include <stdlib.h>
@@ -50,19 +61,2 @@
-#include "calibrate.h"
-
-
-#ifdef QT_QWS_LOGIN
-#include "../login/qdmdialogimpl.h"
-#endif
-
-#ifdef Q_WS_QWS
-#include <qkeyboard_qws.h>
-#endif
-
-#include <qmessagebox.h>
-#include <opie2/odevice.h>
-
-using namespace Opie::Core;
-
-
static void cleanup()
@@ -123,3 +117,3 @@ static void refreshTimeZoneConfig()
if ( !curZone.isValid() ){
- qDebug( "initEnvironment() Invalid TimeZone %s", zoneID.latin1() );
+ odebug << "initEnvironment() Invalid TimeZone " << zoneID << "" << oendl;
break;
@@ -271,3 +265,3 @@ int initApplication( int argc, char ** argv )
- qDebug("exiting...");
+ odebug << "exiting..." << oendl;
delete s;
@@ -343,3 +337,3 @@ int main( int argc, char ** argv )
if ( DesktopApplication::doRestart ) {
- qDebug("Trying to restart");
+ odebug << "Trying to restart" << oendl;
execl( (QPEApplication::qpeDir()+"bin\\qpe").latin1(), "qpe", 0 );
diff --git a/core/launcher/packageslave.cpp b/core/launcher/packageslave.cpp
index 7e61b0e..a11ac86 100644
--- a/core/launcher/packageslave.cpp
+++ b/core/launcher/packageslave.cpp
@@ -21,4 +21,6 @@
#include "packageslave.h"
-#include <qtopia/qprocess.h>
+/* OPIE */
+#include <opie2/odebug.h>
+#include <qtopia/qprocess.h>
#ifdef Q_WS_QWS
@@ -26,3 +28,5 @@
#endif
+using namespace Opie::Core;
+/* QT */
#ifdef Q_WS_QWS
@@ -30,8 +34,7 @@
#endif
-
#include <qtextstream.h>
+/* STD */
#include <stdlib.h>
#include <sys/stat.h> // mkdir()
-
#if defined(_OS_LINUX_) || defined(Q_OS_LINUX)
@@ -40,5 +43,2 @@
#include <mntent.h>
-#elif defined(Q_OS_WIN32)
-#include <windows.h>
-#include <winbase.h>
#elif defined(Q_OS_MACX)
@@ -147,3 +147,3 @@ void PackageHandler::addPackageFiles( const QString &location,
//#### revise
- qDebug("Copy file at %s: %s", __FILE__, __LINE__ );
+ odebug << "Copy file at " << __FILE__ << ": " << __LINE__ << "" << oendl;
d.mkdir(("/usr/lib/ipkg/info/" + location).ascii());
@@ -161,3 +161,3 @@ void PackageHandler::addPackageFiles( const QString &location,
if ( s.right(1) == "/" ) {
- qDebug("do mkdir for %s", s.ascii());
+ odebug << "do mkdir for " << s.ascii() << "" << oendl;
#ifndef Q_OS_WIN32
@@ -172,6 +172,6 @@ void PackageHandler::addPackageFiles( const QString &location,
#ifndef Q_OS_WIN32
- qDebug("do symlink for %s", s.ascii());
+ odebug << "do symlink for " << s.ascii() << "" << oendl;
symlink( (location + s).ascii(), s.ascii() );
#else
- qDebug("Copy file instead of a symlink for WIN32");
+ odebug << "Copy file instead of a symlink for WIN32" << oendl;
if (!CopyFile((TCHAR*)qt_winTchar((location + s), TRUE), (TCHAR*)qt_winTchar(s, TRUE), FALSE))
@@ -217,3 +217,3 @@ void PackageHandler::cleanupPackageFiles( const QString &listfile )
#ifndef Q_OS_WIN32
- qDebug("remove symlink for %s", s.ascii());
+ odebug << "remove symlink for " << s.ascii() << "" << oendl;
//check if it is a symlink first (don't remove /etc/passwd...)
@@ -224,3 +224,3 @@ void PackageHandler::cleanupPackageFiles( const QString &listfile )
// ### revise
- qWarning("Unable to remove symlink %s:%s", __FILE__, __LINE__);
+ owarn << "Unable to remove symlink " << __FILE__ << ":" << __LINE__ << "" << oendl;
#endif
@@ -268,3 +268,3 @@ void PackageHandler::prepareInstall( const QString& size, const QString& path )
if ( s > fs.f_bsize * fs.f_bavail ) {
- //qDebug("############### Not enough space left ###############");
+ //odebug << "############### Not enough space left ###############" << oendl;
mNoSpaceLeft = TRUE;
diff --git a/core/launcher/qcopbridge.cpp b/core/launcher/qcopbridge.cpp
index 33df6c4..e339dc7 100644
--- a/core/launcher/qcopbridge.cpp
+++ b/core/launcher/qcopbridge.cpp
@@ -23,4 +23,5 @@
+/* OPIE */
+#include <opie2/odebug.h>
#include <opie2/oglobal.h>
-
#ifdef Q_WS_QWS
@@ -29,5 +30,6 @@
#include <qtopia/qpeapplication.h>
-
#include <qtopia/version.h>
+using namespace Opie::Core;
+/* QT */
#include <qtextstream.h>
@@ -38,2 +40,3 @@
+/* STD */
#ifndef _XOPEN_SOURCE
@@ -51,8 +54,4 @@
-
-//#define INSECURE
-
const int block_size = 51200;
-using namespace Opie::Core;
QCopBridge::QCopBridge( Q_UINT16 port, QObject *parent,
@@ -64,3 +63,3 @@ QCopBridge::QCopBridge( Q_UINT16 port, QObject *parent,
if ( !ok() )
- qWarning( "Failed to bind to port %d", port );
+ owarn << "Failed to bind to port " << port << "" << oendl;
else {
@@ -173,3 +172,3 @@ void QCopBridge::sendDesktopMessageOld( const QCString& command, const QByteArra
if ( paren <= 0 ) {
- qDebug("DesktopMessage: bad qcop syntax");
+ odebug << "DesktopMessage: bad qcop syntax" << oendl;
return;
@@ -179,3 +178,3 @@ void QCopBridge::sendDesktopMessageOld( const QCString& command, const QByteArra
if ( params[params.length()-1] != ')' ) {
- qDebug("DesktopMessage: bad qcop syntax");
+ odebug << "DesktopMessage: bad qcop syntax" << oendl;
return;
@@ -206,3 +205,3 @@ void QCopBridge::sendDesktopMessageOld( const QCString& command, const QByteArra
} else {
- qDebug(" cannot route the argument type %s throught the qcop bridge", (*it).latin1() );
+ odebug << " cannot route the argument type " << (*it) << " throught the qcop bridge" << oendl;
return;
@@ -334,3 +333,3 @@ void QCopBridgePI::send( const QString& msg )
os << msg << endl;
- //qDebug( "sending qcop message: %s", msg.latin1() );
+ //odebug << "sending qcop message: " << msg << "" << oendl;
}
@@ -347,3 +346,3 @@ void QCopBridgePI::process( const QString& message )
{
- //qDebug( "Command: %s", message.latin1() );
+ //odebug << "Command: " << message << "" << oendl;
diff --git a/core/launcher/qprocess.cpp b/core/launcher/qprocess.cpp
index 97bd539..3fe1238 100644
--- a/core/launcher/qprocess.cpp
+++ b/core/launcher/qprocess.cpp
@@ -583,3 +583,3 @@ void QProcess::connectNotify( const char * signal )
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcess::connectNotify(): signal %s has been connected", signal );
+ odebug << "QProcess::connectNotify(): signal " << signal << " has been connected" << oendl;
#endif
@@ -590,3 +590,3 @@ void QProcess::connectNotify( const char * signal )
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcess::connectNotify(): set ioRedirection to TRUE" );
+ odebug << "QProcess::connectNotify(): set ioRedirection to TRUE" << oendl;
#endif
@@ -597,3 +597,3 @@ void QProcess::connectNotify( const char * signal )
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcess::connectNotify(): set notifyOnExit to TRUE" );
+ odebug << "QProcess::connectNotify(): set notifyOnExit to TRUE" << oendl;
#endif
@@ -604,3 +604,3 @@ void QProcess::connectNotify( const char * signal )
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcess::connectNotify(): set wroteToStdinConnected to TRUE" );
+ odebug << "QProcess::connectNotify(): set wroteToStdinConnected to TRUE" << oendl;
#endif
@@ -620,3 +620,3 @@ void QProcess::disconnectNotify( const char * )
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcess::disconnectNotify(): set ioRedirection to FALSE" );
+ odebug << "QProcess::disconnectNotify(): set ioRedirection to FALSE" << oendl;
#endif
@@ -626,3 +626,3 @@ void QProcess::disconnectNotify( const char * )
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcess::disconnectNotify(): set notifyOnExit to FALSE" );
+ odebug << "QProcess::disconnectNotify(): set notifyOnExit to FALSE" << oendl;
#endif
@@ -632,3 +632,3 @@ void QProcess::disconnectNotify( const char * )
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcess::disconnectNotify(): set wroteToStdinConnected to FALSE" );
+ odebug << "QProcess::disconnectNotify(): set wroteToStdinConnected to FALSE" << oendl;
#endif
diff --git a/core/launcher/qprocess_unix.cpp b/core/launcher/qprocess_unix.cpp
index 19a8c93..d62e4e6 100644
--- a/core/launcher/qprocess_unix.cpp
+++ b/core/launcher/qprocess_unix.cpp
@@ -20,4 +20,2 @@
-//#include "qplatformdefs.h"
-
// Solaris redefines connect -> __xnet_connect with _XOPEN_SOURCE_EXTENDED.
@@ -29,10 +27,14 @@
-#ifndef QT_NO_PROCESS
+/* OPIE */
+#include <opie2/odebug.h>
+using namespace Opie::Core;
-#include "qapplication.h"
-#include "qqueue.h"
-#include "qlist.h"
-#include "qsocketnotifier.h"
-#include "qtimer.h"
-#include "qregexp.h"
+/* QT */
+#ifndef QT_NO_PROCESS
+#include <qapplication.h>
+#include <qqueue.h>
+#include <qlist.h>
+#include <qsocketnotifier.h>
+#include <qtimer.h>
+#include <qregexp.h>
@@ -40,5 +42,4 @@
+/* STD */
#include <stdlib.h>
-
-// ### FOR Qt 2.3 compat
#include <unistd.h>
@@ -49,5 +50,4 @@
#include <sys/fcntl.h>
-
+#include <sys/resource.h>
#include <errno.h>
-
#ifdef Q_OS_MACX
@@ -55,3 +55,2 @@
#endif
-#include <sys/resource.h>
@@ -134,3 +133,3 @@ public:
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProc: Constructor for pid %d and QProcess %p", pid, process );
+ odebug << "QProc: Constructor for pid " << pid << " and QProcess " << process << "" << oendl;
#endif
@@ -143,3 +142,3 @@ public:
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProc: Destructor for pid %d and QProcess %p", pid, process );
+ odebug << "QProc: Destructor for pid " << pid << " and QProcess " << process << "" << oendl;
#endif
@@ -215,3 +214,3 @@ QProcessManager::QProcessManager()
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcessManager: install socket notifier (%d)", sigchldFd[1] );
+ odebug << "QProcessManager: install socket notifier (" << sigchldFd[1] << ")" << oendl;
#endif
@@ -228,3 +227,3 @@ QProcessManager::QProcessManager()
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcessManager: install a SIGCHLD handler" );
+ odebug << "QProcessManager: install a SIGCHLD handler" << oendl;
#endif
@@ -238,6 +237,6 @@ QProcessManager::QProcessManager()
if ( sigaction( SIGCHLD, &act, &oldactChld ) != 0 )
- qWarning( "Error installing SIGCHLD handler" );
+ owarn << "Error installing SIGCHLD handler" << oendl;
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcessManager: install a SIGPIPE handler (SIG_IGN)" );
+ odebug << "QProcessManager: install a SIGPIPE handler (SIG_IGN)" << oendl;
#endif
@@ -254,3 +253,3 @@ QProcessManager::QProcessManager()
if ( sigaction( SIGPIPE, &act, &oldactPipe ) != 0 )
- qWarning( "Error installing SIGPIPE handler" );
+ owarn << "Error installing SIGPIPE handler" << oendl;
}
@@ -268,12 +267,12 @@ QProcessManager::~QProcessManager()
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcessManager: restore old sigchild handler" );
+ odebug << "QProcessManager: restore old sigchild handler" << oendl;
#endif
if ( sigaction( SIGCHLD, &oldactChld, 0 ) != 0 )
- qWarning( "Error restoring SIGCHLD handler" );
+ owarn << "Error restoring SIGCHLD handler" << oendl;
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcessManager: restore old sigpipe handler" );
+ odebug << "QProcessManager: restore old sigpipe handler" << oendl;
#endif
if ( sigaction( SIGPIPE, &oldactPipe, 0 ) != 0 )
- qWarning( "Error restoring SIGPIPE handler" );
+ owarn << "Error restoring SIGPIPE handler" << oendl;
}
@@ -284,3 +283,3 @@ void QProcessManager::append( QProc *p )
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcessManager: append process (procList.count(): %d)", procList->count() );
+ odebug << "QProcessManager: append process (procList.count(): " << procList->count() << ")" << oendl;
#endif
@@ -292,3 +291,3 @@ void QProcessManager::remove( QProc *p )
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcessManager: remove process (procList.count(): %d)", procList->count() );
+ odebug << "QProcessManager: remove process (procList.count(): " << procList->count() << ")" << oendl;
#endif
@@ -318,3 +317,3 @@ void QProcessManager::sigchldHnd( int fd )
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcessManager::sigchldHnd()" );
+ odebug << "QProcessManager::sigchldHnd()" << oendl;
#endif
@@ -331,3 +330,3 @@ void QProcessManager::sigchldHnd( int fd )
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcessManager::sigchldHnd() (PID: %d): process exited (QProcess available)", proc->pid );
+ odebug << "QProcessManager::sigchldHnd() (PID: " << proc->pid << "): process exited (QProcess available)" << oendl;
#endif
@@ -337,3 +336,3 @@ void QProcessManager::sigchldHnd( int fd )
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcessManager::sigchldHnd() (PID: %d): reading %d bytes of pending data on stdout", proc->pid, nbytes );
+ odebug << "QProcessManager::sigchldHnd() (PID: " << proc->pid << "): reading " << nbytes << " bytes of pending data on stdout" << oendl;
#endif
@@ -344,3 +343,3 @@ void QProcessManager::sigchldHnd( int fd )
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcessManager::sigchldHnd() (PID: %d): reading %d bytes of pending data on stderr", proc->pid, nbytes );
+ odebug << "QProcessManager::sigchldHnd() (PID: " << proc->pid << "): reading " << nbytes << " bytes of pending data on stderr" << oendl;
#endif
@@ -358,3 +357,3 @@ void QProcessManager::sigchldHnd( int fd )
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcessManager::sigchldHnd() (PID: %d): process exited (QProcess not available)", proc->pid );
+ odebug << "QProcessManager::sigchldHnd() (PID: " << proc->pid << "): process exited (QProcess not available)" << oendl;
#endif
@@ -388,3 +387,3 @@ QProcessPrivate::QProcessPrivate()
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcessPrivate: Constructor" );
+ odebug << "QProcessPrivate: Constructor" << oendl;
#endif
@@ -405,3 +404,3 @@ QProcessPrivate::~QProcessPrivate()
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcessPrivate: Destructor" );
+ odebug << "QProcessPrivate: Destructor" << oendl;
#endif
@@ -601,3 +600,3 @@ bool QProcess::start( QStringList *env )
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcess::start()" );
+ odebug << "QProcess::start()" << oendl;
#endif
@@ -637,3 +636,3 @@ bool QProcess::start( QStringList *env )
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcess::start(): arg %d = %s", i, arglist[i] );
+ odebug << "QProcess::start(): arg " << i << " = " << arglist[i] << "" << oendl;
#endif
@@ -801,3 +800,3 @@ error:
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcess::start(): error starting process" );
+ odebug << "QProcess::start(): error starting process" << oendl;
#endif
@@ -880,3 +879,3 @@ bool QProcess::isRunning() const
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcess::isRunning(): FALSE (already computed)" );
+ odebug << "QProcess::isRunning(): FALSE (already computed)" << oendl;
#endif
@@ -897,3 +896,3 @@ bool QProcess::isRunning() const
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcess::isRunning() (PID: %d): FALSE", d->proc->pid );
+ odebug << "QProcess::isRunning() (PID: " << d->proc->pid << "): FALSE" << oendl;
#endif
@@ -902,3 +901,3 @@ bool QProcess::isRunning() const
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcess::isRunning() (PID: %d): TRUE", d->proc->pid );
+ odebug << "QProcess::isRunning() (PID: " << d->proc->pid << "): TRUE" << oendl;
#endif
@@ -922,3 +921,3 @@ void QProcess::writeToStdin( const QByteArray& buf )
#if defined(QT_QPROCESS_DEBUG)
-// qDebug( "QProcess::writeToStdin(): write to stdin (%d)", d->socketStdin );
+// odebug << "QProcess::writeToStdin(): write to stdin (" << d->socketStdin << ")" << oendl;
#endif
@@ -949,6 +948,6 @@ void QProcess::closeStdin()
if ( ::close( d->proc->socketStdin ) != 0 ) {
- qWarning( "Could not close stdin of child process" );
+ owarn << "Could not close stdin of child process" << oendl;
}
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcess::closeStdin(): stdin (%d) closed", d->proc->socketStdin );
+ odebug << "QProcess::closeStdin(): stdin (" << d->proc->socketStdin << ") closed" << oendl;
#endif
@@ -972,3 +971,3 @@ void QProcess::socketRead( int fd )
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcess::socketRead(): %d", fd );
+ odebug << "QProcess::socketRead(): " << fd << "" << oendl;
#endif
@@ -1001,3 +1000,3 @@ void QProcess::socketRead( int fd )
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcess::socketRead(): stdout (%d) closed", fd );
+ odebug << "QProcess::socketRead(): stdout (" << fd << ") closed" << oendl;
#endif
@@ -1011,3 +1010,3 @@ void QProcess::socketRead( int fd )
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcess::socketRead(): stderr (%d) closed", fd );
+ odebug << "QProcess::socketRead(): stderr (" << fd << ") closed" << oendl;
#endif
@@ -1063,3 +1062,3 @@ void QProcess::socketWrite( int fd )
#if defined(QT_QPROCESS_DEBUG)
- qDebug( "QProcess::socketWrite(): write to stdin (%d)", fd );
+ odebug << "QProcess::socketWrite(): write to stdin (" << fd << ")" << oendl;
#endif
diff --git a/core/launcher/runningappbar.cpp b/core/launcher/runningappbar.cpp
index 2e9d2a9..a25963f 100644
--- a/core/launcher/runningappbar.cpp
+++ b/core/launcher/runningappbar.cpp
@@ -22,11 +22,15 @@
+#include "runningappbar.h"
+#include "serverinterface.h"
-#include <stdlib.h>
+/* OPIE */
+#include <opie2/odebug.h>
+#include <qtopia/qcopenvelope_qws.h>
+using namespace Opie::Core;
+/* QT */
#include <qpainter.h>
-#include <qtopia/qcopenvelope_qws.h>
-
-#include "runningappbar.h"
-#include "serverinterface.h"
+/* STD */
+#include <stdlib.h>
@@ -53,3 +57,3 @@ void RunningAppBar::received(const QCString& msg, const QByteArray& data) {
stream >> appName;
- // qDebug("fastAppShowing %s", appName.data() );
+ // odebug << "fastAppShowing " << appName.data() << "" << oendl;
const AppLnk* f = ServerInterface::appLnks().findExec(appName);
@@ -65,3 +69,3 @@ void RunningAppBar::received(const QCString& msg, const QByteArray& data) {
void RunningAppBar::addTask(const AppLnk& appLnk) {
- qDebug("Added %s to app list.", appLnk.name().latin1());
+ odebug << "Added " << appLnk.name() << " to app list." << oendl;
AppLnk* newApp = new AppLnk(appLnk);
@@ -77,3 +81,3 @@ void RunningAppBar::removeTask(const AppLnk& appLnk) {
if (target->exec() == appLnk.exec()) {
- qDebug("Removing %s from app list.", appLnk.name().latin1());
+ odebug << "Removing " << appLnk.name() << " from app list." << oendl;
appList.remove();
@@ -137,3 +141,3 @@ void RunningAppBar::paintEvent( QPaintEvent * )
curApp = it.current();
- qWarning("Drawing %s", curApp->name().latin1() );
+ owarn << "Drawing " << curApp->name() << "" << oendl;
if ( (int)i == selectedAppIndex )
@@ -155,3 +159,3 @@ void RunningAppBar::applicationLaunched(const QString &appName)
{
- qDebug("desktop:: app: %s launched with pid ", appName.data() );
+ odebug << "desktop:: app: " << appName.data() << " launched with pid " << oendl;
const AppLnk* newGuy = ServerInterface::appLnks().findExec(appName);
diff --git a/core/launcher/screensaver.cpp b/core/launcher/screensaver.cpp
index 6aaab3a..a7d23c4 100644
--- a/core/launcher/screensaver.cpp
+++ b/core/launcher/screensaver.cpp
@@ -160,3 +160,3 @@ void OpieScreenSaver::setIntervals ( int dim, int lightoff, int suspend )
- //qDebug("screen saver intervals: %d %d %d", dim, lightoff, suspend);
+ //odebug << "screen saver intervals: " << dim << " " << lightoff << " " << suspend << "" << oendl;
diff --git a/core/launcher/server.cpp b/core/launcher/server.cpp
index 9a86a80..b9fa1e5 100644
--- a/core/launcher/server.cpp
+++ b/core/launcher/server.cpp
@@ -38,2 +38,6 @@
+/* OPIE */
+#include <opie2/odebug.h>
+#include <opie2/odevicebutton.h>
+#include <opie2/odevice.h>
#include <qtopia/applnk.h>
@@ -45,13 +49,7 @@
#include <qtopia/storage.h>
-
#include <qtopia/qcopenvelope_qws.h>
-#include <qwindowsystem_qws.h>
-#include <qgfx_qws.h>
#include <qtopia/global.h>
-//#include <qtopia/custom.h>
-
-#include <opie2/odevicebutton.h>
-#include <opie2/odevice.h>
+using namespace Opie::Core;
-#include <unistd.h>
+/* QT */
#include <qmainwindow.h>
@@ -60,3 +58,7 @@
#include <qtextstream.h>
+#include <qwindowsystem_qws.h>
+#include <qgfx_qws.h>
+/* STD */
+#include <unistd.h>
#include <stdlib.h>
@@ -65,4 +67,2 @@ extern QRect qt_maxWindowRect;
-
-using namespace Opie::Core;
static QWidget *calibrate(bool)
@@ -331,3 +331,3 @@ void Server::systemMsg(const QCString &msg, const QByteArray &data)
stream >> link;
- qDebug( "desktop.cpp systemMsg -> linkchanged( %s )", link.latin1() );
+ odebug << "desktop.cpp systemMsg -> linkchanged( " << link << " )" << oendl;
docList->linkChanged(link);
@@ -436,3 +436,3 @@ void Server::systemMsg(const QCString &msg, const QByteArray &data)
cfg.writeEntry( app, date );
- //qDebug("setSyncDate(QString,QString) %s %s", app.latin1(), date.latin1());
+ //odebug << "setSyncDate(QString,QString) " << app << " " << date << "" << oendl;
} else if ( msg == "startSync(QString)" ) {
@@ -574,3 +574,3 @@ bool Server::mkdir(const QString &localPath)
if (dirIndex == -1) {
- //qDebug("No seperators found in path %s", localPath.latin1());
+ //odebug << "No seperators found in path " << localPath << "" << oendl;
checkedPath = QDir::currentDirPath();
@@ -591,6 +591,6 @@ bool Server::mkdir(const QString &localPath)
if (!checkDir.exists()) {
- //qDebug("mkdir making dir %s", checkedPath.latin1());
+ //odebug << "mkdir making dir " << checkedPath << "" << oendl;
if (!checkDir.mkdir(checkedPath)) {
- qDebug("Unable to make directory %s", checkedPath.latin1());
+ odebug << "Unable to make directory " << checkedPath << "" << oendl;
return FALSE;
@@ -672,3 +672,3 @@ void Server::syncConnectionClosed( const QHostAddress & )
{
- qDebug( "Lost sync connection" );
+ odebug << "Lost sync connection" << oendl;
delete syncDialog;
diff --git a/core/launcher/serverapp.cpp b/core/launcher/serverapp.cpp
index e4e16f2..cf543ce 100644
--- a/core/launcher/serverapp.cpp
+++ b/core/launcher/serverapp.cpp
@@ -21,5 +21,7 @@
#include "serverapp.h"
+#include "screensaver.h"
+/* OPIE */
+#include <opie2/odebug.h>
#include <opie2/odevice.h>
-
#include <qtopia/password.h>
@@ -32,4 +34,5 @@
#include <qtopia/global.h>
-//#include <qtopia/custom.h>
+using namespace Opie::Core;
+/* QT */
#ifdef Q_WS_QWS
@@ -37,8 +40,2 @@
#endif
-#ifdef Q_OS_WIN32
-#include <io.h>
-#include <process.h>
-#else
-#include <unistd.h>
-#endif
#include <qmessagebox.h>
@@ -49,4 +46,10 @@
+/* STD */
+#ifdef Q_OS_WIN32
+#include <io.h>
+#include <process.h>
+#else
+#include <unistd.h>
+#endif
#include <stdlib.h>
-#include "screensaver.h"
@@ -55,5 +58,2 @@ static int loggedin=0;
-using namespace Opie;
-
-using namespace Opie::Core;
QCopKeyRegister::QCopKeyRegister()
@@ -858,3 +858,3 @@ int ServerApplication::exec()
ms_is_starting = true;
- qDebug("Serverapp - exec");
+ odebug << "Serverapp - exec" << oendl;
return QPEApplication::exec();
diff --git a/core/launcher/suspendmonitor.cpp b/core/launcher/suspendmonitor.cpp
index f555e84..50bc56f 100644
--- a/core/launcher/suspendmonitor.cpp
+++ b/core/launcher/suspendmonitor.cpp
@@ -52,3 +52,3 @@ void TempScreenSaverMonitor::setTempMode(int mode, int pid)
default:
- qWarning("Unrecognized temp power setting. Ignored");
+ owarn << "Unrecognized temp power setting. Ignored" << oendl;
return;
diff --git a/core/launcher/systray.cpp b/core/launcher/systray.cpp
index 6cc1446..3c72d25 100644
--- a/core/launcher/systray.cpp
+++ b/core/launcher/systray.cpp
@@ -20,2 +20,6 @@
+#include "systray.h"
+
+/* OPIE */
+#include <opie2/odebug.h>
#include <qtopia/qpeapplication.h>
@@ -23,3 +27,5 @@
#include <qtopia/config.h>
+using namespace Opie::Core;
+/* QT */
#include <qlayout.h>
@@ -27,13 +33,5 @@
-#include "systray.h"
-
+/* STD */
#include <stdlib.h>
-/* ### Single build floppies ### */
-#if 0
-#ifdef QT_NO_COMPONENTS
-#include "../plugins/applets/clockapplet/clockappletimpl.h"
-#endif
-#endif
-
SysTray::SysTray( QWidget *parent ) : QFrame( parent ), layout(0)
@@ -114,3 +112,3 @@ void SysTray::addApplets()
continue;
- qWarning( "Found Applet: %s", (*it).latin1() );
+ owarn << "Found Applet: " << (*it) << "" << oendl;
TaskbarAppletInterface *iface = 0;
diff --git a/core/launcher/taskbar.cpp b/core/launcher/taskbar.cpp
index 91e2f20..86e0d0d 100644
--- a/core/launcher/taskbar.cpp
+++ b/core/launcher/taskbar.cpp
@@ -30,2 +30,4 @@
+/* OPIE */
+#include <opie2/odebug.h>
#include <qtopia/config.h>
@@ -36,4 +38,5 @@
#include <qtopia/global.h>
-//#include <qtopia/custom.h>
+using namespace Opie::Core;
+/* QT */
#include <qlabel.h>
@@ -287,3 +290,3 @@ void TaskBar::resizeEvent( QResizeEvent *e )
- qWarning("TaskBar::resize event");
+ owarn << "TaskBar::resize event" << oendl;
}
diff --git a/core/launcher/transferserver.cpp b/core/launcher/transferserver.cpp
index e32cf41..4b764e3 100644
--- a/core/launcher/transferserver.cpp
+++ b/core/launcher/transferserver.cpp
@@ -19,7 +19,21 @@
**********************************************************************/
-//#define _XOPEN_SOURCE
+#include "transferserver.h"
+/* OPIE */
+#include <opie2/odebug.h>
#include <opie2/oglobal.h>
+#include <qtopia/qprocess.h>
+#include <qtopia/process.h>
+#include <qtopia/private/contact.h>
+#include <qtopia/version.h>
+#ifdef Q_WS_QWS
+#include <qtopia/qcopenvelope_qws.h>
+#endif
+using namespace Opie::Core;
-#ifndef Q_OS_WIN32
+/* QT */
+#include <qtextstream.h>
+#include <qmessagebox.h>
+
+/* STD */
#include <pwd.h>
@@ -35,29 +49,4 @@
-#else
-#include <stdlib.h>
-#include <time.h>
-#endif
-
-
-#if defined(_OS_LINUX_)
-#include <shadow.h>
-#endif
-
-#include <qtextstream.h>
-#include <qmessagebox.h>
-//#include <qtopia/qcopchannel_qws.h>
-#include <qtopia/process.h>
-#include <qtopia/private/contact.h>
-#include <qtopia/version.h>
-#ifdef Q_WS_QWS
-#include <qtopia/qcopenvelope_qws.h>
-#endif
-
-
-#include "transferserver.h"
-#include <qtopia/qprocess.h>
-
const int block_size = 51200;
-using namespace Opie::Core;
TransferServer::TransferServer( Q_UINT16 port, QObject *parent,
@@ -68,3 +57,3 @@ TransferServer::TransferServer( Q_UINT16 port, QObject *parent,
if ( !ok() )
- qWarning( "Failed to bind to port %d", port );
+ owarn << "Failed to bind to port " << port << "" << oendl;
}
@@ -373,3 +362,3 @@ void ServerPI::connectionClosed()
{
- // qDebug( "Debug: Connection closed" );
+ // odebug << "Debug: Connection closed" << oendl;
emit connectionClosed(this);
@@ -381,3 +370,3 @@ void ServerPI::send( const QString& msg )
os << msg << endl;
- //qDebug( "Reply: %s", msg.latin1() );
+ //odebug << "Reply: " << msg << "" << oendl;
}
@@ -422,3 +411,3 @@ void ServerPI::process( const QString& message )
{
- //qDebug( "Command: %s", message.latin1() );
+ //odebug << "Command: " << message << "" << oendl;
@@ -446,3 +435,3 @@ void ServerPI::process( const QString& message )
- //qDebug( "args: %s", args.latin1() );
+ //odebug << "args: " << args << "" << oendl;
@@ -585,3 +574,3 @@ void ServerPI::process( const QString& message )
else {
- qDebug("550 Requested action not taken");
+ odebug << "550 Requested action not taken" << oendl;
send( "550 Requested action not taken" ); // No tr
@@ -691,3 +680,3 @@ void ServerPI::process( const QString& message )
if ( args.isEmpty() ) {
- qDebug(" Error: no arg");
+ odebug << " Error: no arg" << oendl;
send( "500 Syntax error, command unrecognized" ); // No tr
@@ -731,3 +720,3 @@ void ServerPI::process( const QString& message )
if ( !duproc.exec(in, out) ) {
- qDebug("du process failed; just sending back 1K");
+ odebug << "du process failed; just sending back 1K" << oendl;
send( "213 1024");
@@ -739,3 +728,3 @@ void ServerPI::process( const QString& message )
guess *= 1000;
- qDebug("sending back gzip guess of %d", guess);
+ odebug << "sending back gzip guess of " << guess << "" << oendl;
send( "213 " + QString::number(guess) );
@@ -1028,3 +1017,3 @@ void ServerPI::newConnection( int socket )
{
- //qDebug( "New incomming connection" );
+ //odebug << "New incomming connection" << oendl;
@@ -1041,3 +1030,3 @@ void ServerPI::newConnection( int socket )
else if ( wait[RetrieveFile] ) {
- qDebug("check retrieve file");
+ odebug << "check retrieve file" << oendl;
if ( backupRestoreGzip( waitfile ) )
@@ -1053,3 +1042,3 @@ void ServerPI::newConnection( int socket )
else if ( wait[RetrieveByteArray] ) {
- qDebug("retrieve byte array");
+ odebug << "retrieve byte array" << oendl;
dtp->retrieveByteArray();
@@ -1113,3 +1102,3 @@ ServerDTP::~ServerDTP()
if ( recvFileSize >= 0 && (int)file.size() != recvFileSize ) {
- qDebug( "STOR incomplete" );
+ odebug << "STOR incomplete" << oendl;
file.remove();
@@ -1124,3 +1113,3 @@ void ServerDTP::extractTarDone()
{
- qDebug("extract done");
+ odebug << "extract done" << oendl;
#ifndef QT_NO_COP
@@ -1142,3 +1131,3 @@ void ServerDTP::connected()
- //qDebug( "Debug: Sending file '%s'", file.name().latin1() );
+ //odebug << "Debug: Sending file '" << file.name() << "'" << oendl;
@@ -1163,3 +1152,3 @@ void ServerDTP::connected()
// SHOULDN'T GET HERE, BUT DOING A SAFETY CHECK ANYWAY
- qWarning("Previous tar --gzip process is still running; killing it...");
+ owarn << "Previous tar --gzip process is still running; killing it..." << oendl;
createTargzProc->kill();
@@ -1168,3 +1157,3 @@ void ServerDTP::connected()
bytes_written = 0;
- qDebug("==>start send tar process");
+ odebug << "==>start send tar process" << oendl;
if ( !createTargzProc->start() )
@@ -1180,3 +1169,3 @@ void ServerDTP::connected()
- // qDebug( "Debug: Sending byte array" );
+ // odebug << "Debug: Sending byte array" << oendl;
bytes_written = 0;
@@ -1199,6 +1188,6 @@ void ServerDTP::connected()
}
- // qDebug( "Debug: Retrieving file %s", file.name().latin1() );
+ // odebug << "Debug: Retrieving file " << file.name() << "" << oendl;
break;
case RetrieveGzipFile:
- qDebug("=-> starting tar process to receive .tgz file");
+ odebug << "=-> starting tar process to receive .tgz file" << oendl;
break;
@@ -1211,6 +1200,6 @@ void ServerDTP::connected()
}
- // qDebug( "Debug: Retrieving byte array" );
+ // odebug << "Debug: Retrieving byte array" << oendl;
break;
case Idle:
- qDebug("connection established but mode set to Idle; BUG!");
+ odebug << "connection established but mode set to Idle; BUG!" << oendl;
break;
@@ -1221,3 +1210,3 @@ void ServerDTP::connectionClosed()
{
- //qDebug( "Debug: Data connection closed %ld bytes written", bytes_written );
+ //odebug << "Debug: Data connection closed " << bytes_written << " bytes written" << oendl;
@@ -1243,3 +1232,3 @@ void ServerDTP::connectionClosed()
if ( recvFileSize >= 0 && (int)file.size() != recvFileSize ) {
- qDebug( "STOR incomplete" );
+ odebug << "STOR incomplete" << oendl;
file.remove();
@@ -1252,3 +1241,3 @@ void ServerDTP::connectionClosed()
else if ( RetrieveGzipFile == mode ) {
- qDebug("Done writing ungzip file; closing input");
+ odebug << "Done writing ungzip file; closing input" << oendl;
retrieveTargzProc->flushStdin();
@@ -1274,3 +1263,3 @@ void ServerDTP::bytesWritten( int bytes )
if ( bytes_written == file.size() ) {
- // qDebug( "Debug: Sending complete: %d bytes", file.size() );
+ // odebug << "Debug: Sending complete: " << file.size() << " bytes" << oendl;
file.close();
@@ -1291,3 +1280,3 @@ void ServerDTP::bytesWritten( int bytes )
if ( bytes_written == buf.size() ) {
- // qDebug( "Debug: Sending complete: %d bytes", buf.size() );
+ // odebug << "Debug: Sending complete: " << buf.size() << " bytes" << oendl;
emit completed();
@@ -1315,3 +1304,3 @@ void ServerDTP::readyRead()
retrieveTargzProc->writeToStdin( s );
- qDebug("wrote %d bytes to ungzip ", s.size() );
+ odebug << "wrote " << s.size() << " bytes to ungzip " << oendl;
}
@@ -1330,3 +1319,3 @@ void ServerDTP::writeTargzBlock()
writeBlock( block.data(), block.size() );
- qDebug("writeTargzBlock %d", block.size());
+ odebug << "writeTargzBlock " << block.size() << "" << oendl;
}
@@ -1335,3 +1324,3 @@ void ServerDTP::targzDone()
{
- qDebug("tar and gzip done");
+ odebug << "tar and gzip done" << oendl;
emit completed();
@@ -1372,3 +1361,3 @@ void ServerDTP::sendGzipFile( const QString &fn,
args += archiveTargets;
- qDebug("sendGzipFile %s", args.join(" ").latin1() );
+ odebug << "sendGzipFile " << args.join(" ") << "" << oendl;
createTargzProc->setArguments( args );
@@ -1395,3 +1384,3 @@ void ServerDTP::retrieveGzipFile( const QString &fn )
{
- qDebug("retrieveGzipFile %s", fn.latin1());
+ odebug << "retrieveGzipFile " << fn << "" << oendl;
file.setName( fn );