-rw-r--r-- | core/launcher/inputmethods.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/core/launcher/inputmethods.cpp b/core/launcher/inputmethods.cpp index 62e316c..5d8faf7 100644 --- a/core/launcher/inputmethods.cpp +++ b/core/launcher/inputmethods.cpp | |||
@@ -562,67 +562,67 @@ void InputMethods::showKbd( bool on ) | |||
562 | top = t; | 562 | top = t; |
563 | width = w; | 563 | width = w; |
564 | height = h; | 564 | height = h; |
565 | } | 565 | } |
566 | else | 566 | else |
567 | { | 567 | { |
568 | qDebug( "InputMethods: config values are new or not ok." ); | 568 | qDebug( "InputMethods: config values are new or not ok." ); |
569 | } | 569 | } |
570 | } | 570 | } |
571 | else | 571 | else |
572 | { | 572 | { |
573 | qDebug( "InputMethods: no floating selected." ); | 573 | qDebug( "InputMethods: no floating selected." ); |
574 | } | 574 | } |
575 | mkeyboard->widget->resize( width, height ); | 575 | mkeyboard->widget->resize( width, height ); |
576 | mkeyboard->widget->move( left, top ); | 576 | mkeyboard->widget->move( left, top ); |
577 | mkeyboard->widget->show(); | 577 | mkeyboard->widget->show(); |
578 | mkeyboard->widget->installEventFilter( this ); | 578 | mkeyboard->widget->installEventFilter( this ); |
579 | } | 579 | } |
580 | else | 580 | else |
581 | { | 581 | { |
582 | if ( inputWidgetStyle & QWidget::WStyle_DialogBorder ) | 582 | if ( inputWidgetStyle & QWidget::WStyle_DialogBorder ) |
583 | { | 583 | { |
584 | QPoint pos = mkeyboard->widget->pos(); | 584 | QPoint pos = mkeyboard->widget->pos(); |
585 | QSize siz = mkeyboard->widget->size(); | 585 | QSize siz = mkeyboard->widget->size(); |
586 | qDebug( "InputMethods: saving geometry." ); | 586 | qDebug( "InputMethods: saving geometry." ); |
587 | Config cfg( "Launcher" ); | 587 | Config cfg( "Launcher" ); |
588 | cfg.setGroup( "InputMethods" ); | 588 | cfg.setGroup( "InputMethods" ); |
589 | cfg.writeEntry( "absX", pos.x() ); | 589 | cfg.writeEntry( "absX", pos.x() ); |
590 | cfg.writeEntry( "absY", pos.y() ); | 590 | cfg.writeEntry( "absY", pos.y() ); |
591 | cfg.writeEntry( "absWidth", siz.width() ); | 591 | cfg.writeEntry( "absWidth", siz.width() ); |
592 | cfg.writeEntry( "absHeight", siz.height() ); | 592 | cfg.writeEntry( "absHeight", siz.height() ); |
593 | cfg.write(); | 593 | cfg.write(); |
594 | mkeyboard->widget->hide(); | ||
595 | mkeyboard->widget->removeEventFilter( this ); | 594 | mkeyboard->widget->removeEventFilter( this ); |
596 | } | 595 | } |
596 | mkeyboard->widget->hide(); | ||
597 | } | 597 | } |
598 | 598 | ||
599 | emit inputToggled( on ); | 599 | emit inputToggled( on ); |
600 | } | 600 | } |
601 | 601 | ||
602 | bool InputMethods::shown() const | 602 | bool InputMethods::shown() const |
603 | { | 603 | { |
604 | return mkeyboard && mkeyboard->widget->isVisible(); | 604 | return mkeyboard && mkeyboard->widget->isVisible(); |
605 | } | 605 | } |
606 | 606 | ||
607 | QString InputMethods::currentShown() const | 607 | QString InputMethods::currentShown() const |
608 | { | 608 | { |
609 | return mkeyboard && mkeyboard->widget->isVisible() | 609 | return mkeyboard && mkeyboard->widget->isVisible() |
610 | ? mkeyboard->name() : QString::null; | 610 | ? mkeyboard->name() : QString::null; |
611 | } | 611 | } |
612 | 612 | ||
613 | void InputMethods::sendKey( ushort unicode, ushort scancode, ushort mod, bool press, bool repeat ) | 613 | void InputMethods::sendKey( ushort unicode, ushort scancode, ushort mod, bool press, bool repeat ) |
614 | { | 614 | { |
615 | #if defined(Q_WS_QWS) | 615 | #if defined(Q_WS_QWS) |
616 | QWSServer::sendKeyEvent( unicode, scancode, mod, press, repeat ); | 616 | QWSServer::sendKeyEvent( unicode, scancode, mod, press, repeat ); |
617 | #endif | 617 | #endif |
618 | } | 618 | } |
619 | 619 | ||
620 | bool InputMethods::eventFilter( QObject* o, QEvent* e ) | 620 | bool InputMethods::eventFilter( QObject* o, QEvent* e ) |
621 | { | 621 | { |
622 | if ( e->type() == QEvent::Close ) | 622 | if ( e->type() == QEvent::Close ) |
623 | { | 623 | { |
624 | ( (QCloseEvent*) e )->ignore(); | 624 | ( (QCloseEvent*) e )->ignore(); |
625 | showKbd( false ); | 625 | showKbd( false ); |
626 | kbdButton->setOn( false ); | 626 | kbdButton->setOn( false ); |
627 | return true; | 627 | return true; |
628 | } | 628 | } |