Changeset View
Changeset View
Standalone View
Standalone View
ksmserver/server.h
Show First 20 Lines • Show All 111 Lines • ▼ Show 20 Line(s) | 81 | public: | |||
---|---|---|---|---|---|
112 | 112 | | |||
113 | // public API | 113 | // public API | ||
114 | void restoreSession( const QString &sessionName ); | 114 | void restoreSession( const QString &sessionName ); | ||
115 | void startDefaultSession(); | 115 | void startDefaultSession(); | ||
116 | void shutdown( KWorkSpace::ShutdownConfirm confirm, | 116 | void shutdown( KWorkSpace::ShutdownConfirm confirm, | ||
117 | KWorkSpace::ShutdownType sdtype, | 117 | KWorkSpace::ShutdownType sdtype, | ||
118 | KWorkSpace::ShutdownMode sdmode ); | 118 | KWorkSpace::ShutdownMode sdmode ); | ||
119 | 119 | | |||
120 | virtual void suspendStartup( const QString &app ); | | |||
121 | virtual void resumeStartup( const QString &app ); | | |||
122 | | ||||
123 | void launchWM( const QList< QStringList >& wmStartCommands ); | 120 | void launchWM( const QList< QStringList >& wmStartCommands ); | ||
124 | 121 | | |||
125 | public Q_SLOTS: | 122 | public Q_SLOTS: | ||
126 | void cleanUp(); | 123 | void cleanUp(); | ||
127 | 124 | | |||
128 | private Q_SLOTS: | 125 | private Q_SLOTS: | ||
129 | void newConnection( int socket ); | 126 | void newConnection( int socket ); | ||
130 | void processData( int socket ); | 127 | void processData( int socket ); | ||
131 | 128 | | |||
132 | void protectionTimeout(); | 129 | void protectionTimeout(); | ||
133 | void timeoutQuit(); | 130 | void timeoutQuit(); | ||
134 | void timeoutWMQuit(); | 131 | void timeoutWMQuit(); | ||
135 | void kcmPhase1Timeout(); | 132 | void kcmPhase1Timeout(); | ||
136 | void kcmPhase2Timeout(); | 133 | void kcmPhase2Timeout(); | ||
137 | void pendingShutdownTimeout(); | 134 | void pendingShutdownTimeout(); | ||
138 | 135 | | |||
139 | void autoStart0(); | 136 | void autoStart0(); | ||
140 | void autoStart1(); | 137 | void autoStart1(); | ||
141 | void autoStart2(); | 138 | void autoStart2(); | ||
142 | void tryRestoreNext(); | 139 | void tryRestoreNext(); | ||
143 | void startupSuspendTimeout(); | | |||
144 | void wmProcessChange(); | 140 | void wmProcessChange(); | ||
145 | void autoStart0Done(); | 141 | void autoStart0Done(); | ||
146 | void autoStart1Done(); | 142 | void autoStart1Done(); | ||
147 | void autoStart2Done(); | 143 | void autoStart2Done(); | ||
148 | void kcmPhase1Done(); | 144 | void kcmPhase1Done(); | ||
149 | void kcmPhase2Done(); | 145 | void kcmPhase2Done(); | ||
150 | 146 | | |||
151 | void defaultLogout(); | 147 | void defaultLogout(); | ||
▲ Show 20 Lines • Show All 42 Lines • ▼ Show 20 Line(s) | 153 | private: | |||
194 | void storeLegacySession( KConfig* config ); | 190 | void storeLegacySession( KConfig* config ); | ||
195 | void restoreLegacySession( KConfig* config ); | 191 | void restoreLegacySession( KConfig* config ); | ||
196 | void restoreLegacySessionInternal( KConfigGroup* config, char sep = ',' ); | 192 | void restoreLegacySessionInternal( KConfigGroup* config, char sep = ',' ); | ||
197 | QStringList windowWmCommand(WId w); | 193 | QStringList windowWmCommand(WId w); | ||
198 | QString windowWmClientMachine(WId w); | 194 | QString windowWmClientMachine(WId w); | ||
199 | WId windowWmClientLeader(WId w); | 195 | WId windowWmClientLeader(WId w); | ||
200 | QByteArray windowSessionId(WId w, WId leader); | 196 | QByteArray windowSessionId(WId w, WId leader); | ||
201 | 197 | | |||
202 | bool checkStartupSuspend(); | | |||
203 | void finishStartup(); | 198 | void finishStartup(); | ||
204 | void resumeStartupInternal(); | | |||
205 | void setupShortcuts(); | 199 | void setupShortcuts(); | ||
206 | 200 | | |||
207 | void runShutdownScripts(); | 201 | void runShutdownScripts(); | ||
208 | 202 | | |||
209 | void performLogout(); | 203 | void performLogout(); | ||
210 | 204 | | |||
211 | // public dcop interface | 205 | // public dcop interface | ||
212 | 206 | | |||
Show All 31 Lines | 234 | enum State | |||
244 | Shutdown, Checkpoint, Killing, KillingWM, WaitingForKNotify, // shutdown | 238 | Shutdown, Checkpoint, Killing, KillingWM, WaitingForKNotify, // shutdown | ||
245 | ClosingSubSession, KillingSubSession, RestoringSubSession | 239 | ClosingSubSession, KillingSubSession, RestoringSubSession | ||
246 | }; | 240 | }; | ||
247 | State state; | 241 | State state; | ||
248 | bool dialogActive; | 242 | bool dialogActive; | ||
249 | bool saveSession; | 243 | bool saveSession; | ||
250 | int wmPhase1WaitingCount; | 244 | int wmPhase1WaitingCount; | ||
251 | int saveType; | 245 | int saveType; | ||
252 | QMap< QString, int > startupSuspendCount; | | |||
253 | 246 | | |||
254 | KWorkSpace::ShutdownType shutdownType; | 247 | KWorkSpace::ShutdownType shutdownType; | ||
255 | KWorkSpace::ShutdownMode shutdownMode; | 248 | KWorkSpace::ShutdownMode shutdownMode; | ||
256 | QString bootOption; | 249 | QString bootOption; | ||
257 | 250 | | |||
258 | bool clean; | 251 | bool clean; | ||
259 | KSMClient* clientInteracting; | 252 | KSMClient* clientInteracting; | ||
260 | QString wm; | 253 | QString wm; | ||
261 | QStringList wmCommands; | 254 | QStringList wmCommands; | ||
262 | KProcess* wmProcess; | 255 | KProcess* wmProcess; | ||
263 | QString sessionGroup; | 256 | QString sessionGroup; | ||
264 | QString sessionName; | 257 | QString sessionName; | ||
265 | QTimer protectionTimer; | 258 | QTimer protectionTimer; | ||
266 | QTimer restoreTimer; | 259 | QTimer restoreTimer; | ||
267 | QString xonCommand; | 260 | QString xonCommand; | ||
268 | QTimer startupSuspendTimeoutTimer; | | |||
269 | bool waitAutoStart2; | 261 | bool waitAutoStart2; | ||
270 | bool waitKcmInit2; | 262 | bool waitKcmInit2; | ||
271 | QTimer pendingShutdown; | 263 | QTimer pendingShutdown; | ||
272 | QWidget* logoutEffectWidget; | 264 | QWidget* logoutEffectWidget; | ||
273 | KWorkSpace::ShutdownConfirm pendingShutdown_confirm; | 265 | KWorkSpace::ShutdownConfirm pendingShutdown_confirm; | ||
274 | KWorkSpace::ShutdownType pendingShutdown_sdtype; | 266 | KWorkSpace::ShutdownType pendingShutdown_sdtype; | ||
275 | KWorkSpace::ShutdownMode pendingShutdown_sdmode; | 267 | KWorkSpace::ShutdownMode pendingShutdown_sdmode; | ||
276 | 268 | | |||
Show All 27 Lines |