From f08fef5c8e3394a99ff6d635e6d61730ace7c208 Mon Sep 17 00:00:00 2001 From: Eli Linden Date: Wed, 28 Jul 2010 10:43:32 -0700 Subject: CT-575 WIP FR linguistic --- indra/newview/skins/default/xui/fr/strings.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/indra/newview/skins/default/xui/fr/strings.xml b/indra/newview/skins/default/xui/fr/strings.xml index 0a269016f5..ced100207b 100644 --- a/indra/newview/skins/default/xui/fr/strings.xml +++ b/indra/newview/skins/default/xui/fr/strings.xml @@ -1472,7 +1472,7 @@ Solde - Remerciements + Crédits Débits @@ -1787,7 +1787,7 @@ Solde - Remerciements + Crédits Débits -- cgit v1.2.3 From e27170de344a3c4fbeeeb8279f9eb8c7665a9216 Mon Sep 17 00:00:00 2001 From: "Brad Payne (Vir Linden)" Date: Wed, 28 Jul 2010 17:22:03 -0400 Subject: EXT-8221 FIX - fixed invalid array index in a vector --- indra/newview/llnearbychatbar.cpp | 46 +++++++++++++++++++++++++++++---------- indra/newview/llnearbychatbar.h | 2 +- 2 files changed, 36 insertions(+), 12 deletions(-) diff --git a/indra/newview/llnearbychatbar.cpp b/indra/newview/llnearbychatbar.cpp index a300e15edd..8a52cf715f 100644 --- a/indra/newview/llnearbychatbar.cpp +++ b/indra/newview/llnearbychatbar.cpp @@ -317,9 +317,19 @@ void LLGestureComboList::refreshGestures() if (gestures) { - S32 index = gestures->getSelectedValue().asInteger(); - if(index > 0) - gesture = mGestures.at(index); + S32 sel_index = gestures->getFirstSelectedIndex(); + if (sel_index != 0) + { + S32 index = gestures->getSelectedValue().asInteger(); + if (index<0 || index >= (S32)mGestures.size()) + { + llwarns << "out of range gesture access" << llendl; + } + else + { + gesture = mGestures.at(index); + } + } } if(gesture && LLGestureMgr::instance().isGesturePlaying(gesture)) @@ -335,13 +345,13 @@ void LLGestureComboList::onCommitGesture() LLCtrlListInterface* gestures = getListInterface(); if (gestures) { - S32 index = gestures->getFirstSelectedIndex(); - if (index == 0) + S32 sel_index = gestures->getFirstSelectedIndex(); + if (sel_index == 0) { return; } - index = gestures->getSelectedValue().asInteger(); + S32 index = gestures->getSelectedValue().asInteger(); if (mViewAllItemIndex == index) { @@ -357,13 +367,20 @@ void LLGestureComboList::onCommitGesture() return; } - LLMultiGesture* gesture = mGestures.at(index); - if(gesture) + if (index<0 || index >= (S32)mGestures.size()) + { + llwarns << "out of range gesture index" << llendl; + } + else { - LLGestureMgr::instance().playGesture(gesture); - if(!gesture->mReplaceText.empty()) + LLMultiGesture* gesture = mGestures.at(index); + if(gesture) { - LLNearbyChatBar::sendChatFromViewer(gesture->mReplaceText, CHAT_TYPE_NORMAL, FALSE); + LLGestureMgr::instance().playGesture(gesture); + if(!gesture->mReplaceText.empty()) + { + LLNearbyChatBar::sendChatFromViewer(gesture->mReplaceText, CHAT_TYPE_NORMAL, FALSE); + } } } } @@ -374,6 +391,13 @@ LLGestureComboList::~LLGestureComboList() LLGestureMgr::instance().removeObserver(this); } +LLCtrlListInterface* LLGestureComboList::getListInterface() +{ + LLCtrlListInterface *result = mList; + llassert((LLCtrlListInterface*)mList==result); + return mList; +}; + LLNearbyChatBar::LLNearbyChatBar() : LLPanel() , mChatBox(NULL) diff --git a/indra/newview/llnearbychatbar.h b/indra/newview/llnearbychatbar.h index 83c174fd10..0eaa60ce81 100644 --- a/indra/newview/llnearbychatbar.h +++ b/indra/newview/llnearbychatbar.h @@ -68,7 +68,7 @@ public: ~LLGestureComboList(); - LLCtrlListInterface* getListInterface() { return (LLCtrlListInterface*)mList; }; + LLCtrlListInterface* getListInterface(); virtual void showList(); virtual void hideList(); virtual BOOL handleKeyHere(KEY key, MASK mask); -- cgit v1.2.3 From 5e2448347c3b3d071a51a26fc71ea29c779dd7b5 Mon Sep 17 00:00:00 2001 From: Tofu Linden Date: Thu, 29 Jul 2010 12:50:25 +0100 Subject: WEB-1819 FIXED Find always resets to start page (plus many dupes). Enough seesawing, I hope - see WEB-1819 for discussion and the nature of the compromise. Patch by Kitty Barnett, reviewed by my. --- doc/contributions.txt | 1 + indra/newview/llfloatersearch.cpp | 12 ++++-------- indra/newview/llfloatersearch.h | 2 -- 3 files changed, 5 insertions(+), 10 deletions(-) diff --git a/doc/contributions.txt b/doc/contributions.txt index c8125c675f..876da9f210 100644 --- a/doc/contributions.txt +++ b/doc/contributions.txt @@ -329,6 +329,7 @@ Khyota Wulluf VWR-9966 Kitty Barnett VWR-19699 + WEB-1819 Kunnis Basiat VWR-82 VWR-102 diff --git a/indra/newview/llfloatersearch.cpp b/indra/newview/llfloatersearch.cpp index 76caa0cf91..13f2d6bc17 100644 --- a/indra/newview/llfloatersearch.cpp +++ b/indra/newview/llfloatersearch.cpp @@ -113,14 +113,10 @@ BOOL LLFloaterSearch::postBuild() void LLFloaterSearch::onOpen(const LLSD& key) { - search(key); -} - -void LLFloaterSearch::onClose(bool app_quitting) -{ - // tear down the web view so we don't show the previous search - // result when the floater is opened next time - destroy(); + if ( (key.has("category")) || ((mBrowser) && (mBrowser->getCurrentNavUrl().empty())) ) + { + search(key); + } } void LLFloaterSearch::handleMediaEvent(LLPluginClassMedia *self, EMediaEvent event) diff --git a/indra/newview/llfloatersearch.h b/indra/newview/llfloatersearch.h index 0a8d9bbe36..ba817adf7f 100644 --- a/indra/newview/llfloatersearch.h +++ b/indra/newview/llfloatersearch.h @@ -59,8 +59,6 @@ public: /// see search() for details on the key parameter. /*virtual*/ void onOpen(const LLSD& key); - /*virtual*/ void onClose(bool app_quitting); - /// perform a search with the specific search term. /// The key should be a map that can contain the following keys: /// - "id": specifies the text phrase to search for -- cgit v1.2.3 From 2e520cb849b735402073369d9f10e1a8ed426c2f Mon Sep 17 00:00:00 2001 From: Tofu Linden Date: Thu, 29 Jul 2010 13:15:24 +0100 Subject: WEB-1819 PARTIAL follow-up tweak. this makes a new externally-invoked search blank-out the old search until it starts really loading. --- indra/newview/llfloatersearch.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/indra/newview/llfloatersearch.cpp b/indra/newview/llfloatersearch.cpp index 13f2d6bc17..08a0615b33 100644 --- a/indra/newview/llfloatersearch.cpp +++ b/indra/newview/llfloatersearch.cpp @@ -115,6 +115,10 @@ void LLFloaterSearch::onOpen(const LLSD& key) { if ( (key.has("category")) || ((mBrowser) && (mBrowser->getCurrentNavUrl().empty())) ) { + // new search triggered - blank the page while loading, instead of + // temporarily showing stale results + mBrowser->navigateTo("about:blank"); + search(key); } } -- cgit v1.2.3 From 45adf1d6124e72be55a5764a72a58cde8b7c85fe Mon Sep 17 00:00:00 2001 From: Vadim Savchuk Date: Thu, 29 Jul 2010 17:48:41 +0300 Subject: EXT-8501 FIXED Check menu items always looked as checked. Reason: Check menu items (instances of LLMenuItemCheckGL) had used LLUICtrl::getValue() to know whether they should draw the checkmark. Recently this was broken when getValue() was overriden in LLMenuItemCallGL to return a string. Fix: Overriden getValue() in LLMenuItemCheckGL to return a boolean value, not a string. Reviewed by Mike Antipov at https://codereview.productengine.com/secondlife/r/821/ --HG-- branch : product-engine --- indra/llui/llmenugl.cpp | 9 +++++++++ indra/llui/llmenugl.h | 1 + indra/newview/llviewermenu.cpp | 2 ++ 3 files changed, 12 insertions(+) diff --git a/indra/llui/llmenugl.cpp b/indra/llui/llmenugl.cpp index 8610d79142..12007f7b52 100644 --- a/indra/llui/llmenugl.cpp +++ b/indra/llui/llmenugl.cpp @@ -928,6 +928,15 @@ void LLMenuItemCheckGL::setValue(const LLSD& value) } } +//virtual +LLSD LLMenuItemCheckGL::getValue() const +{ + // Get our boolean value from the view model. + // If we don't override this method then the implementation from + // LLMenuItemGL will return a string. (EXT-8501) + return LLUICtrl::getValue(); +} + // called to rebuild the draw label void LLMenuItemCheckGL::buildDrawLabel( void ) { diff --git a/indra/llui/llmenugl.h b/indra/llui/llmenugl.h index a484405eaa..bf40163dac 100644 --- a/indra/llui/llmenugl.h +++ b/indra/llui/llmenugl.h @@ -322,6 +322,7 @@ public: virtual void onCommit( void ); virtual void setValue(const LLSD& value); + virtual LLSD getValue() const; // called to rebuild the draw label virtual void buildDrawLabel( void ); diff --git a/indra/newview/llviewermenu.cpp b/indra/newview/llviewermenu.cpp index df8e127b1f..23e502c76f 100644 --- a/indra/newview/llviewermenu.cpp +++ b/indra/newview/llviewermenu.cpp @@ -2411,6 +2411,8 @@ static void init_default_item_label(const std::string& item_name) boost::unordered_map::iterator it = sDefaultItemLabels.find(item_name); if (it == sDefaultItemLabels.end()) { + // *NOTE: This will not work for items of type LLMenuItemCheckGL because they return boolean value + // (doesn't seem to matter much ATM). LLStringExplicit default_label = gMenuHolder->childGetValue(item_name).asString(); if (!default_label.empty()) { -- cgit v1.2.3 From 018065aad27b544b62cdaef660f7e39fce616ddf Mon Sep 17 00:00:00 2001 From: Tofu Linden Date: Thu, 29 Jul 2010 19:32:07 +0100 Subject: Backed out changeset 61a2e2a8fb75 --- indra/newview/llfloatersearch.cpp | 4 ---- 1 file changed, 4 deletions(-) diff --git a/indra/newview/llfloatersearch.cpp b/indra/newview/llfloatersearch.cpp index 08a0615b33..13f2d6bc17 100644 --- a/indra/newview/llfloatersearch.cpp +++ b/indra/newview/llfloatersearch.cpp @@ -115,10 +115,6 @@ void LLFloaterSearch::onOpen(const LLSD& key) { if ( (key.has("category")) || ((mBrowser) && (mBrowser->getCurrentNavUrl().empty())) ) { - // new search triggered - blank the page while loading, instead of - // temporarily showing stale results - mBrowser->navigateTo("about:blank"); - search(key); } } -- cgit v1.2.3 From 1e44674f309ae28bbfad032e9461bbee40062b69 Mon Sep 17 00:00:00 2001 From: Tofu Linden Date: Thu, 29 Jul 2010 19:32:20 +0100 Subject: Backed out changeset b4c03b57a34f --- doc/contributions.txt | 1 - indra/newview/llfloatersearch.cpp | 12 ++++++++---- indra/newview/llfloatersearch.h | 2 ++ 3 files changed, 10 insertions(+), 5 deletions(-) diff --git a/doc/contributions.txt b/doc/contributions.txt index 876da9f210..c8125c675f 100644 --- a/doc/contributions.txt +++ b/doc/contributions.txt @@ -329,7 +329,6 @@ Khyota Wulluf VWR-9966 Kitty Barnett VWR-19699 - WEB-1819 Kunnis Basiat VWR-82 VWR-102 diff --git a/indra/newview/llfloatersearch.cpp b/indra/newview/llfloatersearch.cpp index 13f2d6bc17..76caa0cf91 100644 --- a/indra/newview/llfloatersearch.cpp +++ b/indra/newview/llfloatersearch.cpp @@ -113,10 +113,14 @@ BOOL LLFloaterSearch::postBuild() void LLFloaterSearch::onOpen(const LLSD& key) { - if ( (key.has("category")) || ((mBrowser) && (mBrowser->getCurrentNavUrl().empty())) ) - { - search(key); - } + search(key); +} + +void LLFloaterSearch::onClose(bool app_quitting) +{ + // tear down the web view so we don't show the previous search + // result when the floater is opened next time + destroy(); } void LLFloaterSearch::handleMediaEvent(LLPluginClassMedia *self, EMediaEvent event) diff --git a/indra/newview/llfloatersearch.h b/indra/newview/llfloatersearch.h index ba817adf7f..0a8d9bbe36 100644 --- a/indra/newview/llfloatersearch.h +++ b/indra/newview/llfloatersearch.h @@ -59,6 +59,8 @@ public: /// see search() for details on the key parameter. /*virtual*/ void onOpen(const LLSD& key); + /*virtual*/ void onClose(bool app_quitting); + /// perform a search with the specific search term. /// The key should be a map that can contain the following keys: /// - "id": specifies the text phrase to search for -- cgit v1.2.3