author | cniehaus <cniehaus> | 2003-01-04 14:08:38 (UTC) |
---|---|---|
committer | cniehaus <cniehaus> | 2003-01-04 14:08:38 (UTC) |
commit | 851c182383c34fd4925677713bb5f6fd603c86a0 (patch) (unidiff) | |
tree | 1f1ed41aa225cff23eb64bd0b1631d3f307975aa /noncore/apps/odict/odict.cpp | |
parent | 69f08fb67ec7e92c4b3c573d6a1ce374aaa97cee (diff) | |
download | opie-851c182383c34fd4925677713bb5f6fd603c86a0.zip opie-851c182383c34fd4925677713bb5f6fd603c86a0.tar.gz opie-851c182383c34fd4925677713bb5f6fd603c86a0.tar.bz2 |
one typo ;)
several bugfixes
Diffstat (limited to 'noncore/apps/odict/odict.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/apps/odict/odict.cpp | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/noncore/apps/odict/odict.cpp b/noncore/apps/odict/odict.cpp index 1fbdb85..e0104eb 100644 --- a/noncore/apps/odict/odict.cpp +++ b/noncore/apps/odict/odict.cpp | |||
@@ -66,12 +66,13 @@ void ODict::loadConfig() | |||
66 | errorTol = cfg.readEntry( "errtol" ).toInt(); | 66 | errorTol = cfg.readEntry( "errtol" ).toInt(); |
67 | casesens = cfg.readEntry( "casesens" ).toInt(); | 67 | casesens = cfg.readEntry( "casesens" ).toInt(); |
68 | regexp = cfg.readEntry( "regexp" ).toInt(); | 68 | regexp = cfg.readEntry( "regexp" ).toInt(); |
69 | completewords = cfg.readEntry( "completewords" ).toInt(); | 69 | completewords = cfg.readEntry( "completewords" ).toInt(); |
70 | 70 | ||
71 | QStringList groupListCfg = cfg.groupList().grep( "Method_" ); | 71 | QStringList groupListCfg = cfg.groupList().grep( "Method_" ); |
72 | query_co->clear(); | ||
72 | for ( QStringList::Iterator it = groupListCfg.begin() ; it != groupListCfg.end() ; ++it ) | 73 | for ( QStringList::Iterator it = groupListCfg.begin() ; it != groupListCfg.end() ; ++it ) |
73 | { | 74 | { |
74 | cfg.setGroup( *it ); | 75 | cfg.setGroup( *it ); |
75 | query_co->insertItem( cfg.readEntry( "Name" ) ); | 76 | query_co->insertItem( cfg.readEntry( "Name" ) ); |
76 | } | 77 | } |
77 | } | 78 | } |
@@ -86,21 +87,21 @@ void ODict::saveConfig() | |||
86 | cfg.writeEntry( "regexp" , regexp ); | 87 | cfg.writeEntry( "regexp" , regexp ); |
87 | cfg.writeEntry( "completewords" , completewords ); | 88 | cfg.writeEntry( "completewords" , completewords ); |
88 | } | 89 | } |
89 | 90 | ||
90 | void ODict::slotDisplayAbout() | 91 | void ODict::slotDisplayAbout() |
91 | { | 92 | { |
92 | QMessageBox::about( this, tr( "About ODict" ), tr( "OPIE-Dictionary ODict \n (c) 2002, 2003 Carsten Niehaus \n cniehaus@handhelds.org \n Version 20030103" ) ); | 93 | QMessageBox::about( this, tr( "About ODict" ), tr( "OPIE-Dictionary ODict \n (c) 2002, 2003 Carsten Niehaus \n cniehaus@handhelds.org \n Version 20030104" ) ); |
93 | } | 94 | } |
94 | 95 | ||
95 | void ODict::slotStartQuery() | 96 | void ODict::slotStartQuery() |
96 | { | 97 | { |
97 | QString querystring = query_le->text(); | 98 | QString querystring = query_le->text(); |
98 | qDebug("opening dict >%s< for >%s<", activated_name.latin1(),querystring.latin1()); | 99 | qDebug("opening dict >%s< for >%s<", activated_name.latin1(),querystring.latin1()); |
99 | if (querystring.isEmpty()){ | 100 | if (querystring.isEmpty()){ |
100 | qWarning("empty querysting"); | 101 | qWarning("empty querystring"); |
101 | return; | 102 | return; |
102 | } | 103 | } |
103 | if (!activated_name || activated_name.isEmpty()) | 104 | if (!activated_name || activated_name.isEmpty()) |
104 | QMessageBox::warning(this,tr("No Dictionary"),tr("Please choose a dictonary") ); | 105 | QMessageBox::warning(this,tr("No Dictionary"),tr("Please choose a dictonary") ); |
105 | else | 106 | else |
106 | DingWidget *ding = new DingWidget( querystring , browser_top, browser_bottom, activated_name ); | 107 | DingWidget *ding = new DingWidget( querystring , browser_top, browser_bottom, activated_name ); |
@@ -113,13 +114,16 @@ void ODict::slotSetErrorcount( int count ) | |||
113 | } | 114 | } |
114 | 115 | ||
115 | void ODict::slotSettings() | 116 | void ODict::slotSettings() |
116 | { | 117 | { |
117 | ConfigDlg dlg( this, "Config" , true); | 118 | ConfigDlg dlg( this, "Config" , true); |
118 | if ( dlg.exec() == QDialog::Accepted ) | 119 | if ( dlg.exec() == QDialog::Accepted ) |
120 | { | ||
119 | dlg.writeEntries(); | 121 | dlg.writeEntries(); |
122 | loadConfig(); | ||
123 | } | ||
120 | else qDebug( "abgebrochen" ); | 124 | else qDebug( "abgebrochen" ); |
121 | } | 125 | } |
122 | 126 | ||
123 | void ODict::slotSetParameter( int count ) | 127 | void ODict::slotSetParameter( int count ) |
124 | { | 128 | { |
125 | if ( count == 0 ) | 129 | if ( count == 0 ) |