comparison Framework/Widgets/LayerWidget.h @ 273:f21ba2468570 am-2

force all Widgets to have a name to ease debugging
author am@osimis.io
date Fri, 24 Aug 2018 11:26:59 +0200
parents 46c5296d867e
children 3897f9f28cfa
comparison
equal deleted inserted replaced
272:d7d91d96b9d8 273:f21ba2468570
46 std::vector<RenderStyle> styles_; 46 std::vector<RenderStyle> styles_;
47 CoordinateSystem3D slice_; 47 CoordinateSystem3D slice_;
48 std::auto_ptr<Scene> currentScene_; 48 std::auto_ptr<Scene> currentScene_;
49 std::auto_ptr<Scene> pendingScene_; 49 std::auto_ptr<Scene> pendingScene_;
50 std::vector<bool> changedLayers_; 50 std::vector<bool> changedLayers_;
51 std::string name_;
52 51
53 bool LookupLayer(size_t& index /* out */, 52 bool LookupLayer(size_t& index /* out */,
54 const ILayerSource& layer) const; 53 const ILayerSource& layer) const;
55 54
56 void GetLayerExtent(Extent2D& extent, 55 void GetLayerExtent(Extent2D& extent,
93 void InvalidateLayer(size_t layer); 92 void InvalidateLayer(size_t layer);
94 93
95 public: 94 public:
96 virtual ~LayerWidget(); 95 virtual ~LayerWidget();
97 96
98 const std::string& GetName() const {return name_;}
99
100 size_t AddLayer(ILayerSource* layer); // Takes ownership 97 size_t AddLayer(ILayerSource* layer); // Takes ownership
101 98
102 void ReplaceLayer(size_t layerIndex, ILayerSource* layer); // Takes ownership 99 void ReplaceLayer(size_t layerIndex, ILayerSource* layer); // Takes ownership
103 100
104 size_t GetLayerCount() const 101 size_t GetLayerCount() const