summaryrefslogtreecommitdiff
path: root/core
authorzecke <zecke>2004-02-21 11:32:55 (UTC)
committer zecke <zecke>2004-02-21 11:32:55 (UTC)
commitf80b38b2e348b588bf7560161d7551e6bd4939c0 (patch) (side-by-side diff)
tree34c4359580641cb1447dab8df8731c9733e1d39f /core
parentb38daa3f05f3a250a8c5114890158863ab02a99f (diff)
downloadopie-f80b38b2e348b588bf7560161d7551e6bd4939c0.zip
opie-f80b38b2e348b588bf7560161d7551e6bd4939c0.tar.gz
opie-f80b38b2e348b588bf7560161d7551e6bd4939c0.tar.bz2
Move to LibOpie2
remove launcher global and use OGlobal
Diffstat (limited to 'core') (more/less context) (ignore whitespace changes)
-rw-r--r--core/launcher/applauncher.cpp11
-rw-r--r--core/launcher/config.in6
-rw-r--r--core/launcher/documentlist.cpp11
-rw-r--r--core/launcher/main.cpp9
-rw-r--r--core/launcher/qcopbridge.cpp7
-rw-r--r--core/launcher/screensaver.cpp2
-rw-r--r--core/launcher/server.cpp4
-rw-r--r--core/launcher/server.pro7
-rw-r--r--core/launcher/startmenu.cpp2
-rw-r--r--core/launcher/transferserver.cpp27
-rw-r--r--core/launcher/wait.cpp2
11 files changed, 45 insertions, 43 deletions
diff --git a/core/launcher/applauncher.cpp b/core/launcher/applauncher.cpp
index 0db99dd..f161e98 100644
--- a/core/launcher/applauncher.cpp
+++ b/core/launcher/applauncher.cpp
@@ -28,5 +28,5 @@
#define QTOPIA_PROGRAM_MONITOR
#endif
-#include <qtopia/global.h>
+#include <opie2/oglobal.h>
#ifndef Q_OS_WIN32
@@ -62,5 +62,4 @@
#include "applauncher.h"
#include "documentlist.h"
-#include "launcherglobal.h"
const int AppLauncher::RAISE_TIMEOUT_MS = 5000;
@@ -405,5 +404,5 @@ void AppLauncher::sigStopped(int sigPid, int sigStatus)
QMessageBox::information(0, tr("Application not found"), tr("<qt>Could not locate application <b>%1</b></qt>").arg( app->exec() ) );
} else {
- QFileInfo fi(Opie::Global::tempDir() + "qcop-msg-" + appName);
+ QFileInfo fi(OGlobal::tempDirPath() + "qcop-msg-" + appName);
if ( fi.exists() && fi.size() ) {
emit terminated(sigPid, appName);
@@ -447,6 +446,6 @@ bool AppLauncher::isRunning(const QString &app)
bool AppLauncher::executeBuiltin(const QString &c, const QString &document)
{
- Global::Command* builtin = Opie::Global::builtinCommands();
- QGuardedPtr<QWidget> *running = Opie::Global::builtinRunning();
+ Global::Command* builtin = OGlobal::builtinCommands();
+ QGuardedPtr<QWidget> *running = OGlobal::builtinRunning();
// Attempt to execute the app using a builtin class for the app
@@ -498,5 +497,5 @@ bool AppLauncher::execute(const QString &c, const QString &docParam, bool noRais
// Need to lock it to avoid race conditions with QPEApplication::processQCopFile
- QFile f(Opie::Global::tempDir() + "qcop-msg-" + appName);
+ QFile f(OGlobal::tempDirPath() + "qcop-msg-" + appName);
if ( !noRaise && f.open(IO_WriteOnly | IO_Append) ) {
#ifndef Q_OS_WIN32
diff --git a/core/launcher/config.in b/core/launcher/config.in
index 2d9c1c2..db39210 100644
--- a/core/launcher/config.in
+++ b/core/launcher/config.in
@@ -2,5 +2,5 @@
boolean "opie-taskbar (program launcher qpe for Opie)"
default "y"
- depends ( LIBQPE || LIBQPE-X11 ) && LIBOPIE
+ depends ( LIBQPE || LIBQPE-X11 ) && LIBOPIE2CORE && LIBOPIE2UI
if LAUNCHER
@@ -8,9 +8,9 @@ if LAUNCHER
boolean
default "y"
- depends ( LIBQPE || LIBQPE-X11 ) && LIBOPIE && LAUNCHER
+ depends ( LIBQPE || LIBQPE-X11 ) && LIBOPIE2UI && LAUNCHER
config LAUNCHER_CORE
boolean
default "y"
- depends ( LIBQPE || LIBQPE-X11 ) && LIBOPIE && LAUNCHER && PRELOAD
+ depends ( LIBQPE || LIBQPE-X11 ) && LIBOPIE2UI && LAUNCHER && PRELOAD
endif
diff --git a/core/launcher/documentlist.cpp b/core/launcher/documentlist.cpp
index ece6931..440bf1e 100644
--- a/core/launcher/documentlist.cpp
+++ b/core/launcher/documentlist.cpp
@@ -20,10 +20,10 @@
#include "documentlist.h"
#include "serverinterface.h"
-#include "launcherglobal.h"
+
+#include <opie2/oglobal.h>
#include <qtopia/config.h>
#include <qtopia/mimetype.h>
#include <qtopia/resource.h>
-#include <qtopia/global.h>
#include <qtopia/private/categories.h>
#include <qtopia/qpeapplication.h>
@@ -91,5 +91,8 @@ public:
-DocumentList::DocumentList( ServerInterface *serverGui, bool scanDocs,
+/*
+ * scandocs will be read from Config
+ */
+DocumentList::DocumentList( ServerInterface *serverGui, bool /*scanDocs*/,
QObject *parent, const char *name )
: QObject( parent, name )
@@ -270,5 +273,5 @@ void DocumentList::linkChanged( QString arg )
//qDebug( "linkchanged( %s )", arg.latin1() );
- if ( arg.isNull() || Opie::Global::isAppLnkFileName( arg ) ) {
+ if ( arg.isNull() || OGlobal::isAppLnkFileName( arg ) ) {
reloadAppLnks();
} else {
diff --git a/core/launcher/main.cpp b/core/launcher/main.cpp
index 988e432..bf06e75 100644
--- a/core/launcher/main.cpp
+++ b/core/launcher/main.cpp
@@ -28,5 +28,6 @@
#include "launcher.h"
#include "firstuse.h"
-#include "launcherglobal.h"
+
+#include <opie2/oglobal.h>
#include <qtopia/qpeapplication.h>
@@ -34,5 +35,5 @@
#include <qtopia/config.h>
//#include <qtopia/custom.h>
-#include <qtopia/global.h>
+
#include <qfile.h>
@@ -65,5 +66,5 @@
#include <qmessagebox.h>
-#include <opie/odevice.h>
+#include <opie2/odevice.h>
using namespace Opie;
@@ -72,5 +73,5 @@ using namespace Opie;
static void cleanup()
{
- QDir dir( Opie::Global::tempDir(), "qcop-msg-*" );
+ QDir dir( OGlobal::tempDirPath(), "qcop-msg-*" );
QStringList stale = dir.entryList();
diff --git a/core/launcher/qcopbridge.cpp b/core/launcher/qcopbridge.cpp
index 9cb56ce..b45f0cc 100644
--- a/core/launcher/qcopbridge.cpp
+++ b/core/launcher/qcopbridge.cpp
@@ -22,9 +22,11 @@
#include "transferserver.h"
+#include <opie2/oglobal.h>
+
#ifdef Q_WS_QWS
#include <qtopia/qcopenvelope_qws.h>
#endif
#include <qtopia/qpeapplication.h>
-#include <qtopia/global.h>
+
#include <qtopia/version.h>
#include <qtopia/config.h>
@@ -56,5 +58,4 @@
#endif
-#include "launcherglobal.h"
//#define INSECURE
@@ -326,5 +327,5 @@ void QCopBridgePI::sendDesktopMessage( const QCString &msg, const QByteArray& da
writeBlock(msg,msg.length());
writeBlock(" ",1);
- QByteArray b64 = Opie::Global::encodeBase64(data);
+ QByteArray b64 = OGlobal::encodeBase64(data);
writeBlock(b64.data(),b64.size());
writeBlock("\r\n",2);
diff --git a/core/launcher/screensaver.cpp b/core/launcher/screensaver.cpp
index 48770e8..1146dcd 100644
--- a/core/launcher/screensaver.cpp
+++ b/core/launcher/screensaver.cpp
@@ -6,5 +6,5 @@
#include <qpe/network.h>
-#include <opie/odevice.h>
+#include <opie2/odevice.h>
diff --git a/core/launcher/server.cpp b/core/launcher/server.cpp
index b9580c7..32fcdd0 100644
--- a/core/launcher/server.cpp
+++ b/core/launcher/server.cpp
@@ -52,6 +52,6 @@
//#include <qtopia/custom.h>
-#include <opie/odevicebutton.h>
-#include <opie/odevice.h>
+#include <opie2/odevicebutton.h>
+#include <opie2/odevice.h>
#include <unistd.h>
diff --git a/core/launcher/server.pro b/core/launcher/server.pro
index 0513536..f82c741 100644
--- a/core/launcher/server.pro
+++ b/core/launcher/server.pro
@@ -47,5 +47,4 @@ HEADERS += server.h \
syncdialog.h \
serverapp.h \
- launcherglobal.h \
qprocess.h \
screensaver.h
@@ -102,5 +101,4 @@ SOURCES += server.cpp \
syncdialog.cpp \
serverapp.cpp \
- launcherglobal.cpp \
qprocess.cpp \
qprocess_unix.cpp \
@@ -116,9 +114,10 @@ DEPENDPATH += $(OPIEDIR)/rsync
TARGET = qpe
+#needs OWait and ODevice
CONFTEST = $$system( echo $CONFIG_TARGET_MACOSX )
contains( CONFTEST, y ){
- LIBS += -lqpe -lopie
+ LIBS += -lqpe -lopiecore2 -lopieui2
}else{
- LIBS += -lcrypt -lqpe -lopie
+ LIBS += -lcrypt -lqpe -lopiecore2 -lopieui2
}
diff --git a/core/launcher/startmenu.cpp b/core/launcher/startmenu.cpp
index b84eed8..c199063 100644
--- a/core/launcher/startmenu.cpp
+++ b/core/launcher/startmenu.cpp
@@ -355,5 +355,4 @@ void StartMenu::loadApplets()
while ( napplets-- ) {
MenuApplet *applet = xapplets[napplets];
-
applet->popup = applet->iface->popup( this );
@@ -385,4 +384,5 @@ void StartMenu::addApplets(QPopupMenu* pop) {
applet->iface->text() );
+
dict.insert( applet->id, new MenuApplet( *applet ) );
}
diff --git a/core/launcher/transferserver.cpp b/core/launcher/transferserver.cpp
index 9519d11..9cb9d7a 100644
--- a/core/launcher/transferserver.cpp
+++ b/core/launcher/transferserver.cpp
@@ -20,5 +20,5 @@
//#define _XOPEN_SOURCE
-#include <qtopia/global.h>
+#include <opie2/oglobal.h>
#include <qtopia/qpeapplication.h>
@@ -33,5 +33,5 @@
#include <shadow.h>
#include <crypt.h>
-#endif /* Q_OS_MACX */
+#endif /* Q_OS_MACX */
#else
@@ -64,5 +64,4 @@
#endif
-#include "launcherglobal.h"
#include "transferserver.h"
@@ -115,5 +114,5 @@ QString SyncAuthentication::serverId()
if ( r.isEmpty() ) {
- r = Opie::Global::uuid();
+ r = OGlobal::generateUuid();
cfg.writeEntry("serverid", r );
}
@@ -194,16 +193,16 @@ bool SyncAuthentication::checkPassword( const QString& password )
static int denials=0;
int now = time(0);
-
+
Config cfg("Security");
- cfg.setGroup("Sync");
+ cfg.setGroup("Sync");
QString syncapp = cfg.readEntry("syncapp","Qtopia");
-
+
//No password needed if the user really wants it
if (syncapp == "IntelliSync") {
return TRUE;
- }
-
+ }
+
// Detect old Qtopia Desktop (no password)
- if ( password.isEmpty() ) {
+ if ( password.isEmpty() ) {
if ( denials < 3 || now > lastdenial+600 ) {
QMessageBox unauth(
@@ -220,8 +219,8 @@ bool SyncAuthentication::checkPassword( const QString& password )
denials++;
lastdenial=now;
- }
+ }
return FALSE;
-
- }
+
+ }
// Second, check sync password...
@@ -230,5 +229,5 @@ bool SyncAuthentication::checkPassword( const QString& password )
if ( lock ) return FALSE;
- ++lock;
+ ++lock;
/*
diff --git a/core/launcher/wait.cpp b/core/launcher/wait.cpp
index ab53a07..34ffd1a 100644
--- a/core/launcher/wait.cpp
+++ b/core/launcher/wait.cpp
@@ -24,5 +24,5 @@
#include <qtopia/config.h>
-#include <opie/owait.h>
+#include <opie2/owait.h>
#include <qwidget.h>