VR-Forces Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
planListBoxItem.h
Go to the documentation of this file.
1 /*******************************************************************************
2 ** Copyright (c) 2016 MAK Technologies, Inc.
3 ** All rights reserved.
4 *******************************************************************************/
5 
8 
9 #pragma once
10 
13 #include <vrvCore/DtUniqueID.h>
14 
15 #include <vrfplan/stmtIndex.h>
16 #include <vlutil/vlString.h>
17 
18 #include <QtGui/QImage>
19 #include <QtWidgets/QTreeWidget>
20 
21 namespace makVrv
22 {
23  class DtDe;
24 }
25 
26 class DtPlan;
27 namespace makVrf
28 {
29  class DtPlanTreeWidget;
30 
33  {
34  public:
35  DtPlanListBoxItem(makVrv::DtDe&, const QString& title);
36  virtual ~DtPlanListBoxItem();
37 
38  virtual void setEntityId(makVrv::DtUniqueID id);
39  virtual makVrv::DtUniqueID entityId() const override;
40  virtual bool isHeaderItem() const override;
41 
42  virtual void setPlan(DtPlan*);
43  virtual DtPlan* plan() const { return myPlan; };
44  virtual DtPlan* plan() { return getOrCreatePlan(); };
45  virtual const DtStmtIndex& statementIndex() const override;
46 
47  virtual DtPlanListBoxItem* parentPlanItem() const override;
48 
49  virtual DtPlanStatementItem* findLastItemByIndex(int statementIndex, int subBlock);
50  virtual DtPlanStatementItem* findItemByIndex(int statementIndex, int subBlock);
51  virtual void planLockStatusChanged(bool);
52 
54  virtual int selectedStatementIndex() const;
55 
56  virtual DtPlan* getOrCreatePlan();
57 
58  virtual bool isCopyable() const override;
59 
61  virtual void setName(const DtUUID&);
62  const DtUUID& name() const
63  {
64  return myName;
65  }
66 
67  virtual void setClearing(bool b);
68  bool clearing() const { return myClearing; };
69 
71  virtual void displayPlan();
72 
74  virtual void clear();
75 
77  virtual bool deleteStatement(DtPlanStatementItem*, bool redisplayPlan = true);
78 
79  virtual void addStatementsToPlan(const std::vector<DtSimStatement*>& statements, bool append, bool redisplay);
80 
82  virtual DtSimStatement* addStatementAfter(DtSimStatement* stmt, const DtPlanStatementItem* listItem, bool redisplay, bool addAtEndOfBlock,
83  DtSimStatement* afterStatement = nullptr);
84 
85  virtual void planUpdated();
86 
87  protected:
90  DtPlan* myPlan = nullptr;
92  };
93 
95  {
96  public:
99 
101  virtual ~DtPlanListBoxItemCreator();
102 
103  static DtPlanListBoxItemCreator& instance(makVrv::DtDe& de);
104  static void registerInstance(makVrv::DtDe& de, DtPlanListBoxItemCreator*);
105 
106  virtual DtPlanListBoxItem* create(const QString& str);
107 
108  protected:
110  };
111 }
UUID is a unique ID wrapper class.
Definition: uuid.h:59
virtual DtPlan * plan() const
Definition: planListBoxItem.h:43
Virtual base class. Allows for RTTI and proper virtual destruction. Used by Creators, Factories, Providers, Assemblers and User Interfaces.
Definition: DtVirtualBaseClass.h:19
virtual DtPlan * plan()
Definition: planListBoxItem.h:44
DtUUID myName
Definition: planListBoxItem.h:91
#define DT_DLL_VRFGUICOREQT
Definition: vrfGuiCoreQt.h:26
Definition: planStatementItem.h:35
class DtStmtIndex:
Definition: stmtIndex.h:24
This class will support the listing of plan items and the dragging/dropping thereof.
Definition: planTreeWidget.h:57
DtPlanTreeWidget * myPlanTreeWidget
Definition: planListBoxItem.h:88
This item will be the root node for a plan item – this will create children of type DtPlanStatementIt...
Definition: planListBoxItem.h:32
Definition: planListBoxItem.h:94
const DtUUID & name() const
Definition: planListBoxItem.h:62
unsigned long long DtUniqueID
Definition: DtUniqueID.h:19
class DtPlan:
Definition: plan.h:92
class DtSimStatement:
Definition: simStatement.h:38
makVrv::DtDe & myDe
Definition: planListBoxItem.h:109
Contains makVrv::DtUniqueID type.
bool clearing() const
Definition: planListBoxItem.h:68
The DtDe is the core component of any VR-Vantage application. It owns a DtRenderer, DtDeCommunicator, as well as a DtDisplay and other things.
Definition: DtDe.h:72
makVrv::DtUniqueID myEntityId
Definition: planListBoxItem.h:89

Document ID: Generated on Wed Mar 27 22:49:11 EDT 2024 from SVN revision 264633
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)