summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
Diffstat (limited to 'indra')
-rw-r--r--indra/llui/llloadingindicator.cpp3
-rw-r--r--indra/llui/llui.cpp1
-rw-r--r--indra/llui/lluictrlfactory.cpp20
-rw-r--r--indra/llui/lluictrlfactory.h5
-rw-r--r--indra/newview/llinventorybridge.cpp16
-rw-r--r--indra/newview/llinventoryfilter.cpp4
-rw-r--r--indra/newview/llscrollingpanelparam.cpp4
-rw-r--r--indra/newview/skins/default/xui/en/menu_inventory.xml17
8 files changed, 37 insertions, 33 deletions
diff --git a/indra/llui/llloadingindicator.cpp b/indra/llui/llloadingindicator.cpp
index f8b029e19c..2ad5c5a530 100644
--- a/indra/llui/llloadingindicator.cpp
+++ b/indra/llui/llloadingindicator.cpp
@@ -41,7 +41,8 @@
#include "lluictrlfactory.h"
#include "lluiimage.h"
-static LLDefaultChildRegistry::Register<LLLoadingIndicator> r("loading_indicator");
+// registered in llui.cpp to avoid being left out by MS linker
+//static LLDefaultChildRegistry::Register<LLLoadingIndicator> r("loading_indicator");
///////////////////////////////////////////////////////////////////////////////
// LLLoadingIndicator::Data class
diff --git a/indra/llui/llui.cpp b/indra/llui/llui.cpp
index dff1cb93e7..7f9dca08d2 100644
--- a/indra/llui/llui.cpp
+++ b/indra/llui/llui.cpp
@@ -97,7 +97,6 @@ static LLDefaultChildRegistry::Register<LLFlyoutButton> register_flyout_button("
static LLDefaultChildRegistry::Register<LLSearchEditor> register_search_editor("search_editor");
// register other widgets which otherwise may not be linked in
-static LLDefaultChildRegistry::Register<LLMenuButton> register_menu_button("menu_button");
static LLDefaultChildRegistry::Register<LLLoadingIndicator> register_loading_indicator("loading_indicator");
diff --git a/indra/llui/lluictrlfactory.cpp b/indra/llui/lluictrlfactory.cpp
index 6b337e0d74..a46d961709 100644
--- a/indra/llui/lluictrlfactory.cpp
+++ b/indra/llui/lluictrlfactory.cpp
@@ -452,14 +452,22 @@ void LLUICtrlFactory::registerWidget(const std::type_info* widget_type, const st
{
// associate parameter block type with template .xml file
std::string* existing_tag = LLWidgetNameRegistry::instance().getValue(param_block_type);
- if (existing_tag != NULL && *existing_tag != tag)
+ if (existing_tag != NULL)
{
- std::cerr << "Duplicate entry for T::Params, try creating empty param block in derived classes that inherit T::Params" << std::endl;
- // forcing crash here
- char* foo = 0;
- *foo = 1;
+ if(*existing_tag != tag)
+ {
+ std::cerr << "Duplicate entry for T::Params, try creating empty param block in derived classes that inherit T::Params" << std::endl;
+ // forcing crash here
+ char* foo = 0;
+ *foo = 1;
+ }
+ else
+ {
+ // widget already registered
+ return;
+ }
}
- LLWidgetNameRegistry ::instance().defaultRegistrar().add(param_block_type, tag);
+ LLWidgetNameRegistry::instance().defaultRegistrar().add(param_block_type, tag);
// associate widget type with factory function
LLDefaultWidgetRegistry::instance().defaultRegistrar().add(widget_type, creator_func);
//FIXME: comment this in when working on schema generation
diff --git a/indra/llui/lluictrlfactory.h b/indra/llui/lluictrlfactory.h
index 7da96ffce3..c99acee48e 100644
--- a/indra/llui/lluictrlfactory.h
+++ b/indra/llui/lluictrlfactory.h
@@ -373,8 +373,9 @@ LLChildRegistry<DERIVED>::Register<T>::Register(const char* tag, LLWidgetCreator
LLUICtrlFactory::instance().registerWidget(&typeid(T), &typeid(typename T::Params), &LLUICtrlFactory::createDefaultWidget<T>, tag);
// since registry_t depends on T, do this in line here
- typedef typename T::child_registry_t registry_t;
- LLChildRegistryRegistry::instance().defaultRegistrar().add(&typeid(T), registry_t::instance());
+ // TODO: uncomment this for schema generation
+ //typedef typename T::child_registry_t registry_t;
+ //LLChildRegistryRegistry::instance().defaultRegistrar().add(&typeid(T), registry_t::instance());
}
diff --git a/indra/newview/llinventorybridge.cpp b/indra/newview/llinventorybridge.cpp
index 2cc61a69c1..96dba5717a 100644
--- a/indra/newview/llinventorybridge.cpp
+++ b/indra/newview/llinventorybridge.cpp
@@ -4055,13 +4055,13 @@ void LLObjectBridge::buildContextMenu(LLMenuGL& menu, U32 flags)
if( get_is_item_worn( mUUID ) )
{
- items.push_back(std::string("Attach Separator"));
+ items.push_back(std::string("Wearable And Object Separator"));
items.push_back(std::string("Detach From Yourself"));
}
else if (!isItemInTrash() && !isLinkedObjectInTrash() && !isLinkedObjectMissing() && !isCOFFolder())
{
- items.push_back(std::string("Attach Separator"));
- items.push_back(std::string("Object Wear"));
+ items.push_back(std::string("Wearable And Object Separator"));
+ items.push_back(std::string("Wearable And Object Wear"));
items.push_back(std::string("Attach To"));
items.push_back(std::string("Attach To HUD"));
// commented out for DEV-32347
@@ -4069,7 +4069,7 @@ void LLObjectBridge::buildContextMenu(LLMenuGL& menu, U32 flags)
if (!gAgentAvatarp->canAttachMoreObjects())
{
- disabled_items.push_back(std::string("Object Wear"));
+ disabled_items.push_back(std::string("Wearable And Object Wear"));
disabled_items.push_back(std::string("Attach To"));
disabled_items.push_back(std::string("Attach To HUD"));
}
@@ -4411,7 +4411,7 @@ void LLWearableBridge::buildContextMenu(LLMenuGL& menu, U32 flags)
getClipboardEntries(true, items, disabled_items, flags);
- items.push_back(std::string("Wearable Separator"));
+ items.push_back(std::string("Wearable And Object Separator"));
items.push_back(std::string("Wearable Edit"));
@@ -4422,7 +4422,7 @@ void LLWearableBridge::buildContextMenu(LLMenuGL& menu, U32 flags)
// Don't allow items to be worn if their baseobj is in the trash.
if (isLinkedObjectInTrash() || isLinkedObjectMissing() || isCOFFolder())
{
- disabled_items.push_back(std::string("Wearable Wear"));
+ disabled_items.push_back(std::string("Wearable And Object Wear"));
disabled_items.push_back(std::string("Wearable Add"));
disabled_items.push_back(std::string("Wearable Edit"));
}
@@ -4438,12 +4438,12 @@ void LLWearableBridge::buildContextMenu(LLMenuGL& menu, U32 flags)
case LLAssetType::AT_BODYPART:
if (get_is_item_worn(item->getUUID()))
{
- disabled_items.push_back(std::string("Wearable Wear"));
+ disabled_items.push_back(std::string("Wearable And Object Wear"));
disabled_items.push_back(std::string("Wearable Add"));
}
else
{
- items.push_back(std::string("Wearable Wear"));
+ items.push_back(std::string("Wearable And Object Wear"));
items.push_back(std::string("Wearable Add"));
disabled_items.push_back(std::string("Take Off"));
disabled_items.push_back(std::string("Wearable Edit"));
diff --git a/indra/newview/llinventoryfilter.cpp b/indra/newview/llinventoryfilter.cpp
index f8241320cf..5dcf0680db 100644
--- a/indra/newview/llinventoryfilter.cpp
+++ b/indra/newview/llinventoryfilter.cpp
@@ -234,10 +234,12 @@ BOOL LLInventoryFilter::checkAgainstPermissions(const LLFolderViewItem* item) co
BOOL LLInventoryFilter::checkAgainstFilterLinks(const LLFolderViewItem* item) const
{
const LLFolderViewEventListener* listener = item->getListener();
- if (!listener) return FALSE;
+ if (!listener) return TRUE;
const LLUUID object_id = listener->getUUID();
const LLInventoryObject *object = gInventory.getObject(object_id);
+ if (!object) return TRUE;
+
const BOOL is_link = object->getIsLinkType();
if (is_link && (mFilterOps.mFilterLinks == FILTERLINK_EXCLUDE_LINKS))
return FALSE;
diff --git a/indra/newview/llscrollingpanelparam.cpp b/indra/newview/llscrollingpanelparam.cpp
index 6f5238f0a1..36d581a41a 100644
--- a/indra/newview/llscrollingpanelparam.cpp
+++ b/indra/newview/llscrollingpanelparam.cpp
@@ -209,6 +209,7 @@ void LLScrollingPanelParam::onSliderMoved(LLUICtrl* ctrl, void* userdata)
if (current_weight != new_weight )
{
self->mWearable->setVisualParamWeight( param->getID(), new_weight, FALSE );
+ self->mWearable->writeToAvatar();
gAgentAvatarp->updateVisualParams();
}
}
@@ -298,6 +299,7 @@ void LLScrollingPanelParam::onHintHeldDown( LLVisualParamHint* hint )
&& new_percent < slider->getMaxValue())
{
mWearable->setVisualParamWeight( hint->getVisualParam()->getID(), new_weight, FALSE);
+ mWearable->writeToAvatar();
gAgentAvatarp->updateVisualParams();
slider->setValue( weightToPercent( new_weight ) );
@@ -330,6 +332,7 @@ void LLScrollingPanelParam::onHintMinMouseUp( void* userdata )
&& new_percent < slider->getMaxValue())
{
self->mWearable->setVisualParamWeight(hint->getVisualParam()->getID(), new_weight, FALSE);
+ self->mWearable->writeToAvatar();
slider->setValue( self->weightToPercent( new_weight ) );
}
}
@@ -363,6 +366,7 @@ void LLScrollingPanelParam::onHintMaxMouseUp( void* userdata )
&& new_percent < slider->getMaxValue())
{
self->mWearable->setVisualParamWeight(hint->getVisualParam()->getID(), new_weight, FALSE);
+ self->mWearable->writeToAvatar();
slider->setValue( self->weightToPercent( new_weight ) );
}
}
diff --git a/indra/newview/skins/default/xui/en/menu_inventory.xml b/indra/newview/skins/default/xui/en/menu_inventory.xml
index 221457ac1f..5c19f1932d 100644
--- a/indra/newview/skins/default/xui/en/menu_inventory.xml
+++ b/indra/newview/skins/default/xui/en/menu_inventory.xml
@@ -606,7 +606,7 @@
</menu_item_call>
<menu_item_separator
layout="topleft"
- name="Attach Separator"/>
+ name="Wearable And Object Separator"/>
<menu_item_call
label="Detach From Yourself"
layout="topleft"
@@ -629,10 +629,10 @@
<menu_item_call
label="Wear"
layout="topleft"
- name="Object Wear">
+ name="Wearable And Object Wear">
<menu_item_call.on_click
function="Inventory.DoToSelected"
- parameter="attach" />
+ parameter="wear" />
</menu_item_call>
<menu
label="Attach To"
@@ -642,9 +642,6 @@
label="Attach To HUD"
layout="topleft"
name="Attach To HUD" />
- <menu_item_separator
- layout="topleft"
- name="Wearable Separator"/>
<menu_item_call
label="Edit"
layout="topleft"
@@ -654,14 +651,6 @@
parameter="edit" />
</menu_item_call>
<menu_item_call
- label="Wear"
- layout="topleft"
- name="Wearable Wear">
- <menu_item_call.on_click
- function="Inventory.DoToSelected"
- parameter="wear" />
- </menu_item_call>
- <menu_item_call
label="Add"
layout="topleft"
name="Wearable Add">