summaryrefslogtreecommitdiff
path: root/indra/llui
diff options
context:
space:
mode:
authorAlexander Gavriliuk <alexandrgproductengine@lindenlab.com>2023-07-13 21:18:22 +0200
committerGuru <alexandrgproductengine@lindenlab.com>2023-07-13 22:13:31 +0200
commit1fe007abef6eeceefb0dc720b4a5ecb4505ede88 (patch)
tree52bd2189940592af109c81734c0ab452193ee79c /indra/llui
parent8b718cbc2edc1f18bfa0cc0a76899fcade149813 (diff)
SL-20001 EmojiPicker - make the preview to be a panel instead of a button
Diffstat (limited to 'indra/llui')
-rw-r--r--indra/llui/lllineeditor.cpp4
-rw-r--r--indra/llui/lllineeditor.h2
2 files changed, 5 insertions, 1 deletions
diff --git a/indra/llui/lllineeditor.cpp b/indra/llui/lllineeditor.cpp
index 940cf398c0..7d13d731e2 100644
--- a/indra/llui/lllineeditor.cpp
+++ b/indra/llui/lllineeditor.cpp
@@ -89,6 +89,7 @@ LLLineEditor::Params::Params()
background_image_disabled("background_image_disabled"),
background_image_focused("background_image_focused"),
bg_image_always_focused("bg_image_always_focused", false),
+ show_label_focused("show_label_focused", false),
select_on_focus("select_on_focus", false),
revert_on_esc("revert_on_esc", true),
spellcheck("spellcheck", false),
@@ -152,6 +153,7 @@ LLLineEditor::LLLineEditor(const LLLineEditor::Params& p)
mBgImageDisabled( p.background_image_disabled ),
mBgImageFocused( p.background_image_focused ),
mShowImageFocused( p.bg_image_always_focused ),
+ mShowLabelFocused( p.show_label_focused ),
mUseBgColor(p.use_bg_color),
mHaveHistory(FALSE),
mReplaceNewlinesWithSpaces( TRUE ),
@@ -2068,7 +2070,7 @@ void LLLineEditor::draw()
//draw label if no text is provided
//but we should draw it in a different color
//to give indication that it is not text you typed in
- if (0 == mText.length() && mReadOnly)
+ if (0 == mText.length() && (mReadOnly || mShowLabelFocused))
{
mGLFont->render(mLabel.getWString(), 0,
mTextLeftEdge, (F32)text_bottom,
diff --git a/indra/llui/lllineeditor.h b/indra/llui/lllineeditor.h
index ae4e05c065..624371ebda 100644
--- a/indra/llui/lllineeditor.h
+++ b/indra/llui/lllineeditor.h
@@ -91,6 +91,7 @@ public:
commit_on_focus_lost,
ignore_tab,
bg_image_always_focused,
+ show_label_focused,
is_password,
use_bg_color;
@@ -395,6 +396,7 @@ protected:
BOOL mReadOnly;
BOOL mShowImageFocused;
+ BOOL mShowLabelFocused;
bool mUseBgColor;