~ubuntu-branches/ubuntu/vivid/mygui/vivid

« back to all changes in this revision

Viewing changes to MyGUIEngine/include/MyGUI_LayerItem.h

  • Committer: Package Import Robot
  • Author(s): Scott Howard, Bret Curtis, Scott Howard
  • Date: 2014-09-18 17:57:48 UTC
  • mfrom: (1.1.1)
  • Revision ID: package-import@ubuntu.com-20140918175748-dd8va78mvpw1jbes
Tags: 3.2.1-1
[ Bret Curtis ]
* Updated license for majority of files from LGPL to Expat (MIT)

[ Scott Howard ]
* New upstream release
* Updated patch to add build option for system GLEW libraries
* All patches accepted upstream except shared_libraries.patch
* Bumped SONAME due to dropped symbols, updated *.symbols and package
  names
* Updated license of debian/* to Expat with permission of all authors
* Don't install Doxygen autogenerated md5 and map files (thanks
  lintian)

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/*!
2
 
        @file
3
 
        @author         Albert Semenov
4
 
        @date           02/2008
5
 
*/
6
 
/*
7
 
        This file is part of MyGUI.
8
 
 
9
 
        MyGUI is free software: you can redistribute it and/or modify
10
 
        it under the terms of the GNU Lesser General Public License as published by
11
 
        the Free Software Foundation, either version 3 of the License, or
12
 
        (at your option) any later version.
13
 
 
14
 
        MyGUI is distributed in the hope that it will be useful,
15
 
        but WITHOUT ANY WARRANTY; without even the implied warranty of
16
 
        MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
17
 
        GNU Lesser General Public License for more details.
18
 
 
19
 
        You should have received a copy of the GNU Lesser General Public License
20
 
        along with MyGUI.  If not, see <http://www.gnu.org/licenses/>.
21
 
*/
22
 
#ifndef __MYGUI_LAYER_ITEM_H__
23
 
#define __MYGUI_LAYER_ITEM_H__
24
 
 
25
 
#include "MyGUI_Prerequest.h"
26
 
#include "MyGUI_LayerManager.h"
27
 
#include "MyGUI_ILayer.h"
28
 
#include "MyGUI_ILayerNode.h"
29
 
#include "MyGUI_ILayerItem.h"
30
 
#include "MyGUI_ISubWidget.h"
31
 
 
32
 
namespace MyGUI
33
 
{
34
 
 
35
 
        class MYGUI_EXPORT LayerItem :
36
 
                public ILayerItem
37
 
        {
38
 
        public:
39
 
                LayerItem();
40
 
                virtual ~LayerItem();
41
 
 
42
 
                ILayer* getLayer() const;
43
 
 
44
 
                virtual void attachItemToNode(ILayer* _layer, ILayerNode* _node);
45
 
                virtual void detachFromLayer();
46
 
                virtual void upLayerItem();
47
 
 
48
 
                void setRenderItemTexture(ITexture* _texture);
49
 
 
50
 
                void addChildItem(LayerItem* _item);
51
 
                void removeChildItem(LayerItem* _item);
52
 
 
53
 
                void addChildNode(LayerItem* _item);
54
 
                void removeChildNode(LayerItem* _item);
55
 
 
56
 
                void addRenderItem(ISubWidget* _item);
57
 
                void removeAllRenderItems();
58
 
 
59
 
                void saveLayerItem();
60
 
                void restoreLayerItem();
61
 
 
62
 
        protected:
63
 
                void attachToLayerItemNode(ILayerNode* _node, bool _deep);
64
 
                void detachFromLayerItemNode(bool _deep);
65
 
 
66
 
        private:
67
 
                // актуально для рутового виджета
68
 
                ILayer* mLayer;
69
 
                // конкретный айтем находящийся в слое
70
 
                ILayerNode* mLayerNode;
71
 
                ILayerNode* mSaveLayerNode;
72
 
 
73
 
                typedef std::vector<LayerItem*> VectorLayerItem;
74
 
                // список наших детей айтемов
75
 
                VectorLayerItem mLayerItems;
76
 
                // список наших узлов
77
 
                VectorLayerItem mLayerNodes;
78
 
 
79
 
                // вектор всех детей сабскинов
80
 
                VectorSubWidget mDrawItems;
81
 
 
82
 
                ITexture* mTexture;
83
 
        };
84
 
 
85
 
} // namespace MyGUI
86
 
 
87
 
#endif // __MYGUI_LAYER_ITEM_H__
 
1
/*
 
2
 * This source file is part of MyGUI. For the latest info, see http://mygui.info/
 
3
 * Distributed under the MIT License
 
4
 * (See accompanying file COPYING.MIT or copy at http://opensource.org/licenses/MIT)
 
5
 */
 
6
 
 
7
#ifndef __MYGUI_LAYER_ITEM_H__
 
8
#define __MYGUI_LAYER_ITEM_H__
 
9
 
 
10
#include "MyGUI_Prerequest.h"
 
11
#include "MyGUI_LayerManager.h"
 
12
#include "MyGUI_ILayer.h"
 
13
#include "MyGUI_ILayerNode.h"
 
14
#include "MyGUI_ILayerItem.h"
 
15
#include "MyGUI_ISubWidget.h"
 
16
 
 
17
namespace MyGUI
 
18
{
 
19
 
 
20
        class MYGUI_EXPORT LayerItem :
 
21
                public ILayerItem
 
22
        {
 
23
        public:
 
24
                LayerItem();
 
25
                virtual ~LayerItem();
 
26
 
 
27
                ILayer* getLayer() const;
 
28
                ILayerNode* getLayerNode() const;
 
29
 
 
30
                virtual void attachItemToNode(ILayer* _layer, ILayerNode* _node);
 
31
                virtual void detachFromLayer();
 
32
                virtual void upLayerItem();
 
33
 
 
34
                void setRenderItemTexture(ITexture* _texture);
 
35
 
 
36
                void addChildItem(LayerItem* _item);
 
37
                void removeChildItem(LayerItem* _item);
 
38
 
 
39
                void addChildNode(LayerItem* _item);
 
40
                void removeChildNode(LayerItem* _item);
 
41
 
 
42
                void addRenderItem(ISubWidget* _item);
 
43
                void removeAllRenderItems();
 
44
 
 
45
                void saveLayerItem();
 
46
                void restoreLayerItem();
 
47
 
 
48
        protected:
 
49
                void attachToLayerItemNode(ILayerNode* _node, bool _deep);
 
50
                void detachFromLayerItemNode(bool _deep);
 
51
 
 
52
        private:
 
53
                // актуально для рутового виджета
 
54
                ILayer* mLayer;
 
55
                // конкретный айтем находящийся в слое
 
56
                ILayerNode* mLayerNode;
 
57
                ILayerNode* mSaveLayerNode;
 
58
 
 
59
                typedef std::vector<LayerItem*> VectorLayerItem;
 
60
                // список наших детей айтемов
 
61
                VectorLayerItem mLayerItems;
 
62
                // список наших узлов
 
63
                VectorLayerItem mLayerNodes;
 
64
 
 
65
                // вектор всех детей сабскинов
 
66
                VectorSubWidget mDrawItems;
 
67
 
 
68
                ITexture* mTexture;
 
69
        };
 
70
 
 
71
} // namespace MyGUI
 
72
 
 
73
#endif // __MYGUI_LAYER_ITEM_H__