50 #ifndef _LAYOUTREGION_H_
51 #define _LAYOUTREGION_H_
53 #include "../Entity.h"
54 using namespace ::br::pucrio::telemidia::ncl;
56 #include "util/functions.h"
57 #include "util/Color.h"
58 using namespace ::br::pucrio::telemidia::util;
76 string outputMapRegionId;
86 bool bottomPercentual;
90 bool heightPercentual;
93 map<string, LayoutRegion*> regions;
94 vector<LayoutRegion*> sorted;
100 pthread_mutex_t mutex;
105 virtual void setOutputMapRegion(
LayoutRegion* outMapRegion);
107 virtual string getOutputMapRegionId();
108 virtual void setDeviceClass(
int deviceClass,
string mapId);
109 virtual int getDeviceClass();
115 virtual int compareWidthSize(
string w);
116 virtual int compareHeightSize(
string h);
117 virtual double getBottom();
118 virtual double getHeight();
119 virtual double getLeft();
120 virtual double getRight();
123 void printRegionIdsRecursively();
124 virtual vector<LayoutRegion*>* getRegions();
125 virtual string getTitle();
126 virtual double getTop();
127 virtual double getWidth();
128 virtual int getZIndex();
129 virtual int getZIndexValue();
130 virtual bool isBottomPercentual();
131 virtual bool isHeightPercentual();
132 virtual bool isLeftPercentual();
133 virtual bool isRightPercentual();
134 virtual bool isTopPercentual();
135 virtual bool isWidthPercentual();
136 virtual string toString();
142 virtual void removeRegions();
146 virtual double getDeviceWidthInPixels();
147 virtual double getDeviceHeightInPixels();
150 virtual bool setBottom(
double newBottom,
bool isPercentual);
151 virtual bool setTargetBottom(
double newBottom,
bool isPercentual);
152 virtual bool setHeight(
double newHeight,
bool isPercentual);
153 virtual bool setTargetHeight(
double newHeight,
bool isPercentual);
154 virtual bool setLeft(
double newLeft,
bool isPercentual);
155 virtual bool setTargetLeft(
double newLeft,
bool isPercentual);
156 virtual bool setRight(
double newRight,
bool isPercentual);
157 virtual bool setTargetRight(
double newRight,
bool isPercentual);
158 virtual bool setTop(
double newTop,
bool isPercentual);
159 virtual bool setTargetTop(
double newTop,
bool isPercentual);
160 virtual bool setWidth(
double newWidth,
bool isPercentual);
161 virtual bool setTargetWidth(
double newWidth,
bool isPercentual);
163 virtual void validateTarget();
165 virtual void setTitle(
string newTitle);
166 virtual void setZIndex(
int newZIndex);
167 virtual vector<LayoutRegion*>* getRegionsSortedByZIndex();
168 virtual vector<LayoutRegion*>* getRegionsOverRegion(
173 virtual void refreshDeviceClassRegions();
174 virtual int getTopInPixels();
175 virtual int getBottomInPixels();
176 virtual int getRightInPixels();
177 virtual int getLeftInPixels();
178 virtual int getHeightInPixels();
179 virtual int getWidthInPixels();
180 virtual bool isMovable();
181 virtual bool isResizable();
182 virtual bool isDecorated();
183 virtual void setMovable(
bool movable);
184 virtual void setResizable(
bool resizable);
185 virtual void setDecorated(
bool decorated);
186 virtual void resetTop();
187 virtual void resetBottom();
188 virtual void resetRight();
189 virtual void resetLeft();
190 virtual void resetHeight();
191 virtual void resetWidth();
192 virtual void resetZIndex();
193 virtual void resetDecorated();
194 virtual void resetMovable();
195 virtual void resetResizable();
196 virtual int getAbsoluteLeft();
197 virtual int getAbsoluteTop();
199 virtual bool intersects(
int x,
int y);
202 double getPercentualValue(
string value);
203 bool isPercentualValue(
string value);
213 #endif //_LAYOUTREGION_H_
Definition: LayoutRegion.h:73