21 files changed, 135 insertions, 93 deletions
diff --git a/noncore/apps/opie-console/MyPty.cpp b/noncore/apps/opie-console/MyPty.cpp index a37f980..6d57703 100644 --- a/noncore/apps/opie-console/MyPty.cpp +++ b/noncore/apps/opie-console/MyPty.cpp @@ -65,3 +65,10 @@ +#include "procctl.h" +#include "MyPty.h" +/* OPIE */ +#include <opie2/odebug.h> +using namespace Opie::Core; + +/* QT */ #include <qsocketnotifier.h> @@ -69,2 +76,3 @@ +/* STD */ #include <stdlib.h> @@ -83,6 +91,2 @@ -#include "procctl.h" -#include "MyPty.h" - - #undef VERBOSE_DEBUG @@ -99,3 +103,3 @@ void MyPty::setSize(int lines, int columns) { - qWarning("setting size"); + owarn << "setting size" << oendl; struct winsize wsize; diff --git a/noncore/apps/opie-console/TEWidget.cpp b/noncore/apps/opie-console/TEWidget.cpp index e535296..d168a5e 100644 --- a/noncore/apps/opie-console/TEWidget.cpp +++ b/noncore/apps/opie-console/TEWidget.cpp @@ -1031,3 +1031,3 @@ bool TEWidget::eventFilter( QObject *obj, QEvent *e ) static bool alt = FALSE; -// qDebug(" Has a keyboard with no CTRL and ALT keys, but we fake it:"); +// odebug << " Has a keyboard with no CTRL and ALT keys, but we fake it:" << oendl; bool dele=FALSE; @@ -1070,3 +1070,3 @@ bool TEWidget::eventFilter( QObject *obj, QEvent *e ) -// qDebug("key pressed is 0x%x",ke->key()); +// odebug << "key pressed is 0x" << ke->key() << "" << oendl; @@ -1074,3 +1074,3 @@ bool TEWidget::eventFilter( QObject *obj, QEvent *e ) -// qDebug("key pressed 2 is 0x%x",ke->key()); +// odebug << "key pressed 2 is 0x" << ke->key() << "" << oendl; emitText("\\"); // expose diff --git a/noncore/apps/opie-console/TEmulation.cpp b/noncore/apps/opie-console/TEmulation.cpp index d0169d7..6ff73af 100644 --- a/noncore/apps/opie-console/TEmulation.cpp +++ b/noncore/apps/opie-console/TEmulation.cpp @@ -72,2 +72,8 @@ #include "TEmulation.h" + +/* OPIE */ +#include <opie2/odebug.h> +using namespace Opie::Core; + +/* STD */ #include <stdio.h> @@ -206,3 +212,3 @@ void TEmulation::onKeyPress( QKeyEvent* ev ) { - qWarning("onKeyPress,...."); + owarn << "onKeyPress,...." << oendl; if (!connected) return; // someone else gets the keys diff --git a/noncore/apps/opie-console/atconfigdialog.cpp b/noncore/apps/opie-console/atconfigdialog.cpp index 8e91b9e..c998f96 100644 --- a/noncore/apps/opie-console/atconfigdialog.cpp +++ b/noncore/apps/opie-console/atconfigdialog.cpp @@ -1,2 +1,9 @@ +#include "atconfigdialog.h" +#include "io_modem.h" +/* OPIE */ +#include <opie2/odebug.h> +using namespace Opie::Core; + +/* QT */ #include <qlineedit.h> @@ -9,6 +16,2 @@ -#include "atconfigdialog.h" -#include "io_modem.h" - - ATConfigDialog::ATConfigDialog( QWidget* parent, const char* name, bool modal, WFlags fl ) @@ -154,3 +157,3 @@ QWidget* ATConfigDialog::tab1( QWidget* parent ) { void ATConfigDialog::readConfig( const Profile& config ) { - qWarning("config in atconfigdialog"); + owarn << "config in atconfigdialog" << oendl; diff --git a/noncore/apps/opie-console/dialer.cpp b/noncore/apps/opie-console/dialer.cpp index 67ad10e..7010594 100644 --- a/noncore/apps/opie-console/dialer.cpp +++ b/noncore/apps/opie-console/dialer.cpp @@ -1,3 +1,9 @@ #include "dialer.h" +#include "io_modem.h" + +/* OPIE */ +#include <opie2/odebug.h> +using namespace Opie::Core; +/* QT */ #include <qlayout.h> @@ -10,2 +16,3 @@ +/* STD */ #include <unistd.h> @@ -15,4 +22,2 @@ -#include "io_modem.h" - // State machine: | When an error occurs, we don't have to @@ -106,3 +111,3 @@ void Dialer::reset() { - qWarning("reset"); + owarn << "reset" << oendl; switchState(state_cancel); @@ -138,3 +143,3 @@ void Dialer::trydial(const QString& number) { - qWarning("TryDial:%s", number.latin1() ); + owarn << "TryDial:" << number.latin1() << "" << oendl; if(state != state_cancel) switchState(state_preinit); @@ -142,3 +147,3 @@ void Dialer::trydial(const QString& number) { - qWarning("HangupString " + m_profile.readEntry("HangupString", MODEM_DEFAULT_HANGUP_STRING)); + owarn << "HangupString " << m_profile.readEntry("HangupString") << oendl; send(m_profile.readEntry("HangupString", MODEM_DEFAULT_HANGUP_STRING ) + "\r"); @@ -149,3 +154,3 @@ void Dialer::trydial(const QString& number) switchState(state_init); -// qWarning("Init String " + m_profile.readEntry("InitString") ); +// owarn << "Init String " + m_profile.readEntry("InitString") << oendl; send(m_profile.readEntry("InitString",MODEM_DEFAULT_INIT_STRING ) + "\r"); @@ -160,3 +165,3 @@ void Dialer::trydial(const QString& number) - qWarning("ATM3l3"); + owarn << "ATM3l3" << oendl; send("ATM3L3\r"); @@ -180,3 +185,3 @@ void Dialer::trydial(const QString& number) { - qWarning("progress"); + owarn << "progress" << oendl; switchState(state_dialing); @@ -216,3 +221,3 @@ void Dialer::send(const QString& msg) - qWarning("Sending: %s", m.latin1()); + owarn << "Sending: " << m.latin1() << "" << oendl; @@ -249,3 +254,3 @@ QString Dialer::receive() buffer[ret] = 0; - qWarning("Got: %s", buffer); + owarn << "Got: " << buffer << "" << oendl; buf.append(QString(buffer)); @@ -253,3 +258,3 @@ QString Dialer::receive() { - //qWarning("Receiving: '%s'", buf.latin1()); + //owarn << "Receiving: '" << buf.latin1() << "'" << oendl; cleanshutdown = 1; diff --git a/noncore/apps/opie-console/emulation_handler.cpp b/noncore/apps/opie-console/emulation_handler.cpp index 99d069f..89b70c6 100644 --- a/noncore/apps/opie-console/emulation_handler.cpp +++ b/noncore/apps/opie-console/emulation_handler.cpp @@ -1,4 +1,2 @@ - #include "TEmuVt102.h" - #include "profile.h" @@ -7,2 +5,6 @@ +/* OPIE */ +#include <opie2/odebug.h> +using namespace Opie::Core; + EmulationHandler::EmulationHandler( const Profile& prof, QWidget* parent,const char* name ) @@ -130,3 +132,3 @@ QColor EmulationHandler::foreColor(int col) { case Profile::Green: - qWarning("Foreground green"); + owarn << "Foreground green" << oendl; co = Qt::green; @@ -134,3 +136,3 @@ QColor EmulationHandler::foreColor(int col) { case Profile::Orange: - qWarning("Foreground orange"); + owarn << "Foreground orange" << oendl; co.setRgb( 231, 184, 98 ); @@ -154,3 +156,3 @@ QColor EmulationHandler::backColor(int col ) { case Profile::Green: - qWarning("Background black"); + owarn << "Background black" << oendl; co = Qt::black; @@ -158,3 +160,3 @@ QColor EmulationHandler::backColor(int col ) { case Profile::Orange: - qWarning("Background black"); + owarn << "Background black" << oendl; co = Qt::black; diff --git a/noncore/apps/opie-console/emulation_widget.cpp b/noncore/apps/opie-console/emulation_widget.cpp index ad8ecba..4688551 100644 --- a/noncore/apps/opie-console/emulation_widget.cpp +++ b/noncore/apps/opie-console/emulation_widget.cpp @@ -226,5 +226,5 @@ void EmulationWidget::calcGeometry() - qDebug( QString(" TEST").arg( contentsRect().width() ) ); - qDebug( QString(" TEST").arg( contentsRect().height() ) ); - qDebug("NEUER TESTT!!!!!!!!"); + odebug << QString(" TEST").arg( contentsRect().width() ) << oendl; + odebug << QString(" TEST").arg( contentsRect().height() ) << oendl; + odebug << "NEUER TESTT!!!!!!!!" << oendl; @@ -260,3 +260,3 @@ void EmulationWidget::drawAttrString( QString& string, QPainter &painter, QRect { - qWarning("Color1 %s", color_table[attr.b].color.name().latin1() ); + owarn << "Color1 " << color_table[attr.b].color.name().latin1() << "" << oendl; if ( usePixmap && color_table[attr.b].transparent ) @@ -274,3 +274,3 @@ void EmulationWidget::drawAttrString( QString& string, QPainter &painter, QRect painter.setBackgroundMode( OpaqueMode ); - qWarning("Color %s", color_table[attr.b].color.name().latin1() ); + owarn << "Color " << color_table[attr.b].color.name().latin1() << "" << oendl; painter.setBackgroundColor( color_table[attr.b].color ); diff --git a/noncore/apps/opie-console/function_keyboard.cpp b/noncore/apps/opie-console/function_keyboard.cpp index eb32551..6613183 100644 --- a/noncore/apps/opie-console/function_keyboard.cpp +++ b/noncore/apps/opie-console/function_keyboard.cpp @@ -2,2 +2,7 @@ +/* OPIE */ +#include <opie2/odebug.h> +using namespace Opie::Core; + +/* QT */ #include <qlayout.h> @@ -39,3 +44,3 @@ FunctionKeyboard::FunctionKeyboard(QWidget *parent) : } - //qWarning("loaded %d keys", keys.count()); + //owarn << "loaded " << keys.count() << " keys" << oendl; */ @@ -258,3 +263,3 @@ FunctionKeyboardConfig::FunctionKeyboardConfig(const QString& name, QWidget* par { - qWarning("FunctionKeyboardConfig"); + owarn << "FunctionKeyboardConfig" << oendl; diff --git a/noncore/apps/opie-console/io_bt.cpp b/noncore/apps/opie-console/io_bt.cpp index a29fa8e..c102427 100644 --- a/noncore/apps/opie-console/io_bt.cpp +++ b/noncore/apps/opie-console/io_bt.cpp @@ -3,3 +3,6 @@ +/* OPIE */ +#include <opie2/odebug.h> using namespace Opie::Core; + IOBt::IOBt( const Profile &config ) : IOSerial( config ) { @@ -45,3 +48,3 @@ bool IOBt::open() { } else { - qWarning("could not attach to device"); + owarn << "could not attach to device" << oendl; delete m_attach; @@ -91,3 +94,3 @@ bool IOBt::isConnected() { void IOBt::send(const QByteArray &data) { - qDebug( "Please overload me..." ); + odebug << "Please overload me..." << oendl; } diff --git a/noncore/apps/opie-console/io_irda.cpp b/noncore/apps/opie-console/io_irda.cpp index 07c2b62..38542f5 100644 --- a/noncore/apps/opie-console/io_irda.cpp +++ b/noncore/apps/opie-console/io_irda.cpp @@ -1,5 +1,7 @@ - #include "io_irda.h" +/* OPIE */ +#include <opie2/odebug.h> using namespace Opie::Core; + IOIrda::IOIrda( const Profile &config ) : IOSerial( config ) { @@ -37,3 +39,3 @@ bool IOIrda::open() { // emit error!!! - qWarning("could not attach to device"); + owarn << "could not attach to device" << oendl; delete m_attach; @@ -76,3 +78,3 @@ bool IOIrda::isConnected() { void IOIrda::send(const QByteArray &data) { - qDebug( "Please overload me..." ); + odebug << "Please overload me..." << oendl; } diff --git a/noncore/apps/opie-console/io_modem.cpp b/noncore/apps/opie-console/io_modem.cpp index b74d076..c499dfe 100644 --- a/noncore/apps/opie-console/io_modem.cpp +++ b/noncore/apps/opie-console/io_modem.cpp @@ -2,7 +2,8 @@ #include "io_modem.h" - #include "dialer.h" +/* OPIE */ +#include <opie2/odebug.h> using namespace Opie::Core; -using namespace Opie::Core; + IOModem::IOModem( const Profile &profile ) @@ -14,3 +15,2 @@ IOModem::IOModem( const Profile &profile ) IOModem::~IOModem() { - } @@ -106,3 +106,3 @@ bool IOModem::isConnected() { void IOModem::send(const QByteArray &data) { - qDebug( "Please overload me..." ); + odebug << "Please overload me..." << oendl; } diff --git a/noncore/apps/opie-console/main.cpp b/noncore/apps/opie-console/main.cpp index dfb2f83..1bd4338 100644 --- a/noncore/apps/opie-console/main.cpp +++ b/noncore/apps/opie-console/main.cpp @@ -93,3 +93,3 @@ int main(int argc, char **argv) { #ifdef FSCKED_DISTRIBUTION - qWarning("fscked"); + owarn << "fscked" << oendl; FixIt it; diff --git a/noncore/apps/opie-console/mainwindow.cpp b/noncore/apps/opie-console/mainwindow.cpp index 06a8f7d..b403b4d 100644 --- a/noncore/apps/opie-console/mainwindow.cpp +++ b/noncore/apps/opie-console/mainwindow.cpp @@ -1,14 +1 @@ -#include <assert.h> - -#include <qaction.h> -#include <qmenubar.h> -#include <qtoolbar.h> -#include <qmessagebox.h> -#include <qwhatsthis.h> -#include <qfileinfo.h> - -#include <qpe/filemanager.h> - -#include <opie2/ofiledialog.h> - #include "TEmulation.h" @@ -25,4 +12,20 @@ - +/* OPIE */ +#include <opie2/odebug.h> +#include <opie2/ofiledialog.h> +#include <qpe/filemanager.h> +using namespace Opie::Core; using namespace Opie::Ui; + +/* QT */ +#include <qaction.h> +#include <qmenubar.h> +#include <qtoolbar.h> +#include <qmessagebox.h> +#include <qwhatsthis.h> +#include <qfileinfo.h> + +/* STD */ +#include <assert.h> + MainWindow::MainWindow(QWidget *parent, const char *name, WFlags) : QMainWindow(parent, name, WStyle_ContextHelp) { @@ -448,3 +451,3 @@ void MainWindow::slotClose() { Session* ses = currentSession(); - qWarning("removing! currentSession %s", currentSession()->name().latin1() ); + owarn << "removing! currentSession " << currentSession()->name().latin1() << "" << oendl; /* set to NULL to be safe, if its needed slotSessionChanged resets it automatically */ @@ -454,3 +457,3 @@ void MainWindow::slotClose() { m_sessions.remove( ses ); - qWarning("after remove!!"); + owarn << "after remove!!" << oendl; @@ -572,3 +575,3 @@ void MainWindow::slotOpenButtons( bool state ) { void MainWindow::slotSessionChanged( Session* ses ) { - qWarning("changed!"); + owarn << "changed!" << oendl; @@ -581,3 +584,3 @@ void MainWindow::slotSessionChanged( Session* ses ) { m_curSession = ses; - qDebug(QString("is connected : %1").arg( m_curSession->layer()->isConnected() ) ); + odebug << QString("is connected : %1").arg( m_curSession->layer()->isConnected() ) << oendl; if ( m_curSession->layer()->isConnected() ) { diff --git a/noncore/apps/opie-console/modemconfigwidget.cpp b/noncore/apps/opie-console/modemconfigwidget.cpp index 3466e3a..9fdaf73 100644 --- a/noncore/apps/opie-console/modemconfigwidget.cpp +++ b/noncore/apps/opie-console/modemconfigwidget.cpp @@ -1,4 +1,10 @@ +#include "modemconfigwidget.h" +#include "dialdialog.h" +/* OPIE */ +#include <opie2/odebug.h> #include <qpe/qpeapplication.h> +using namespace Opie::Core; +/* QT */ #include <qlabel.h> @@ -9,5 +15,2 @@ -#include "modemconfigwidget.h" -#include "dialdialog.h" - namespace { @@ -137,3 +140,3 @@ void ModemConfigWidget::load( const Profile& prof ) { if ( prof.readEntry( "Device" ).isEmpty() ) { - qWarning("device empty!"); + owarn << "device empty!" << oendl; return; diff --git a/noncore/apps/opie-console/opie-console.pro b/noncore/apps/opie-console/opie-console.pro index 7a15828..f7e33e9 100644 --- a/noncore/apps/opie-console/opie-console.pro +++ b/noncore/apps/opie-console/opie-console.pro @@ -1,5 +1,3 @@ TEMPLATE = app -TMAKE_CXXFLAGS += -DHAVE_OPENPTY CONFIG += qt warn_on -#CONFIG = qt DESTDIR = $(OPIEDIR)/bin @@ -72,3 +70,3 @@ TARGET = opie-console - +DEFINES += HAVE_OPENPTY diff --git a/noncore/apps/opie-console/sz_transfer.cpp b/noncore/apps/opie-console/sz_transfer.cpp index fbc5306..f505998 100644 --- a/noncore/apps/opie-console/sz_transfer.cpp +++ b/noncore/apps/opie-console/sz_transfer.cpp @@ -43,3 +43,3 @@ void SzTransfer::SzReceivedStdout(OProcess *, char *buffer, int buflen) { - qWarning("recieved from sz on stdout %d bytes", buflen); + owarn << "recieved from sz on stdout " << buflen << " bytes" << oendl; @@ -67,3 +67,3 @@ void SzTransfer::receivedStdin(const QByteArray &data) { - qWarning("recieved from io_serial %d bytes", data.size()); + owarn << "recieved from io_serial " << data.size() << " bytes" << oendl; @@ -76,3 +76,3 @@ void SzTransfer::sent() { - qWarning("sent file"); + owarn << "sent file" << oendl; diff --git a/noncore/apps/opie-console/tabwidget.cpp b/noncore/apps/opie-console/tabwidget.cpp index 6429e3c..41a91ed 100644 --- a/noncore/apps/opie-console/tabwidget.cpp +++ b/noncore/apps/opie-console/tabwidget.cpp @@ -1,5 +1,8 @@ - #include "tabwidget.h" +/* OPIE */ +#include <opie2/odebug.h> +using namespace Opie::Core; using namespace Opie::Ui; + TabWidget::TabWidget( QWidget* parent, const char* name ) @@ -14,3 +17,3 @@ TabWidget::~TabWidget() { void TabWidget::add( Session* ses ) { - qWarning("session ses " + ses->name() ); + owarn << "session ses " + ses->name() << oendl; if ( !ses->widgetStack() ) return; diff --git a/noncore/apps/opie-console/terminalwidget.cpp b/noncore/apps/opie-console/terminalwidget.cpp index 6870487..087476b 100644 --- a/noncore/apps/opie-console/terminalwidget.cpp +++ b/noncore/apps/opie-console/terminalwidget.cpp @@ -1 +1,8 @@ +#include "terminalwidget.h" + +/* OPIE */ +#include <opie2/odebug.h> +using namespace Opie::Core; + +/* QT */ #include <qlabel.h> @@ -8,4 +15,2 @@ -#include "terminalwidget.h" - namespace { @@ -71,3 +76,3 @@ TerminalWidget::TerminalWidget( const QString& name, QWidget* parent, // Fill in some options - qWarning("Options for terminal box"); + owarn << "Options for terminal box" << oendl; m_terminalBox->insertItem( tr("VT 100"), 0 ); // /*, id_term_vt100*/ ); diff --git a/noncore/apps/opie-console/test/senderui.cpp b/noncore/apps/opie-console/test/senderui.cpp index df27055..45fd11d 100644 --- a/noncore/apps/opie-console/test/senderui.cpp +++ b/noncore/apps/opie-console/test/senderui.cpp @@ -28,3 +28,3 @@ SenderUI::SenderUI() - qWarning("prof " + prof.readEntry("Device") + " " + str); + owarn << "prof " + prof.readEntry("Device") + " " + str << oendl; ser = new IOSerial(prof); @@ -34,5 +34,5 @@ SenderUI::SenderUI() if ( ser->open() ) - qWarning("opened!!!"); + owarn << "opened!!!" << oendl; else - qWarning("could not open"); + owarn << "could not open" << oendl; @@ -54,3 +54,3 @@ void SenderUI::slotSend() { QCString str = MultiLineEdit1->text().utf8(); - qWarning("sending: %s", str.data() ); + owarn << "sending: " << str.data() << "" << oendl; str = str.replace( QRegExp("\n"), "\r"); @@ -59,3 +59,3 @@ void SenderUI::slotSend() { void SenderUI::got(const QByteArray& ar) { - qWarning("got:"); + owarn << "got:" << oendl; for ( uint i = 0; i < ar.count(); i++ ) { @@ -68,3 +68,3 @@ void SenderUI::fileTransComplete() { - qWarning("file transfer complete"); + owarn << "file transfer complete" << oendl; } @@ -74,3 +74,3 @@ void SenderUI::send() { void SenderUI::slotRev(){ -qWarning("Going to receive!"); +owarn << "Going to receive!" << oendl; FileReceive *rev = new FileReceive( FileReceive::SZ, ser ); diff --git a/noncore/apps/opie-console/widget.cpp b/noncore/apps/opie-console/widget.cpp index e17dfd4..c51983f 100644 --- a/noncore/apps/opie-console/widget.cpp +++ b/noncore/apps/opie-console/widget.cpp @@ -997,3 +997,3 @@ bool Widget::eventFilter( QObject *obj, QEvent *e ) static bool alt = FALSE; -// qDebug(" Has a keyboard with no CTRL and ALT keys, but we fake it:"); +// odebug << " Has a keyboard with no CTRL and ALT keys, but we fake it:" << oendl; bool dele=FALSE; @@ -1036,3 +1036,3 @@ bool Widget::eventFilter( QObject *obj, QEvent *e ) -// qDebug("key pressed is 0x%x",ke->key()); +// odebug << "key pressed is 0x" << ke->key() << "" << oendl; @@ -1040,3 +1040,3 @@ bool Widget::eventFilter( QObject *obj, QEvent *e ) -// qDebug("key pressed 2 is 0x%x",ke->key()); +// odebug << "key pressed 2 is 0x" << ke->key() << "" << oendl; emitText("\\"); // expose diff --git a/noncore/apps/opie-console/widget_layer.cpp b/noncore/apps/opie-console/widget_layer.cpp index 96dda1c..ab25919 100644 --- a/noncore/apps/opie-console/widget_layer.cpp +++ b/noncore/apps/opie-console/widget_layer.cpp @@ -77,3 +77,3 @@ bool WidgetLayer::eventFilter( QObject *obj, QEvent *e ) static bool alt = false; -// qDebug(" Has a keyboard with no CTRL and ALT keys, but we fake it:"); +// odebug << " Has a keyboard with no CTRL and ALT keys, but we fake it:" << oendl; bool dele = false; @@ -117,3 +117,3 @@ QChar(a,0)); -// qDebug("key pressed is 0x%x",ke->key()); +// odebug << "key pressed is 0x" << ke->key() << "" << oendl; |