summaryrefslogtreecommitdiff
path: root/core/applets/vmemo
Side-by-side diff
Diffstat (limited to 'core/applets/vmemo') (more/less context) (show whitespace changes)
-rw-r--r--core/applets/vmemo/vmemo.cpp9
1 files changed, 4 insertions, 5 deletions
diff --git a/core/applets/vmemo/vmemo.cpp b/core/applets/vmemo/vmemo.cpp
index 835f63a..f088bef 100644
--- a/core/applets/vmemo/vmemo.cpp
+++ b/core/applets/vmemo/vmemo.cpp
@@ -214,25 +214,25 @@ VMemo::VMemo( QWidget *parent, const char *_name )
odebug << "toggleKey " << toggleKey << "" << oendl;
// if ( QFile::exists ( "/dev/sharp_buz" ) || QFile::exists ( "/dev/sharp_led" ))
// systemZaurus=TRUE;
// else
systemZaurus = FALSE;
myChannel = new QCopChannel( "QPE/VMemo", this );
connect( myChannel, SIGNAL(received(const QCString&,const QByteArray&)),
this, SLOT(receive(const QCString&,const QByteArray&)) );
if( toggleKey != -1 ) {
- qDebug("Register key %d", toggleKey);
+ odebug << "Register key " << toggleKey << "" << oendl;
QCopEnvelope e("QPE/Launcher", "keyRegister(int,QCString,QCString)");
// e << 4096; // Key_Escape
// e << Key_F5; //4148
e << toggleKey;
e << QString("QPE/VMemo");
e << QString("toggleRecord()");
}
if(toggleKey == 1)
usingIcon = TRUE;
else
usingIcon = FALSE;
// if( vmCfg.readNumEntry("hideIcon",0) == 1)
@@ -467,26 +467,26 @@ int VMemo::openWAV(const char *filename) {
wh.sc_len = 16;
if(useADPCM)
wh.format = WAVE_FORMAT_DVI_ADPCM;//PCM_CODE;
else
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.bit_p_spl = resolution;
wh.data_chunk = DATA;
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 );
+ // odebug << "Write header channels " << wh.modus << ", speed " << wh.sample_fq << ", b/s "
+ // << wh.byte_p_sec << ", blockalign " << wh.byte_p_spl << ", bitrate " << wh.bit_p_spl << oendl;
write (wav, &wh, sizeof(WaveHeader));
return 1;
}
bool VMemo::record() {
length = 0;
int bytesWritten = 0;
int result = 0;
int value = 0;
QString msg;
msg.sprintf("Recording format %d", format);
@@ -550,26 +550,25 @@ bool VMemo::record() {
recording = false;
perror("dev/dsp's is a lookin' messy");
QMessageBox::message("Vmemo","Error writing to file\n"+ fileName);
break;
return FALSE;
}
// printf("%d\r", length);
// fflush(stdout);
qApp->processEvents();
}
}
}
- // qDebug("file has length of %d lasting %d seconds",
- // length, (( length / speed) / channels) / 2 );
+ // odebug << "file has length of " << length << " lasting " << (( length / speed) / channels) / 2 ) << " seconds" << oendl;
value = length + 36;
lseek(wav, 4, SEEK_SET);
write(wav, &value, 4);
lseek(wav, 40, SEEK_SET);
write(wav, &length, 4);
track.close();
odebug << "Track closed" << oendl;