summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
Diffstat (limited to 'indra')
-rw-r--r--indra/llui/llstatbar.cpp7
-rw-r--r--indra/newview/llfloaterscriptlimits.cpp43
-rw-r--r--indra/newview/llinventorybridge.cpp60
-rw-r--r--indra/newview/llinventorybridge.h1
-rw-r--r--indra/newview/llpanelmaininventory.cpp14
-rw-r--r--indra/newview/skins/default/xui/en/floater_scene_load_stats.xml15
-rw-r--r--indra/newview/skins/default/xui/en/floater_script_limits.xml3
-rw-r--r--indra/newview/skins/default/xui/en/floater_stats.xml8
-rw-r--r--indra/newview/skins/default/xui/en/menu_inventory.xml8
-rw-r--r--indra/newview/skins/default/xui/en/menu_viewer.xml2
-rw-r--r--indra/newview/skins/default/xui/en/panel_script_limits_my_avatar.xml12
-rw-r--r--indra/newview/skins/default/xui/en/panel_script_limits_region_memory.xml34
-rw-r--r--indra/newview/skins/default/xui/en/strings.xml3
13 files changed, 155 insertions, 55 deletions
diff --git a/indra/llui/llstatbar.cpp b/indra/llui/llstatbar.cpp
index 35f5330a3f..6c8e63442b 100644
--- a/indra/llui/llstatbar.cpp
+++ b/indra/llui/llstatbar.cpp
@@ -40,6 +40,7 @@
#include "lltooltip.h"
#include "lllocalcliprect.h"
#include <iostream>
+#include "lltrans.h"
// rate at which to update display of value that is rapidly changing
const F32 MEAN_VALUE_UPDATE_TIME = 1.f / 4.f;
@@ -619,19 +620,19 @@ void LLStatBar::drawLabelAndValue( F32 value, std::string &label, LLRect &bar_re
std::string value_str = !llisnan(value)
? llformat("%10.*f %s", decimal_digits, value, label.c_str())
- : "n/a";
+ : LLTrans::getString("na");
// Draw the current value.
if (mOrientation == HORIZONTAL)
{
LLFontGL::getFontMonospace()->renderUTF8(value_str, 0, bar_rect.mRight, getRect().getHeight(),
- LLColor4(1.f, 1.f, 1.f, 0.5f),
+ LLColor4(1.f, 1.f, 1.f, 1.f),
LLFontGL::RIGHT, LLFontGL::TOP);
}
else
{
LLFontGL::getFontMonospace()->renderUTF8(value_str, 0, bar_rect.mRight, getRect().getHeight(),
- LLColor4(1.f, 1.f, 1.f, 0.5f),
+ LLColor4(1.f, 1.f, 1.f, 1.f),
LLFontGL::RIGHT, LLFontGL::TOP);
}
}
diff --git a/indra/newview/llfloaterscriptlimits.cpp b/indra/newview/llfloaterscriptlimits.cpp
index eae16b9f03..c14bb4e7ae 100644
--- a/indra/newview/llfloaterscriptlimits.cpp
+++ b/indra/newview/llfloaterscriptlimits.cpp
@@ -523,6 +523,8 @@ void LLPanelScriptLimitsRegionMemory::setRegionDetails(LLSD content)
LLScrollListCell::Params cell_params;
cell_params.font = LLFontGL::getFontSansSerif();
+ // Start out right justifying numeric displays
+ cell_params.font_halign = LLFontGL::RIGHT;
cell_params.column = "size";
cell_params.value = size;
@@ -532,6 +534,8 @@ void LLPanelScriptLimitsRegionMemory::setRegionDetails(LLSD content)
cell_params.value = urls;
item_params.columns.add(cell_params);
+ cell_params.font_halign = LLFontGL::LEFT;
+ // The rest of the columns are text to left justify them
cell_params.column = "name";
cell_params.value = name_buf;
item_params.columns.add(cell_params);
@@ -546,7 +550,7 @@ void LLPanelScriptLimitsRegionMemory::setRegionDetails(LLSD content)
cell_params.column = "location";
cell_params.value = has_locations
- ? llformat("<%0.1f,%0.1f,%0.1f>", location_x, location_y, location_z)
+ ? llformat("<%0.0f, %0.0f, %0.0f>", location_x, location_y, location_z)
: "";
item_params.columns.add(cell_params);
@@ -623,13 +627,20 @@ void LLPanelScriptLimitsRegionMemory::setRegionSummary(LLSD content)
if((mParcelMemoryUsed >= 0) && (mParcelMemoryMax >= 0))
{
- S32 parcel_memory_available = mParcelMemoryMax - mParcelMemoryUsed;
-
LLStringUtil::format_map_t args_parcel_memory;
args_parcel_memory["[COUNT]"] = llformat ("%d", mParcelMemoryUsed);
- args_parcel_memory["[MAX]"] = llformat ("%d", mParcelMemoryMax);
- args_parcel_memory["[AVAILABLE]"] = llformat ("%d", parcel_memory_available);
- std::string msg_parcel_memory = LLTrans::getString("ScriptLimitsMemoryUsed", args_parcel_memory);
+ std::string translate_message = "ScriptLimitsMemoryUsedSimple";
+
+ if (0 < mParcelMemoryMax)
+ {
+ S32 parcel_memory_available = mParcelMemoryMax - mParcelMemoryUsed;
+
+ args_parcel_memory["[MAX]"] = llformat ("%d", mParcelMemoryMax);
+ args_parcel_memory["[AVAILABLE]"] = llformat ("%d", parcel_memory_available);
+ translate_message = "ScriptLimitsMemoryUsed";
+ }
+
+ std::string msg_parcel_memory = LLTrans::getString(translate_message, args_parcel_memory);
getChild<LLUICtrl>("memory_used")->setValue(LLSD(msg_parcel_memory));
}
@@ -1061,10 +1072,12 @@ void LLPanelScriptLimitsAttachment::setAttachmentDetails(LLSD content)
element["columns"][0]["column"] = "size";
element["columns"][0]["value"] = llformat("%d", size);
element["columns"][0]["font"] = "SANSSERIF";
+ element["columns"][0]["halign"] = LLFontGL::RIGHT;
element["columns"][1]["column"] = "urls";
element["columns"][1]["value"] = llformat("%d", urls);
element["columns"][1]["font"] = "SANSSERIF";
+ element["columns"][1]["halign"] = LLFontGL::RIGHT;
element["columns"][2]["column"] = "name";
element["columns"][2]["value"] = name;
@@ -1151,14 +1164,20 @@ void LLPanelScriptLimitsAttachment::setAttachmentSummary(LLSD content)
if((mAttachmentMemoryUsed >= 0) && (mAttachmentMemoryMax >= 0))
{
- S32 attachment_memory_available = mAttachmentMemoryMax - mAttachmentMemoryUsed;
-
LLStringUtil::format_map_t args_attachment_memory;
args_attachment_memory["[COUNT]"] = llformat ("%d", mAttachmentMemoryUsed);
- args_attachment_memory["[MAX]"] = llformat ("%d", mAttachmentMemoryMax);
- args_attachment_memory["[AVAILABLE]"] = llformat ("%d", attachment_memory_available);
- std::string msg_attachment_memory = LLTrans::getString("ScriptLimitsMemoryUsed", args_attachment_memory);
- getChild<LLUICtrl>("memory_used")->setValue(LLSD(msg_attachment_memory));
+ std::string translate_message = "ScriptLimitsMemoryUsedSimple";
+
+ if (0 < mAttachmentMemoryMax)
+ {
+ S32 attachment_memory_available = mAttachmentMemoryMax - mAttachmentMemoryUsed;
+
+ args_attachment_memory["[MAX]"] = llformat ("%d", mAttachmentMemoryMax);
+ args_attachment_memory["[AVAILABLE]"] = llformat ("%d", attachment_memory_available);
+ translate_message = "ScriptLimitsMemoryUsed";
+ }
+
+ getChild<LLUICtrl>("memory_used")->setValue(LLTrans::getString(translate_message, args_attachment_memory));
}
if((mAttachmentURLsUsed >= 0) && (mAttachmentURLsMax >= 0))
diff --git a/indra/newview/llinventorybridge.cpp b/indra/newview/llinventorybridge.cpp
index 02fa81d5be..1de579d4c3 100644
--- a/indra/newview/llinventorybridge.cpp
+++ b/indra/newview/llinventorybridge.cpp
@@ -3093,6 +3093,10 @@ void LLFolderBridge::performAction(LLInventoryModel* model, std::string action)
LLAppearanceMgr::instance().takeOffOutfit( cat->getLinkedUUID() );
return;
}
+ else if ("copyoutfittoclipboard" == action)
+ {
+ copyOutfitToClipboard();
+ }
else if ("purge" == action)
{
purgeItem(model, mUUID);
@@ -3250,6 +3254,39 @@ void LLFolderBridge::gatherMessage(std::string& message, S32 depth, LLError::ELe
}
}
+void LLFolderBridge::copyOutfitToClipboard()
+{
+ std::string text;
+
+ LLInventoryModel::cat_array_t* cat_array;
+ LLInventoryModel::item_array_t* item_array;
+ gInventory.getDirectDescendentsOf(mUUID, cat_array, item_array);
+
+ S32 item_count(0);
+ if( item_array )
+ {
+ item_count = item_array->size();
+ }
+
+ if (item_count)
+ {
+ for (S32 i = 0; i < item_count;)
+ {
+ LLSD uuid =item_array->at(i)->getUUID();
+ LLViewerInventoryItem* item = gInventory.getItem(uuid);
+
+ i++;
+ if (item != NULL)
+ {
+ // Append a newline to all but the last line
+ text += i != item_count ? item->getName() + "\n" : item->getName();
+ }
+ }
+ }
+
+ LLClipboard::instance().copyToClipboard(utf8str_to_wstring(text),0,text.size());
+}
+
void LLFolderBridge::openItem()
{
LL_DEBUGS() << "LLFolderBridge::openItem()" << LL_ENDL;
@@ -3737,6 +3774,15 @@ void LLFolderBridge::buildContextMenuOptions(U32 flags, menuentry_vec_t& items
// This is the lost+found folder.
items.push_back(std::string("Empty Lost And Found"));
+ LLInventoryModel::cat_array_t* cat_array;
+ LLInventoryModel::item_array_t* item_array;
+ gInventory.getDirectDescendentsOf(mUUID, cat_array, item_array);
+ // Enable Empty menu item only when there is something to act upon.
+ if (0 == cat_array->size() && 0 == item_array->size())
+ {
+ disabled_items.push_back(std::string("Empty Lost And Found"));
+ }
+
disabled_items.push_back(std::string("New Folder"));
disabled_items.push_back(std::string("New Script"));
disabled_items.push_back(std::string("New Note"));
@@ -3781,6 +3827,15 @@ void LLFolderBridge::buildContextMenuOptions(U32 flags, menuentry_vec_t& items
{
// This is the trash.
items.push_back(std::string("Empty Trash"));
+
+ LLInventoryModel::cat_array_t* cat_array;
+ LLInventoryModel::item_array_t* item_array;
+ gInventory.getDirectDescendentsOf(mUUID, cat_array, item_array);
+ // Enable Empty menu item only when there is something to act upon.
+ if (0 == cat_array->size() && 0 == item_array->size())
+ {
+ disabled_items.push_back(std::string("Empty Trash"));
+ }
}
else if(isItemInTrash())
{
@@ -3830,6 +3885,11 @@ void LLFolderBridge::buildContextMenuOptions(U32 flags, menuentry_vec_t& items
}
}
+ if (model->findCategoryUUIDForType(LLFolderType::FT_CURRENT_OUTFIT) == mUUID)
+ {
+ items.push_back(std::string("Copy outfit list to clipboard"));
+ }
+
//Added by aura to force inventory pull on right-click to display folder options correctly. 07-17-06
mCallingCards = mWearables = FALSE;
diff --git a/indra/newview/llinventorybridge.h b/indra/newview/llinventorybridge.h
index df25e01688..b7d8c9d034 100644
--- a/indra/newview/llinventorybridge.h
+++ b/indra/newview/llinventorybridge.h
@@ -344,6 +344,7 @@ protected:
BOOL checkFolderForContentsOfType(LLInventoryModel* model, LLInventoryCollectFunctor& typeToCheck);
void modifyOutfit(BOOL append);
+ void copyOutfitToClipboard();
void determineFolderType();
void dropToFavorites(LLInventoryItem* inv_item);
diff --git a/indra/newview/llpanelmaininventory.cpp b/indra/newview/llpanelmaininventory.cpp
index c9fc1cc33e..fa946ee5c7 100644
--- a/indra/newview/llpanelmaininventory.cpp
+++ b/indra/newview/llpanelmaininventory.cpp
@@ -1192,6 +1192,20 @@ bool LLPanelMainInventory::isSaveTextureEnabled(const LLSD& userdata)
BOOL LLPanelMainInventory::isActionEnabled(const LLSD& userdata)
{
const std::string command_name = userdata.asString();
+ if (command_name == "not_empty")
+ {
+ BOOL status = FALSE;
+ LLFolderViewItem* current_item = getActivePanel()->getRootFolder()->getCurSelectedItem();
+ if (current_item)
+ {
+ const LLUUID& item_id = static_cast<LLFolderViewModelItemInventory*>(current_item->getViewModelItem())->getUUID();
+ LLInventoryModel::cat_array_t* cat_array;
+ LLInventoryModel::item_array_t* item_array;
+ gInventory.getDirectDescendentsOf(item_id, cat_array, item_array);
+ status = (0 == cat_array->size() && 0 == item_array->size());
+ }
+ return status;
+ }
if (command_name == "delete")
{
return getActivePanel()->isSelectionRemovable();
diff --git a/indra/newview/skins/default/xui/en/floater_scene_load_stats.xml b/indra/newview/skins/default/xui/en/floater_scene_load_stats.xml
index 71ff961c59..b53698a9f2 100644
--- a/indra/newview/skins/default/xui/en/floater_scene_load_stats.xml
+++ b/indra/newview/skins/default/xui/en/floater_scene_load_stats.xml
@@ -7,29 +7,22 @@
save_rect="true"
save_visibility="true"
title="SCENE LOAD STATISTICS"
- width="260">
- <button follows="top|left"
- top="20"
- bottom="60"
- left="10"
- width="100"
- label="Pause"
- name="playpause"/>
+ width="400">
<scroll_container follows="top|left|bottom|right"
bottom="400"
layout="topleft"
left="0"
name="statistics_scroll"
reserve_scroll_corner="true"
- top="60"
- width="260">
+ top="20"
+ width="395">
<container_view follows="top|left|bottom|right"
height="378"
layout="topleft"
left="2"
name="statistics_view"
top="20"
- width="245" >
+ width="380" >
<!--Basic Section-->
<stat_view name="basic"
label="Basic"
diff --git a/indra/newview/skins/default/xui/en/floater_script_limits.xml b/indra/newview/skins/default/xui/en/floater_script_limits.xml
index 6b36cdfcc5..96b2ceec63 100644
--- a/indra/newview/skins/default/xui/en/floater_script_limits.xml
+++ b/indra/newview/skins/default/xui/en/floater_script_limits.xml
@@ -8,7 +8,8 @@
name="scriptlimits"
save_rect="true"
title="SCRIPT INFORMATION"
- width="480">
+ min_width="620"
+ width="620">
<tab_container
bottom="555"
follows="left|right|top|bottom"
diff --git a/indra/newview/skins/default/xui/en/floater_stats.xml b/indra/newview/skins/default/xui/en/floater_stats.xml
index 90f9591f29..be9b93837a 100644
--- a/indra/newview/skins/default/xui/en/floater_stats.xml
+++ b/indra/newview/skins/default/xui/en/floater_stats.xml
@@ -8,7 +8,7 @@
save_rect="true"
save_visibility="true"
title="STATISTICS"
- width="260">
+ width="270">
<scroll_container follows="all"
height="380"
layout="topleft"
@@ -16,14 +16,14 @@
name="statistics_scroll"
reserve_scroll_corner="true"
top="20"
- width="260">
+ width="265">
<container_view follows="all"
height="378"
layout="topleft"
- left="2"
+ left="0"
name="statistics_view"
top="20"
- width="245" >
+ width="250" >
<stat_view name="basic"
label="Basic"
setting="OpenDebugStatBasic">
diff --git a/indra/newview/skins/default/xui/en/menu_inventory.xml b/indra/newview/skins/default/xui/en/menu_inventory.xml
index 61002bf1b5..5b8a9413bf 100644
--- a/indra/newview/skins/default/xui/en/menu_inventory.xml
+++ b/indra/newview/skins/default/xui/en/menu_inventory.xml
@@ -457,6 +457,14 @@
function="Inventory.DoToSelected"
parameter="removefromoutfit" />
</menu_item_call>
+ <menu_item_call
+ label="Copy outfit list to clipboard"
+ layout="topleft"
+ name="Copy outfit list to clipboard">
+ <menu_item_call.on_click
+ function="Inventory.DoToSelected"
+ parameter="copyoutfittoclipboard" />
+ </menu_item_call>
<menu_item_separator
layout="topleft"
name="Outfit Separator" />
diff --git a/indra/newview/skins/default/xui/en/menu_viewer.xml b/indra/newview/skins/default/xui/en/menu_viewer.xml
index 98dcdcd1dc..f911c2da7b 100644
--- a/indra/newview/skins/default/xui/en/menu_viewer.xml
+++ b/indra/newview/skins/default/xui/en/menu_viewer.xml
@@ -448,7 +448,7 @@
parameter="mini_map" />
</menu_item_check>
<menu_item_check
- label="Search"
+ label="Search..."
name="Search"
shortcut="control|F">
<menu_item_check.on_check
diff --git a/indra/newview/skins/default/xui/en/panel_script_limits_my_avatar.xml b/indra/newview/skins/default/xui/en/panel_script_limits_my_avatar.xml
index 629d8567d1..2c2803a503 100644
--- a/indra/newview/skins/default/xui/en/panel_script_limits_my_avatar.xml
+++ b/indra/newview/skins/default/xui/en/panel_script_limits_my_avatar.xml
@@ -8,7 +8,7 @@
left="0"
name="script_limits_my_avatar_panel"
top="0"
- width="480">
+ width="620">
<text
type="string"
length="1"
@@ -19,7 +19,7 @@
name="script_memory"
top_pad="24"
text_color="White"
- width="480">
+ width="620">
Avatar Script Usage
</text>
<text
@@ -31,7 +31,7 @@
left="30"
name="memory_used"
top_delta="18"
- width="480">
+ width="620">
</text>
<text
@@ -43,7 +43,7 @@
left="30"
name="urls_used"
top_delta="18"
- width="480">
+ width="620">
</text>
<text
@@ -56,7 +56,7 @@
name="loading_text"
top="80"
text_color="EmphasisColor"
- width="480">
+ width="620">
Loading...
</text>
<scroll_list
@@ -68,7 +68,7 @@
multi_select="true"
name="scripts_list"
top="100"
- width="460">
+ width="600">
<scroll_list.columns
label="Size (kb)"
name="size"
diff --git a/indra/newview/skins/default/xui/en/panel_script_limits_region_memory.xml b/indra/newview/skins/default/xui/en/panel_script_limits_region_memory.xml
index c5e8bf5803..79bb781bc6 100644
--- a/indra/newview/skins/default/xui/en/panel_script_limits_region_memory.xml
+++ b/indra/newview/skins/default/xui/en/panel_script_limits_region_memory.xml
@@ -8,7 +8,7 @@
name="script_limits_region_memory_panel"
top="0"
left="0"
- width="480">
+ width="620">
<text
type="string"
length="1"
@@ -19,7 +19,7 @@
name="script_memory"
top_pad="24"
text_color="White"
- width="480">
+ width="620">
Parcel Script Memory
</text>
<text
@@ -32,7 +32,7 @@
name="parcels_listed"
top_delta="18"
visible="true"
- width="480">
+ width="620">
</text>
<text
@@ -44,7 +44,7 @@
left="30"
name="memory_used"
top_delta="18"
- width="480">
+ width="620">
</text>
<text
@@ -56,7 +56,7 @@
left="30"
name="urls_used"
top_delta="18"
- width="480">
+ width="620">
</text>
<text
@@ -69,7 +69,7 @@
name="loading_text"
top_delta="12"
text_color="EmphasisColor"
- width="480">
+ width="620">
Loading...
</text>
<scroll_list
@@ -83,7 +83,7 @@
sort_ascending="true"
name="scripts_list"
top_delta="16"
- width="460">
+ width="600">
<scroll_list.columns
label="Size (kb)"
name="size"
@@ -120,23 +120,23 @@
left="10"
width="100" />
<button
- follows="bottom|right"
+ follows="bottom|left"
height="19"
- label="Highlight"
+ label="Return"
visible="false"
- layout="bottomright"
- left="370"
- name="highlight_btn"
+ layout="bottomleft"
+ name="return_btn"
top="34"
+ left_delta="390"
width="100" />
<button
- follows="bottom|right"
+ follows="bottom|left"
height="19"
- label="Return"
+ label="Highlight"
visible="false"
- layout="bottomright"
- name="return_btn"
+ layout="bottomleft"
+ left_delta="105"
+ name="highlight_btn"
top="34"
- left_delta="-105"
width="100" />
</panel>
diff --git a/indra/newview/skins/default/xui/en/strings.xml b/indra/newview/skins/default/xui/en/strings.xml
index 8d84dd47ab..88ad8bbf7b 100644
--- a/indra/newview/skins/default/xui/en/strings.xml
+++ b/indra/newview/skins/default/xui/en/strings.xml
@@ -4200,6 +4200,9 @@ Try enclosing path to the editor with double quotes.
Loading...
</string>
+ <!-- Statistics -->
+ <string name="na">n/a</string>
+
<!-- Presets graphic/camera -->
<string name="preset_combo_label">-Empty list-</string>
<string name="Default">Default</string>