orca-robotics INTRODUCTION Overview Download and Install Quick Start Documentation Publications REPOSITORY Interfaces Components Libraries Utilities Software Map DEVELOPER Tutorials Examples Dev Guide Dashboard Wiki login/pass: orca/orca PEOPLE Contributors Users Project Download Mailing lists
|
libs/orcaqgui/mainwin.h00001 /* 00002 * Orca-Robotics Project: Components for robotics 00003 * http://orca-robotics.sf.net/ 00004 * Copyright (c) 2004-2008 Alex Brooks, Alexei Makarenko, Tobias Kaupp 00005 * 00006 * This copy of Orca is licensed to you under the terms described in 00007 * the LICENSE file included in this distribution. 00008 * 00009 */ 00010 00011 #ifndef ORCA_ORCAQGUI_MAIN_WINDOW_H 00012 #define ORCA_ORCAQGUI_MAIN_WINDOW_H 00013 00014 #include <vector> 00015 #include <QMainWindow> 00016 00017 #include <hydroiceutil/jobqueue.h> 00018 #include <hydroqguielementutil/ihumanmanager.h> 00019 #include <orcaice/context.h> 00020 #include <orcaqguielementmodelview/guielementmodel.h> 00021 #include <orcaqguielementmodelview/guielementview.h> 00022 #include "platformfocuscombo.h" 00023 00024 namespace orcaqcm { 00025 class OcmModel; 00026 }; 00027 00028 class QTreeView; 00029 class QItemDelegate; 00030 class QSplitter; 00031 class QTimer; 00032 00033 namespace orcaqgui { 00034 00041 class MainWindow : public QMainWindow, 00042 public hydroqguielementutil::IHumanManager 00043 { 00044 Q_OBJECT 00045 public: 00046 00048 struct ScreenDumpParams { 00049 int topPad; 00050 int sidePad; 00051 int bottomPad; 00052 std::string dumpPath; 00053 int captureTimerInterval; 00054 }; 00055 00056 MainWindow( std::string title, 00057 ScreenDumpParams screenDumpParams, 00058 const std::vector<std::string> &supportedInterfaces ); 00059 00060 // Inherited from hydroqguielementutil::IHumanManager 00061 virtual void showDialogMsg( hydroqguielementutil::IHumanManager::MessageType type, const QString &msg ); 00062 virtual void showStatusMsg( hydroqguielementutil::IHumanManager::MessageType type, const QString &msg ); 00063 virtual QMenu *fileMenu() { return fileMenu_; } 00064 virtual QMenu *optionsMenu() { return optionsMenu_; } 00065 virtual QMenu *displayMenu() { return displayMenu_; } 00066 virtual QMenuBar *menuBar() { return QMainWindow::menuBar(); } 00067 virtual QToolBar *toolBar() { return toolBar_; } 00068 00069 private slots: 00070 00071 // screen capture 00072 void toggleScreenCapture( bool capture ); 00073 void grabWindow(); 00074 00075 void quit(); 00076 void aboutOrca(); 00077 void aboutApp(); 00078 00079 private: 00080 00081 // configuration parameters 00082 ScreenDumpParams screenDumpParams_; 00083 00084 std::vector<std::string> supportedInterfaces_; 00085 00086 // screen capture 00087 void initScreenCapture(); 00088 int screenDumpCounter_; 00089 QTimer* screenCaptureTimer_; 00090 00091 QMenu* fileMenu_; 00092 QMenu* optionsMenu_; 00093 QMenu* displayMenu_; 00094 QToolBar *toolBar_; 00095 00096 orcaice::Context context_; 00097 }; 00098 00099 } 00100 00101 #endif |
Webmaster: Tobias Kaupp (tobasco at users.sourceforge.net)