summaryrefslogtreecommitdiff
path: root/core/settings/launcher/inputmethodsettings.cpp
Unidiff
Diffstat (limited to 'core/settings/launcher/inputmethodsettings.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--core/settings/launcher/inputmethodsettings.cpp29
1 files changed, 24 insertions, 5 deletions
diff --git a/core/settings/launcher/inputmethodsettings.cpp b/core/settings/launcher/inputmethodsettings.cpp
index 0422075..125b178 100644
--- a/core/settings/launcher/inputmethodsettings.cpp
+++ b/core/settings/launcher/inputmethodsettings.cpp
@@ -32,4 +32,5 @@
32#include <qpe/config.h> 32#include <qpe/config.h>
33#include <opie2/odebug.h> 33#include <opie2/odebug.h>
34#include <qpe/qcopenvelope_qws.h>
34 35
35/* QT */ 36/* QT */
@@ -57,7 +58,15 @@ InputMethodSettings::InputMethodSettings( QWidget *parent, const char *name ):QW
57 Config cfg( "Launcher" ); 58 Config cfg( "Launcher" );
58 cfg.setGroup( "InputMethods" ); 59 cfg.setGroup( "InputMethods" );
59 _resize->setChecked( cfg.readBoolEntry( "Resize", true ) ); 60
60 _float->setChecked( cfg.readBoolEntry( "Float", false ) ); 61 /*
61 _size->setValue( cfg.readNumEntry( "Width", 100 ) ); 62 * load the values to see if something was changed
63 */
64 _wasResize = cfg.readBoolEntry( "Resize", true );
65 _wasFloat = cfg.readBoolEntry( "Float", false );
66 _wasWidth = cfg.readNumEntry( "Width", 100 );
67
68 _resize->setChecked( _wasResize );
69 _float ->setChecked( _wasFloat );
70 _size ->setValue( _wasWidth );
62 71
63 lay->addWidget( _resize ); 72 lay->addWidget( _resize );
@@ -72,6 +81,13 @@ InputMethodSettings::InputMethodSettings( QWidget *parent, const char *name ):QW
72} 81}
73 82
74void InputMethodSettings::appletChanged() 83bool InputMethodSettings::changed()const{
75{ 84 if ( _wasResize != _resize->isChecked() )
85 return true;
86 else if ( _wasFloat != _float->isChecked() )
87 return true;
88 else if ( _wasWidth != _size->value() )
89 return true;
90 else
91 return false;
76} 92}
77 93
@@ -85,4 +101,7 @@ void InputMethodSettings::accept()
85 cfg.writeEntry( "Width", _size->value() ); 101 cfg.writeEntry( "Width", _size->value() );
86 cfg.write(); 102 cfg.write();
103
104 if ( changed() )
105 QCopEnvelope( "QPE/TaskBar", "reloadInputMethods()" );
87} 106}
88 107