VR-Forces 4.6.1 Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
imageLayerWidget.h
Go to the documentation of this file.
1 /******************************************************************************
2 ** Copyright (c) 2014 MAK Technologies, Inc.
3 ** All rights reserved.
4 ******************************************************************************/
5 
9 
10 #pragma once
11 
12 #include <vrvUtil/signalslib.h>
13 
16 #include <QtWidgets/QWidget>
17 
18 namespace makVrv
19 {
20  class DtDe;
21 }
22 
23 namespace osgEarth
24 {
25  class ImageLayer;
26  class ModelLayer;
27 }
28 
29 class QTreeWidget;
30 class QTreeWidgetItem;
31 
32 namespace makVrf
33 {
35 
36  class DT_DLL_VRFGUICOREQT DtImageLayerWidget : public QWidget
37  {
38 
39  Q_OBJECT;
40 
41  public:
43  DtImageLayerWidget(makVrv::DtDe& de, QWidget* parent,
44  Qt::WindowFlags f = Qt::Widget);
45 
47  virtual ~DtImageLayerWidget();
48 
49  virtual void addImageLayer(const std::string&, const std::vector<bool>& enabled, osgEarth::ImageLayer*,
50  int index = -1);
51  virtual void removeImageLayer(osgEarth::ImageLayer*);
52 
53  virtual void addModelLayer(const std::string&, const std::vector<bool>& enabled, osgEarth::ModelLayer*,
54  int index = -1);
55  virtual void removeModelLayer(osgEarth::ModelLayer*);
56 
57  virtual void clearLayers();
58 
59  boost::signal<void (int, bool, int)> signal_imageLayerEnabledChanged;
60  boost::signal<void (int, bool, int)> signal_modelLayerEnabledChanged;
61 
62  protected slots:
63  virtual void itemChanged(QTreeWidgetItem*, int);
64 
65  protected:
68  virtual bool addStealthViewModes(QTreeWidgetItem* parent, const std::vector<bool>& enabled);
69 
70  protected:
72 
73  typedef std::map<osgEarth::ImageLayer*, QTreeWidgetItem*> ImageLayers;
75 
76  typedef std::map<osgEarth::ModelLayer*, QTreeWidgetItem*> ModelLayers;
78 
79  public:
83  };
84 
87  {
88 
89  public:
91  static DtImageLayerWidgetCreator& instance(makVrv::DtDe& de);
92 
94  static void registerInstance(makVrv::DtDe& de,DtImageLayerWidgetCreator* anInstance);
95 
97  virtual DtImageLayerWidget* create(makVrv::DtDe& de, QWidget * parent = NULL,
98  const Qt::WindowFlags& flags = 0);
99  };
100 }

Document ID: Generated on Wed Jul 25 16:57:45 EDT 2018 from SVN revision 190790
Copyright © 2005-2018 VT MÄK. All Rights Reserved (www.mak.com)