// Set the widget area bounds.\r
widgetAreaBounds.set(bgLeftWidth, bgBottomHeight, areaWidth, areaHeight);\r
\r
- maxX = widgetWidth - areaWidth;\r
- maxY = widgetHeight - areaHeight;\r
- amountX = MathUtils.clamp(amountX, 0, maxX);\r
- amountY = MathUtils.clamp(amountY, 0, maxY);\r
-\r
// Make sure widgets are drawn under fading scrollbars.\r
if (fade) {\r
if (scrollX && hScrollKnob != null) areaHeight -= hScrollKnob.getMinHeight();\r
widget.setHeight(widgetHeight);\r
}\r
\r
+ maxX = widgetWidth - areaWidth;\r
+ maxY = widgetHeight - areaHeight;\r
+ amountX = MathUtils.clamp(amountX, 0, maxX);\r
+ amountY = MathUtils.clamp(amountY, 0, maxY);\r
+\r
// Set the bounds and scroll knob sizes if scrollbars are needed.\r
if (scrollX) {\r
if (hScrollKnob != null) {\r