author | llornkcor <llornkcor> | 2002-09-20 16:15:20 (UTC) |
---|---|---|
committer | llornkcor <llornkcor> | 2002-09-20 16:15:20 (UTC) |
commit | 40df2487c53a5ab484d33d619f5b6ed449c0b485 (patch) (unidiff) | |
tree | 9439fb7a35a16a798c4a07a612f001ab7f36d948 /core/applets | |
parent | 5442f262a9e59becacdde4822f439b91d43795df (diff) | |
download | opie-40df2487c53a5ab484d33d619f5b6ed449c0b485.zip opie-40df2487c53a5ab484d33d619f5b6ed449c0b485.tar.gz opie-40df2487c53a5ab484d33d619f5b6ed449c0b485.tar.bz2 |
cleanup
-rw-r--r-- | core/applets/vmemo/vmemo.cpp | 36 |
1 files changed, 3 insertions, 33 deletions
diff --git a/core/applets/vmemo/vmemo.cpp b/core/applets/vmemo/vmemo.cpp index c5d0a5b..4c07b3a 100644 --- a/core/applets/vmemo/vmemo.cpp +++ b/core/applets/vmemo/vmemo.cpp | |||
@@ -213,4 +213,2 @@ VMemo::VMemo( QWidget *parent, const char *_name ) | |||
213 | 213 | ||
214 | recording = FALSE; | ||
215 | |||
216 | t_timer = new QTimer( this ); | 214 | t_timer = new QTimer( this ); |
@@ -239,3 +237,2 @@ VMemo::VMemo( QWidget *parent, const char *_name ) | |||
239 | if( toggleKey != -1 ) { | 237 | if( toggleKey != -1 ) { |
240 | // QPEApplication::grabKeyboard(); | ||
241 | QCopEnvelope e("QPE/Desktop", "keyRegister(int key, QString channel, QString message)"); | 238 | QCopEnvelope e("QPE/Desktop", "keyRegister(int key, QString channel, QString message)"); |
@@ -253,2 +250,3 @@ VMemo::VMemo( QWidget *parent, const char *_name ) | |||
253 | hide(); | 250 | hide(); |
251 | recording = FALSE; | ||
254 | } | 252 | } |
@@ -264,6 +262,4 @@ void VMemo::receive( const QCString &msg, const QByteArray &data ) { | |||
264 | if (msg == "toggleRecord()") { | 262 | if (msg == "toggleRecord()") { |
265 | |||
266 | if (recording) { | 263 | if (recording) { |
267 | fromToggle = TRUE; | 264 | fromToggle = TRUE; |
268 | mouseReleaseEvent(NULL); | ||
269 | stopRecording(); | 265 | stopRecording(); |
@@ -271,3 +267,2 @@ void VMemo::receive( const QCString &msg, const QByteArray &data ) { | |||
271 | fromToggle = TRUE; | 267 | fromToggle = TRUE; |
272 | // mousePressEvent(NULL); | ||
273 | startRecording(); | 268 | startRecording(); |
@@ -283,12 +278,6 @@ void VMemo::paintEvent( QPaintEvent* ) { | |||
283 | void VMemo::mousePressEvent( QMouseEvent * me) { | 278 | void VMemo::mousePressEvent( QMouseEvent * me) { |
284 | // just to be safe | ||
285 | // if (recording) { | ||
286 | // recording = FALSE; | ||
287 | // return; | ||
288 | // } | ||
289 | /* No mousePress/mouseRelease recording on the iPAQ. The REC button on the iPAQ calls these functions | 279 | /* No mousePress/mouseRelease recording on the iPAQ. The REC button on the iPAQ calls these functions |
290 | mousePressEvent and mouseReleaseEvent with a NULL parameter. */ | 280 | mousePressEvent and mouseReleaseEvent with a NULL parameter. */ |
291 | // if ( me->button() != LeftButton && me != NULL /*&& !systemZaurus*/) { | ||
292 | 281 | ||
293 | // if (!systemZaurus && me != NULL) | 282 | // if (!systemZaurus && me != NULL) |
294 | // return; | 283 | // return; |
@@ -303,4 +292,2 @@ void VMemo::mousePressEvent( QMouseEvent * me) { | |||
303 | void VMemo::mouseReleaseEvent( QMouseEvent * ) { | 292 | void VMemo::mouseReleaseEvent( QMouseEvent * ) { |
304 | // if(usingIcon && !recording) | ||
305 | // stopRecording(); | ||
306 | } | 293 | } |
@@ -308,6 +295,2 @@ void VMemo::mouseReleaseEvent( QMouseEvent * ) { | |||
308 | bool VMemo::startRecording() { | 295 | bool VMemo::startRecording() { |
309 | |||
310 | if ( recording) | ||
311 | return FALSE; | ||
312 | |||
313 | Config config( "Vmemo" ); | 296 | Config config( "Vmemo" ); |
@@ -323,9 +306,2 @@ bool VMemo::startRecording() { | |||
323 | 306 | ||
324 | // if(useAlerts) | ||
325 | // QMessageBox::message("VMemo","Really Record?");//) ==1) | ||
326 | // return; | ||
327 | // } else { | ||
328 | // if (!systemZaurus ) | ||
329 | // QSound::play(Resource::findSound("vmemob")); | ||
330 | // } | ||
331 | qDebug("Start recording engines"); | 307 | qDebug("Start recording engines"); |
@@ -334,4 +310,2 @@ bool VMemo::startRecording() { | |||
334 | if (openDSP() == -1) { | 310 | if (openDSP() == -1) { |
335 | // QMessageBox::critical(0, "vmemo", "Could not open dsp device.\n"+errorMsg, "Abort"); | ||
336 | // delete msgLabel; | ||
337 | recording = FALSE; | 311 | recording = FALSE; |
@@ -578,3 +552,3 @@ bool VMemo::record() { | |||
578 | perror("dev/dsp's is a lookin' messy"); | 552 | perror("dev/dsp's is a lookin' messy"); |
579 | QMessageBox::message("Vmemo"," Done1 recording\n"+ fileName); | 553 | QMessageBox::message("Vmemo","Error writing to file\n"+ fileName); |
580 | break; | 554 | break; |
@@ -608,8 +582,4 @@ bool VMemo::record() { | |||
608 | 582 | ||
609 | // if(useAlerts) | ||
610 | // QMessageBox::message("Vmemo"," Done1 recording\n"+ fileName); | ||
611 | qDebug("done recording "+fileName); | 583 | qDebug("done recording "+fileName); |
612 | 584 | ||
613 | // QSound::play(Resource::findSound("vmemoe")); | ||
614 | |||
615 | Config cfg("qpe"); | 585 | Config cfg("qpe"); |