summaryrefslogtreecommitdiff
path: root/indra/newview
diff options
context:
space:
mode:
authorAndrey Kleshchev <andreykproductengine@lindenlab.com>2022-04-18 23:39:21 +0300
committerAndrey Kleshchev <andreykproductengine@lindenlab.com>2022-04-18 23:39:21 +0300
commitea0c810d2d082a9684d9ce6b9cbd888c87f06612 (patch)
tree2ba79cdce632286bc14c2e34015c62fa95689388 /indra/newview
parent8a39aaa3a485d9f1d4486c02e98286cfb08761d4 (diff)
SL-15312 Small tweaks for profiles
Diffstat (limited to 'indra/newview')
-rw-r--r--indra/newview/llfloaterpreference.cpp3
-rw-r--r--indra/newview/llpanelprofile.cpp17
-rw-r--r--indra/newview/llpanelprofile.h1
-rw-r--r--indra/newview/skins/default/xui/en/menu_profile_other.xml22
-rw-r--r--indra/newview/skins/default/xui/en/panel_profile_notes.xml14
-rw-r--r--indra/newview/skins/default/xui/en/panel_profile_secondlife.xml4
6 files changed, 36 insertions, 25 deletions
diff --git a/indra/newview/llfloaterpreference.cpp b/indra/newview/llfloaterpreference.cpp
index 9064a65d05..7bc16293a5 100644
--- a/indra/newview/llfloaterpreference.cpp
+++ b/indra/newview/llfloaterpreference.cpp
@@ -381,10 +381,13 @@ void LLFloaterPreference::saveAvatarProperties( void )
// "allow publish" flag, the last remaining profile setting in the viewer
// that doesn't exist in the web profile.
//
+
if ((LLStartUp::getStartupState() == STATE_STARTED) && mAvatarDataInitialized && (allowPublish != mAvatarProperties.allow_publish))
{
mAvatarProperties.allow_publish = allowPublish;
+ // TODO!!!: replace with an AgentProfile cap, once allow_publish works correctly
+ // otherwise this will trim long descritions/reset profile
LLAvatarPropertiesProcessor::getInstance()->sendAvatarPropertiesUpdate( &mAvatarProperties );
}
}
diff --git a/indra/newview/llpanelprofile.cpp b/indra/newview/llpanelprofile.cpp
index 46b2d032e1..bb6fdc1757 100644
--- a/indra/newview/llpanelprofile.cpp
+++ b/indra/newview/llpanelprofile.cpp
@@ -786,9 +786,10 @@ void LLFloaterProfilePermissions::onCancel()
// LLPanelProfileSecondLife
LLPanelProfileSecondLife::LLPanelProfileSecondLife()
- : LLPanelProfileTab()
- , mAvatarNameCacheConnection()
- , mWaitingForImageUpload(false)
+ : LLPanelProfileTab()
+ , mAvatarNameCacheConnection()
+ , mWaitingForImageUpload(false)
+ , mAllowPublish(false)
{
}
@@ -1056,7 +1057,8 @@ void LLPanelProfileSecondLife::fillCommonData(const LLAvatarData* avatar_data)
if (getSelfProfile())
{
- mShowInSearchCombo->setValue((BOOL)(avatar_data->flags & AVATAR_ALLOW_PUBLISH));
+ mAllowPublish = avatar_data->flags & AVATAR_ALLOW_PUBLISH;
+ mShowInSearchCombo->setValue((BOOL)mAllowPublish);
}
}
@@ -1530,11 +1532,16 @@ void LLPanelProfileSecondLife::onSetDescriptionDirty()
void LLPanelProfileSecondLife::onShowInSearchCallback()
{
+ if (mAllowPublish == mShowInSearchCombo->getValue().asBoolean())
+ {
+ return;
+ }
std::string cap_url = gAgent.getRegionCapability(PROFILE_PROPERTIES_CAP);
if (!cap_url.empty())
{
+ mAllowPublish = mShowInSearchCombo->getValue().asBoolean();
LLSD data;
- data["allow_publish"] = mShowInSearchCombo->getValue().asBoolean();
+ data["allow_publish"] = mAllowPublish;
LLCoros::instance().launch("putAgentUserInfoCoro",
boost::bind(put_avatar_properties_coro, cap_url, getAvatarId(), data));
}
diff --git a/indra/newview/llpanelprofile.h b/indra/newview/llpanelprofile.h
index b959ac1ec3..c4b48979ea 100644
--- a/indra/newview/llpanelprofile.h
+++ b/indra/newview/llpanelprofile.h
@@ -193,6 +193,7 @@ private:
bool mVoiceStatus;
bool mWaitingForImageUpload;
+ bool mAllowPublish;
std::string mDescriptionText;
boost::signals2::connection mAvatarNameCacheConnection;
diff --git a/indra/newview/skins/default/xui/en/menu_profile_other.xml b/indra/newview/skins/default/xui/en/menu_profile_other.xml
index fff1f7b614..4db4d0922b 100644
--- a/indra/newview/skins/default/xui/en/menu_profile_other.xml
+++ b/indra/newview/skins/default/xui/en/menu_profile_other.xml
@@ -86,6 +86,17 @@
</menu_item_call>
<menu_item_separator name="separator_invite_to_group"/>
<menu_item_call
+ label="Permissions"
+ layout="topleft"
+ name="agent_permissions">
+ <menu_item_call.on_click
+ function="Profile.Commit"
+ parameter="agent_permissions"/>
+ <menu_item_call.on_visible
+ function="Profile.EnableItem"
+ parameter="agent_permissions"/>
+ </menu_item_call>
+ <menu_item_call
label="Map"
layout="topleft"
name="map">
@@ -128,17 +139,6 @@
</menu_item_check>
<menu_item_separator name="separator_copy_options"/>
<menu_item_call
- label="Permissions"
- layout="topleft"
- name="agent_permissions">
- <menu_item_call.on_click
- function="Profile.Commit"
- parameter="agent_permissions"/>
- <menu_item_call.on_visible
- function="Profile.EnableItem"
- parameter="agent_permissions"/>
- </menu_item_call>
- <menu_item_call
label="Copy Display Name"
layout="topleft"
name="copy_display_name">
diff --git a/indra/newview/skins/default/xui/en/panel_profile_notes.xml b/indra/newview/skins/default/xui/en/panel_profile_notes.xml
index 78d5fb5915..16e7365042 100644
--- a/indra/newview/skins/default/xui/en/panel_profile_notes.xml
+++ b/indra/newview/skins/default/xui/en/panel_profile_notes.xml
@@ -21,7 +21,7 @@
/>
<text
name="status_message"
- value="Private notes on this avatar:"
+ value="Make notes about this person here. No one else can see your notes."
top="6"
left="6"
right="-6"
@@ -33,10 +33,10 @@
<text_editor
name="notes_edit"
enabled="false"
- top_pad="4"
+ top="28"
left="6"
right="-6"
- height="311"
+ bottom="-26"
follows="all"
layout="topleft"
max_length="65530"
@@ -45,21 +45,21 @@
<button
name="notes_save_changes"
label="Save"
- top="429"
+ bottom="-1"
right="-108"
height="20"
width="80"
enabled="false"
- follows="top|right"
+ follows="bottom|right"
layout="topleft"/>
<button
name="notes_discard_changes"
label="Discard"
- top_delta="0"
+ bottom="-1"
right="-4"
height="20"
width="100"
enabled="false"
- follows="top|right"
+ follows="bottom|right"
layout="topleft"/>
</panel>
diff --git a/indra/newview/skins/default/xui/en/panel_profile_secondlife.xml b/indra/newview/skins/default/xui/en/panel_profile_secondlife.xml
index 21743baf9d..1402803ebe 100644
--- a/indra/newview/skins/default/xui/en/panel_profile_secondlife.xml
+++ b/indra/newview/skins/default/xui/en/panel_profile_secondlife.xml
@@ -380,7 +380,7 @@ Account: [ACCTTYPE]
name="settings_panel"
follows="all"
layout="topleft"
- width="200"
+ width="190"
auto_resize="false"
user_resize="false">
<!-- only for self -->
@@ -399,7 +399,7 @@ Account: [ACCTTYPE]
left="1"
top="18"
height="23"
- width="140"
+ width="180"
follows="left|top"
layout="topleft"
visible="true"