Diffstat (limited to 'korganizer/kodialogmanager.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | korganizer/kodialogmanager.cpp | 21 |
1 files changed, 4 insertions, 17 deletions
diff --git a/korganizer/kodialogmanager.cpp b/korganizer/kodialogmanager.cpp index aa30c52..3dfa344 100644 --- a/korganizer/kodialogmanager.cpp +++ b/korganizer/kodialogmanager.cpp | |||
@@ -69,81 +69,68 @@ KODialogManager::~KODialogManager() | |||
69 | delete mFilterEditDialog; | 69 | delete mFilterEditDialog; |
70 | #ifndef KORG_NOPLUGINS | 70 | #ifndef KORG_NOPLUGINS |
71 | delete mPluginDialog; | 71 | delete mPluginDialog; |
72 | #endif | 72 | #endif |
73 | } | 73 | } |
74 | 74 | ||
75 | OutgoingDialog *KODialogManager::outgoingDialog() | 75 | OutgoingDialog *KODialogManager::outgoingDialog() |
76 | { | 76 | { |
77 | createOutgoingDialog(); | 77 | createOutgoingDialog(); |
78 | return mOutgoingDialog; | 78 | return mOutgoingDialog; |
79 | } | 79 | } |
80 | 80 | ||
81 | void KODialogManager::createOutgoingDialog() | 81 | void KODialogManager::createOutgoingDialog() |
82 | { | 82 | { |
83 | if (!mOutgoingDialog) { | 83 | if (!mOutgoingDialog) { |
84 | mOutgoingDialog = new OutgoingDialog(mMainView->calendar(),mMainView); | 84 | mOutgoingDialog = new OutgoingDialog(mMainView->calendar(),mMainView); |
85 | if (mIncomingDialog) mIncomingDialog->setOutgoingDialog(mOutgoingDialog); | 85 | if (mIncomingDialog) mIncomingDialog->setOutgoingDialog(mOutgoingDialog); |
86 | connect(mOutgoingDialog,SIGNAL(numMessagesChanged(int)), | 86 | connect(mOutgoingDialog,SIGNAL(numMessagesChanged(int)), |
87 | mMainView,SIGNAL(numOutgoingChanged(int))); | 87 | mMainView,SIGNAL(numOutgoingChanged(int))); |
88 | } | 88 | } |
89 | } | 89 | } |
90 | 90 | ||
91 | void KODialogManager::showGlobalOptionsDialog( bool showSync ) | 91 | void KODialogManager::showGlobalOptionsDialog( bool showSync ) |
92 | { | 92 | { |
93 | if (!mOptionsDialog) { | 93 | KPimPrefsGlobalDialog gc ( mMainView ); |
94 | mOptionsDialog = new KOPrefsDialog(0); | ||
95 | connect(mOptionsDialog,SIGNAL(configChanged()), | ||
96 | mMainView,SLOT(updateConfig())); | ||
97 | } | ||
98 | mOptionsDialog->readConfig(); | ||
99 | #ifndef DESKTOP_VERSION | ||
100 | mOptionsDialog->showMaximized(); | ||
101 | #else | ||
102 | mOptionsDialog->show(); | ||
103 | #endif | ||
104 | if ( showSync ) | 94 | if ( showSync ) |
105 | mOptionsDialog->showSyncPage(); | 95 | gc.showTZconfig(); |
106 | mOptionsDialog->exec(); | 96 | gc.exec(); |
107 | delete mOptionsDialog; | ||
108 | mOptionsDialog = 0; | ||
109 | } | 97 | } |
110 | void KODialogManager::showOptionsDialog( bool showSync ) | 98 | void KODialogManager::showOptionsDialog( bool showSync ) |
111 | { | 99 | { |
112 | 100 | ||
113 | if (!mOptionsDialog) { | 101 | if (!mOptionsDialog) { |
114 | mOptionsDialog = new KOPrefsDialog(mMainView); | 102 | mOptionsDialog = new KOPrefsDialog(mMainView); |
115 | connect(mOptionsDialog,SIGNAL(configChanged()), | 103 | connect(mOptionsDialog,SIGNAL(configChanged()), |
116 | mMainView,SLOT(updateConfig())); | 104 | mMainView,SLOT(updateConfig())); |
117 | } | 105 | } |
118 | mOptionsDialog->readConfig(); | 106 | mOptionsDialog->readConfig(); |
119 | #ifndef DESKTOP_VERSION | 107 | #ifndef DESKTOP_VERSION |
120 | mOptionsDialog->showMaximized(); | 108 | mOptionsDialog->showMaximized(); |
121 | #else | 109 | #else |
122 | mOptionsDialog->show(); | 110 | mOptionsDialog->show(); |
123 | #endif | 111 | #endif |
124 | if ( showSync ) | 112 | |
125 | mOptionsDialog->showSyncPage(); | ||
126 | mOptionsDialog->exec(); | 113 | mOptionsDialog->exec(); |
127 | delete mOptionsDialog; | 114 | delete mOptionsDialog; |
128 | mOptionsDialog = 0; | 115 | mOptionsDialog = 0; |
129 | } | 116 | } |
130 | void KODialogManager::showSyncOptions() | 117 | void KODialogManager::showSyncOptions() |
131 | { | 118 | { |
132 | showGlobalOptionsDialog( true ); | 119 | showGlobalOptionsDialog( true ); |
133 | 120 | ||
134 | } | 121 | } |
135 | void KODialogManager::showOutgoingDialog() | 122 | void KODialogManager::showOutgoingDialog() |
136 | { | 123 | { |
137 | createOutgoingDialog(); | 124 | createOutgoingDialog(); |
138 | mOutgoingDialog->show(); | 125 | mOutgoingDialog->show(); |
139 | mOutgoingDialog->raise(); | 126 | mOutgoingDialog->raise(); |
140 | } | 127 | } |
141 | 128 | ||
142 | IncomingDialog *KODialogManager::incomingDialog() | 129 | IncomingDialog *KODialogManager::incomingDialog() |
143 | { | 130 | { |
144 | createOutgoingDialog(); | 131 | createOutgoingDialog(); |
145 | if (!mIncomingDialog) { | 132 | if (!mIncomingDialog) { |
146 | mIncomingDialog = new IncomingDialog(mMainView->calendar(),mOutgoingDialog,mMainView); | 133 | mIncomingDialog = new IncomingDialog(mMainView->calendar(),mOutgoingDialog,mMainView); |
147 | connect(mIncomingDialog,SIGNAL(numMessagesChanged(int)), | 134 | connect(mIncomingDialog,SIGNAL(numMessagesChanged(int)), |
148 | mMainView,SIGNAL(numIncomingChanged(int))); | 135 | mMainView,SIGNAL(numIncomingChanged(int))); |
149 | connect(mIncomingDialog,SIGNAL(calendarUpdated()), | 136 | connect(mIncomingDialog,SIGNAL(calendarUpdated()), |