Konsole
Application.h
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020 #ifndef APPLICATION_H
00021 #define APPLICATION_H
00022
00023
00024 #include <KUniqueApplication>
00025
00026 class KCmdLineArgs;
00027
00028 namespace Konsole
00029 {
00030 class ProfileList;
00031 class ViewManager;
00032 class MainWindow;
00033 class Session;
00034
00046 class Application : public KUniqueApplication
00047 {
00048 Q_OBJECT
00049
00050 public:
00052 #ifdef Q_WS_X11
00053 Application(Display* display , Qt::HANDLE visual, Qt::HANDLE colormap);
00054 #endif
00055
00057 Application();
00058
00059 virtual ~Application();
00060
00062 virtual int newInstance();
00063
00069 MainWindow* newMainWindow();
00070
00072 static Application* self();
00073
00074 private slots:
00075 void createSession(const QString& key, const QString& directory , ViewManager* view);
00076 void createWindow(const QString& key , const QString& directory);
00077 void detachView(Session* session);
00078
00079 void toggleBackgroundInstance();
00080
00081 private:
00082 void init();
00083 void listAvailableProfiles();
00084 void startBackgroundMode(MainWindow* window);
00085 bool processHelpArgs(KCmdLineArgs* args);
00086 MainWindow* processWindowArgs(KCmdLineArgs* args);
00087 void processProfileSelectArgs(KCmdLineArgs* args,MainWindow* window);
00088 void processProfileChangeArgs(KCmdLineArgs* args,MainWindow* window);
00089
00090 KCmdLineArgs* _arguments;
00091 ProfileList* _sessionList;
00092
00093 MainWindow* _backgroundInstance;
00094 };
00095
00096 }
00097 #endif //APPLICATION_H