summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--indra/newview/llfloatertopobjects.cpp41
-rw-r--r--indra/newview/llfloatertopobjects.h11
-rw-r--r--indra/newview/skins/default/xui/en/floater_top_objects.xml26
3 files changed, 6 insertions, 72 deletions
diff --git a/indra/newview/llfloatertopobjects.cpp b/indra/newview/llfloatertopobjects.cpp
index 3e6fc3dc0d..9b5b3a0fc9 100644
--- a/indra/newview/llfloatertopobjects.cpp
+++ b/indra/newview/llfloatertopobjects.cpp
@@ -78,8 +78,6 @@ LLFloaterTopObjects::LLFloaterTopObjects(const LLSD& key)
mCommitCallbackRegistrar.add("TopObjects.ShowBeacon", boost::bind(&LLFloaterTopObjects::onClickShowBeacon, this));
mCommitCallbackRegistrar.add("TopObjects.ReturnSelected", boost::bind(&LLFloaterTopObjects::onReturnSelected, this));
mCommitCallbackRegistrar.add("TopObjects.ReturnAll", boost::bind(&LLFloaterTopObjects::onReturnAll, this));
- mCommitCallbackRegistrar.add("TopObjects.DisableSelected", boost::bind(&LLFloaterTopObjects::onDisableSelected, this));
- mCommitCallbackRegistrar.add("TopObjects.DisableAll", boost::bind(&LLFloaterTopObjects::onDisableAll, this));
mCommitCallbackRegistrar.add("TopObjects.Refresh", boost::bind(&LLFloaterTopObjects::onRefresh, this));
mCommitCallbackRegistrar.add("TopObjects.GetByObjectName", boost::bind(&LLFloaterTopObjects::onGetByObjectName, this));
mCommitCallbackRegistrar.add("TopObjects.GetByOwnerName", boost::bind(&LLFloaterTopObjects::onGetByOwnerName, this));
@@ -332,7 +330,7 @@ void LLFloaterTopObjects::onClickShowBeacon()
showBeacon();
}
-void LLFloaterTopObjects::doToObjects(int action, bool all)
+void LLFloaterTopObjects::returnObjects(bool all)
{
LLMessageSystem *msg = gMessageSystem;
@@ -356,14 +354,7 @@ void LLFloaterTopObjects::doToObjects(int action, bool all)
}
if (start_message)
{
- if (action == ACTION_RETURN)
- {
- msg->newMessageFast(_PREHASH_ParcelReturnObjects);
- }
- else
- {
- msg->newMessageFast(_PREHASH_ParcelDisableObjects);
- }
+ msg->newMessageFast(_PREHASH_ParcelReturnObjects);
msg->nextBlockFast(_PREHASH_AgentData);
msg->addUUIDFast(_PREHASH_AgentID, gAgent.getID());
msg->addUUIDFast(_PREHASH_SessionID,gAgent.getSessionID());
@@ -397,7 +388,7 @@ bool LLFloaterTopObjects::callbackReturnAll(const LLSD& notification, const LLSD
if(!instance) return false;
if (option == 0)
{
- instance->doToObjects(ACTION_RETURN, true);
+ instance->returnObjects(true);
}
return false;
}
@@ -410,31 +401,7 @@ void LLFloaterTopObjects::onReturnAll()
void LLFloaterTopObjects::onReturnSelected()
{
- doToObjects(ACTION_RETURN, false);
-}
-
-
-//static
-bool LLFloaterTopObjects::callbackDisableAll(const LLSD& notification, const LLSD& response)
-{
- S32 option = LLNotificationsUtil::getSelectedOption(notification, response);
- LLFloaterTopObjects* instance = LLFloaterReg::getTypedInstance<LLFloaterTopObjects>("top_objects");
- if(!instance) return false;
- if (option == 0)
- {
- instance->doToObjects(ACTION_DISABLE, true);
- }
- return false;
-}
-
-void LLFloaterTopObjects::onDisableAll()
-{
- LLNotificationsUtil::add("DisableAllTopObjects", LLSD(), LLSD(), callbackDisableAll);
-}
-
-void LLFloaterTopObjects::onDisableSelected()
-{
- doToObjects(ACTION_DISABLE, false);
+ returnObjects(false);
}
diff --git a/indra/newview/llfloatertopobjects.h b/indra/newview/llfloatertopobjects.h
index dbbe9ac521..3138249c7a 100644
--- a/indra/newview/llfloatertopobjects.h
+++ b/indra/newview/llfloatertopobjects.h
@@ -78,15 +78,12 @@ private:
static void onDoubleClickObjectsList(void* data);
void onClickShowBeacon();
- void doToObjects(int action, bool all);
+ void returnObjects(bool all);
void onReturnAll();
void onReturnSelected();
- void onDisableAll();
- void onDisableSelected();
static bool callbackReturnAll(const LLSD& notification, const LLSD& response);
- static bool callbackDisableAll(const LLSD& notification, const LLSD& response);
void onGetByOwnerName();
void onGetByObjectName();
@@ -108,12 +105,6 @@ private:
F32 mtotalScore;
- enum
- {
- ACTION_RETURN = 0,
- ACTION_DISABLE
- };
-
static LLFloaterTopObjects* sInstance;
};
diff --git a/indra/newview/skins/default/xui/en/floater_top_objects.xml b/indra/newview/skins/default/xui/en/floater_top_objects.xml
index 36ceddd305..ceef541290 100644
--- a/indra/newview/skins/default/xui/en/floater_top_objects.xml
+++ b/indra/newview/skins/default/xui/en/floater_top_objects.xml
@@ -2,7 +2,7 @@
<floater
legacy_header_height="18"
can_resize="true"
- height="372"
+ height="350"
layout="topleft"
min_height="300"
min_width="450"
@@ -273,28 +273,4 @@
<button.commit_callback
function="TopObjects.ReturnAll" />
</button>
- <button
- follows="bottom|left"
- height="23"
- label="Disable Selected"
- layout="topleft"
-
- left="112"
- name="disable_selected_btn"
- width="130">
- <button.commit_callback
- function="TopObjects.DisableSelected" />
- </button>
- <button
- follows="bottom|left"
- height="23"
- label="Disable All"
- layout="topleft"
- left_pad="10"
- name="disable_all_btn"
- top_delta="0"
- width="130">
- <button.commit_callback
- function="TopObjects.DisableAll" />
- </button>
</floater>