Nux

Merge lp:~unity-team/nux/nux.remove-deprecated into lp:nux

Proposed by Eleni Maria Stea
Status: Needs review
Proposed branch: lp:~unity-team/nux/nux.remove-deprecated
Merge into: lp:nux
Diff against target: 1422 lines (+199/-199)
48 files modified
Nux/AbstractCheckedButton.cpp (+8/-8)
Nux/Area.cpp (+1/-1)
Nux/BaseWindow.cpp (+1/-1)
Nux/Button.cpp (+2/-2)
Nux/ColorEditor.cpp (+1/-1)
Nux/FloatingWindow.cpp (+1/-1)
Nux/GridHLayout.cpp (+12/-12)
Nux/GridVLayout.cpp (+6/-6)
Nux/GroupBox.cpp (+6/-6)
Nux/GroupBox2.cpp (+6/-6)
Nux/HLayout.cpp (+10/-10)
Nux/HScrollBar.cpp (+1/-1)
Nux/HSplitter.cpp (+3/-3)
Nux/LayeredLayout.cpp (+5/-5)
Nux/LayeredLayout.h (+4/-4)
Nux/Layout.cpp (+1/-1)
Nux/Layout.h (+4/-4)
Nux/LinearLayout.h (+2/-2)
Nux/MenuBar.cpp (+1/-1)
Nux/MenuPage.cpp (+5/-5)
Nux/NumericValuator.cpp (+1/-1)
Nux/PangoText.cpp (+6/-6)
Nux/ProgramFramework/ProgramTemplate.cpp (+2/-2)
Nux/RGBValuator.cpp (+2/-2)
Nux/RangeValue.cpp (+2/-2)
Nux/RangeValueInteger.cpp (+2/-2)
Nux/ScrollView.cpp (+2/-2)
Nux/StaticText.cpp (+6/-6)
Nux/VLayout.cpp (+10/-10)
Nux/VScrollBar.cpp (+1/-1)
Nux/VSplitter.cpp (+3/-3)
Nux/View.cpp (+7/-7)
examples/cairo.cpp (+1/-1)
examples/canvas.cpp (+3/-3)
examples/checkbox.cpp (+2/-2)
examples/combobox.cpp (+2/-2)
examples/focus.cpp (+43/-43)
examples/gridlayout.cpp (+2/-2)
examples/kinetic_scroll_view.cpp (+2/-2)
examples/pango_combobox.cpp (+2/-2)
examples/pangotextedit.cpp (+2/-2)
examples/scrollview.cpp (+3/-3)
examples/text_entry_focus.cpp (+4/-4)
examples/textedit.cpp (+2/-2)
examples/tiles_view.cpp (+2/-2)
examples/timeline.cpp (+3/-3)
tests/gtest-nux-windowcompositor.cpp (+1/-1)
tests/test-timeline.cpp (+1/-1)
To merge this branch: bzr merge lp:~unity-team/nux/nux.remove-deprecated
Reviewer Review Type Date Requested Status
PS Jenkins bot (community) continuous-integration Needs Fixing
Unity Team Pending
Review via email: mp+129667@code.launchpad.net

Description of the change

replaced depricated enumerations with non deprecated ones

To post a comment you must log in.
690. By Eleni Maria Stea

more replacements

Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :

FAILED: Continuous integration, rev:690
No commit message was specified in the merge proposal. Click on the following link and set the commit message (if you want a jenkins rebuild you need to trigger it yourself):
https://code.launchpad.net/~unity-team/nux/nux.remove-deprecated/+merge/129667/+edit-commit-message

http://jenkins.qa.ubuntu.com/job/nux-ci/8/
Executed test runs:
    FAILURE: http://jenkins.qa.ubuntu.com/job/nux-raring-amd64-ci/8/console
    FAILURE: http://jenkins.qa.ubuntu.com/job/nux-raring-armhf-ci/8/console
    FAILURE: http://jenkins.qa.ubuntu.com/job/nux-raring-i386-ci/8/console

Click here to trigger a rebuild:
http://s-jenkins:8080/job/nux-ci/8/rebuild

review: Needs Fixing (continuous-integration)

Unmerged revisions

690. By Eleni Maria Stea

more replacements

689. By Eleni Maria Stea

removed deprecated enumerations

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'Nux/AbstractCheckedButton.cpp'
2--- Nux/AbstractCheckedButton.cpp 2012-09-26 06:44:12 +0000
3+++ Nux/AbstractCheckedButton.cpp 2012-10-19 12:49:20 +0000
4@@ -48,7 +48,7 @@
5 check_area_->SetMinMaxSize(14, 14);
6
7 hlayout_->SetSpaceBetweenChildren(4);
8- hlayout_->SetContentDistribution(MAJOR_POSITION_LEFT);
9+ hlayout_->SetContentDistribution(MAJOR_POSITION_START);
10 hlayout_->AddView(check_area_, 0, MINOR_POSITION_CENTER, MINOR_SIZE_MATCHCONTENT);
11 hlayout_->AddView(static_text_, 1, MINOR_POSITION_CENTER, MINOR_SIZE_MATCHCONTENT);
12
13@@ -166,29 +166,29 @@
14 // The layout has been resized to tightly pack its content
15 if (new_width > old_width)
16 {
17- size_compliance |= eLargerWidth; // need scrollbar
18+ size_compliance |= SIZE_LARGER_WIDTH; // need scrollbar
19 }
20 else if (new_width < old_width)
21 {
22- size_compliance |= eSmallerWidth;
23+ size_compliance |= SIZE_SMALLER_WIDTH;
24 }
25 else
26 {
27- size_compliance |= eCompliantWidth;
28+ size_compliance |= SIZE_EQUAL_WIDTH;
29 }
30
31 // The layout has been resized to tightly pack its content
32 if (new_height > old_height)
33 {
34- size_compliance |= eLargerHeight; // need scrollbar
35+ size_compliance |= SIZE_LARGER_HEIGHT; // need scrollbar
36 }
37 else if (new_height < old_height)
38 {
39- size_compliance |= eSmallerHeight;
40+ size_compliance |= SIZE_SMALLER_HEIGHT;
41 }
42 else
43 {
44- size_compliance |= eCompliantHeight;
45+ size_compliance |= SIZE_EQUAL_HEIGHT;
46 }
47
48 return size_compliance;
49@@ -196,7 +196,7 @@
50 else
51 {
52 PreLayoutManagement();
53- int ret = PostLayoutManagement(eCompliantHeight | eCompliantWidth);
54+ int ret = PostLayoutManagement(SIZE_EQUAL_HEIGHT | SIZE_EQUAL_WIDTH);
55 return ret;
56 }
57
58
59=== modified file 'Nux/Area.cpp'
60--- Nux/Area.cpp 2012-09-30 23:28:23 +0000
61+++ Nux/Area.cpp 2012-10-19 12:49:20 +0000
62@@ -469,7 +469,7 @@
63
64 long Area::ComputeContentSize()
65 {
66- return (eCompliantWidth | eCompliantHeight);
67+ return (SIZE_EQUAL_WIDTH | SIZE_EQUAL_HEIGHT);
68 }
69
70 void Area::ComputeContentPosition(float /* offsetX */, float /* offsetY */)
71
72=== modified file 'Nux/BaseWindow.cpp'
73--- Nux/BaseWindow.cpp 2012-10-02 07:32:55 +0000
74+++ Nux/BaseWindow.cpp 2012-10-19 12:49:20 +0000
75@@ -228,7 +228,7 @@
76 }
77
78 // A BaseWindow must kill the result of the management and pass it to the parent Layout.
79- return (eCompliantHeight | eCompliantWidth);
80+ return (SIZE_EQUAL_HEIGHT | SIZE_EQUAL_WIDTH);
81 //return result;
82 }
83
84
85=== modified file 'Nux/Button.cpp'
86--- Nux/Button.cpp 2012-09-26 06:44:12 +0000
87+++ Nux/Button.cpp 2012-10-19 12:49:20 +0000
88@@ -303,11 +303,11 @@
89 switch(distribution_)
90 {
91 case START_OF_LAYOUT:
92- layout->SetContentDistribution(MAJOR_POSITION_LEFT);
93+ layout->SetContentDistribution(MAJOR_POSITION_START);
94 break;
95
96 case END_OF_LAYOUT:
97- layout->SetContentDistribution(MAJOR_POSITION_RIGHT);
98+ layout->SetContentDistribution(MAJOR_POSITION_END);
99 break;
100
101 case CENTER_OF_LAYOUT:
102
103=== modified file 'Nux/ColorEditor.cpp'
104--- Nux/ColorEditor.cpp 2012-10-12 03:42:26 +0000
105+++ Nux/ColorEditor.cpp 2012-10-19 12:49:20 +0000
106@@ -228,7 +228,7 @@
107
108 m_hlayout->AddView(picker_area_, 1);
109 m_hlayout->AddLayout(new SpaceLayout(5, 5, 20, 20), 0);
110- m_hlayout->AddView(channel_area_, 0, eAbove, eFull);
111+ m_hlayout->AddView(channel_area_, 0, MINOR_POSITION_START, MINOR_SIZE_FULL);
112 SetCompositionLayout(m_hlayout);
113
114 // RGB
115
116=== modified file 'Nux/FloatingWindow.cpp'
117--- Nux/FloatingWindow.cpp 2012-10-10 22:46:50 +0000
118+++ Nux/FloatingWindow.cpp 2012-10-19 12:49:20 +0000
119@@ -406,7 +406,7 @@
120 GetWindowThread()->ComputeElementLayout(_title_bar_layout);
121
122 // A FloatingWindow must kill the result of the management and pass it to the parent Layout.
123- return (eCompliantHeight | eCompliantWidth);
124+ return (SIZE_EQUAL_HEIGHT | SIZE_EQUAL_WIDTH);
125 //return result;
126 }
127
128
129=== modified file 'Nux/GridHLayout.cpp'
130--- Nux/GridHLayout.cpp 2012-08-02 23:34:48 +0000
131+++ Nux/GridHLayout.cpp 2012-10-19 12:49:20 +0000
132@@ -56,7 +56,7 @@
133
134 // Start packing the elements from the top. Is the layout has more space than the elements can use,
135 // leave that space at the bottom of the GridHLayout.
136- m_ContentStacking = MAJOR_POSITION_LEFT;
137+ m_ContentStacking = MAJOR_POSITION_START;
138
139 SetMinimumSize(32, 32);
140 }
141@@ -171,7 +171,7 @@
142
143 if (_layout_element_list.size() == 0)
144 {
145- return eCompliantHeight | eCompliantWidth;
146+ return SIZE_EQUAL_HEIGHT | SIZE_EQUAL_WIDTH;
147 }
148
149 int num_elements = 0;
150@@ -271,7 +271,7 @@
151 // The layout and its content resized together without trouble.
152 std::cout << "ComputeContentSize: GridHLayout Width compliant = " << m_fittingWidth << std::endl;
153 #endif
154- size_compliance |= eCompliantWidth;
155+ size_compliance |= SIZE_EQUAL_WIDTH;
156 }
157
158 // The layout has been resized to tightly pack its content
159@@ -282,7 +282,7 @@
160 // Or you can say that the layout refuse to be smaller than total HEIGHT of its elements.
161 std::cout << "ComputeContentSize: GridHLayout Height block at " << GetBaseHeight() << std::endl;
162 #endif
163- size_compliance |= eLargerHeight; // need scrollbar
164+ size_compliance |= SIZE_LARGER_HEIGHT; // need scrollbar
165 }
166 else if (GetBaseHeight() < original_height)
167 {
168@@ -290,7 +290,7 @@
169 // The layout is smaller.
170 std::cout << "ComputeContentSize: GridHLayout Height is smaller = " << GetBaseHeight() << std::endl;
171 #endif
172- size_compliance |= eSmallerHeight;
173+ size_compliance |= SIZE_SMALLER_HEIGHT;
174 }
175 else
176 {
177@@ -298,12 +298,12 @@
178 // The layout and its content resized together without trouble.
179 std::cout << "ComputeContentSize: GridHLayout Height compliant = " << GetBaseHeight() << std::endl;
180 #endif
181- size_compliance |= eCompliantHeight;
182+ size_compliance |= SIZE_EQUAL_HEIGHT;
183 }
184
185 // if (GetScaleFactor() == 0)
186 // {
187- // return size_compliance | eForceComply;
188+ // return size_compliance | SIZE_FORCE_COMPLY;
189 // }
190
191 //SetDirty(false);
192@@ -321,7 +321,7 @@
193
194 if (_layout_element_list.size() == 0)
195 {
196- return eCompliantHeight | eCompliantWidth;
197+ return SIZE_EQUAL_HEIGHT | SIZE_EQUAL_WIDTH;
198 }
199
200 int num_elements = 0;
201@@ -418,7 +418,7 @@
202 // Or you can say that the layout refuse to be smaller than total WIDTH of its elements.
203 std::cout << "ComputeContentSize: VLayout Width block at " << GetWidth() << std::endl;
204 #endif
205- size_compliance |= eLargerWidth; // need scrollbar
206+ size_compliance |= SIZE_LARGER_WIDTH; // need scrollbar
207 }
208 else if (GetBaseWidth() < original_width)
209 {
210@@ -426,7 +426,7 @@
211 // The layout is smaller.
212 std::cout << "ComputeContentSize: VLayout Width smaller = " << GetWidth() << std::endl;
213 #endif
214- size_compliance |= eSmallerWidth;
215+ size_compliance |= SIZE_SMALLER_WIDTH;
216 }
217 else
218 {
219@@ -434,7 +434,7 @@
220 // The layout and its content resized together without trouble.
221 std::cout << "ComputeContentSize: VLayout Width compliant = " << GetWidth() << std::endl;
222 #endif
223- size_compliance |= eCompliantWidth;
224+ size_compliance |= SIZE_EQUAL_WIDTH;
225 }
226
227 {
228@@ -442,7 +442,7 @@
229 // The layout and its content resized together without trouble.
230 std::cout << "ComputeContentSize: VLayout Height compliant = " << m_fittingHeight << std::endl;
231 #endif
232- size_compliance |= eCompliantHeight;
233+ size_compliance |= SIZE_EQUAL_HEIGHT;
234 }
235
236 return size_compliance;
237
238=== modified file 'Nux/GridVLayout.cpp'
239--- Nux/GridVLayout.cpp 2012-07-24 05:39:41 +0000
240+++ Nux/GridVLayout.cpp 2012-10-19 12:49:20 +0000
241@@ -52,7 +52,7 @@
242
243 // Start packing the elements from the top. Is the layout has more space than the elements can use,
244 // leave that space at the bottom of the GridVLayout.
245- m_ContentStacking = eStackLeft;
246+ m_ContentStacking = MAJOR_POSITION_START;
247
248 SetMinimumSize(32, 32);
249 }
250@@ -158,7 +158,7 @@
251
252 if (_layout_element_list.size() == 0)
253 {
254- return eCompliantHeight | eCompliantWidth;
255+ return SIZE_EQUAL_HEIGHT | SIZE_EQUAL_WIDTH;
256 }
257
258 int num_elements = 0;
259@@ -254,7 +254,7 @@
260 // Or you can say that the layout refuse to be smaller than total WIDTH of its elements.
261 std::cout << "ComputeContentSize: VLayout Width block at " << GetWidth() << std::endl;
262 #endif
263- size_compliance |= eLargerWidth; // need scrollbar
264+ size_compliance |= SIZE_LARGER_WIDTH; // need scrollbar
265 }
266 else if (GetBaseWidth() + VERROR < original_width)
267 {
268@@ -262,7 +262,7 @@
269 // The layout is smaller.
270 std::cout << "ComputeContentSize: VLayout Width smaller = " << GetWidth() << std::endl;
271 #endif
272- size_compliance |= eSmallerWidth;
273+ size_compliance |= SIZE_SMALLER_WIDTH;
274 }
275 else
276 {
277@@ -270,7 +270,7 @@
278 // The layout and its content resized together without trouble.
279 std::cout << "ComputeContentSize: VLayout Width compliant = " << GetWidth() << std::endl;
280 #endif
281- size_compliance |= eCompliantWidth;
282+ size_compliance |= SIZE_EQUAL_WIDTH;
283 }
284
285 {
286@@ -278,7 +278,7 @@
287 // The layout and its content resized together without trouble.
288 std::cout << "ComputeContentSize: VLayout Height compliant = " << m_fittingHeight << std::endl;
289 #endif
290- size_compliance |= eCompliantHeight;
291+ size_compliance |= SIZE_EQUAL_HEIGHT;
292 }
293
294 return size_compliance;
295
296=== modified file 'Nux/GroupBox.cpp'
297--- Nux/GroupBox.cpp 2012-10-02 07:32:55 +0000
298+++ Nux/GroupBox.cpp 2012-10-19 12:49:20 +0000
299@@ -158,18 +158,18 @@
300 m_CaptionArea.SetBaseXY(base.x + 6, base.y);
301
302 if (old_geo.GetWidth() > base.GetWidth())
303- ret |= eLargerWidth;
304+ ret |= SIZE_LARGER_WIDTH;
305 else if (old_geo.GetWidth() < base.GetWidth())
306- ret |= eSmallerWidth;
307+ ret |= SIZE_SMALLER_WIDTH;
308 else
309- ret |= eCompliantWidth;
310+ ret |= SIZE_EQUAL_WIDTH;
311
312 if (old_geo.GetHeight() > base.GetHeight())
313- ret |= eLargerHeight;
314+ ret |= SIZE_LARGER_HEIGHT;
315 else if (old_geo.GetHeight() < base.GetHeight())
316- ret |= eSmallerHeight;
317+ ret |= SIZE_SMALLER_HEIGHT;
318 else
319- ret |= eCompliantHeight;
320+ ret |= SIZE_EQUAL_HEIGHT;
321
322 return ret;
323 }
324
325=== modified file 'Nux/GroupBox2.cpp'
326--- Nux/GroupBox2.cpp 2012-10-02 07:32:55 +0000
327+++ Nux/GroupBox2.cpp 2012-10-19 12:49:20 +0000
328@@ -165,18 +165,18 @@
329
330
331 if (old_geo.GetWidth() > base.GetWidth())
332- ret |= eLargerWidth;
333+ ret |= SIZE_LARGER_WIDTH;
334 else if (old_geo.GetWidth() < base.GetWidth())
335- ret |= eSmallerWidth;
336+ ret |= SIZE_SMALLER_WIDTH;
337 else
338- ret |= eCompliantWidth;
339+ ret |= SIZE_EQUAL_WIDTH;
340
341 if (old_geo.GetHeight() > base.GetHeight())
342- ret |= eLargerHeight;
343+ ret |= SIZE_LARGER_HEIGHT;
344 else if (old_geo.GetHeight() < base.GetHeight())
345- ret |= eSmallerHeight;
346+ ret |= SIZE_SMALLER_HEIGHT;
347 else
348- ret |= eCompliantHeight;
349+ ret |= SIZE_EQUAL_HEIGHT;
350
351 return ret;
352 }
353
354=== modified file 'Nux/HLayout.cpp'
355--- Nux/HLayout.cpp 2012-10-10 22:46:50 +0000
356+++ Nux/HLayout.cpp 2012-10-19 12:49:20 +0000
357@@ -45,7 +45,7 @@
358
359 // Start packing the elements from the top. Is the layout has more space than the elements can use,
360 // leave that space at the bottom of the HLayout.
361- m_ContentStacking = eStackLeft;
362+ m_ContentStacking = MAJOR_POSITION_START;
363 }
364
365 HLayout::HLayout(std::string name, NUX_FILE_LINE_DECL)
366@@ -61,7 +61,7 @@
367 bottom_padding_ = 10;
368 #endif
369
370- m_ContentStacking = eStackLeft;
371+ m_ContentStacking = MAJOR_POSITION_START;
372 }
373
374 HLayout::~HLayout()
375@@ -149,7 +149,7 @@
376 }
377 break;
378
379- case eStackCenter:
380+ case MAJOR_POSITION_CENTER:
381 {
382 offset_space = (remaining_width - total_used_space) / 2;
383
384@@ -160,7 +160,7 @@
385 }
386 break;
387
388- case eStackExpand:
389+ case MAJOR_POSITION_SPREAD:
390 default:
391 {
392 offset_space = 0;
393@@ -174,7 +174,7 @@
394 {
395 if (_layout_element_list.size() == 0)
396 {
397- return eCompliantHeight | eCompliantWidth;
398+ return SIZE_EQUAL_HEIGHT | SIZE_EQUAL_WIDTH;
399 }
400
401 std::list<Area *>::iterator it;
402@@ -418,7 +418,7 @@
403
404 if ((*it)->IsSpaceLayout() == false)
405 {
406- if ((GetScaleFactor() != 0) && (ret & eSmallerHeight))
407+ if ((GetScaleFactor() != 0) && (ret & SIZE_SMALLER_HEIGHT))
408 {
409 if (m_contentHeight < element_height)
410 {
411@@ -485,7 +485,7 @@
412 // The layout and its content resized together without trouble.
413 std::cout << "ComputeContentSize: HLayout Width compliant = " << m_fittingWidth << std::endl;
414 #endif
415- size_compliance |= eCompliantWidth;
416+ size_compliance |= SIZE_EQUAL_WIDTH;
417 }
418
419 // The layout has been resized to tightly pack its content
420@@ -496,7 +496,7 @@
421 // Or you can say that the layout refuse to be smaller than total HEIGHT of its elements.
422 std::cout << "ComputeContentSize: HLayout Height block at " << GetBaseHeight() << std::endl;
423 #endif
424- size_compliance |= eLargerHeight; // need scrollbar
425+ size_compliance |= SIZE_LARGER_HEIGHT; // need scrollbar
426 }
427 else if (GetBaseHeight() + HERROR < original_height)
428 {
429@@ -504,7 +504,7 @@
430 // The layout is smaller.
431 std::cout << "ComputeContentSize: HLayout Height is smaller = " << GetBaseHeight() << std::endl;
432 #endif
433- size_compliance |= eSmallerHeight;
434+ size_compliance |= SIZE_SMALLER_HEIGHT;
435 }
436 else
437 {
438@@ -512,7 +512,7 @@
439 // The layout and its content resized together without trouble.
440 std::cout << "ComputeContentSize: HLayout Height compliant = " << GetBaseHeight() << std::endl;
441 #endif
442- size_compliance |= eCompliantHeight;
443+ size_compliance |= SIZE_EQUAL_HEIGHT;
444 }
445
446 return size_compliance;
447
448=== modified file 'Nux/HScrollBar.cpp'
449--- Nux/HScrollBar.cpp 2012-09-26 06:44:12 +0000
450+++ Nux/HScrollBar.cpp 2012-10-19 12:49:20 +0000
451@@ -86,7 +86,7 @@
452
453
454 hlayout->AddView(_scroll_left_button, 0, eCenter, eFix);
455- hlayout->AddView(_track, 1, eCenter, eFull);
456+ hlayout->AddView(_track, 1, eCenter, MINOR_SIZE_FULL);
457 hlayout->AddView(_scroll_right_button, 0, eCenter, eFix);
458
459 callback = new TimerFunctor;
460
461=== modified file 'Nux/HSplitter.cpp'
462--- Nux/HSplitter.cpp 2012-10-02 07:32:55 +0000
463+++ Nux/HSplitter.cpp 2012-10-19 12:49:20 +0000
464@@ -262,7 +262,7 @@
465
466 if ((w == 0) || (h == 0))
467 {
468- return eCompliantHeight | eCompliantWidth;
469+ return SIZE_EQUAL_HEIGHT | SIZE_EQUAL_WIDTH;
470 }
471
472 if (num_element < 1)
473@@ -273,7 +273,7 @@
474 m_current_y = y;
475
476 new_addition = false;
477- return eCompliantHeight | eCompliantWidth;
478+ return SIZE_EQUAL_HEIGHT | SIZE_EQUAL_WIDTH;
479 }
480
481 std::vector<Area *>::iterator it;
482@@ -361,7 +361,7 @@
483 m_current_x = x;
484 m_current_y = y;
485
486- return eCompliantHeight | eCompliantWidth;
487+ return SIZE_EQUAL_HEIGHT | SIZE_EQUAL_WIDTH;
488 }
489
490 void HSplitter::ResetSplitConfig()
491
492=== modified file 'Nux/LayeredLayout.cpp'
493--- Nux/LayeredLayout.cpp 2012-09-26 06:44:12 +0000
494+++ Nux/LayeredLayout.cpp 2012-10-19 12:49:20 +0000
495@@ -58,7 +58,7 @@
496 m_input_mode(INPUT_MODE_ACTIVE),
497 m_child_draw_queued(false)
498 {
499- m_ContentStacking = eStackLeft;
500+ m_ContentStacking = MAJOR_POSITION_START;
501 child_queue_draw.connect(sigc::mem_fun(this, &LayeredLayout::ChildQueueDraw));
502 }
503
504@@ -139,14 +139,14 @@
505 SetBaseSize(total_max_width, total_max_height);
506
507 if (base.width < total_max_width)
508- ret |= eLargerWidth;
509+ ret |= SIZE_LARGER_WIDTH;
510 else
511- ret |= eCompliantWidth; // We don't complain about getting more space
512+ ret |= SIZE_EQUAL_WIDTH; // We don't complain about getting more space
513
514 if (base.height < total_max_height)
515- ret |= eLargerHeight;
516+ ret |= SIZE_LARGER_HEIGHT;
517 else
518- ret |= eCompliantHeight; // Don't complain about getting more space
519+ ret |= SIZE_EQUAL_HEIGHT; // Don't complain about getting more space
520
521 return ret;
522 }
523
524=== modified file 'Nux/LayeredLayout.h'
525--- Nux/LayeredLayout.h 2012-04-10 00:58:09 +0000
526+++ Nux/LayeredLayout.h 2012-10-19 12:49:20 +0000
527@@ -210,13 +210,13 @@
528
529 void AddLayout(Layout *layouy,
530 unsigned int stretch_factor = 1,
531- MinorDimensionPosition position = eAbove,
532- MinorDimensionSize extend = eFull,
533+ MinorDimensionPosition position = MINOR_POSITION_START,
534+ MinorDimensionSize extend = MINOR_SIZE_FULL,
535 float percentage = 100.0f);
536 void AddView(Area *view,
537 unsigned int stretch_factor = 1,
538- MinorDimensionPosition positioning = eAbove,
539- MinorDimensionSize extend = eFull,
540+ MinorDimensionPosition positioning = MINOR_POSITION_START,
541+ MinorDimensionSize extend = MINOR_SIZE_FULL,
542 float percentage = 100.0f);
543 void RemoveChildObject(Area *area);
544 void Clear();
545
546=== modified file 'Nux/Layout.cpp'
547--- Nux/Layout.cpp 2012-09-26 06:44:12 +0000
548+++ Nux/Layout.cpp 2012-10-19 12:49:20 +0000
549@@ -40,7 +40,7 @@
550 bottom_padding_ = 0;
551 m_contentWidth = 0;
552 m_contentHeight = 0;
553- m_ContentStacking = eStackExpand;
554+ m_ContentStacking = MAJOR_POSITION_SPREAD;
555 draw_cmd_queued_ = false;
556 child_draw_cmd_queued_ = false;
557
558
559=== modified file 'Nux/Layout.h'
560--- Nux/Layout.h 2012-10-10 22:46:50 +0000
561+++ Nux/Layout.h 2012-10-19 12:49:20 +0000
562@@ -42,7 +42,7 @@
563 Layout(NUX_FILE_LINE_PROTO);
564 virtual ~Layout();
565
566- virtual void AddLayout(Layout *, unsigned int stretchFactor = 1, MinorDimensionPosition = eAbove, MinorDimensionSize extend = eFull, float percentage = 100.0f, LayoutPosition = NUX_LAYOUT_END);
567+ virtual void AddLayout(Layout *, unsigned int stretchFactor = 1, MinorDimensionPosition = MINOR_POSITION_START, MinorDimensionSize extend = MINOR_SIZE_FULL, float percentage = 100.0f, LayoutPosition = NUX_LAYOUT_END);
568
569 //! Add an object to the layout.
570 /*! Add an object to the layout.
571@@ -68,7 +68,7 @@
572 /param percentage Controls the object minor dimension size in percentage of the layout minor dimension size.
573 /param index Controls the object position in the layout.
574 */
575- virtual void AddView(Area *baseobject, unsigned int stretchFactor = 1, MinorDimensionPosition positioning = eAbove, MinorDimensionSize extend = eFull, float percentage = 100.0f, LayoutPosition index = NUX_LAYOUT_END);
576+ virtual void AddView(Area *baseobject, unsigned int stretchFactor = 1, MinorDimensionPosition positioning = MINOR_POSITION_START, MinorDimensionSize extend = MINOR_SIZE_FULL, float percentage = 100.0f, LayoutPosition index = NUX_LAYOUT_END);
577 virtual void AddSpace(unsigned int width, unsigned int stretchFactor = 0, LayoutPosition index = NUX_LAYOUT_END);
578
579 virtual void Clear();
580@@ -331,12 +331,12 @@
581 }
582
583
584- virtual void AddLayout(Layout *, unsigned int /* stretchFactor */ = 1, MinorDimensionPosition /* minor_position */ = eAbove, MinorDimensionSize /* minor_size */ = eFull, float /* percentage */ = 100.0f, LayoutPosition /* index */ = NUX_LAYOUT_END)
585+ virtual void AddLayout(Layout *, unsigned int /* stretchFactor */ = 1, MinorDimensionPosition /* minor_position */ = MINOR_POSITION_START, MinorDimensionSize /* minor_size */ = MINOR_SIZE_FULL, float /* percentage */ = 100.0f, LayoutPosition /* index */ = NUX_LAYOUT_END)
586 {
587 // Do not allow a WidgetLayout to encapsulate an object of type layout
588 }
589
590- virtual void AddView(Area * /* baseobject */, unsigned int /* stretchFactor */ = 1, MinorDimensionPosition /* positioning */ = eAbove, MinorDimensionSize /* extend */ = eFull, float /* percentage */ = 100.0f, LayoutPosition /* index */ = NUX_LAYOUT_END)
591+ virtual void AddView(Area * /* baseobject */, unsigned int /* stretchFactor */ = 1, MinorDimensionPosition /* positioning */ = MINOR_POSITION_START, MinorDimensionSize /* extend */ = MINOR_SIZE_FULL, float /* percentage */ = 100.0f, LayoutPosition /* index */ = NUX_LAYOUT_END)
592 {
593 // the baseObject is provided via the constructor.
594 };
595
596=== modified file 'Nux/LinearLayout.h'
597--- Nux/LinearLayout.h 2011-10-11 13:55:55 +0000
598+++ Nux/LinearLayout.h 2012-10-19 12:49:20 +0000
599@@ -32,7 +32,7 @@
600 {
601 NUX_DECLARE_OBJECT_TYPE(LinearLayout, Layout);
602 public:
603- virtual void AddLayout(Layout *, unsigned int stretchFactor = 1, MinorDimensionPosition = eAbove, MinorDimensionSize extend = eFull, float percentage = 100.0f, LayoutPosition = NUX_LAYOUT_END);
604+ virtual void AddLayout(Layout *, unsigned int stretchFactor = 1, MinorDimensionPosition = MINOR_POSITION_START, MinorDimensionSize extend = MINOR_SIZE_FULL, float percentage = 100.0f, LayoutPosition = NUX_LAYOUT_END);
605
606 //! Add an object to the layout.
607 /*! Add an object to the layout.
608@@ -58,7 +58,7 @@
609 /param percentage Controls the object minor dimension size in percentage of the layout minor dimension size.
610 /param index Controls the object position in the layout.
611 */
612- virtual void AddView(Area *baseobject, unsigned int stretchFactor = 1, MinorDimensionPosition positioning = eAbove, MinorDimensionSize extend = eFull, float percentage = 100.0f, LayoutPosition index = NUX_LAYOUT_END);
613+ virtual void AddView(Area *baseobject, unsigned int stretchFactor = 1, MinorDimensionPosition positioning = MINOR_POSITION_START, MinorDimensionSize extend = MINOR_SIZE_FULL, float percentage = 100.0f, LayoutPosition index = NUX_LAYOUT_END);
614 virtual void AddSpace(unsigned int width, unsigned int stretchFactor = 0, LayoutPosition index = NUX_LAYOUT_END);
615
616
617
618=== modified file 'Nux/MenuBar.cpp'
619--- Nux/MenuBar.cpp 2012-10-02 07:32:55 +0000
620+++ Nux/MenuBar.cpp 2012-10-19 12:49:20 +0000
621@@ -73,7 +73,7 @@
622
623 m_hlayout->SetHorizontalInternalMargin(4);
624 m_hlayout->SetVerticalExternalMargin(0);
625- m_hlayout->SetContentDistribution(eStackLeft);
626+ m_hlayout->SetContentDistribution(MAJOR_POSITION_START);
627 SetCompositionLayout(m_hlayout);
628 }
629
630
631=== modified file 'Nux/MenuPage.cpp'
632--- Nux/MenuPage.cpp 2012-10-10 22:46:50 +0000
633+++ Nux/MenuPage.cpp 2012-10-19 12:49:20 +0000
634@@ -426,7 +426,7 @@
635 }
636
637 m_numItem = (int) m_MenuItemVector.size();
638- _vlayout->AddView(pMenuItem, 0, eLeft, eFix);
639+ _vlayout->AddView(pMenuItem, 0, MINOR_POSITION_START, eFix);
640 ComputeContentSize();
641
642 return pMenuItem->GetActionItem();
643@@ -500,7 +500,7 @@
644 // }
645 //
646 // m_numItem = (int)m_MenuItemVector.size();
647-// _vlayout->AddView(pMenuItem, 0, eLeft, eFix);
648+// _vlayout->AddView(pMenuItem, 0, MINOR_POSITION_START, eFix);
649 // ComputeContentSize();
650 //}
651
652@@ -572,7 +572,7 @@
653 }
654
655 m_numItem = (int) m_MenuItemVector.size();
656- _vlayout->AddView(pMenuItem, 0, eLeft, eFix);
657+ _vlayout->AddView(pMenuItem, 0, MINOR_POSITION_START, eFix);
658 ComputeContentSize();
659
660 return pMenuItem->GetChildMenu();
661@@ -645,7 +645,7 @@
662 }
663
664 m_numItem = (int) m_MenuItemVector.size();
665- _vlayout->AddView(pMenuItem, 0, eLeft, eFix);
666+ _vlayout->AddView(pMenuItem, 0, MINOR_POSITION_START, eFix);
667 ComputeContentSize();
668
669 return pMenuItem->GetActionItem();
670@@ -673,7 +673,7 @@
671 + MENU_ITEM_TEXT_TO_BORDER_MARGIN, 4);
672 }
673
674- _vlayout->AddView(pMenuSeparator, 0, eLeft, eFix);
675+ _vlayout->AddView(pMenuSeparator, 0, MINOR_POSITION_START, eFix);
676 ComputeContentSize();
677 }
678
679
680=== modified file 'Nux/NumericValuator.cpp'
681--- Nux/NumericValuator.cpp 2012-10-10 22:46:50 +0000
682+++ Nux/NumericValuator.cpp 2012-10-19 12:49:20 +0000
683@@ -62,7 +62,7 @@
684 hlayout->AddView(m_SpinnerDownBtn, 0);
685 hlayout->AddView(m_EditLine, 1);
686 hlayout->AddView(m_SpinnerUpBtn, 0);
687- hlayout->SetContentDistribution(eStackLeft);
688+ hlayout->SetContentDistribution(MAJOR_POSITION_START);
689
690 SetCompositionLayout(hlayout);
691 }
692
693=== modified file 'Nux/PangoText.cpp'
694--- Nux/PangoText.cpp 2012-10-10 22:46:50 +0000
695+++ Nux/PangoText.cpp 2012-10-19 12:49:20 +0000
696@@ -68,18 +68,18 @@
697 int h = GetBaseHeight();
698
699 if (_pre_layout_width < w)
700- result |= eLargerWidth;
701+ result |= SIZE_LARGER_WIDTH;
702 else if (_pre_layout_width > w)
703- result |= eSmallerWidth;
704+ result |= SIZE_SMALLER_WIDTH;
705 else
706- result |= eCompliantWidth;
707+ result |= SIZE_EQUAL_WIDTH;
708
709 if (_pre_layout_height < h)
710- result |= eLargerHeight;
711+ result |= SIZE_LARGER_HEIGHT;
712 else if (_pre_layout_height > h)
713- result |= eSmallerHeight;
714+ result |= SIZE_SMALLER_HEIGHT;
715 else
716- result |= eCompliantHeight;
717+ result |= SIZE_EQUAL_HEIGHT;
718
719 return result;
720 }
721
722=== modified file 'Nux/ProgramFramework/ProgramTemplate.cpp'
723--- Nux/ProgramFramework/ProgramTemplate.cpp 2012-09-26 06:44:12 +0000
724+++ Nux/ProgramFramework/ProgramTemplate.cpp 2012-10-19 12:49:20 +0000
725@@ -72,9 +72,9 @@
726 // nux::VLayout *MainVLayout = new nux::VLayout(NUX_TRACKER_LOCATION);
727 // nux::TextEntry *text_entry_0 = new nux::TextEntry(TEXT("0123456789abcdefghij"), NUX_TRACKER_LOCATION);
728
729- // MainVLayout->AddView(text_entry_0, 0, nux::eCenter, nux::eFull);
730+ // MainVLayout->AddView(text_entry_0, 0, nux::eCenter, nux::MINOR_SIZE_FULL);
731 // MainVLayout->SetVerticalInternalMargin(10);
732- // MainVLayout->SetContentDistribution(nux::eStackCenter);
733+ // MainVLayout->SetContentDistribution(nux::MAJOR_POSITION_CENTER);
734
735 // nux::GetWindowThread()->SetLayout(MainVLayout);
736 // nux::ColorLayer background(nux::Color(0xFF4D4D4D));
737
738=== modified file 'Nux/RGBValuator.cpp'
739--- Nux/RGBValuator.cpp 2012-10-10 22:46:50 +0000
740+++ Nux/RGBValuator.cpp 2012-10-19 12:49:20 +0000
741@@ -243,8 +243,8 @@
742
743 // Set layout
744 colormodel_layout->AddView(color_square_, 0, eCenter, eFix);
745- colormodel_layout->AddView(m_ColorModel, 0, eCenter, eFull);
746- colormodel_layout->AddView(m_ColorFormat, 0, eCenter, eFull);
747+ colormodel_layout->AddView(m_ColorModel, 0, eCenter, MINOR_SIZE_FULL);
748+ colormodel_layout->AddView(m_ColorFormat, 0, eCenter, MINOR_SIZE_FULL);
749 colormodel_layout->SetSpaceBetweenChildren(2);
750
751 hlayout->AddView(colormodel_layout, 0, MINOR_POSITION_START, MINOR_SIZE_MATCHCONTENT);
752
753=== modified file 'Nux/RangeValue.cpp'
754--- Nux/RangeValue.cpp 2012-10-10 22:46:50 +0000
755+++ Nux/RangeValue.cpp 2012-10-19 12:49:20 +0000
756@@ -76,8 +76,8 @@
757 // This is use by RangeValuePropertyItem::GetItemBestHeight
758 SetMinimumSize(DEFAULT_WIDGET_WIDTH, PRACTICAL_WIDGET_HEIGHT);
759
760- hlayout->AddView(m_ValueString, 0, eCenter, eFull);
761- hlayout->AddView(m_Percentage, 4, eCenter, eFull);
762+ hlayout->AddView(m_ValueString, 0, eCenter, MINOR_SIZE_FULL);
763+ hlayout->AddView(m_Percentage, 4, eCenter, MINOR_SIZE_FULL);
764 //hlayout->AddLayout(&vlayout, 4);
765 hlayout->SetHorizontalExternalMargin(0);
766 hlayout->SetHorizontalInternalMargin(2);
767
768=== modified file 'Nux/RangeValueInteger.cpp'
769--- Nux/RangeValueInteger.cpp 2012-10-10 22:46:50 +0000
770+++ Nux/RangeValueInteger.cpp 2012-10-19 12:49:20 +0000
771@@ -75,8 +75,8 @@
772 SetMinimumSize(DEFAULT_WIDGET_WIDTH, PRACTICAL_WIDGET_HEIGHT);
773
774
775- hlayout->AddView(m_ValueString, 0, eCenter, eFull);
776- hlayout->AddView(m_Percentage, 4, eCenter, eFull);
777+ hlayout->AddView(m_ValueString, 0, eCenter, MINOR_SIZE_FULL);
778+ hlayout->AddView(m_Percentage, 4, eCenter, MINOR_SIZE_FULL);
779 //hlayout->AddLayout(&vlayout, 4);
780 hlayout->SetHorizontalExternalMargin(0);
781 hlayout->SetHorizontalInternalMargin(2);
782
783=== modified file 'Nux/ScrollView.cpp'
784--- Nux/ScrollView.cpp 2012-10-02 07:32:55 +0000
785+++ Nux/ScrollView.cpp 2012-10-19 12:49:20 +0000
786@@ -503,7 +503,7 @@
787 view_layout_->ComputeContentPosition(0, 0);
788
789 // The ScrollView always returns complient width and height to its parent layout.
790- return (eCompliantHeight | eCompliantWidth);
791+ return (SIZE_EQUAL_HEIGHT | SIZE_EQUAL_WIDTH);
792 }
793
794 long ScrollView::PostLayoutManagement2(long /* LayoutResult */)
795@@ -655,7 +655,7 @@
796 if (view_layout_)
797 view_layout_->ComputeContentPosition(0, 0);
798
799- return (eCompliantHeight | eCompliantWidth);
800+ return (SIZE_EQUAL_HEIGHT | SIZE_EQUAL_WIDTH);
801 }
802
803 // When the ScrollView is in a Layout object, and that layout call View::ComputeContentPosition
804
805=== modified file 'Nux/StaticText.cpp'
806--- Nux/StaticText.cpp 2012-09-26 06:44:12 +0000
807+++ Nux/StaticText.cpp 2012-10-19 12:49:20 +0000
808@@ -166,18 +166,18 @@
809
810 long result = 0;
811 if (pre_layout_width < width)
812- result |= eLargerWidth;
813+ result |= SIZE_LARGER_WIDTH;
814 else if (pre_layout_width > width)
815- result |= eSmallerWidth;
816+ result |= SIZE_SMALLER_WIDTH;
817 else
818- result |= eCompliantWidth;
819+ result |= SIZE_EQUAL_WIDTH;
820
821 if (pre_layout_height < height)
822- result |= eLargerHeight;
823+ result |= SIZE_LARGER_HEIGHT;
824 else if (pre_layout_height > height)
825- result |= eSmallerHeight;
826+ result |= SIZE_SMALLER_HEIGHT;
827 else
828- result |= eCompliantHeight;
829+ result |= SIZE_EQUAL_HEIGHT;
830
831 return result;
832
833
834=== modified file 'Nux/VLayout.cpp'
835--- Nux/VLayout.cpp 2012-10-10 22:46:50 +0000
836+++ Nux/VLayout.cpp 2012-10-19 12:49:20 +0000
837@@ -45,7 +45,7 @@
838
839 // Start packing the elements from the left size. Is the layout has more space than the elements can use,
840 // leave that space on the right side of the VLayout.
841- m_ContentStacking = eStackTop;
842+ m_ContentStacking = MAJOR_POSITION_START;
843
844 }
845
846@@ -62,7 +62,7 @@
847 bottom_padding_ = 10;
848 #endif
849
850- m_ContentStacking = eStackTop;
851+ m_ContentStacking = MAJOR_POSITION_START;
852 }
853
854 VLayout::~VLayout()
855@@ -156,7 +156,7 @@
856 }
857 break;
858
859- case eStackCenter:
860+ case MAJOR_POSITION_CENTER:
861 {
862 offset_space = (remaining_height - total_used_space) / 2;
863
864@@ -167,7 +167,7 @@
865 }
866 break;
867
868- case eStackExpand:
869+ case MAJOR_POSITION_SPREAD:
870 default:
871 {
872 offset_space = 0;
873@@ -181,7 +181,7 @@
874 {
875 if (_layout_element_list.size() == 0)
876 {
877- return eCompliantHeight | eCompliantWidth;
878+ return SIZE_EQUAL_HEIGHT | SIZE_EQUAL_WIDTH;
879 }
880
881 std::list<Area *>::iterator it;
882@@ -424,7 +424,7 @@
883
884 if ((*it)->IsSpaceLayout() == false)
885 {
886- if ((GetScaleFactor() != 0) && (ret & eSmallerWidth))
887+ if ((GetScaleFactor() != 0) && (ret & SIZE_SMALLER_WIDTH))
888 {
889 if (m_contentWidth < element_width)
890 {
891@@ -493,7 +493,7 @@
892 // Or you can say that the layout refuse to be smaller than total WIDTH of its elements.
893 std::cout << "ComputeContentSize: VLayout Width block at " << GetWidth() << std::endl;
894 #endif
895- size_compliance |= eLargerWidth; // need scrollbar
896+ size_compliance |= SIZE_LARGER_WIDTH; // need scrollbar
897 }
898 else if (GetBaseWidth() + VERROR < original_width)
899 {
900@@ -501,7 +501,7 @@
901 // The layout is smaller.
902 std::cout << "ComputeContentSize: VLayout Width smaller = " << GetWidth() << std::endl;
903 #endif
904- size_compliance |= eSmallerWidth;
905+ size_compliance |= SIZE_SMALLER_WIDTH;
906 }
907 else
908 {
909@@ -509,7 +509,7 @@
910 // The layout and its content resized together without trouble.
911 std::cout << "ComputeContentSize: VLayout Width compliant = " << GetWidth() << std::endl;
912 #endif
913- size_compliance |= eCompliantWidth;
914+ size_compliance |= SIZE_EQUAL_WIDTH;
915 }
916
917 {
918@@ -517,7 +517,7 @@
919 // The layout and its content resized together without trouble.
920 std::cout << "ComputeContentSize: VLayout Height compliant = " << m_fittingHeight << std::endl;
921 #endif
922- size_compliance |= eCompliantHeight;
923+ size_compliance |= SIZE_EQUAL_HEIGHT;
924 }
925
926 return size_compliance;
927
928=== modified file 'Nux/VScrollBar.cpp'
929--- Nux/VScrollBar.cpp 2012-09-26 06:44:12 +0000
930+++ Nux/VScrollBar.cpp 2012-10-19 12:49:20 +0000
931@@ -87,7 +87,7 @@
932 _scroll_up_button->SetGeometry(Geometry(0, 0, VSCROLLBAR_WIDTH, VSCROLLBAR_HEIGHT));
933
934 vlayout->AddView(_scroll_up_button, 0, eCenter, eFix);
935- vlayout->AddView(_track, 1, eCenter, eFull);
936+ vlayout->AddView(_track, 1, eCenter, MINOR_SIZE_FULL);
937 vlayout->AddView(_scroll_down_button, 0, eCenter, eFix);
938
939 callback = new TimerFunctor;
940
941=== modified file 'Nux/VSplitter.cpp'
942--- Nux/VSplitter.cpp 2012-10-02 07:32:55 +0000
943+++ Nux/VSplitter.cpp 2012-10-19 12:49:20 +0000
944@@ -258,7 +258,7 @@
945
946 if ((w == 0) || (h == 0))
947 {
948- return eCompliantHeight | eCompliantWidth;
949+ return SIZE_EQUAL_HEIGHT | SIZE_EQUAL_WIDTH;
950 }
951
952 if (num_element < 1)
953@@ -269,7 +269,7 @@
954 m_current_y = y;
955
956 new_addition = false;
957- return eCompliantHeight | eCompliantWidth;
958+ return SIZE_EQUAL_HEIGHT | SIZE_EQUAL_WIDTH;
959 }
960
961 std::vector<Area *>::iterator it;
962@@ -357,7 +357,7 @@
963 m_current_x = x;
964 m_current_y = y;
965
966- return eCompliantHeight | eCompliantWidth;
967+ return SIZE_EQUAL_HEIGHT | SIZE_EQUAL_WIDTH;
968 }
969
970 void VSplitter::ResetSplitConfig()
971
972=== modified file 'Nux/View.cpp'
973--- Nux/View.cpp 2012-10-05 13:27:55 +0000
974+++ Nux/View.cpp 2012-10-19 12:49:20 +0000
975@@ -80,29 +80,29 @@
976 // The layout has been resized to tightly pack its content
977 if (PostWidth > PreWidth)
978 {
979- size_compliance |= eLargerWidth; // need scrollbar
980+ size_compliance |= SIZE_LARGER_WIDTH; // need scrollbar
981 }
982 else if (PostWidth < PreWidth)
983 {
984- size_compliance |= eSmallerWidth;
985+ size_compliance |= SIZE_SMALLER_WIDTH;
986 }
987 else
988 {
989- size_compliance |= eCompliantWidth;
990+ size_compliance |= SIZE_EQUAL_WIDTH;
991 }
992
993 // The layout has been resized to tightly pack its content
994 if (PostHeight > PreHeight)
995 {
996- size_compliance |= eLargerHeight; // need scrollbar
997+ size_compliance |= SIZE_LARGER_HEIGHT; // need scrollbar
998 }
999 else if (PostHeight < PreHeight)
1000 {
1001- size_compliance |= eSmallerHeight;
1002+ size_compliance |= SIZE_SMALLER_HEIGHT;
1003 }
1004 else
1005 {
1006- size_compliance |= eCompliantHeight;
1007+ size_compliance |= SIZE_EQUAL_HEIGHT;
1008 }
1009
1010 return size_compliance;
1011@@ -110,7 +110,7 @@
1012 else
1013 {
1014 PreLayoutManagement();
1015- int ret = PostLayoutManagement(eCompliantHeight | eCompliantWidth);
1016+ int ret = PostLayoutManagement(SIZE_EQUAL_HEIGHT | SIZE_EQUAL_WIDTH);
1017 return ret;
1018 }
1019
1020
1021=== modified file 'examples/cairo.cpp'
1022--- examples/cairo.cpp 2011-01-06 16:23:48 +0000
1023+++ examples/cairo.cpp 2012-10-19 12:49:20 +0000
1024@@ -56,7 +56,7 @@
1025
1026 texture_area->SetMinMaxSize(64, 64);
1027 MainVLayout->AddView(texture_area, 1, nux::eCenter, nux::eFix);
1028- MainVLayout->SetContentDistribution(nux::eStackCenter);
1029+ MainVLayout->SetContentDistribution(nux::MAJOR_POSITION_CENTER);
1030
1031 nux::GetWindowThread ()->SetLayout(MainVLayout);
1032 }
1033
1034=== modified file 'examples/canvas.cpp'
1035--- examples/canvas.cpp 2011-07-15 02:39:12 +0000
1036+++ examples/canvas.cpp 2012-10-19 12:49:20 +0000
1037@@ -169,9 +169,9 @@
1038 FooCanvas* foocanvas = new FooCanvas (NUX_TRACKER_LOCATION);
1039 BarCanvas* barcanvas = new BarCanvas (NUX_TRACKER_LOCATION);
1040
1041- layout->AddView (foocanvas, 1, nux::eCenter, nux::eFull);
1042- layout->AddView (barcanvas, 1, nux::eCenter, nux::eFull);
1043- layout->SetContentDistribution (nux::eStackCenter);
1044+ layout->AddView (foocanvas, 1, nux::eCenter, nux::MINOR_SIZE_FULL);
1045+ layout->AddView (barcanvas, 1, nux::eCenter, nux::MINOR_SIZE_FULL);
1046+ layout->SetContentDistribution (nux::MAJOR_POSITION_CENTER);
1047
1048 nux::GetWindowThread()->SetLayout (layout);
1049 }
1050
1051=== modified file 'examples/checkbox.cpp'
1052--- examples/checkbox.cpp 2011-09-20 06:03:43 +0000
1053+++ examples/checkbox.cpp 2012-10-19 12:49:20 +0000
1054@@ -35,8 +35,8 @@
1055 checkbox->SetMaximumHeight(60);
1056
1057
1058- MainVLayout->AddView(checkbox, 1, nux::eCenter, nux::eFull);
1059- MainVLayout->SetContentDistribution(nux::eStackCenter);
1060+ MainVLayout->AddView(checkbox, 1, nux::eCenter, nux::MINOR_SIZE_FULL);
1061+ MainVLayout->SetContentDistribution(nux::MAJOR_POSITION_CENTER);
1062
1063 nux::GetWindowThread ()->SetLayout(MainVLayout);
1064 nux::ColorLayer background(nux::Color(0xFF4D4D4D));
1065
1066=== modified file 'examples/combobox.cpp'
1067--- examples/combobox.cpp 2011-04-10 13:26:34 +0000
1068+++ examples/combobox.cpp 2012-10-19 12:49:20 +0000
1069@@ -43,8 +43,8 @@
1070 combobox->SetMaximumWidth(150);
1071
1072
1073- MainVLayout->AddView(combobox, 0, nux::eCenter, nux::eFull);
1074- MainVLayout->SetContentDistribution(nux::eStackCenter);
1075+ MainVLayout->AddView(combobox, 0, nux::eCenter, nux::MINOR_SIZE_FULL);
1076+ MainVLayout->SetContentDistribution(nux::MAJOR_POSITION_CENTER);
1077
1078 nux::GetWindowThread ()->SetLayout(MainVLayout);
1079 nux::ColorLayer background(nux::Color(0xFF4D4D4D));
1080
1081=== modified file 'examples/focus.cpp'
1082--- examples/focus.cpp 2011-09-20 06:03:43 +0000
1083+++ examples/focus.cpp 2012-10-19 12:49:20 +0000
1084@@ -98,24 +98,24 @@
1085 layout_scroll_12->SetLayout (layout_scroll_12_content);
1086
1087
1088- layout_scroll_1->AddLayout (layout_scroll_11, 0, nux::MINOR_POSITION_TOP);
1089- layout_scroll_1->AddView (layout_scroll_12, 1, nux::MINOR_POSITION_TOP);
1090+ layout_scroll_1->AddLayout (layout_scroll_11, 0, nux::MINOR_POSITION_START);
1091+ layout_scroll_1->AddView (layout_scroll_12, 1, nux::MINOR_POSITION_START);
1092
1093 nux::VLayout* layout_scroll_2 = new nux::VLayout(NUX_TRACKER_LOCATION);
1094 nux::HLayout* layout_scroll_21 = new nux::HLayout(NUX_TRACKER_LOCATION);
1095 nux::GridHLayout* layout_scroll_22 = new nux::GridHLayout (NUX_TRACKER_LOCATION);
1096
1097- layout_scroll_2->AddLayout (layout_scroll_21, 0, nux::MINOR_POSITION_TOP);
1098- layout_scroll_2->AddLayout (layout_scroll_22, 1, nux::MINOR_POSITION_TOP);
1099+ layout_scroll_2->AddLayout (layout_scroll_21, 0, nux::MINOR_POSITION_START);
1100+ layout_scroll_2->AddLayout (layout_scroll_22, 1, nux::MINOR_POSITION_START);
1101
1102- //layout_scroll_container->AddView (text_entry, 0, nux::MINOR_POSITION_TOP);
1103+ //layout_scroll_container->AddView (text_entry, 0, nux::MINOR_POSITION_START);
1104 layout_scroll_container->AddView (combo, 0, nux::eCenter, nux::eFix);
1105
1106 //layout_scroll->SetLayout (layout_scroll_container);
1107- layout_scroll_container->AddLayout (layout_scroll_1, 1, nux::MINOR_POSITION_TOP);
1108- layout_scroll_container->AddLayout (layout_scroll_2, 1, nux::MINOR_POSITION_TOP);
1109+ layout_scroll_container->AddLayout (layout_scroll_1, 1, nux::MINOR_POSITION_START);
1110+ layout_scroll_container->AddLayout (layout_scroll_2, 1, nux::MINOR_POSITION_START);
1111
1112- content_layout->AddLayout (layout_scroll_container, 1, nux::MINOR_POSITION_TOP);
1113+ content_layout->AddLayout (layout_scroll_container, 1, nux::MINOR_POSITION_START);
1114 layout->AddLayout (layout_left, 0);
1115 layout->AddLayout (content_layout, 1);
1116 layout->AddLayout (layout_right, 0);
1117@@ -130,7 +130,7 @@
1118 // texture_area->SetPaintLayer (&color);
1119 // texture_area->FocusChanged.connect (sigc::ptr_fun (&OnFocusChanged));
1120 //
1121-// layout_top->AddView (texture_area, 1, nux::eLeft, nux::eFull);
1122+// layout_top->AddView (texture_area, 1, nux::MINOR_POSITION_START, nux::MINOR_SIZE_FULL);
1123 // }
1124
1125 for (int i = 0; i < 6; i++)
1126@@ -140,7 +140,7 @@
1127 texture_area->SetPaintLayer (&color);
1128 texture_area->FocusChanged.connect (sigc::ptr_fun (&OnFocusChanged));
1129 //~ //~
1130- layout_scroll_11->AddView (texture_area, 1, nux::eLeft, nux::eFull);
1131+ layout_scroll_11->AddView (texture_area, 1, nux::MINOR_POSITION_START, nux::MINOR_SIZE_FULL);
1132 }
1133
1134 for (int i = 0; i < 128; i++)
1135@@ -150,7 +150,7 @@
1136 texture_area->SetPaintLayer (&color);
1137 texture_area->FocusChanged.connect (sigc::ptr_fun (&OnFocusChanged));
1138 //~ //~
1139- layout_scroll_12_content->AddView (texture_area, 1, nux::eLeft, nux::eFull);
1140+ layout_scroll_12_content->AddView (texture_area, 1, nux::MINOR_POSITION_START, nux::MINOR_SIZE_FULL);
1141 }
1142
1143 for (int i = 0; i < 6; i++)
1144@@ -160,38 +160,38 @@
1145 texture_area->SetPaintLayer (&color);
1146 texture_area->FocusChanged.connect (sigc::ptr_fun (&OnFocusChanged));
1147 //~ //~
1148- layout_scroll_21->AddView (texture_area, 1, nux::eLeft, nux::eFull);
1149- }
1150-
1151- for (int i = 0; i < 16; i++)
1152- {
1153- nux::ColorLayer color (nux::Color (0.2, 0.2, 0.4+ frand ()*0.3, 1.0));
1154- nux::TextureArea* texture_area = new nux::TextureArea ();
1155- texture_area->SetPaintLayer (&color);
1156- texture_area->FocusChanged.connect (sigc::ptr_fun (&OnFocusChanged));
1157- //~ //~
1158- layout_scroll_22->AddView (texture_area, 1, nux::eLeft, nux::eFull);
1159- }
1160-
1161-
1162- for (int i = 0; i < 16; i++)
1163- {
1164- nux::ColorLayer color (nux::Color (0.2, 0.2, 0.4+ frand ()*0.3, 1.0));
1165- nux::TextureArea* texture_area = new nux::TextureArea ();
1166- texture_area->SetPaintLayer (&color);
1167- texture_area->FocusChanged.connect (sigc::ptr_fun (&OnFocusChanged));
1168- //~ //~
1169- layout_left->AddView (texture_area, 1, nux::eLeft, nux::eFull);
1170- }
1171-
1172- for (int i = 0; i < 16; i++)
1173- {
1174- nux::ColorLayer color (nux::Color (0.2, 0.2, 0.4+ frand ()*0.3, 1.0));
1175- nux::TextureArea* texture_area = new nux::TextureArea ();
1176- texture_area->SetPaintLayer (&color);
1177- texture_area->FocusChanged.connect (sigc::ptr_fun (&OnFocusChanged));
1178- //~ //~
1179- layout_right->AddView (texture_area, 1, nux::eLeft, nux::eFull);
1180+ layout_scroll_21->AddView (texture_area, 1, nux::MINOR_POSITION_START, nux::MINOR_SIZE_FULL);
1181+ }
1182+
1183+ for (int i = 0; i < 16; i++)
1184+ {
1185+ nux::ColorLayer color (nux::Color (0.2, 0.2, 0.4+ frand ()*0.3, 1.0));
1186+ nux::TextureArea* texture_area = new nux::TextureArea ();
1187+ texture_area->SetPaintLayer (&color);
1188+ texture_area->FocusChanged.connect (sigc::ptr_fun (&OnFocusChanged));
1189+ //~ //~
1190+ layout_scroll_22->AddView (texture_area, 1, nux::MINOR_POSITION_START, nux::MINOR_SIZE_FULL);
1191+ }
1192+
1193+
1194+ for (int i = 0; i < 16; i++)
1195+ {
1196+ nux::ColorLayer color (nux::Color (0.2, 0.2, 0.4+ frand ()*0.3, 1.0));
1197+ nux::TextureArea* texture_area = new nux::TextureArea ();
1198+ texture_area->SetPaintLayer (&color);
1199+ texture_area->FocusChanged.connect (sigc::ptr_fun (&OnFocusChanged));
1200+ //~ //~
1201+ layout_left->AddView (texture_area, 1, nux::MINOR_POSITION_START, nux::MINOR_SIZE_FULL);
1202+ }
1203+
1204+ for (int i = 0; i < 16; i++)
1205+ {
1206+ nux::ColorLayer color (nux::Color (0.2, 0.2, 0.4+ frand ()*0.3, 1.0));
1207+ nux::TextureArea* texture_area = new nux::TextureArea ();
1208+ texture_area->SetPaintLayer (&color);
1209+ texture_area->FocusChanged.connect (sigc::ptr_fun (&OnFocusChanged));
1210+ //~ //~
1211+ layout_right->AddView (texture_area, 1, nux::MINOR_POSITION_START, nux::MINOR_SIZE_FULL);
1212 }
1213
1214
1215
1216=== modified file 'examples/gridlayout.cpp'
1217--- examples/gridlayout.cpp 2011-05-13 01:36:50 +0000
1218+++ examples/gridlayout.cpp 2012-10-19 12:49:20 +0000
1219@@ -42,7 +42,7 @@
1220 nux::TextureArea* texture_area = new nux::TextureArea ();
1221 texture_area->SetPaintLayer (&color);
1222 texture_area->SetVisible (a % 2);
1223- grid_h_layout->AddView (texture_area, 1, nux::eLeft, nux::eFull);
1224+ grid_h_layout->AddView (texture_area, 1, nux::MINOR_POSITION_START, nux::MINOR_SIZE_FULL);
1225
1226 a++;
1227 }
1228@@ -64,7 +64,7 @@
1229 nux::TextureArea* texture_area = new nux::TextureArea();
1230 texture_area->SetPaintLayer (&color);
1231 texture_area->SetVisible (a % 2);
1232- grid_v_layout->AddView(texture_area, 1, nux::eLeft, nux::eFull);
1233+ grid_v_layout->AddView(texture_area, 1, nux::MINOR_POSITION_START, nux::MINOR_SIZE_FULL);
1234
1235 a++;
1236 }
1237
1238=== modified file 'examples/kinetic_scroll_view.cpp'
1239--- examples/kinetic_scroll_view.cpp 2012-10-04 15:48:14 +0000
1240+++ examples/kinetic_scroll_view.cpp 2012-10-19 12:49:20 +0000
1241@@ -38,7 +38,7 @@
1242 Button *button = new TestButton(buffer, NUX_TRACKER_LOCATION);
1243 button->SetMinimumHeight(50);
1244
1245- layout->AddView(button, 1, eLeft, eFull);
1246+ layout->AddView(button, 1, MINOR_POSITION_START, MINOR_SIZE_FULL);
1247 }
1248
1249 KineticScrollView *kinetic_scroll_view = new KineticScrollView(NUX_TRACKER_LOCATION);
1250@@ -52,7 +52,7 @@
1251 {
1252
1253 HLayout* mainLayout = new HLayout(NUX_TRACKER_LOCATION);
1254- mainLayout->AddView(CreateKineticScrollView(), 1, eCenter, eFull);
1255+ mainLayout->AddView(CreateKineticScrollView(), 1, eCenter, MINOR_SIZE_FULL);
1256
1257 GetWindowThread()->SetLayout(mainLayout);
1258 }
1259
1260=== modified file 'examples/pango_combobox.cpp'
1261--- examples/pango_combobox.cpp 2011-02-28 22:47:25 +0000
1262+++ examples/pango_combobox.cpp 2012-10-19 12:49:20 +0000
1263@@ -43,8 +43,8 @@
1264 combobox->SetMaximumWidth(250);
1265
1266
1267- MainVLayout->AddView(combobox, 0, nux::eCenter, nux::eFull);
1268- MainVLayout->SetContentDistribution(nux::eStackCenter);
1269+ MainVLayout->AddView(combobox, 0, nux::eCenter, nux::MINOR_SIZE_FULL);
1270+ MainVLayout->SetContentDistribution(nux::MAJOR_POSITION_CENTER);
1271
1272 nux::GetWindowThread ()->SetLayout(MainVLayout);
1273 nux::ColorLayer background(nux::Color(0xFF4D4D4D));
1274
1275=== modified file 'examples/pangotextedit.cpp'
1276--- examples/pangotextedit.cpp 2011-03-08 01:47:17 +0000
1277+++ examples/pangotextedit.cpp 2012-10-19 12:49:20 +0000
1278@@ -34,8 +34,8 @@
1279 text_entry->SetMinimumHeight (20);
1280
1281
1282- MainVLayout->AddView(text_entry, 0, nux::eCenter, nux::eFull);
1283- MainVLayout->SetContentDistribution(nux::eStackCenter);
1284+ MainVLayout->AddView(text_entry, 0, nux::eCenter, nux::MINOR_SIZE_FULL);
1285+ MainVLayout->SetContentDistribution(nux::MAJOR_POSITION_CENTER);
1286
1287 nux::GetWindowThread ()->SetLayout(MainVLayout);
1288 nux::ColorLayer background(nux::Color(0xFF4D4D4D));
1289
1290=== modified file 'examples/scrollview.cpp'
1291--- examples/scrollview.cpp 2011-05-13 01:36:50 +0000
1292+++ examples/scrollview.cpp 2012-10-19 12:49:20 +0000
1293@@ -40,7 +40,7 @@
1294 nux::TextureArea* texture_area = new nux::TextureArea ();
1295 texture_area->SetPaintLayer (&color);
1296
1297- grid_h_layout->AddView (texture_area, 1, nux::eLeft, nux::eFull);
1298+ grid_h_layout->AddView (texture_area, 1, nux::MINOR_POSITION_START, nux::MINOR_SIZE_FULL);
1299 }
1300
1301 grid_h_layout->ForceChildrenSize (true);
1302@@ -58,8 +58,8 @@
1303 grid_h_layout->SetStretchFactor(1);
1304 scroll_view->SetLayout(grid_h_layout);
1305
1306- MainVLayout->AddView(scroll_view, 1, nux::eCenter, nux::eFull);
1307- MainVLayout->SetContentDistribution(nux::eStackCenter);
1308+ MainVLayout->AddView(scroll_view, 1, nux::eCenter, nux::MINOR_SIZE_FULL);
1309+ MainVLayout->SetContentDistribution(nux::MAJOR_POSITION_CENTER);
1310
1311 nux::GetWindowThread ()->SetLayout(MainVLayout);
1312 nux::ColorLayer background(nux::Color(0xFF4D4D4D));
1313
1314=== modified file 'examples/text_entry_focus.cpp'
1315--- examples/text_entry_focus.cpp 2012-09-26 06:44:12 +0000
1316+++ examples/text_entry_focus.cpp 2012-10-19 12:49:20 +0000
1317@@ -44,13 +44,13 @@
1318 text_entry_2->SetMaximumWidth(300);
1319 text_entry_2->SetMinimumHeight (20);
1320
1321- MainVLayout->AddView(text_entry_0, 0, nux::eCenter, nux::eFull);
1322- MainVLayout->AddView(text_entry_1, 0, nux::eCenter, nux::eFull);
1323- MainVLayout->AddView(text_entry_2, 0, nux::eCenter, nux::eFull, 1.0, nux::NUX_LAYOUT_BEGIN);
1324+ MainVLayout->AddView(text_entry_0, 0, nux::eCenter, nux::MINOR_SIZE_FULL);
1325+ MainVLayout->AddView(text_entry_1, 0, nux::eCenter, nux::MINOR_SIZE_FULL);
1326+ MainVLayout->AddView(text_entry_2, 0, nux::eCenter, nux::MINOR_SIZE_FULL, 1.0, nux::NUX_LAYOUT_BEGIN);
1327
1328 MainVLayout->SetVerticalInternalMargin(10);
1329
1330- MainVLayout->SetContentDistribution(nux::eStackCenter);
1331+ MainVLayout->SetContentDistribution(nux::MAJOR_POSITION_CENTER);
1332 nux::GetWindowThread ()->SetLayout(MainVLayout);
1333 nux::ColorLayer background(nux::Color(0xFF4D4D4D));
1334 static_cast<nux::WindowThread*>(thread)->SetWindowBackgroundPaintLayer(&background);
1335
1336=== modified file 'examples/textedit.cpp'
1337--- examples/textedit.cpp 2011-01-06 16:23:48 +0000
1338+++ examples/textedit.cpp 2012-10-19 12:49:20 +0000
1339@@ -33,8 +33,8 @@
1340 text_box_edit->SetMaximumWidth(300);
1341
1342
1343- MainVLayout->AddView(text_box_edit, 0, nux::eCenter, nux::eFull);
1344- MainVLayout->SetContentDistribution(nux::eStackCenter);
1345+ MainVLayout->AddView(text_box_edit, 0, nux::eCenter, nux::MINOR_SIZE_FULL);
1346+ MainVLayout->SetContentDistribution(nux::MAJOR_POSITION_CENTER);
1347
1348 nux::GetWindowThread ()->SetLayout(MainVLayout);
1349 nux::ColorLayer background(nux::Color(0xFF4D4D4D));
1350
1351=== modified file 'examples/tiles_view.cpp'
1352--- examples/tiles_view.cpp 2011-08-19 03:58:54 +0000
1353+++ examples/tiles_view.cpp 2012-10-19 12:49:20 +0000
1354@@ -150,7 +150,7 @@
1355 if (tile == NULL)
1356 return;
1357
1358- grid_layout_->AddView(tile, 1, nux::eLeft, nux::eFull);
1359+ grid_layout_->AddView(tile, 1, nux::MINOR_POSITION_START, nux::MINOR_SIZE_FULL);
1360 }
1361
1362 nux::Area* TilesView::FindAreaUnderMouse(const nux::Point& mouse_position, nux::NuxEventType event_type)
1363@@ -387,7 +387,7 @@
1364 }
1365
1366 MainVLayout->AddView(tile_manager->GetTilesView(), 1, nux::eCenter, nux::MINOR_SIZE_FULL);
1367- MainVLayout->SetContentDistribution(nux::eStackCenter);
1368+ MainVLayout->SetContentDistribution(nux::MAJOR_POSITION_CENTER);
1369
1370 nux::GetWindowThread ()->SetLayout(MainVLayout);
1371 nux::ColorLayer background(nux::Color(0xFF4D4D4D));
1372
1373=== modified file 'examples/timeline.cpp'
1374--- examples/timeline.cpp 2011-01-06 16:23:48 +0000
1375+++ examples/timeline.cpp 2012-10-19 12:49:20 +0000
1376@@ -34,10 +34,10 @@
1377 {
1378 texture_area = new nux::TextureArea ();
1379
1380- layout->AddView(texture_area, 1, nux::eCenter, nux::eFull);
1381+ layout->AddView(texture_area, 1, nux::eCenter, nux::MINOR_SIZE_FULL);
1382
1383 texture_area_2 = new nux::TextureArea ();
1384- layout->AddView (texture_area_2, 1, nux::eCenter, nux::eFull);
1385+ layout->AddView (texture_area_2, 1, nux::eCenter, nux::MINOR_SIZE_FULL);
1386
1387 timeline_1 = new nux::TimelineEaseInOutQuad (1000, "Timeline_1", NUX_TRACKER_LOCATION);
1388 timeline_1->Looping = true;
1389@@ -56,7 +56,7 @@
1390 nux::VLayout* MainVLayout = new nux::VLayout("", NUX_TRACKER_LOCATION);
1391
1392 self->Init (MainVLayout);
1393- MainVLayout->SetContentDistribution(nux::eStackCenter);
1394+ MainVLayout->SetContentDistribution(nux::MAJOR_POSITION_CENTER);
1395
1396 nux::GetWindowThread ()->SetLayout(MainVLayout);
1397 nux::ColorLayer background(nux::Color(0xFF4D4D4D));
1398
1399=== modified file 'tests/gtest-nux-windowcompositor.cpp'
1400--- tests/gtest-nux-windowcompositor.cpp 2012-09-26 16:09:07 +0000
1401+++ tests/gtest-nux-windowcompositor.cpp 2012-10-19 12:49:20 +0000
1402@@ -748,7 +748,7 @@
1403 tracked_area->SetMinimumSize(100, 1000);
1404
1405 nux::VLayout *layout = new VLayout(NUX_TRACKER_LOCATION);
1406- layout->AddView(tracked_area, 1, eLeft, eFull);
1407+ layout->AddView(tracked_area, 1, MINOR_POSITION_START, MINOR_SIZE_FULL);
1408 layout->Set2DTranslation(0, -123, 0); // x, y, z
1409
1410 TrackerWindow *tracker_window = new TrackerWindow;
1411
1412=== modified file 'tests/test-timeline.cpp'
1413--- tests/test-timeline.cpp 2012-09-26 00:43:42 +0000
1414+++ tests/test-timeline.cpp 2012-10-19 12:49:20 +0000
1415@@ -67,7 +67,7 @@
1416 {
1417 TimelineTestClass *self = (TimelineTestClass*) InitData;
1418 nux::VLayout* MainVLayout = new nux::VLayout(TEXT(""), NUX_TRACKER_LOCATION);
1419- MainVLayout->SetContentDistribution(nux::eStackCenter);
1420+ MainVLayout->SetContentDistribution(nux::MAJOR_POSITION_CENTER);
1421
1422 self->Init (MainVLayout);
1423

Subscribers

People subscribed via source and target branches