author | mickeyl <mickeyl> | 2003-10-30 13:18:08 (UTC) |
---|---|---|
committer | mickeyl <mickeyl> | 2003-10-30 13:18:08 (UTC) |
commit | 37414f207b147af4cf6778b323a0aa23127901bd (patch) (unidiff) | |
tree | b08c10043ab689b0a40425d268cd72226799b0cf /noncore/apps/checkbook/mainwindow.cpp | |
parent | d53637f46cf217fc760d7aac58b4596843a73803 (diff) | |
download | opie-37414f207b147af4cf6778b323a0aa23127901bd.zip opie-37414f207b147af4cf6778b323a0aa23127901bd.tar.gz opie-37414f207b147af4cf6778b323a0aa23127901bd.tar.bz2 |
apply patch to HEAD
Diffstat (limited to 'noncore/apps/checkbook/mainwindow.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/apps/checkbook/mainwindow.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/noncore/apps/checkbook/mainwindow.cpp b/noncore/apps/checkbook/mainwindow.cpp index 8d64cad..bf00102 100644 --- a/noncore/apps/checkbook/mainwindow.cpp +++ b/noncore/apps/checkbook/mainwindow.cpp | |||
@@ -55,13 +55,12 @@ MainWindow::MainWindow( QWidget* parent, const char* name, WFlags fl ) | |||
55 | 55 | ||
56 | cbDir = Global::applicationFileName( "checkbook", "" ); | 56 | cbDir = Global::applicationFileName( "checkbook", "" ); |
57 | lockIcon = Resource::loadPixmap( "locked" ); | 57 | lockIcon = Resource::loadPixmap( "locked" ); |
58 | 58 | ||
59 | // Load configuration options | 59 | // Load configuration options |
60 | Config config( "checkbook" ); | 60 | Config config( "checkbook" ); |
61 | qDebug( "Reading config" ); | ||
62 | _cfg.readConfig( config ); | 61 | _cfg.readConfig( config ); |
63 | 62 | ||
64 | 63 | ||
65 | // Build menu and tool bars | 64 | // Build menu and tool bars |
66 | setToolBarsMovable( FALSE ); | 65 | setToolBarsMovable( FALSE ); |
67 | 66 | ||
@@ -311,12 +310,18 @@ void MainWindow::openBook(QListViewItem *curritem) | |||
311 | if ( _cfg.getShowBalances() && cb->balance() != currbalance ) | 310 | if ( _cfg.getShowBalances() && cb->balance() != currbalance ) |
312 | { | 311 | { |
313 | QString tempstr; | 312 | QString tempstr; |
314 | tempstr.sprintf( "%s%.2f", _cfg.getCurrencySymbol().latin1(), cb->balance() ); | 313 | tempstr.sprintf( "%s%.2f", _cfg.getCurrencySymbol().latin1(), cb->balance() ); |
315 | curritem->setText( posName + 1, tempstr ); | 314 | curritem->setText( posName + 1, tempstr ); |
316 | } | 315 | } |
316 | |||
317 | // write config, if needed | ||
318 | if( _cfg.isDirty() ) { | ||
319 | Config config("checkbook"); | ||
320 | _cfg.writeConfig( config ); | ||
321 | } | ||
317 | } | 322 | } |
318 | delete currcb; | 323 | delete currcb; |
319 | } | 324 | } |
320 | 325 | ||
321 | // --- slotDelete ------------------------------------------------------------- | 326 | // --- slotDelete ------------------------------------------------------------- |
322 | void MainWindow::slotDelete() | 327 | void MainWindow::slotDelete() |