diff options
-rw-r--r-- | indra/newview/llfloatergesture.cpp | 2 | ||||
-rw-r--r-- | indra/newview/llgrouplist.cpp | 33 | ||||
-rw-r--r-- | indra/newview/llgrouplist.h | 5 | ||||
-rw-r--r-- | indra/newview/skins/default/textures/icons/Profile_Search_Visibility_Dark.png | bin | 368 -> 0 bytes | |||
-rw-r--r-- | indra/newview/skins/default/textures/icons/Profile_Search_Visibility_Light.png | bin | 366 -> 0 bytes | |||
-rw-r--r-- | indra/newview/skins/default/textures/icons/profile_group_visibility_eye_off.png | bin | 0 -> 507 bytes | |||
-rw-r--r-- | indra/newview/skins/default/textures/icons/profile_group_visibility_eye_off_pressed.png | bin | 0 -> 639 bytes | |||
-rw-r--r-- | indra/newview/skins/default/textures/icons/profile_group_visibility_eye_on.png | bin | 0 -> 485 bytes | |||
-rw-r--r-- | indra/newview/skins/default/textures/icons/profile_group_visibility_eye_on_pressed.png | bin | 0 -> 609 bytes | |||
-rw-r--r-- | indra/newview/skins/default/textures/textures.xml | 6 | ||||
-rw-r--r-- | indra/newview/skins/default/xui/en/menu_gesture_gear.xml | 2 | ||||
-rw-r--r-- | indra/newview/skins/default/xui/en/panel_group_list_item_short.xml | 27 |
12 files changed, 52 insertions, 23 deletions
diff --git a/indra/newview/llfloatergesture.cpp b/indra/newview/llfloatergesture.cpp index 6e326ff3cf..d17889bed1 100644 --- a/indra/newview/llfloatergesture.cpp +++ b/indra/newview/llfloatergesture.cpp @@ -122,7 +122,7 @@ LLFloaterGesture::LLFloaterGesture(const LLSD& key) mObserver = new LLFloaterGestureObserver(this); LLGestureMgr::instance().addObserver(mObserver); - mCommitCallbackRegistrar.add("Gesture.Action.ToogleActiveState", boost::bind(&LLFloaterGesture::onActivateBtnClick, this)); + mCommitCallbackRegistrar.add("Gesture.Action.ToggleActiveState", boost::bind(&LLFloaterGesture::onActivateBtnClick, this)); mCommitCallbackRegistrar.add("Gesture.Action.ShowPreview", boost::bind(&LLFloaterGesture::onClickEdit, this)); mCommitCallbackRegistrar.add("Gesture.Action.CopyPaste", boost::bind(&LLFloaterGesture::onCopyPasteAction, this, _2)); mCommitCallbackRegistrar.add("Gesture.Action.SaveToCOF", boost::bind(&LLFloaterGesture::addToCurrentOutFit, this)); diff --git a/indra/newview/llgrouplist.cpp b/indra/newview/llgrouplist.cpp index 9c1c32d573..38c0b64e0a 100644 --- a/indra/newview/llgrouplist.cpp +++ b/indra/newview/llgrouplist.cpp @@ -401,7 +401,8 @@ mGroupIcon(NULL), mGroupNameBox(NULL), mInfoBtn(NULL), mProfileBtn(NULL), -mVisibilityBtn(NULL), +mVisibilityHideBtn(NULL), +mVisibilityShowBtn(NULL), mGroupID(LLUUID::null), mForAgent(for_agent) { @@ -439,10 +440,15 @@ BOOL LLGroupListItem::postBuild() mProfileBtn = getChild<LLButton>("profile_btn"); mProfileBtn->setClickedCallback([this](LLUICtrl *, const LLSD &) { onProfileBtnClick(); }); - mVisibilityBtn = findChild<LLButton>("visibility_btn"); - if (mVisibilityBtn) + mVisibilityHideBtn = findChild<LLButton>("visibility_hide_btn"); + if (mVisibilityHideBtn) { - mVisibilityBtn->setClickedCallback([this](LLUICtrl *, const LLSD &) { onVisibilityBtnClick(); }); + mVisibilityHideBtn->setClickedCallback([this](LLUICtrl *, const LLSD &) { onVisibilityBtnClick(false); }); + } + mVisibilityShowBtn = findChild<LLButton>("visibility_show_btn"); + if (mVisibilityShowBtn) + { + mVisibilityShowBtn->setClickedCallback([this](LLUICtrl *, const LLSD &) { onVisibilityBtnClick(true); }); } return TRUE; @@ -463,9 +469,14 @@ void LLGroupListItem::onMouseEnter(S32 x, S32 y, MASK mask) { mInfoBtn->setVisible(true); mProfileBtn->setVisible(true); - if (mForAgent && mVisibilityBtn) + if (mForAgent && mVisibilityHideBtn) { - mVisibilityBtn->setVisible(true); + LLGroupData agent_gdatap; + if (gAgent.getGroupData(mGroupID, agent_gdatap)) + { + mVisibilityHideBtn->setVisible(agent_gdatap.mListInProfile); + mVisibilityShowBtn->setVisible(!agent_gdatap.mListInProfile); + } } } @@ -477,9 +488,10 @@ void LLGroupListItem::onMouseLeave(S32 x, S32 y, MASK mask) getChildView("hovered_icon")->setVisible( false); mInfoBtn->setVisible(false); mProfileBtn->setVisible(false); - if (mVisibilityBtn) + if (mVisibilityHideBtn) { - mVisibilityBtn->setVisible(false); + mVisibilityHideBtn->setVisible(false); + mVisibilityShowBtn->setVisible(false); } LLPanel::onMouseLeave(x, y, mask); @@ -570,14 +582,15 @@ void LLGroupListItem::onProfileBtnClick() LLGroupActions::show(mGroupID); } -void LLGroupListItem::onVisibilityBtnClick() +void LLGroupListItem::onVisibilityBtnClick(bool new_visibility) { LLGroupData agent_gdatap; if (gAgent.getGroupData(mGroupID, agent_gdatap)) { - bool new_visibility = !agent_gdatap.mListInProfile; gAgent.setUserGroupFlags(mGroupID, agent_gdatap.mAcceptNotices, new_visibility); setVisibleInProfile(new_visibility); + mVisibilityHideBtn->setVisible(new_visibility); + mVisibilityShowBtn->setVisible(!new_visibility); } } diff --git a/indra/newview/llgrouplist.h b/indra/newview/llgrouplist.h index 5d4bb7bed2..bab9127e10 100644 --- a/indra/newview/llgrouplist.h +++ b/indra/newview/llgrouplist.h @@ -123,14 +123,15 @@ private: void setBold(bool bold); void onInfoBtnClick(); void onProfileBtnClick(); - void onVisibilityBtnClick(); + void onVisibilityBtnClick(bool new_visibility); LLTextBox* mGroupNameBox; LLUUID mGroupID; LLGroupIconCtrl* mGroupIcon; LLButton* mInfoBtn; LLButton* mProfileBtn; - LLButton* mVisibilityBtn; + LLButton* mVisibilityHideBtn; + LLButton* mVisibilityShowBtn; std::string mGroupName; bool mForAgent; diff --git a/indra/newview/skins/default/textures/icons/Profile_Search_Visibility_Dark.png b/indra/newview/skins/default/textures/icons/Profile_Search_Visibility_Dark.png Binary files differdeleted file mode 100644 index 09e627861c..0000000000 --- a/indra/newview/skins/default/textures/icons/Profile_Search_Visibility_Dark.png +++ /dev/null diff --git a/indra/newview/skins/default/textures/icons/Profile_Search_Visibility_Light.png b/indra/newview/skins/default/textures/icons/Profile_Search_Visibility_Light.png Binary files differdeleted file mode 100644 index 1a5aa63727..0000000000 --- a/indra/newview/skins/default/textures/icons/Profile_Search_Visibility_Light.png +++ /dev/null diff --git a/indra/newview/skins/default/textures/icons/profile_group_visibility_eye_off.png b/indra/newview/skins/default/textures/icons/profile_group_visibility_eye_off.png Binary files differnew file mode 100644 index 0000000000..3a2ed399b2 --- /dev/null +++ b/indra/newview/skins/default/textures/icons/profile_group_visibility_eye_off.png diff --git a/indra/newview/skins/default/textures/icons/profile_group_visibility_eye_off_pressed.png b/indra/newview/skins/default/textures/icons/profile_group_visibility_eye_off_pressed.png Binary files differnew file mode 100644 index 0000000000..789f59a491 --- /dev/null +++ b/indra/newview/skins/default/textures/icons/profile_group_visibility_eye_off_pressed.png diff --git a/indra/newview/skins/default/textures/icons/profile_group_visibility_eye_on.png b/indra/newview/skins/default/textures/icons/profile_group_visibility_eye_on.png Binary files differnew file mode 100644 index 0000000000..4fb56c389c --- /dev/null +++ b/indra/newview/skins/default/textures/icons/profile_group_visibility_eye_on.png diff --git a/indra/newview/skins/default/textures/icons/profile_group_visibility_eye_on_pressed.png b/indra/newview/skins/default/textures/icons/profile_group_visibility_eye_on_pressed.png Binary files differnew file mode 100644 index 0000000000..ae04a256a4 --- /dev/null +++ b/indra/newview/skins/default/textures/icons/profile_group_visibility_eye_on_pressed.png diff --git a/indra/newview/skins/default/textures/textures.xml b/indra/newview/skins/default/textures/textures.xml index a4e9e2eb1b..02d48bb0d6 100644 --- a/indra/newview/skins/default/textures/textures.xml +++ b/indra/newview/skins/default/textures/textures.xml @@ -506,8 +506,10 @@ with the same filename but different name <texture name="Play_Over" file_name="icons/Play_Over.png" preload="false" /> <texture name="Play_Press" file_name="icons/Play_Press.png" preload="false" /> - <texture name="Profile_Search_Visibility_Dark" file_name="icons/Profile_Search_Visibility_Dark.png" preload="true"/> - <texture name="Profile_Search_Visibility_Light" file_name="icons/Profile_Search_Visibility_Light.png" preload="true"/> + <texture name="Profile_Group_Visibility_Off" file_name="icons/profile_group_visibility_eye_off.png" preload="true"/> + <texture name="Profile_Group_Visibility_Off_Pressed" file_name="icons/profile_group_visibility_eye_off_pressed.png" preload="true"/> + <texture name="Profile_Group_Visibility_On" file_name="icons/profile_group_visibility_eye_on.png" preload="true"/> + <texture name="Profile_Group_Visibility_On_Pressed" file_name="icons/profile_group_visibility_eye_on_pressed.png" preload="true"/> <texture name="Profile_Perm_Find_Disabled" file_name="icons/Profile_Perm_Find_Disabled.png" preload="true"/> <texture name="Profile_Perm_Find_Enabled" file_name="icons/Profile_Perm_Find_Enabled.png" preload="true"/> <texture name="Profile_Perm_Objects_Disabled" file_name="icons/Profile_Perm_Objects_Disabled.png" preload="true"/> diff --git a/indra/newview/skins/default/xui/en/menu_gesture_gear.xml b/indra/newview/skins/default/xui/en/menu_gesture_gear.xml index 5cae643e44..359c093eff 100644 --- a/indra/newview/skins/default/xui/en/menu_gesture_gear.xml +++ b/indra/newview/skins/default/xui/en/menu_gesture_gear.xml @@ -9,7 +9,7 @@ layout="topleft" name="activate"> <on_click - function="Gesture.Action.ToogleActiveState" /> + function="Gesture.Action.ToggleActiveState" /> </menu_item_call> <menu_item_call label="Rename" diff --git a/indra/newview/skins/default/xui/en/panel_group_list_item_short.xml b/indra/newview/skins/default/xui/en/panel_group_list_item_short.xml index ee99625497..b72af7221e 100644 --- a/indra/newview/skins/default/xui/en/panel_group_list_item_short.xml +++ b/indra/newview/skins/default/xui/en/panel_group_list_item_short.xml @@ -54,23 +54,36 @@ use_ellipses="true" /> <button - name="visibility_btn" - tool_tip="Toogle visibility in profile" - top_delta="-1" + name="visibility_hide_btn" + tool_tip="Hide group on my profile" + top_delta="-3" left_pad="3" right="-53" - height="14" + height="20" + width="20" + follows="right" + image_pressed="Profile_Group_Visibility_Off_Pressed" + image_unselected="Profile_Group_Visibility_Off" + tab_stop="false" + visible="false" + /> + <button + name="visibility_show_btn" + tool_tip="Show group on my profile" + top_delta="0" + right_delta="0" + height="20" width="20" follows="right" - image_pressed="Profile_Search_Visibility_Dark" - image_unselected="Profile_Search_Visibility_Light" + image_pressed="Profile_Group_Visibility_On_Pressed" + image_unselected="Profile_Group_Visibility_On" tab_stop="false" visible="false" /> <button name="info_btn" tool_tip="More info" - top_delta="-1" + top_delta="2" left_pad="3" right="-30" height="16" |