summaryrefslogtreecommitdiff
path: root/indra/llui
diff options
context:
space:
mode:
authormaksymsproductengine <maksymsproductengine@lindenlab.com>2013-05-14 01:30:23 +0300
committermaksymsproductengine <maksymsproductengine@lindenlab.com>2013-05-14 01:30:23 +0300
commit36a51f4927eb1bba511b73613a7f9baeddf467fd (patch)
tree07e8cbc2aab91a5d15b0af4e72830961b72429ad /indra/llui
parent5ff0d34ab71a6795b7314603272035f72afe2a17 (diff)
CHUI-958 FIXED Log spam: "drawtext: Ran off Segmentation End" and To field in nearby chat blank when selected
Diffstat (limited to 'indra/llui')
-rw-r--r--indra/llui/llchatentry.cpp12
-rw-r--r--indra/llui/llchatentry.h2
-rw-r--r--indra/llui/lltexteditor.cpp7
-rw-r--r--indra/llui/lltexteditor.h1
4 files changed, 20 insertions, 2 deletions
diff --git a/indra/llui/llchatentry.cpp b/indra/llui/llchatentry.cpp
index f6c4b69308..416c3e65e4 100644
--- a/indra/llui/llchatentry.cpp
+++ b/indra/llui/llchatentry.cpp
@@ -163,6 +163,18 @@ bool LLChatEntry::useLabel()
return !getLength() && !mLabel.empty();
}
+void LLChatEntry::onFocusReceived()
+{
+ LLUICtrl::onFocusReceived();
+ updateAllowingLanguageInput();
+}
+
+void LLChatEntry::onFocusLost()
+{
+ LLTextEditor::focusLostHelper();
+ LLUICtrl::onFocusLost();
+}
+
BOOL LLChatEntry::handleSpecialKey(const KEY key, const MASK mask)
{
BOOL handled = FALSE;
diff --git a/indra/llui/llchatentry.h b/indra/llui/llchatentry.h
index a20a505ae1..3a5e87e8c8 100644
--- a/indra/llui/llchatentry.h
+++ b/indra/llui/llchatentry.h
@@ -62,6 +62,8 @@ public:
virtual void draw();
virtual void onCommit();
+ /*virtual*/ void onFocusReceived();
+ /*virtual*/ void onFocusLost();
void enableSingleLineMode(bool single_line_mode);
boost::signals2::connection setTextExpandedCallback(const commit_signal_t::slot_type& cb);
diff --git a/indra/llui/lltexteditor.cpp b/indra/llui/lltexteditor.cpp
index 834f213097..09caec7b73 100644
--- a/indra/llui/lltexteditor.cpp
+++ b/indra/llui/lltexteditor.cpp
@@ -1964,8 +1964,7 @@ void LLTextEditor::onFocusReceived()
updateAllowingLanguageInput();
}
-// virtual, from LLView
-void LLTextEditor::onFocusLost()
+void LLTextEditor::focusLostHelper()
{
updateAllowingLanguageInput();
@@ -1982,7 +1981,11 @@ void LLTextEditor::onFocusLost()
// Make sure cursor is shown again
getWindow()->showCursorFromMouseMove();
+}
+void LLTextEditor::onFocusLost()
+{
+ focusLostHelper();
LLTextBase::onFocusLost();
}
diff --git a/indra/llui/lltexteditor.h b/indra/llui/lltexteditor.h
index 969e072704..13f63a17ef 100644
--- a/indra/llui/lltexteditor.h
+++ b/indra/llui/lltexteditor.h
@@ -255,6 +255,7 @@ protected:
S32 insert(S32 pos, const LLWString &wstr, bool group_with_next_op, LLTextSegmentPtr segment);
S32 remove(S32 pos, S32 length, bool group_with_next_op);
+ void focusLostHelper();
void updateAllowingLanguageInput();
BOOL hasPreeditString() const;