summaryrefslogtreecommitdiff
path: root/indra/llui
diff options
context:
space:
mode:
authorJames Cook <james@lindenlab.com>2009-11-23 18:16:03 -0800
committerJames Cook <james@lindenlab.com>2009-11-23 18:16:03 -0800
commit6634d3c1ccbe13d3c0cdd17b60628eabe633ea7d (patch)
treeab6b994092906e0ddf0d377cc81f6f19d27baac2 /indra/llui
parent2ede27a5e266794fc3d034f12344a580260a3546 (diff)
Add damage % text to nav bar, clip text entry to avoid overlapping icons
Fixed includes of llmenugl.h / llnotifications.h Note: Clipping is incorrect, I think due to line editor bug.
Diffstat (limited to 'indra/llui')
-rw-r--r--indra/llui/lllineeditor.cpp13
-rw-r--r--indra/llui/lllineeditor.h3
2 files changed, 16 insertions, 0 deletions
diff --git a/indra/llui/lllineeditor.cpp b/indra/llui/lllineeditor.cpp
index 406c77a365..bd5734312a 100644
--- a/indra/llui/lllineeditor.cpp
+++ b/indra/llui/lllineeditor.cpp
@@ -323,6 +323,19 @@ void LLLineEditor::setMaxTextLength(S32 max_text_length)
mMaxLengthBytes = max_len;
}
+void LLLineEditor::getTextPadding(S32 *left, S32 *right)
+{
+ *left = mTextPadLeft;
+ *right = mTextPadRight;
+}
+
+void LLLineEditor::setTextPadding(S32 left, S32 right)
+{
+ mTextPadLeft = left;
+ mTextPadRight = right;
+ updateTextPadding();
+}
+
void LLLineEditor::updateTextPadding()
{
static LLUICachedControl<S32> line_editor_hpad ("UILineEditorHPad", 0);
diff --git a/indra/llui/lllineeditor.h b/indra/llui/lllineeditor.h
index 4474963b1a..4c4b00094d 100644
--- a/indra/llui/lllineeditor.h
+++ b/indra/llui/lllineeditor.h
@@ -226,6 +226,9 @@ public:
void setKeystrokeCallback(callback_t callback, void* user_data);
void setMaxTextLength(S32 max_text_length);
+ // Manipulate left and right padding for text
+ void getTextPadding(S32 *left, S32 *right);
+ void setTextPadding(S32 left, S32 right);
// Prevalidation controls which keystrokes can affect the editor
void setPrevalidate( LLLinePrevalidateFunc func );