VR-Forces Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
DtMenuAssembler.h
Go to the documentation of this file.
1 /******************************************************************************
2 ** Copyright (c) 2021 MAK Technologies, Inc.
3 ** All rights reserved.
4 ******************************************************************************/
5 
9 
10 #pragma once
11 
12 #include <vrvCore/vrvCore.h>
14 #include <vrvCore/DtMenuPath.h>
15 
16 #include <stack>
17 
18 namespace makVrv
19 {
20  class DtMenuConfiguration;
21  class DtDe;
22 
26  {
27  public:
28 
29  friend class DtMenuAssemblerCreator;
30 
32  static DtMenuAssembler& instance(DtDe&);
33 
35  virtual ~DtMenuAssembler();
36 
38  virtual void assemble(const DtMenuConfiguration& configuration);
39 
42  virtual void sortConfiguration(const DtMenuConfiguration& configuration) = 0;
43 
44  protected:
45 
46  DtMenuAssembler(DtDe& de);
47 
49  void assembleMenuPath(const DtMenuPath& menuPath,
50  const DtMenuConfiguration& configuration);
51 
53  virtual void assembleMenu(const DtMenuPath& menuPath) = 0;
54 
56  virtual void assembleMenuItem(const DtMenuPath& menuPath) = 0;
57 
58  protected:
59 
60  std::stack<DtMenuPath> myMenuStack;
61 
63 
64  };
65 
74  {
75  public:
76 
78  static DtMenuAssemblerCreator& instance(DtDe& de);
79 
82  static void registerInstance(DtDe& de, DtMenuAssemblerCreator* creator);
83 
85  virtual ~DtMenuAssemblerCreator();
86 
88  virtual DtMenuAssembler* create(DtDe& de) = 0;
89 
90  };
91 }
Virtual base class. Allows for RTTI and proper virtual destruction. Used by Creators, Factories, Providers, Assemblers and User Interfaces.
Definition: DtVirtualBaseClass.h:19
DtDe & myDe
Definition: DtMenuAssembler.h:62
Contains makVrv::DtMenuPath class.
Contains makVrv::DtVirtualBaseClass class.
#define DT_DLL_VRVCORE
Definition: vrvCore.h:20
a Class which represents a menu path. The specific strings are not menu text, but the names used when...
Definition: DtMenuPath.h:27
std::stack< DtMenuPath > myMenuStack
Definition: DtMenuAssembler.h:60
A configuration of a menu layout. A menu configuration manages an ordered collection of menu paths th...
Definition: DtMenuConfiguration.h:43
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
An abstract menu assembler base class.
Definition: DtMenuAssembler.h:25
An abstract menu assembler creator base class. This base class allows for the application&#39;s default m...
Definition: DtMenuAssembler.h:73
Contains DLL export macros.

Document ID: Generated on Tue Sep 24 19:28:17 EDT 2024 from SVN revision 269799
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)