-rw-r--r-- | core/launcher/serverapp.cpp | 26 |
1 files changed, 13 insertions, 13 deletions
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 @@ -1,106 +1,106 @@ /********************************************************************** ** Copyright (C) 2000-2003 Trolltech AS. All rights reserved. ** ** This file is part of the Qtopia Environment. ** ** This file may be distributed and/or modified under the terms of the ** GNU General Public License version 2 as published by the Free Software ** Foundation and appearing in the file LICENSE.GPL included in the ** packaging of this file. ** ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. ** ** See http://www.trolltech.com/gpl/ for GPL licensing information. ** ** Contact info@trolltech.com if any conditions of this licensing are ** not clear to you. ** **********************************************************************/ #include "serverapp.h" +#include "screensaver.h" +/* OPIE */ +#include <opie2/odebug.h> #include <opie2/odevice.h> - #include <qtopia/password.h> #include <qtopia/config.h> #include <qtopia/power.h> #ifdef Q_WS_QWS #include <qtopia/qcopenvelope_qws.h> #endif #include <qtopia/global.h> -//#include <qtopia/custom.h> +using namespace Opie::Core; +/* QT */ #ifdef Q_WS_QWS #include <qgfx_qws.h> #endif -#ifdef Q_OS_WIN32 -#include <io.h> -#include <process.h> -#else -#include <unistd.h> -#endif #include <qmessagebox.h> #include <qtimer.h> #include <qpainter.h> #include <qfile.h> #include <qpixmapcache.h> +/* STD */ +#ifdef Q_OS_WIN32 +#include <io.h> +#include <process.h> +#else +#include <unistd.h> +#endif #include <stdlib.h> -#include "screensaver.h" static ServerApplication *serverApp = 0; static int loggedin=0; -using namespace Opie; - -using namespace Opie::Core; QCopKeyRegister::QCopKeyRegister() : m_keyCode( 0 ) { } QCopKeyRegister::QCopKeyRegister( int k, const QCString& c, const QCString& m ) :m_keyCode( k ), m_channel( c ), m_message( m ) { } int QCopKeyRegister::keyCode()const { return m_keyCode; } QCString QCopKeyRegister::channel()const { return m_channel; } QCString QCopKeyRegister::message()const { return m_message; } bool QCopKeyRegister::send() { if (m_channel.isNull() ) return false; QCopEnvelope( m_channel, m_message ); return true; } //--------------------------------------------------------------------------- /* Priority is number of alerts that are needed to pop up alert. */ class DesktopPowerAlerter : public QMessageBox { Q_OBJECT public: DesktopPowerAlerter( QWidget *parent, const char *name = 0 ) : QMessageBox( tr("Battery Status"), tr("Low Battery"), QMessageBox::Critical, QMessageBox::Ok | QMessageBox::Default, QMessageBox::NoButton, QMessageBox::NoButton, parent, name, FALSE ) { currentPriority = INT_MAX; alertCount = 0; @@ -811,53 +811,53 @@ void ServerApplication::checkMemory() case MemVeryLow: memstate = MemUnknown; QMessageBox::critical( 0 , tr("Memory Status"), tr("Critical Memory Shortage\n" "Please end this application\n" "immediately.") ); recoverMemory(); } existingMessage = FALSE; #endif } bool ServerApplication::recoverMemory() { return FALSE; } void ServerApplication::keyClick(int , bool press, bool ) { if ( press && m_keyclick_sound ) ODevice::inst() -> playKeySound(); } void ServerApplication::screenClick(bool press) { if ( press && m_screentap_sound ) ODevice::inst() -> playTouchSound(); } void ServerApplication::soundAlarm() { if ( me ()->m_alarm_sound ) ODevice::inst()->playAlarmSound(); } ServerApplication *ServerApplication::me ( ) { return static_cast<ServerApplication*>( qApp ); } bool ServerApplication::isStarting() { return ms_is_starting; } int ServerApplication::exec() { ms_is_starting = true; - qDebug("Serverapp - exec"); + odebug << "Serverapp - exec" << oendl; return QPEApplication::exec(); } #include "serverapp.moc" |