aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
-rw-r--r--linden/indra/newview/app_settings/settings.xml11
-rw-r--r--linden/indra/newview/panelradar.cpp33
-rw-r--r--linden/indra/newview/panelradar.h3
-rw-r--r--linden/indra/newview/skins/default/xui/en-us/panel_radar.xml14
4 files changed, 7 insertions, 54 deletions
diff --git a/linden/indra/newview/app_settings/settings.xml b/linden/indra/newview/app_settings/settings.xml
index 894473b..65a6c00 100644
--- a/linden/indra/newview/app_settings/settings.xml
+++ b/linden/indra/newview/app_settings/settings.xml
@@ -551,17 +551,6 @@
551 <key>Value</key> 551 <key>Value</key>
552 <integer>0</integer> 552 <integer>0</integer>
553 </map> 553 </map>
554 <key>RadarSimWide</key>
555 <map>
556 <key>Comment</key>
557 <string>If true, radar shows everyone in the sim</string>
558 <key>Persist</key>
559 <integer>1</integer>
560 <key>Type</key>
561 <string>Boolean</string>
562 <key>Value</key>
563 <integer>0</integer>
564 </map>
565 <key>SavedRenderFarClip</key> 554 <key>SavedRenderFarClip</key>
566 <map> 555 <map>
567 <key>Comment</key> 556 <key>Comment</key>
diff --git a/linden/indra/newview/panelradar.cpp b/linden/indra/newview/panelradar.cpp
index cfaffde..ce91da2 100644
--- a/linden/indra/newview/panelradar.cpp
+++ b/linden/indra/newview/panelradar.cpp
@@ -29,7 +29,6 @@
29 29
30#include "panelradar.h" 30#include "panelradar.h"
31 31
32#include "hippoLimits.h"
33#include "llagent.h" 32#include "llagent.h"
34#include "llchat.h" 33#include "llchat.h"
35#include "llfloateravatarinfo.h" 34#include "llfloateravatarinfo.h"
@@ -46,7 +45,6 @@
46#include "llregionposition.h" 45#include "llregionposition.h"
47#include "roles_constants.h" 46#include "roles_constants.h"
48#include "llscrolllistctrl.h" 47#include "llscrolllistctrl.h"
49#include "llspinctrl.h"
50#include "lltracker.h" 48#include "lltracker.h"
51#include "lluictrlfactory.h" 49#include "lluictrlfactory.h"
52#include "llviewercontrol.h" 50#include "llviewercontrol.h"
@@ -79,11 +77,6 @@ BOOL PanelRadar::postBuild()
79 childSetCommitCallback("RadarList", onUseRadarList, this); 77 childSetCommitCallback("RadarList", onUseRadarList, this);
80 mRadarList->setDoubleClickCallback(onClickIM); 78 mRadarList->setDoubleClickCallback(onClickIM);
81 79
82 childSetCommitCallback("simwide_checkbox", onCheckSimWide, this);
83
84 // Set max range to max height
85 getChild<LLSpinCtrl>("near_me_range")->setMaxValue(gHippoLimits->getMaxHeight());
86
87 childSetAction("im_btn", onClickIM, this); 80 childSetAction("im_btn", onClickIM, this);
88 childSetAction("profile_btn", onClickProfile, this); 81 childSetAction("profile_btn", onClickProfile, this);
89 childSetAction("offer_teleport_btn", onClickOfferTeleport, this); 82 childSetAction("offer_teleport_btn", onClickOfferTeleport, this);
@@ -223,6 +216,8 @@ void PanelRadar::updateRadarDisplay()
223 F32 range = gSavedSettings.getF32("NearMeRange"); 216 F32 range = gSavedSettings.getF32("NearMeRange");
224 bool notify_chat = gSavedSettings.getBOOL("MiniMapNotifyChatRange"); 217 bool notify_chat = gSavedSettings.getBOOL("MiniMapNotifyChatRange");
225 bool notify_sim = gSavedSettings.getBOOL("MiniMapNotifySimRange"); 218 bool notify_sim = gSavedSettings.getBOOL("MiniMapNotifySimRange");
219 // We show avatars outside the estate even if you can't manage it in case griefers are lying on the border
220 bool is_manager = gAgent.getRegion()->canManageEstate();
226// [RLVa:KB] - Alternate: Imprudence-1.2.0 221// [RLVa:KB] - Alternate: Imprudence-1.2.0
227 if (gRlvHandler.hasBehaviour(RLV_BHVR_SHOWNAMES)) 222 if (gRlvHandler.hasBehaviour(RLV_BHVR_SHOWNAMES))
228 { 223 {
@@ -291,7 +286,7 @@ void PanelRadar::updateRadarDisplay()
291 } 286 }
292 287
293 // Only display avatars in range 288 // Only display avatars in range
294 if (mSimWide || entry->getDistance() <= range) 289 if (is_manager || entry->getDistance() <= range)
295 { 290 {
296 // Append typing string 291 // Append typing string
297 std::string typing = ""; 292 std::string typing = "";
@@ -554,28 +549,6 @@ void PanelRadar::onUseRadarList(LLUICtrl* ctrl, void* user_data)
554} 549}
555 550
556 551
557// static
558void PanelRadar::onCheckSimWide(LLUICtrl* ctrl, void* user_data)
559{
560 PanelRadar* self = (PanelRadar*)user_data;
561 if (self)
562 {
563 self->updateRangeControls();
564 }
565}
566
567
568void PanelRadar::updateRangeControls()
569{
570 LLSpinCtrl* near_me = getChild<LLSpinCtrl>("near_me_range");
571 if (near_me)
572 {
573 near_me->setEnabled(!gSavedSettings.getBOOL("RadarSimWide"));
574 }
575 mSimWide = gSavedSettings.getBOOL("RadarSimWide");
576}
577
578
579bool PanelRadar::visibleItemsSelected() const 552bool PanelRadar::visibleItemsSelected() const
580{ 553{
581 return (mRadarList->getFirstSelectedIndex() >= 0); 554 return (mRadarList->getFirstSelectedIndex() >= 0);
diff --git a/linden/indra/newview/panelradar.h b/linden/indra/newview/panelradar.h
index 4d53b56..59e6aff 100644
--- a/linden/indra/newview/panelradar.h
+++ b/linden/indra/newview/panelradar.h
@@ -77,7 +77,6 @@ private:
77 LLScrollListCtrl* mRadarList; 77 LLScrollListCtrl* mRadarList;
78 LLUUID mSelectedAvatar; 78 LLUUID mSelectedAvatar;
79 F32 mSelectedDistance; 79 F32 mSelectedDistance;
80 bool mSimWide;
81 80
82 bool visibleItemsSelected() const; 81 bool visibleItemsSelected() const;
83 bool isKickable(const LLUUID& agent_id); 82 bool isKickable(const LLUUID& agent_id);
@@ -89,8 +88,6 @@ private:
89 88
90 static void onUseRadarList(LLUICtrl* ctrl, void* user_data); 89 static void onUseRadarList(LLUICtrl* ctrl, void* user_data);
91 static void onRangeChange(LLFocusableElement* focus, void* user_data); 90 static void onRangeChange(LLFocusableElement* focus, void* user_data);
92 static void onCheckSimWide(LLUICtrl* ctrl, void* user_data);
93 void updateRangeControls();
94 91
95 static void onClickProfile(void* user_data); 92 static void onClickProfile(void* user_data);
96 static void onClickIM(void* user_data); 93 static void onClickIM(void* user_data);
diff --git a/linden/indra/newview/skins/default/xui/en-us/panel_radar.xml b/linden/indra/newview/skins/default/xui/en-us/panel_radar.xml
index d02ff0d..603f2d8 100644
--- a/linden/indra/newview/skins/default/xui/en-us/panel_radar.xml
+++ b/linden/indra/newview/skins/default/xui/en-us/panel_radar.xml
@@ -40,13 +40,13 @@
40 0 avatars in 40 0 avatars in
41 </text> 41 </text>
42 42
43 <spinner name="near_me_range" label="" control_name="NearMeRange" 43 <slider name="near_me_range" label="" control_name="NearMeRange"
44 bottom_delta="0" left_delta="66" width="60" height="15" 44 bottom_delta="0" left_delta="62" width="110" height="15"
45 follows="left|top" min_val="5" increment="15" 45 follows="left|top" min_val="5" max_val="512" increment="1"
46 initial_val="96" decimal_digits="0" /> 46 initial_val="96" decimal_digits="0" />
47 47
48 <text name="meters" 48 <text name="meters"
49 bottom_delta="0" left="140" height="15" width="40" 49 bottom_delta="0" left="180" height="15" width="40"
50 h_pad="0" halign="left" v_pad="0" follows="left|top" 50 h_pad="0" halign="left" v_pad="0" follows="left|top"
51 bg_visible="false" border_drop_shadow_visible="false" 51 bg_visible="false" border_drop_shadow_visible="false"
52 border_visible="false" drop_shadow_visible="true" 52 border_visible="false" drop_shadow_visible="true"
@@ -54,12 +54,6 @@
54 m 54 m
55 </text> 55 </text>
56 56
57 <check_box bottom_delta="-1" enabled="true" follows="left|top"
58 font="SansSerifSmall" height="16" initial_value="false"
59 label="Sim-wide" left_delta="20" mouse_opaque="true"
60 name="simwide_checkbox" control_name="RadarSimWide"
61 radio_style="false" width="100" />
62
63 <tab_container name="radar_tab_container" 57 <tab_container name="radar_tab_container"
64 bottom="1" left="0" right="0" height="172" 58 bottom="1" left="0" right="0" height="172"
65 follows="left|right|bottom" border="false" 59 follows="left|right|bottom" border="false"