diff options
author | Leyla Farazha <leyla@lindenlab.com> | 2010-04-08 16:22:19 -0700 |
---|---|---|
committer | Leyla Farazha <leyla@lindenlab.com> | 2010-04-08 16:22:19 -0700 |
commit | 571ee16a1ff240873b602c6d01a1e3dbd17f2bc2 (patch) | |
tree | d014842034007f3e6891632e1e720f419c6635b2 /indra/newview/llpanellandmarks.cpp | |
parent | 1c4b6085064a623268919ed5c56f052f52110b41 (diff) | |
parent | 3ff6c576211a10902bd02085c11fdb448ba9181f (diff) |
Merge
Diffstat (limited to 'indra/newview/llpanellandmarks.cpp')
-rw-r--r-- | indra/newview/llpanellandmarks.cpp | 17 |
1 files changed, 13 insertions, 4 deletions
diff --git a/indra/newview/llpanellandmarks.cpp b/indra/newview/llpanellandmarks.cpp index 8d8c996374..a1cdbdad59 100644 --- a/indra/newview/llpanellandmarks.cpp +++ b/indra/newview/llpanellandmarks.cpp @@ -280,6 +280,17 @@ void LLLandmarksPanel::onShowOnMap() doActionOnCurSelectedLandmark(boost::bind(&LLLandmarksPanel::doShowOnMap, this, _1)); } +//virtual +void LLLandmarksPanel::onShowProfile() +{ + LLFolderViewItem* cur_item = getCurSelectedItem(); + + if(!cur_item) + return; + + cur_item->getListener()->performAction(mCurrentSelectedList->getModel(),"about"); +} + // virtual void LLLandmarksPanel::onTeleport() { @@ -306,6 +317,7 @@ void LLLandmarksPanel::updateVerbs() bool landmark_selected = isLandmarkSelected(); mTeleportBtn->setEnabled(landmark_selected && isActionEnabled("teleport")); mShowOnMapBtn->setEnabled(landmark_selected && isActionEnabled("show_on_map")); + mShowProfile->setEnabled(landmark_selected && isActionEnabled("more_info")); // TODO: mantipov: Uncomment when mShareBtn is supported // Share button should be enabled when neither a folder nor a landmark is selected @@ -977,13 +989,10 @@ bool LLLandmarksPanel::isActionEnabled(const LLSD& userdata) const void LLLandmarksPanel::onCustomAction(const LLSD& userdata) { - LLFolderViewItem* cur_item = getCurSelectedItem(); - if(!cur_item) - return; std::string command_name = userdata.asString(); if("more_info" == command_name) { - cur_item->getListener()->performAction(mCurrentSelectedList->getModel(),"about"); + onShowProfile(); } else if ("teleport" == command_name) { |