author | mickeyl <mickeyl> | 2004-04-05 12:48:49 (UTC) |
---|---|---|
committer | mickeyl <mickeyl> | 2004-04-05 12:48:49 (UTC) |
commit | f1708be741dfb73ceaffb633b44093f2cb2b3d57 (patch) (side-by-side diff) | |
tree | 0bdcab2ac6c5f0e5cac67eb58807a50bb79d82e0 | |
parent | 0b481957a2eebf28b05d9803780d05ad4232aa00 (diff) | |
download | opie-f1708be741dfb73ceaffb633b44093f2cb2b3d57.zip opie-f1708be741dfb73ceaffb633b44093f2cb2b3d57.tar.gz opie-f1708be741dfb73ceaffb633b44093f2cb2b3d57.tar.bz2 |
convert core/applets/* to Opie debug framework
-rw-r--r-- | core/applets/cardmon/cardmon.cpp | 26 | ||||
-rw-r--r-- | core/applets/clockapplet/clock.cpp | 10 | ||||
-rw-r--r-- | core/applets/irdaapplet/irda.cpp | 4 | ||||
-rw-r--r-- | core/applets/multikeyapplet/multikey.cpp | 2 | ||||
-rw-r--r-- | core/applets/restartapplet/restart.cpp | 2 | ||||
-rw-r--r-- | core/applets/restartapplet/restartappletimpl.cpp | 5 | ||||
-rw-r--r-- | core/applets/rotateapplet/rotate.cpp | 9 | ||||
-rw-r--r-- | core/applets/screenshotapplet/screenshot.cpp | 522 | ||||
-rw-r--r-- | core/applets/vmemo/vmemo.cpp | 108 | ||||
-rw-r--r-- | core/applets/vtapplet/vt.cpp | 65 | ||||
-rw-r--r-- | core/obex/obexsend.cpp | 29 | ||||
-rw-r--r-- | core/obex/receiver.cpp | 41 |
12 files changed, 417 insertions, 406 deletions
diff --git a/core/applets/cardmon/cardmon.cpp b/core/applets/cardmon/cardmon.cpp index 1ad8b55..3a6ad27 100644 --- a/core/applets/cardmon/cardmon.cpp +++ b/core/applets/cardmon/cardmon.cpp @@ -20,8 +20,11 @@ /* OPIE */ +#include <opie2/odebug.h> #include <opie2/odevice.h> #include <opie2/otaskbarapplet.h> #include <qpe/applnk.h> #include <qpe/resource.h> +using namespace Opie::Core; +using namespace Opie::Ui; /* QT */ @@ -39,5 +42,4 @@ #include <string.h> #include <fcntl.h> - #if defined(_OS_LINUX_) || defined(Q_OS_LINUX) #include <sys/vfs.h> @@ -45,10 +47,4 @@ #endif -using namespace Opie; - -using namespace Opie::Ui; -using namespace Opie::Ui; -using namespace Opie::Core; - CardMonitor::CardMonitor( QWidget * parent ) : QWidget( parent ), pm( Resource::loadPixmap( "cardmon/pcmcia" ) ) @@ -198,10 +194,10 @@ void CardMonitor::cardMessage( const QCString & msg, const QByteArray & ) if ( msg == "stabChanged()" ) { - // qDebug("Pcmcia: stabchanged"); + // odebug << "Pcmcia: stabchanged" << oendl; getStatusPcmcia(); } else if ( msg == "mtabChanged()" ) { - // qDebug("CARDMONAPPLET: mtabchanged"); + // odebug << "CARDMONAPPLET: mtabchanged" << oendl; getStatusSd(); } @@ -211,5 +207,5 @@ bool CardMonitor::getStatusPcmcia( int showPopUp ) { - bool cardWas0 = cardInPcmcia0; // remember last state + bool cardWas0 = cardInPcmcia0; // remember last state bool cardWas1 = cardInPcmcia1; @@ -332,5 +328,5 @@ bool CardMonitor::getStatusPcmcia( int showPopUp ) { // no file found - qDebug( "no file found" ); + odebug << "no file found" << oendl; cardInPcmcia0 = FALSE; cardInPcmcia1 = FALSE; @@ -346,5 +342,5 @@ bool CardMonitor::getStatusSd( int showPopUp ) { - bool cardWas = cardInSd; // remember last state + bool cardWas = cardInSd; // remember last state cardInSd = FALSE; @@ -358,5 +354,5 @@ bool CardMonitor::getStatusSd( int showPopUp ) { QString fs = me->mnt_fsname; - //qDebug( fs ); + //odebug << fs << oendl; if ( fs.left( 14 ) == "/dev/mmc/part1" || fs.left( 7 ) == "/dev/sd" || fs.left( 9 ) == "/dev/mmcd" ) @@ -386,9 +382,9 @@ bool CardMonitor::getStatusSd( int showPopUp ) what = "off"; } - //qDebug("TEXT: " + text ); + //odebug << "TEXT: " + text << oendl; #ifndef QT_NO_SOUND QSound::play( Resource::findSound( "cardmon/card" + what ) ); #endif - popUp( text, "cardmon/ide" ); // XX add SD pic + popUp( text, "cardmon/ide" ); // XX add SD pic } #else diff --git a/core/applets/clockapplet/clock.cpp b/core/applets/clockapplet/clock.cpp index 3b13d74..7d396e7 100644 --- a/core/applets/clockapplet/clock.cpp +++ b/core/applets/clockapplet/clock.cpp @@ -21,4 +21,6 @@ #include "clock.h" +/* OPIE */ +#include <opie2/odebug.h> #include <opie2/otaskbarapplet.h> #include <qpe/qpeapplication.h> @@ -26,5 +28,7 @@ #include <qpe/config.h> +using namespace Opie::Core; using namespace Opie::Ui; + LauncherClock::LauncherClock( QWidget *parent ) : QLabel( parent ) { @@ -56,7 +60,7 @@ void LauncherClock::readConfig() { void LauncherClock::mouseReleaseEvent( QMouseEvent * ) { - QCString setTimeApp; - setTimeApp="systemtime"; - QCopEnvelope e("QPE/Application/"+setTimeApp, "raise()"); + QCString setTimeApp; + setTimeApp="systemtime"; + QCopEnvelope e("QPE/Application/"+setTimeApp, "raise()"); } diff --git a/core/applets/irdaapplet/irda.cpp b/core/applets/irdaapplet/irda.cpp index 2196d18..7122b40 100644 --- a/core/applets/irdaapplet/irda.cpp +++ b/core/applets/irdaapplet/irda.cpp @@ -208,5 +208,5 @@ void IrdaApplet::showDiscovered ( ) deviceAddr = line. mid ( line. find ( "daddr:" ) + 9, 8 ); - // qDebug(discoveredDevice + "(" + deviceAddr + ")"); + // odebug << discoveredDevice + "(" + deviceAddr + ")" << oendl; if ( !m_devices. contains ( deviceAddr )) { @@ -220,5 +220,5 @@ void IrdaApplet::showDiscovered ( ) for ( it = m_devices. begin ( ); it != m_devices. end ( ); ) { - // qDebug("IrdaMon: delete " + it.currentKey() + "=" + *devicesAvailable[it.currentKey()] + "?"); + // odebug << "IrdaMon: delete " + it.currentKey() + "=" + *devicesAvailable[it.currentKey()] + "?" << oendl; if ( it. data ( ). left ( 3 ) == "+++" ) { diff --git a/core/applets/multikeyapplet/multikey.cpp b/core/applets/multikeyapplet/multikey.cpp index 195ada5..195d8a4 100644 --- a/core/applets/multikeyapplet/multikey.cpp +++ b/core/applets/multikeyapplet/multikey.cpp @@ -69,5 +69,5 @@ void Multikey::mouseReleaseEvent(QMouseEvent *ev) lang = lang < sw_maps.count()-1 ? lang+1 : 0; QCopEnvelope e("MultiKey/Keyboard", "setmultikey(QString)"); - //qDebug("Lang=%d, count=%d, lab=%s", lang, sw_maps.count(), labels[lang].ascii()); + //odebug << "Lang=" << lang << ", count=" << sw_maps.count() << ", lab=" << labels[lang].ascii() << "" << oendl; e << sw_maps[lang]; setText(labels[lang]); diff --git a/core/applets/restartapplet/restart.cpp b/core/applets/restartapplet/restart.cpp index 226c2a8..2e17608 100644 --- a/core/applets/restartapplet/restart.cpp +++ b/core/applets/restartapplet/restart.cpp @@ -54,5 +54,4 @@ RestartApplet::RestartApplet( QWidget *parent, const char *name ) setFixedHeight( 18 ); setFixedWidth( 16 ); - qDebug("new restartapplet"); show(); } @@ -67,5 +66,4 @@ void RestartApplet::mousePressEvent( QMouseEvent *) { void RestartApplet::paintEvent( QPaintEvent* ) { QPainter p(this); - qDebug("paint RESTART pixmap"); p.drawPixmap( 0, 1, ( const char** ) restart_xpm ); } diff --git a/core/applets/restartapplet/restartappletimpl.cpp b/core/applets/restartapplet/restartappletimpl.cpp index d8e10d3..3adc80c 100644 --- a/core/applets/restartapplet/restartappletimpl.cpp +++ b/core/applets/restartapplet/restartappletimpl.cpp @@ -34,5 +34,4 @@ RestartAppletImpl::~RestartAppletImpl() QWidget *RestartAppletImpl::applet( QWidget *parent ) { - qDebug("restart applet"); if ( !restart ) restart = new RestartApplet( parent ); @@ -53,6 +52,6 @@ QRESULT RestartAppletImpl::queryInterface( const QUuid &uuid, QUnknownInterface *iface = this; else - return QS_FALSE; - + return QS_FALSE; + if ( *iface ) (*iface)->addRef(); diff --git a/core/applets/rotateapplet/rotate.cpp b/core/applets/rotateapplet/rotate.cpp index f621aa9..f23423d 100644 --- a/core/applets/rotateapplet/rotate.cpp +++ b/core/applets/rotateapplet/rotate.cpp @@ -32,4 +32,5 @@ /* OPIE */ +#include <opie2/odebug.h> #include <opie2/odevice.h> #include <qpe/config.h> @@ -63,5 +64,5 @@ RotateApplet::~RotateApplet ( ) void RotateApplet::channelReceived( const QCString &msg, const QByteArray & data ) { - qDebug( "RotateApplet::channelReceived( '%s' )", (const char*) msg ); + odebug << "RotateApplet::channelReceived( '" << msg << "' )" << oendl; if ( ODevice::inst()->hasHingeSensor() ) @@ -73,5 +74,5 @@ void RotateApplet::channelReceived( const QCString &msg, const QByteArray & data ::nanosleep( &interval, &remain ); OHingeStatus status = ODevice::inst()->readHingeSensor(); - qDebug( "RotateApplet::readHingeSensor = %d", (int) status ); + odebug << "RotateApplet::readHingeSensor = " << (int) status << "" << oendl; Config cfg( "apm" ); @@ -97,5 +98,5 @@ void RotateApplet::channelReceived( const QCString &msg, const QByteArray & data } } - qDebug( "RotateApplet::switchAction %d performed.", cfg.readNumEntry( "CloseHingeAction", 0 ) ); + odebug << "RotateApplet::switchAction " << cfg.readNumEntry( "CloseHingeAction" ) << " performed." << oendl; } @@ -240,5 +241,5 @@ QRESULT RotateApplet::queryInterface( const QUuid &uuid, QUnknownInterface **ifa *iface = this; else - return QS_FALSE; + return QS_FALSE; if ( *iface ) diff --git a/core/applets/screenshotapplet/screenshot.cpp b/core/applets/screenshotapplet/screenshot.cpp index 9aa012a..938ea0c 100644 --- a/core/applets/screenshotapplet/screenshot.cpp +++ b/core/applets/screenshotapplet/screenshot.cpp @@ -17,7 +17,10 @@ /* OPIE */ +#include <opie2/odebug.h> #include <opie2/otaskbarapplet.h> #include <qpe/qpeapplication.h> #include <qpe/applnk.h> +using namespace Opie::Core; +using namespace Opie::Ui; /* QT */ @@ -40,184 +43,183 @@ /* XPM */ -using namespace Opie::Ui; static char * snapshot_xpm[] = { "32 32 177 2", -" c None", -". c #042045", -"+ c #0D2B47", -"@ c #0E325E", -"# c #0D2E50", -"$ c #0A1C32", -"% c #0F3A69", -"& c #164680", -"* c #165EAE", -"= c #134D89", -"- c #0A3A6E", -"; c #031024", -"> c #031B36", -", c #1A5EA3", -"' c #1862B1", -") c #1866B9", -"! c #0F5AAC", -"~ c #0F56A8", -"{ c #0C4C96", -"] c #030918", -"^ c #060206", -"/ c #20242C", -"( c #3E3B3B", -"_ c #186ABD", -": c #115EB3", -"< c #082644", -"[ c #222C38", -"} c #5A5859", -"| c #091921", -"1 c #1E7EDE", -"2 c #1A7ADA", -"3 c #1970CD", -"4 c #1758A1", -"5 c #0E529A", -"6 c #094388", -"7 c #22364E", -"8 c #384454", -"9 c #04162C", -"0 c #123451", -"a c #3296B4", -"b c #298AB1", -"c c #2484AC", -"d c #033D86", -"e c #033677", -"f c #072C58", -"g c #525862", -"h c #5E5E5E", -"i c #23492A", -"j c #4FBD3F", -"k c #50B24C", -"l c #51C72E", -"m c #42C64A", -"n c #2686CA", -"o c #0B52A4", -"p c #054A9A", -"q c #053B7C", -"r c #2B2325", -"s c #6E7070", -"t c #0D240E", -"u c #1E423E", -"v c #468ABE", -"w c #6A8AC2", -"x c #7EAA8E", -"y c #84BE4E", -"z c #65C639", -"A c #064EA0", -"B c #0A4DA0", -"C c #4E5242", -"D c #62362E", -"E c #721A1A", -"F c #6E0A0A", -"G c #3E0E0E", -"H c #6AB85E", -"I c #7E8ECA", -"J c #929CD4", -"K c #9EAECA", -"L c #9EBEAE", -"M c #8EC26A", -"N c #32A276", -"O c #20518C", -"P c #46566E", -"Q c #614A51", -"R c #AE2A26", -"S c #C41C1A", -"T c #CE0A0A", -"U c #A60606", -"V c #921616", -"W c #863735", -"X c #866A66", -"Y c #9E9EA2", -"Z c #1E5212", -"` c #7EC652", -" . c #B2B2F2", -".. c #CACAF6", -"+. c #AECEC6", -"@. c #92CE72", -"#. c #42AA86", -"$. c #365E96", -"%. c #B82420", -"&. c #E20E0E", -"*. c #EF0E0B", -"=. c #566A86", -"-. c #92929A", -";. c #16260E", -">. c #2E571A", -",. c #7ED64E", -"'. c #9ECEB2", -"). c #C6D5EF", -"!. c #E2E0FE", -"~. c #A2DE8A", -"{. c #4AAA5B", -"]. c #2A6AB2", -"^. c #9A7A6E", -"/. c #D25A52", -"(. c #F62626", -"_. c #FA0206", -":. c #DE1E16", -"<. c #B63A26", -"[. c #865A2E", -"}. c #26568E", -"|. c #435F7D", -"1. c #7AE246", -"2. c #96EA6E", -"3. c #BEEAAE", -"4. c #D0EADC", -"5. c #B6CEFE", -"6. c #9ADE8A", -"7. c #2A609A", -"8. c #7E623E", -"9. c #CA7A72", -"0. c #F26E6E", -"a. c #FE5252", -"b. c #FA3638", -"c. c #DA2E28", -"d. c #9E3E3A", -"e. c #3E7656", -"f. c #76CB3A", -"g. c #90DE44", -"h. c #A2EE6A", -"i. c #9EEA9A", -"j. c #92BEDE", -"k. c #7ADA7E", -"l. c #5ECE52", -"m. c #6A5E52", -"n. c #A83238", -"o. c #FA5656", -"p. c #F29A92", -"q. c #D29E92", -"r. c #8A7A62", -"s. c #05336B", -"t. c #59C631", -"u. c #8AD23A", -"v. c #66E242", -"w. c #1D6FC1", -"x. c #E61212", -"y. c #CA261E", -"z. c #5A763E", -"A. c #1E6E9A", -"B. c #023272", -"C. c #329696", -"D. c #2074B6", -"E. c #3E4E76", -"F. c #5A525E", -"G. c #425868", -"H. c #04448E", -"I. c #28828A", -"J. c #2D8593", -"K. c #12427A", -"L. c #054696", -"M. c #042B5E", -"N. c #134F95", -"O. c #1E6ABB", -"P. c #1A5E96", -"Q. c #022E67", -"R. c #0C3E7C", -"S. c #023E8A", -"T. c #021A3E", +" c None", +". c #042045", +"+ c #0D2B47", +"@ c #0E325E", +"# c #0D2E50", +"$ c #0A1C32", +"% c #0F3A69", +"& c #164680", +"* c #165EAE", +"= c #134D89", +"- c #0A3A6E", +"; c #031024", +"> c #031B36", +", c #1A5EA3", +"' c #1862B1", +") c #1866B9", +"! c #0F5AAC", +"~ c #0F56A8", +"{ c #0C4C96", +"] c #030918", +"^ c #060206", +"/ c #20242C", +"( c #3E3B3B", +"_ c #186ABD", +": c #115EB3", +"< c #082644", +"[ c #222C38", +"} c #5A5859", +"| c #091921", +"1 c #1E7EDE", +"2 c #1A7ADA", +"3 c #1970CD", +"4 c #1758A1", +"5 c #0E529A", +"6 c #094388", +"7 c #22364E", +"8 c #384454", +"9 c #04162C", +"0 c #123451", +"a c #3296B4", +"b c #298AB1", +"c c #2484AC", +"d c #033D86", +"e c #033677", +"f c #072C58", +"g c #525862", +"h c #5E5E5E", +"i c #23492A", +"j c #4FBD3F", +"k c #50B24C", +"l c #51C72E", +"m c #42C64A", +"n c #2686CA", +"o c #0B52A4", +"p c #054A9A", +"q c #053B7C", +"r c #2B2325", +"s c #6E7070", +"t c #0D240E", +"u c #1E423E", +"v c #468ABE", +"w c #6A8AC2", +"x c #7EAA8E", +"y c #84BE4E", +"z c #65C639", +"A c #064EA0", +"B c #0A4DA0", +"C c #4E5242", +"D c #62362E", +"E c #721A1A", +"F c #6E0A0A", +"G c #3E0E0E", +"H c #6AB85E", +"I c #7E8ECA", +"J c #929CD4", +"K c #9EAECA", +"L c #9EBEAE", +"M c #8EC26A", +"N c #32A276", +"O c #20518C", +"P c #46566E", +"Q c #614A51", +"R c #AE2A26", +"S c #C41C1A", +"T c #CE0A0A", +"U c #A60606", +"V c #921616", +"W c #863735", +"X c #866A66", +"Y c #9E9EA2", +"Z c #1E5212", +"` c #7EC652", +" . c #B2B2F2", +".. c #CACAF6", +"+. c #AECEC6", +"@. c #92CE72", +"#. c #42AA86", +"$. c #365E96", +"%. c #B82420", +"&. c #E20E0E", +"*. c #EF0E0B", +"=. c #566A86", +"-. c #92929A", +";. c #16260E", +">. c #2E571A", +",. c #7ED64E", +"'. c #9ECEB2", +"). c #C6D5EF", +"!. c #E2E0FE", +"~. c #A2DE8A", +"{. c #4AAA5B", +"]. c #2A6AB2", +"^. c #9A7A6E", +"/. c #D25A52", +"(. c #F62626", +"_. c #FA0206", +":. c #DE1E16", +"<. c #B63A26", +"[. c #865A2E", +"}. c #26568E", +"|. c #435F7D", +"1. c #7AE246", +"2. c #96EA6E", +"3. c #BEEAAE", +"4. c #D0EADC", +"5. c #B6CEFE", +"6. c #9ADE8A", +"7. c #2A609A", +"8. c #7E623E", +"9. c #CA7A72", +"0. c #F26E6E", +"a. c #FE5252", +"b. c #FA3638", +"c. c #DA2E28", +"d. c #9E3E3A", +"e. c #3E7656", +"f. c #76CB3A", +"g. c #90DE44", +"h. c #A2EE6A", +"i. c #9EEA9A", +"j. c #92BEDE", +"k. c #7ADA7E", +"l. c #5ECE52", +"m. c #6A5E52", +"n. c #A83238", +"o. c #FA5656", +"p. c #F29A92", +"q. c #D29E92", +"r. c #8A7A62", +"s. c #05336B", +"t. c #59C631", +"u. c #8AD23A", +"v. c #66E242", +"w. c #1D6FC1", +"x. c #E61212", +"y. c #CA261E", +"z. c #5A763E", +"A. c #1E6E9A", +"B. c #023272", +"C. c #329696", +"D. c #2074B6", +"E. c #3E4E76", +"F. c #5A525E", +"G. c #425868", +"H. c #04448E", +"I. c #28828A", +"J. c #2D8593", +"K. c #12427A", +"L. c #054696", +"M. c #042B5E", +"N. c #134F95", +"O. c #1E6ABB", +"P. c #1A5E96", +"Q. c #022E67", +"R. c #0C3E7C", +"S. c #023E8A", +"T. c #021A3E", " ", " ", @@ -300,5 +302,5 @@ ScreenshotControl::ScreenshotControl( QWidget *parent, const char *name ) grabTimer = new QTimer ( this, "grab timer"); - + connect ( grabTimer, SIGNAL( timeout()), this, SLOT( performGrab())); connect ( grabItButton, SIGNAL( clicked()), SLOT( slotGrab())); @@ -363,5 +365,5 @@ void ScreenshotControl::savePixmap() fileName = fileName + ".png"; lnk.setFile(fileName); //sets File property - qDebug("saving file " + fileName); + odebug << "saving file " + fileName << oendl; snapshot.save( fileName, "PNG"); QFileInfo fi( fileName); @@ -369,5 +371,5 @@ void ScreenshotControl::savePixmap() if (!lnk.writeLink()) - qDebug("Writing doclink did not work"); + odebug << "Writing doclink did not work" << oendl; } else { @@ -381,5 +383,5 @@ void ScreenshotControl::savePixmap() if ( !QDir( dirName).exists() ) { - qDebug("making dir " + dirName); + odebug << "making dir " + dirName << oendl; QString msg = "mkdir -p " + dirName; system(msg.latin1()); @@ -389,5 +391,5 @@ void ScreenshotControl::savePixmap() fileName = fileName + ".png"; lnk.setFile(fileName); //sets File property - qDebug("saving file " + fileName); + odebug << "saving file " + fileName << oendl; snapshot.save( fileName, "PNG"); QFileInfo fi( fileName); @@ -395,5 +397,5 @@ void ScreenshotControl::savePixmap() if (!lnk.writeLink()) - qDebug("Writing doclink did not work"); + odebug << "Writing doclink did not work" << oendl; } @@ -404,82 +406,82 @@ void ScreenshotControl::savePixmap() void ScreenshotControl::performGrab() { - snapshot = QPixmap::grabWindow( QPEApplication::desktop()->winId(), 0, 0, QApplication::desktop()->width(), QApplication::desktop()->height() ); + snapshot = QPixmap::grabWindow( QPEApplication::desktop()->winId(), 0, 0, QApplication::desktop()->width(), QApplication::desktop()->height() ); - if (buttonPushed == 1) { - qDebug("grabbing screen"); - grabTimer->stop(); - show(); - qApp->processEvents(); - savePixmap(); - } else { - grabTimer->stop(); + if (buttonPushed == 1) { + odebug << "grabbing screen" << oendl; + grabTimer->stop(); + show(); + qApp->processEvents(); + savePixmap(); + } else { + grabTimer->stop(); - struct sockaddr_in raddr; - struct hostent *rhost_info; - int sock = -1; - bool ok = false; + struct sockaddr_in raddr; + struct hostent *rhost_info; + int sock = -1; + bool ok = false; - QString displayEnv = getenv("QWS_DISPLAY"); - qDebug(displayEnv); + QString displayEnv = getenv("QWS_DISPLAY"); + odebug << displayEnv << oendl; - if(( displayEnv.left(2) != ":0" ) && (!displayEnv.isEmpty())) { + if(( displayEnv.left(2) != ":0" ) && (!displayEnv.isEmpty())) { - if (( rhost_info = (struct hostent *) ::gethostbyname ((char *) SCAP_hostname )) != 0 ) { - ::memset ( &raddr, 0, sizeof (struct sockaddr_in)); - ::memcpy ( &raddr. sin_addr, rhost_info-> h_addr, rhost_info-> h_length ); - raddr. sin_family = rhost_info-> h_addrtype; - raddr. sin_port = htons ( SCAP_port ); + if (( rhost_info = (struct hostent *) ::gethostbyname ((char *) SCAP_hostname )) != 0 ) { + ::memset ( &raddr, 0, sizeof (struct sockaddr_in)); + ::memcpy ( &raddr. sin_addr, rhost_info-> h_addr, rhost_info-> h_length ); + raddr. sin_family = rhost_info-> h_addrtype; + raddr. sin_port = htons ( SCAP_port ); - if (( sock = ::socket ( AF_INET, SOCK_STREAM, 0 )) >= 0 ) { - if ( ::connect ( sock, (struct sockaddr *) & raddr, sizeof (struct sockaddr)) >= 0 ) { + if (( sock = ::socket ( AF_INET, SOCK_STREAM, 0 )) >= 0 ) { + if ( ::connect ( sock, (struct sockaddr *) & raddr, sizeof (struct sockaddr)) >= 0 ) { - QString header; + QString header; - QPixmap pix; + QPixmap pix; - QString SCAP_model=""; + QString SCAP_model=""; #warning FIXME: model string should be filled with actual device model - if( snapshot.width() > 320) - SCAP_model ="Corgi"; - - if(displayEnv == "QVFb:0") {//set this if you plan on using this app in qvfb!! - pix = snapshot.xForm(QWMatrix().rotate(90)); - } else - pix = ( snapshot.width() > snapshot.height() ) ? snapshot : snapshot.xForm( QWMatrix().rotate(90) ); - - QImage img = pix.convertToImage().convertDepth( 16 ); // could make that also depth independent, if hh.org/scap can handle it - - header = "POST /scap/capture.cgi?%1+%2 HTTP/1.1\n" // 1: model / 2: user - "Content-length: %3\n" // 3: content length - "Content-Type: image/png\n" - "Host: %4\n" // 4: scap host - "\n"; - - - header = header.arg( SCAP_model).arg( ::getenv( "USER" ) ).arg( img.numBytes() ).arg( SCAP_hostname ); - qDebug(header); - - if ( !pix.isNull() ) { - const char *ascii = header.latin1( ); - uint ascii_len = ::strlen( ascii ); - ::write ( sock, ascii, ascii_len ); - ::write ( sock, img.bits(), img.numBytes() ); - - ok = true; - } - } - ::close ( sock ); - } - } - if ( ok ) { - QMessageBox::information( 0, tr( "Success" ), QString( "<p>%1</p>" ).arg ( tr( "Screenshot was uploaded to %1" )).arg( SCAP_hostname )); - } else { - QMessageBox::warning( 0, tr( "Error" ), QString( "<p>%1</p>" ).arg( tr( "Connection to %1 failed." )).arg( SCAP_hostname )); - } - } else { - QMessageBox::warning( 0, tr( "Error" ),tr("Please set <b>QWS_DISPLAY</b> environmental variable.")); - } - } - + if( snapshot.width() > 320) + SCAP_model ="Corgi"; + + if(displayEnv == "QVFb:0") {//set this if you plan on using this app in qvfb!! + pix = snapshot.xForm(QWMatrix().rotate(90)); + } else + pix = ( snapshot.width() > snapshot.height() ) ? snapshot : snapshot.xForm( QWMatrix().rotate(90) ); + + QImage img = pix.convertToImage().convertDepth( 16 ); // could make that also depth independent, if hh.org/scap can handle it + + header = "POST /scap/capture.cgi?%1+%2 HTTP/1.1\n" // 1: model / 2: user + "Content-length: %3\n" // 3: content length + "Content-Type: image/png\n" + "Host: %4\n" // 4: scap host + "\n"; + + + header = header.arg( SCAP_model).arg( ::getenv( "USER" ) ).arg( img.numBytes() ).arg( SCAP_hostname ); + odebug << header << oendl; + + if ( !pix.isNull() ) { + const char *ascii = header.latin1( ); + uint ascii_len = ::strlen( ascii ); + ::write ( sock, ascii, ascii_len ); + ::write ( sock, img.bits(), img.numBytes() ); + + ok = true; + } + } + ::close ( sock ); + } + } + if ( ok ) { + QMessageBox::information( 0, tr( "Success" ), QString( "<p>%1</p>" ).arg ( tr( "Screenshot was uploaded to %1" )).arg( SCAP_hostname )); + } else { + QMessageBox::warning( 0, tr( "Error" ), QString( "<p>%1</p>" ).arg( tr( "Connection to %1 failed." )).arg( SCAP_hostname )); + } + } else { + QMessageBox::warning( 0, tr( "Error" ),tr("Please set <b>QWS_DISPLAY</b> environmental variable.")); + } + } + } @@ -491,5 +493,5 @@ ScreenshotApplet::ScreenshotApplet( QWidget *parent, const char *name ) : QWidget( parent, name ) { - setFixedWidth( AppLnk::smallIconSize()); + setFixedWidth( AppLnk::smallIconSize()); QImage img = (const char **)snapshot_xpm; @@ -515,17 +517,17 @@ void ScreenshotApplet::mousePressEvent( QMouseEvent *) // If the icon is near the edge of the screen, the window would leave the visible area // so we check the position against the screen width and correct the difference if needed - + int screenWidth = qApp->desktop()->width(); int windowPosX = curPos. x ( ) - ( sc-> sizeHint ( ). width ( ) - width ( )) / 2 ; int ZwindowPosX, XwindowPosX; - + // the window would be placed beyond the screen wich doesn't look tooo good if ( (windowPosX + sc-> sizeHint ( ). width ( )) > screenWidth ) { - XwindowPosX = windowPosX + sc-> sizeHint ( ). width ( ) - screenWidth; - ZwindowPosX = windowPosX - XwindowPosX - 1; + XwindowPosX = windowPosX + sc-> sizeHint ( ). width ( ) - screenWidth; + ZwindowPosX = windowPosX - XwindowPosX - 1; } else { - ZwindowPosX = windowPosX; + ZwindowPosX = windowPosX; } - + sc-> move ( ZwindowPosX, curPos. y ( ) - sc-> sizeHint ( ). height ( ) ); sc-> show ( ); @@ -535,5 +537,5 @@ void ScreenshotApplet::paintEvent( QPaintEvent* ) { QPainter p ( this ); - p.drawPixmap( 0,0, m_icon ); + p.drawPixmap( 0,0, m_icon ); } diff --git a/core/applets/vmemo/vmemo.cpp b/core/applets/vmemo/vmemo.cpp index 7dd5b4b..622b1df 100644 --- a/core/applets/vmemo/vmemo.cpp +++ b/core/applets/vmemo/vmemo.cpp @@ -13,4 +13,8 @@ // copyright 2002 and 2003 L.J.Potter <ljp@llornkcor.com> +/* OPIE */ +#include <opie2/odebug.h> +using namespace Opie::Core; + extern "C" { #include "adpcm.h" @@ -30,5 +34,5 @@ typedef struct _waveheader { u_long chunk_type; /* 'WAVE' */ u_long sub_chunk; /* 'fmt ' */ - u_long sc_len; /* length of sub_chunk, =16 + u_long sc_len; /* length of sub_chunk, =16 (chunckSize) format len */ u_short format; /* should be 1 for PCM-code (formatTag) */ @@ -199,8 +203,8 @@ VMemo::VMemo( QWidget *parent, const char *_name ) setFixedHeight( 18 ); setFixedWidth( 14 ); - + t_timer = new QTimer( this ); connect( t_timer, SIGNAL( timeout() ), SLOT( timerBreak() ) ); - + Config vmCfg("Vmemo"); vmCfg.setGroup("Defaults"); @@ -208,10 +212,10 @@ VMemo::VMemo( QWidget *parent, const char *_name ) useADPCM = vmCfg.readBoolEntry("use_ADPCM", 0); - qDebug("toggleKey %d", toggleKey); + odebug << "toggleKey " << toggleKey << "" << oendl; if ( QFile::exists ( "/dev/sharp_buz" ) || QFile::exists ( "/dev/sharp_led" )) systemZaurus=TRUE; - else + else systemZaurus=FALSE; - + myChannel = new QCopChannel( "QPE/VMemo", this ); connect( myChannel, SIGNAL(received(const QCString&,const QByteArray&)), @@ -246,5 +250,5 @@ int VMemo::position() void VMemo::receive( const QCString &msg, const QByteArray &data ) { - qDebug("receive"); + odebug << "receive" << oendl; QDataStream stream( data, IO_ReadOnly ); @@ -268,5 +272,5 @@ void VMemo::mousePressEvent( QMouseEvent * me) { /* No mousePress/mouseRelease recording on the iPAQ. The REC button on the iPAQ calls these functions mousePressEvent and mouseReleaseEvent with a NULL parameter. */ - + // if (!systemZaurus && me != NULL) // return; @@ -294,5 +298,5 @@ bool VMemo::startRecording() { } - qDebug("Start recording engines"); + odebug << "Start recording engines" << oendl; recording = TRUE; @@ -301,5 +305,5 @@ bool VMemo::startRecording() { return FALSE; } - + config.setGroup("Defaults"); @@ -319,5 +323,5 @@ bool VMemo::startRecording() { if(s) fileName=fileName.right(fileName.length()-s-2); - qDebug("pathname will be "+fileName); + odebug << "pathname will be "+fileName << oendl; if( fileName.left(1).find('/') == -1) @@ -326,12 +330,12 @@ bool VMemo::startRecording() { fileName+="/"; fName = "vm_"+ date+ ".wav"; - + fileName+=fName; - qDebug("filename is "+fileName); + odebug << "filename is "+fileName << oendl; // open tmp file here char *pointer; - pointer=tmpnam(NULL); - qDebug("Opening tmp file %s",pointer); - + pointer=tmpnam(NULL); + odebug << "Opening tmp file " << pointer << "" << oendl; + if(openWAV(pointer ) == -1) { @@ -350,10 +354,10 @@ bool VMemo::startRecording() { cmd.sprintf("mv %s "+fileName, pointer); // move tmp file to regular file here - + system(cmd.latin1()); QArray<int> cats(1); cats[0] = config.readNumEntry("Category", 0); - + QString dlName("vm_"); dlName += date; @@ -367,10 +371,10 @@ bool VMemo::startRecording() { } else return FALSE; - + } void VMemo::stopRecording() { show(); - qDebug("Stopped recording"); + odebug << "Stopped recording" << oendl; recording = FALSE; if(useAlerts) { @@ -389,5 +393,5 @@ int VMemo::openDSP() { Config cfg("Vmemo"); cfg.setGroup("Record"); - + speed = cfg.readNumEntry("SampleRate", 22050); channels = cfg.readNumEntry("Stereo", 1) ? 2 : 1; // 1 = stereo(2), 0 = mono(1) @@ -400,5 +404,5 @@ int VMemo::openDSP() { } - qDebug("samplerate: %d, channels %d, resolution %d", speed, channels, resolution); + odebug << "samplerate: " << speed << ", channels " << channels << ", resolution " << resolution << "" << oendl; if(systemZaurus) { @@ -408,10 +412,10 @@ int VMemo::openDSP() { dsp = open("/dev/dsp", O_RDONLY); } - + if(dsp == -1) { msgLabel->close(); msgLabel=0; delete msgLabel; - + perror("open(\"/dev/dsp\")"); errorMsg="open(\"/dev/dsp\")\n "+(QString)strerror(errno); @@ -419,5 +423,5 @@ int VMemo::openDSP() { return -1; } - + if(ioctl(dsp, SNDCTL_DSP_SETFMT , &format)==-1) { perror("ioctl(\"SNDCTL_DSP_SETFMT\")"); @@ -438,5 +442,5 @@ int VMemo::openDSP() { QCopEnvelope( "QPE/System", "volumeChange(bool)" ) << FALSE; //mute - + return 1; } @@ -453,9 +457,9 @@ int VMemo::openWAV(const char *filename) { vmCfg.setGroup("Defaults"); useADPCM = vmCfg.readBoolEntry("use_ADPCM", 0); - + WaveHeader wh; wh.main_chunk = RIFF; - wh.length=0; + wh.length=0; wh.chunk_type = WAVE; wh.sub_chunk = FMT; @@ -464,16 +468,16 @@ int VMemo::openWAV(const char *filename) { wh.format = WAVE_FORMAT_DVI_ADPCM;//PCM_CODE; else - wh.format = PCM_CODE; + wh.format = PCM_CODE; wh.modus = channels; wh.sample_fq = speed; wh.byte_p_sec = speed * channels * resolution/8; - wh.byte_p_spl = channels * (resolution / 8); + wh.byte_p_spl = channels * (resolution / 8); wh.bit_p_spl = resolution; wh.data_chunk = DATA; - wh.data_length= 0; + wh.data_length= 0; // qDebug("Write header channels %d, speed %d, b/s %d, blockalign %d, bitrate %d" // , wh.modus, wh.sample_fq, wh.byte_p_sec, wh.byte_p_spl, wh.bit_p_spl ); write (wav, &wh, sizeof(WaveHeader)); - + return 1; } @@ -484,5 +488,5 @@ bool VMemo::record() { QString msg; msg.sprintf("Recording format %d", format); - qDebug(msg); + odebug << msg << oendl; Config config("Vmemo"); config.setGroup("Record"); @@ -495,5 +499,5 @@ bool VMemo::record() { msg.sprintf("Recording format other"); - qDebug(msg); + odebug << msg << oendl; int bufsize=1024; @@ -514,5 +518,5 @@ bool VMemo::record() { if( result <= 0) { perror("recording error "); -// qDebug(currentFileName); +// odebug << currentFileName << oendl; QMessageBox::message(tr("Note"),tr("error recording")); recording=FALSE; @@ -541,5 +545,5 @@ bool VMemo::record() { return FALSE; } - // printf("%d\r",length); + // odebug << "" << length << "\r" << oendl; // fflush(stdout); qApp->processEvents(); @@ -560,6 +564,6 @@ bool VMemo::record() { track.close(); - qDebug("Track closed"); - + odebug << "Track closed" << oendl; + if( ioctl( dsp, SNDCTL_DSP_RESET,0) == -1) perror("ioctl(\"SNDCTL_DSP_RESET\")"); @@ -574,5 +578,5 @@ bool VMemo::record() { QString currentFileName = fileName; QString currentFile = "vm_"+ date; - + float numberOfRecordedSeconds=(float) length / (float)speed * (float)2; @@ -584,9 +588,9 @@ bool VMemo::record() { time.sprintf("%.2f", numberOfRecordedSeconds); cfgO.writeEntry( currentFileName, time ); - // qDebug("writing config numberOfRecordedSeconds "+time); + // odebug << "writing config numberOfRecordedSeconds "+time << oendl; cfgO.write(); - qDebug("done recording "+fileName); + odebug << "done recording "+fileName << oendl; Config cfg("qpe"); @@ -603,30 +607,30 @@ int VMemo::setToggleButton(int tog) { switch (tog) { case 0: - return -1; - break; + return -1; + break; case 1: - return 0; - break; + return 0; + break; case 2: return Key_F24; //was Escape - break; + break; case 3: return Key_Space; - break; + break; case 4: return Key_F12; - break; + break; case 5: return Key_F9; - break; + break; case 6: return Key_F10; - break; + break; case 7: return Key_F11; - break; + break; case 8: return Key_F13; - break; + break; }; } diff --git a/core/applets/vtapplet/vt.cpp b/core/applets/vtapplet/vt.cpp index bd39093..aec63c3 100644 --- a/core/applets/vtapplet/vt.cpp +++ b/core/applets/vtapplet/vt.cpp @@ -1,6 +1,4 @@ /********************************************************************** -** Copyright (C) 2003 Michael 'Mickey' Lauer. All rights reserved. -** -** Contact me @ mickeyl@handhelds.org +** Copyright (C) 2003-2004 Michael 'Mickey' Lauer <mickey@Vanille.de> ** ** This file may be distributed and/or modified under the terms of the @@ -14,8 +12,15 @@ **********************************************************************/ +#include "vt.h" + +/* OPIE */ +#include <opie2/odebug.h> #include <qpe/resource.h> +using namespace Opie::Core; +/* QT */ #include <qpopupmenu.h> +/* STD */ #include <fcntl.h> #include <unistd.h> @@ -25,8 +30,6 @@ #include <linux/vt.h> -#include "vt.h" - VTApplet::VTApplet ( ) - : QObject ( 0, "VTApplet" ) + : QObject ( 0, "VTApplet" ) { } @@ -43,10 +46,10 @@ int VTApplet::position ( ) const QString VTApplet::name ( ) const { - return tr( "VT shortcut" ); + return tr( "VT shortcut" ); } QString VTApplet::text ( ) const { - return tr( "Terminal" ); + return tr( "Terminal" ); } @@ -65,15 +68,15 @@ QString VTApplet::tr( const char* s, const char* p ) const QIconSet VTApplet::icon ( ) const { - QPixmap pix; - QImage img = Resource::loadImage ( "terminal" ); + QPixmap pix; + QImage img = Resource::loadImage ( "terminal" ); - if ( !img. isNull ( )) - pix. convertFromImage ( img. smoothScale ( 14, 14 )); - return pix; + if ( !img. isNull ( )) + pix. convertFromImage ( img. smoothScale ( 14, 14 )); + return pix; } QPopupMenu *VTApplet::popup ( QWidget* parent ) const { - qDebug( "VTApplet::popup" ); + odebug << "VTApplet::popup" << oendl; struct vt_stat vtstat; @@ -100,5 +103,5 @@ QPopupMenu *VTApplet::popup ( QWidget* parent ) const void VTApplet::changeVT( int index ) { - //qDebug( "VTApplet::changeVT( %d )", index-500 ); + //odebug << "VTApplet::changeVT( " << index-500 << " )" << oendl; int fd = ::open("/dev/tty0", O_RDWR); @@ -110,5 +113,5 @@ void VTApplet::changeVT( int index ) void VTApplet::updateMenu() { - //qDebug( "VTApplet::updateMenu()" ); + //odebug << "VTApplet::updateMenu()" << oendl; int fd = ::open( "/dev/console", O_RDONLY ); @@ -121,7 +124,7 @@ void VTApplet::updateMenu() /* if ( result == -1 ) - qDebug( "VT %d disallocated == free", i ); + odebug << "VT " << i << " disallocated == free" << oendl; else - qDebug( "VT %d _not_ disallocated == busy", i ); + odebug << "VT " << i << " _not_ disallocated == busy" << oendl; */ @@ -135,5 +138,5 @@ void VTApplet::updateMenu() void VTApplet::activated() { - qDebug( "VTApplet::activated()" ); + odebug << "VTApplet::activated()" << oendl; } @@ -141,20 +144,20 @@ void VTApplet::activated() QRESULT VTApplet::queryInterface ( const QUuid &uuid, QUnknownInterface **iface ) { - *iface = 0; - if ( uuid == IID_QUnknown ) - *iface = this; - else if ( uuid == IID_MenuApplet ) - *iface = this; - else - return QS_FALSE; - - if ( *iface ) - (*iface)-> addRef ( ); - return QS_OK; + *iface = 0; + if ( uuid == IID_QUnknown ) + *iface = this; + else if ( uuid == IID_MenuApplet ) + *iface = this; + else + return QS_FALSE; + + if ( *iface ) + (*iface)-> addRef ( ); + return QS_OK; } Q_EXPORT_INTERFACE( ) { - Q_CREATE_INSTANCE( VTApplet ) + Q_CREATE_INSTANCE( VTApplet ) } diff --git a/core/obex/obexsend.cpp b/core/obex/obexsend.cpp index cd8d58e..f3dd11c 100644 --- a/core/obex/obexsend.cpp +++ b/core/obex/obexsend.cpp @@ -1,2 +1,12 @@ +#include "obex.h" +#include "obexsend.h" +using namespace OpieObex; + +/* OPIE */ +#include <opie2/odebug.h> +#include <qpe/qcopenvelope_qws.h> +using namespace Opie::Core; + +/* QT */ #include <qpushbutton.h> #include <qlabel.h> @@ -4,15 +14,6 @@ #include <qtimer.h> - -#include <qpe/qcopenvelope_qws.h> - -#include "obex.h" -#include "obexsend.h" - -using namespace OpieObex; - /* TRANSLATOR OpieObex::SendWidget */ - SendWidget::SendWidget( QWidget* parent, const char* name ) : QWidget( parent, name ) { @@ -105,5 +106,5 @@ void SendWidget::send( const QString& file, const QString& desc ) { } void SendWidget::slotIrDaDevices( const QStringList& list) { - qWarning("slot it irda devices "); + owarn << "slot it irda devices " << oendl; for (QStringList::ConstIterator it = list.begin(); it != list.end(); ++it ) { int id = m_devBox->addDevice( (*it), DeviceBox::IrDa, tr("Scheduling for beam.") ); @@ -124,5 +125,5 @@ void SendWidget::slotBTDevices( const QMap<QString, QString>& str ) { } void SendWidget::slotSelectedDevice( int name, int dev ) { - qWarning("Start beam? %d %d", name, dev ); + owarn << "Start beam? " << name << " " << dev << "" << oendl; if ( name == m_irDeSearch ) { for (QMap<int, QString>::Iterator it= m_irDa.begin(); it != m_irDa.end(); ++it ) @@ -133,5 +134,5 @@ void SendWidget::slotSelectedDevice( int name, int dev ) { } void SendWidget::dispatchIrda( const QCString& str, const QByteArray& ar ) { - qWarning("dispatch irda %s", str.data() ); + owarn << "dispatch irda " << str.data() << "" << oendl; if ( str == "devices(QStringList)" ) { QDataStream stream( ar, IO_ReadOnly ); @@ -148,5 +149,5 @@ void SendWidget::slotIrError( int ) { } void SendWidget::slotIrSent( bool b) { - qWarning("irda sent!!"); + owarn << "irda sent!!" << oendl; QString text = b ? tr("Sent") : tr("Failure"); m_devBox->setStatus( m_irDaIt.key(), text ); @@ -205,5 +206,5 @@ void DeviceBox::setStatus( int id, const QString& status ) { } void DeviceBox::setSource( const QString& str ) { - qWarning("SetSource:%d", str.toInt() ); + owarn << "SetSource:" << str.toInt() << "" << oendl; int id = str.toInt(); emit selectedDevice( id, m_dev[id].device() ); diff --git a/core/obex/receiver.cpp b/core/obex/receiver.cpp index ee2668b..8885256 100644 --- a/core/obex/receiver.cpp +++ b/core/obex/receiver.cpp @@ -1,10 +1,14 @@ -#include <sys/types.h> -#include <sys/stat.h> -#include <sys/mman.h> -#include <stdlib.h> // int system -#include <unistd.h> +#include "obex.h" +#include "receiver.h" +using namespace OpieObex; -#include <fcntl.h> +/* OPIE */ +#include <opie2/odebug.h> +#include <qpe/applnk.h> +#include <qpe/qpeapplication.h> +#include <qpe/qcopenvelope_qws.h> +using namespace Opie::Core; +/* QT */ #include <qfileinfo.h> #include <qlabel.h> @@ -12,12 +16,11 @@ #include <qpushbutton.h> -#include <qpe/applnk.h> -#include <qpe/qpeapplication.h> -#include <qpe/qcopenvelope_qws.h> - -#include "obex.h" -#include "receiver.h" - -using namespace OpieObex; +/* STD */ +#include <sys/types.h> +#include <sys/stat.h> +#include <sys/mman.h> +#include <stdlib.h> // int system +#include <unistd.h> +#include <fcntl.h> /* TRANSLATOR OpieObex::Receiver */ @@ -76,5 +79,5 @@ void Receiver::tidyUp( QString& _file, const QString& ending) { _file = QString::fromLatin1( foo ); QString cmd = QString("sed -e \"s/^\\(X-MICROSOFT-BODYINK\\)\\;/\\1:/;\" < %2 > %2 ").arg( Global::shellQuote(file)).arg( Global::shellQuote(_file) ); - qWarning("Executing: %s", cmd.latin1() ); + owarn << "Executing: " << cmd << "" << oendl; (void)::system( cmd.latin1() ); @@ -83,5 +86,5 @@ void Receiver::tidyUp( QString& _file, const QString& ending) { } int Receiver::checkFile( QString& file ) { - qWarning("check file!! %s", file.latin1() ); + owarn << "check file!! " << file << "" << oendl; int ret; QString ending; @@ -108,5 +111,5 @@ int Receiver::checkFile( QString& file ) { tidyUp( file, ending ); - qWarning("check it now %d", ret ); + owarn << "check it now " << ret << "" << oendl; return ret; } @@ -149,5 +152,5 @@ void OtherHandler::handle( const QString& file ) { m_na->setText(file); DocLnk lnk(file); - qWarning(" %s %s", lnk.type().latin1(), lnk.icon().latin1() ); + owarn << " " << lnk.type() << " " << lnk.icon() << "" << oendl; QString str = tr("<p>You received a file of type %1 (<img src=\"%2\"> )What do you want to do?").arg(lnk.type() ).arg(lnk.icon() ); @@ -192,5 +195,5 @@ QString OtherHandler::targetName( const QString& file ) { /* fast cpy */ void OtherHandler::copy(const QString& src, const QString& file) { - qWarning("src %s, dest %s", src.latin1(),file.latin1() ); + owarn << "src " << src << ", dest " << file << "" << oendl; QString cmd = QString("mv %1 %2").arg( Global::shellQuote( src )). arg( Global::shellQuote( file ) ); |