diff options
author | Loren Shih <seraph@lindenlab.com> | 2010-04-01 17:54:08 -0400 |
---|---|---|
committer | Loren Shih <seraph@lindenlab.com> | 2010-04-01 17:54:08 -0400 |
commit | 2854008e8edd3419fe37a8c4971223eda5945bfa (patch) | |
tree | 83640a42fcc5f71200a19e173a95da433760cf74 /indra/newview/llpanellandmarks.cpp | |
parent | 1ec47c39a6c4a6e7e518d0b91a87f50596362f06 (diff) | |
parent | 406b595e8c6811c2550340ba316328289d8b856f (diff) |
automated merge
Diffstat (limited to 'indra/newview/llpanellandmarks.cpp')
-rw-r--r-- | indra/newview/llpanellandmarks.cpp | 18 |
1 files changed, 6 insertions, 12 deletions
diff --git a/indra/newview/llpanellandmarks.cpp b/indra/newview/llpanellandmarks.cpp index 9cc79d95b8..8d8c996374 100644 --- a/indra/newview/llpanellandmarks.cpp +++ b/indra/newview/llpanellandmarks.cpp @@ -924,12 +924,7 @@ bool LLLandmarksPanel::isActionEnabled(const LLSD& userdata) const return false; } } - else if (!root_folder_view && "category" != command_name) - { - return false; - } else if ( "paste" == command_name - || "rename" == command_name || "cut" == command_name || "copy" == command_name || "delete" == command_name @@ -941,17 +936,16 @@ bool LLLandmarksPanel::isActionEnabled(const LLSD& userdata) const } else if ( "teleport" == command_name || "more_info" == command_name - || "rename" == command_name || "show_on_map" == command_name || "copy_slurl" == command_name ) { // disable some commands for multi-selection. EXT-1757 - if (root_folder_view && - root_folder_view->getSelectedCount() > 1) - { - return false; - } + return root_folder_view && root_folder_view->getSelectedCount() == 1; + } + else if ("rename" == command_name) + { + return root_folder_view && root_folder_view->getSelectedCount() == 1 && canSelectedBeModified(command_name); } else if("category" == command_name) { @@ -1080,7 +1074,7 @@ bool LLLandmarksPanel::canSelectedBeModified(const std::string& command_name) co } else if ("delete" == command_name) { - can_be_modified = listenerp ? listenerp->isItemRemovable() : false; + can_be_modified = listenerp ? listenerp->isItemRemovable() && !listenerp->isItemInTrash() : false; } else if("paste" == command_name) { |