File indexing completed on 2024-06-02 04:34:53
0001 /*************************************************************************** 0002 * * 0003 * copyright : (C) 2007 The University of Toronto * 0004 * netterfield@astro.utoronto.ca * 0005 * * 0006 * This program is free software; you can redistribute it and/or modify * 0007 * it under the terms of the GNU General Public License as published by * 0008 * the Free Software Foundation; either version 2 of the License, or * 0009 * (at your option) any later version. * 0010 * * 0011 ***************************************************************************/ 0012 0013 #ifndef APPLICATION_H 0014 #define APPLICATION_H 0015 0016 #include <QPointer> 0017 #include <QApplication> 0018 0019 0020 #include "mainwindow.h" 0021 0022 #define kstApp \ 0023 (static_cast<Kst::Application*>(QCoreApplication::instance())) 0024 0025 namespace Kst { 0026 0027 class Application : public QApplication 0028 { 0029 Q_OBJECT 0030 public: 0031 Application(int &argc, char **argv); 0032 virtual ~Application(); 0033 0034 MainWindow *mainWindow() const; 0035 0036 void initMainWindow(); 0037 QString userName() {return _userName;} 0038 private: 0039 QPointer<MainWindow> _mainWindow; 0040 QString _userName; 0041 }; 0042 0043 } 0044 0045 #endif 0046 0047 // vim: ts=2 sw=2 et