summaryrefslogtreecommitdiff
path: root/indra/newview/llpanelgroup.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llpanelgroup.cpp')
-rw-r--r--indra/newview/llpanelgroup.cpp24
1 files changed, 21 insertions, 3 deletions
diff --git a/indra/newview/llpanelgroup.cpp b/indra/newview/llpanelgroup.cpp
index acad897fa4..e2281743c9 100644
--- a/indra/newview/llpanelgroup.cpp
+++ b/indra/newview/llpanelgroup.cpp
@@ -211,9 +211,19 @@ void LLPanelGroup::reposButton(const std::string& name)
button->setRect(btn_rect);
}
-void LLPanelGroup::reshape(S32 width, S32 height, BOOL called_from_parent )
+void LLPanelGroup::reposButtons()
{
- LLPanel::reshape(width, height, called_from_parent );
+ LLButton* button_refresh = findChild<LLButton>("btn_refresh");
+ LLButton* button_cancel = findChild<LLButton>("btn_cancel");
+
+ if(button_refresh && button_cancel && button_refresh->getVisible() && button_cancel->getVisible())
+ {
+ LLRect btn_refresh_rect = button_refresh->getRect();
+ LLRect btn_cancel_rect = button_cancel->getRect();
+ btn_refresh_rect.setLeftTopAndSize( btn_cancel_rect.mLeft + btn_cancel_rect.getWidth() + 2,
+ btn_refresh_rect.getHeight() + 2, btn_refresh_rect.getWidth(), btn_refresh_rect.getHeight());
+ button_refresh->setRect(btn_refresh_rect);
+ }
reposButton("btn_apply");
reposButton("btn_create");
@@ -221,6 +231,13 @@ void LLPanelGroup::reshape(S32 width, S32 height, BOOL called_from_parent )
reposButton("btn_cancel");
}
+void LLPanelGroup::reshape(S32 width, S32 height, BOOL called_from_parent )
+{
+ LLPanel::reshape(width, height, called_from_parent );
+
+ reposButtons();
+}
+
void LLPanelGroup::onBackBtnClick()
{
LLSideTrayPanelContainer* parent = dynamic_cast<LLSideTrayPanelContainer*>(getParent());
@@ -411,7 +428,6 @@ void LLPanelGroup::setGroupID(const LLUUID& group_id)
getChild<LLUICtrl>("group_name")->setVisible(false);
getChild<LLUICtrl>("group_name_editor")->setVisible(true);
-
}
else
{
@@ -431,6 +447,8 @@ void LLPanelGroup::setGroupID(const LLUUID& group_id)
getChild<LLUICtrl>("group_name")->setVisible(true);
getChild<LLUICtrl>("group_name_editor")->setVisible(false);
}
+
+ reposButtons();
}
bool LLPanelGroup::apply(LLPanelGroupTab* tab)