![]() |
VR-Forces 4.0.4 Class Documentation
|
00001 /******************************************************************************* 00002 ** Copyright (c) 2009 MAK Technologies, Inc. 00003 ** All rights reserved. 00004 *******************************************************************************/ 00005 /******************************************************************************* 00006 ** $RCSfile: DtSimulationCommandDialogInterface.h,v $ $Revision: 1.2 $ $State: Exp $ 00007 *******************************************************************************/ 00008 00011 00013 00014 #pragma once 00015 00016 #include <vrvUtil/signalslib.h> 00017 00018 #include <vrfGuiCoreQt/vrfGuiCoreQt.h> 00019 #include <vrfGuiCoreQt/DtBaseTaskSetDialogInterface.h> 00020 00021 #include <QtGui/QWidget> 00022 00023 namespace makVrv 00024 { 00025 class DtDe; 00026 class DtSimEntry; 00027 struct DtEntityState; 00028 class DtSimObjectEntry; 00029 } 00030 00031 static const Qt::WindowFlags theSimulationCommandSetCreationFlags = 00032 Qt::Dialog | Qt::CustomizeWindowHint | Qt::WindowTitleHint; 00033 00034 class QWidget; 00035 class DtSimCommand; 00036 class DtString; 00037 class DtSimStatement; 00038 00039 namespace makVrf 00040 { 00041 class DtSimulationCommandDialogInterface; 00042 00043 //* This wrapper MUST be used for all sim commands that take an object. The subclass will be 00044 //* implemented by the individual sim command dialogs to appropriately set the object name 00045 00046 class DT_DLL_VRFGUICOREQT DtSimCommandObjectWrapper 00047 { 00048 public: 00049 DtSimCommandObjectWrapper(const DtSimCommand&); 00050 DtSimCommandObjectWrapper(const DtSimCommandObjectWrapper&); 00051 virtual ~DtSimCommandObjectWrapper(); 00052 00053 virtual void setObjectName(const DtString&) = 0; 00054 virtual DtString objectName() const = 0; 00055 00056 virtual DtSimCommandObjectWrapper* clone() const = 0; 00057 00058 DtSimCommand* simCommand() 00059 { 00060 return mySimCommand; 00061 } 00062 00063 const DtSimCommand* simCommand() const 00064 { 00065 return mySimCommand; 00066 } 00067 00068 protected: 00069 DtSimCommand* mySimCommand; 00070 }; 00071 00073 class DT_DLL_VRFGUICOREQT DtVrfSimulationCommandDialogCreator 00074 { 00075 public: 00076 virtual DtSimulationCommandDialogInterface* create(makVrv::DtDe&, QWidget* parent) = 0; 00077 virtual bool supportsType(int, const DtSimStatement* stmt) const = 0; 00078 virtual std::string objectNameFromStatement(const DtSimCommand*) const = 0; 00079 }; 00080 00081 class DT_DLL_VRFGUICOREQT DtSimulationCommandDialogInterface : public DtBaseTaskSetDialogInterface 00082 { 00083 public: 00084 //CTOR 00085 DtSimulationCommandDialogInterface(makVrv::DtDe& de, QWidget* parent, const Qt::WindowFlags& flags = 0); 00086 00087 protected: 00088 virtual QWidget* contents(const std::vector<makVrv::DtSimEntry*>& data); 00089 }; 00090 }