author | zecke <zecke> | 2002-10-02 12:25:01 (UTC) |
---|---|---|
committer | zecke <zecke> | 2002-10-02 12:25:01 (UTC) |
commit | 6d20f295c578281b043073a5c0dd668fe754581a (patch) (unidiff) | |
tree | b34f24c6ad01589dca15eb4ef40640b5e9e57013 /noncore/apps/opie-console/mainwindow.cpp | |
parent | ff02919c1d2e83c3cb0dc1c726bf1eb636d1eb38 (diff) | |
download | opie-6d20f295c578281b043073a5c0dd668fe754581a.zip opie-6d20f295c578281b043073a5c0dd668fe754581a.tar.gz opie-6d20f295c578281b043073a5c0dd668fe754581a.tar.bz2 |
Commit my files so other people can play with them
Diffstat (limited to 'noncore/apps/opie-console/mainwindow.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/apps/opie-console/mainwindow.cpp | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/noncore/apps/opie-console/mainwindow.cpp b/noncore/apps/opie-console/mainwindow.cpp index 3c1c8ea..88d5823 100644 --- a/noncore/apps/opie-console/mainwindow.cpp +++ b/noncore/apps/opie-console/mainwindow.cpp | |||
@@ -5,6 +5,7 @@ | |||
5 | #include <qpopupmenu.h> | 5 | #include <qpopupmenu.h> |
6 | #include <qtoolbar.h> | 6 | #include <qtoolbar.h> |
7 | 7 | ||
8 | #include "configdialog.h" | ||
8 | #include "metafactory.h" | 9 | #include "metafactory.h" |
9 | #include "profilemanager.h" | 10 | #include "profilemanager.h" |
10 | #include "mainwindow.h" | 11 | #include "mainwindow.h" |
@@ -14,6 +15,7 @@ MainWindow::MainWindow() { | |||
14 | m_sessions.setAutoDelete( TRUE ); | 15 | m_sessions.setAutoDelete( TRUE ); |
15 | m_curSession = 0; | 16 | m_curSession = 0; |
16 | m_manager = new ProfileManager(m_factory); | 17 | m_manager = new ProfileManager(m_factory); |
18 | m_manager->load(); | ||
17 | 19 | ||
18 | initUI(); | 20 | initUI(); |
19 | populateProfiles(); | 21 | populateProfiles(); |
@@ -104,7 +106,7 @@ ProfileManager* MainWindow::manager() { | |||
104 | return m_manager; | 106 | return m_manager; |
105 | } | 107 | } |
106 | void MainWindow::populateProfiles() { | 108 | void MainWindow::populateProfiles() { |
107 | manager()->load(); | 109 | m_sessionsPop->clear(); |
108 | Profile::ValueList list = manager()->all(); | 110 | Profile::ValueList list = manager()->all(); |
109 | for (Profile::ValueList::Iterator it = list.begin(); it != list.end(); | 111 | for (Profile::ValueList::Iterator it = list.begin(); it != list.end(); |
110 | ++it ) { | 112 | ++it ) { |
@@ -147,6 +149,15 @@ void MainWindow::slotTerminate() { | |||
147 | } | 149 | } |
148 | void MainWindow::slotConfigure() { | 150 | void MainWindow::slotConfigure() { |
149 | qWarning("configure"); | 151 | qWarning("configure"); |
152 | ConfigDialog conf( manager()->all() ); | ||
153 | conf.showMaximized(); | ||
154 | |||
155 | int ret = conf.exec(); | ||
156 | |||
157 | if ( QDialog::Accepted == ret ) { | ||
158 | manager()->setProfiles( conf.list() ); | ||
159 | populateProfiles(); | ||
160 | } | ||
150 | } | 161 | } |
151 | void MainWindow::slotClose() { | 162 | void MainWindow::slotClose() { |
152 | 163 | ||