aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/linden/indra/llui/lllineeditor.h
diff options
context:
space:
mode:
authorthickbrick2010-09-24 02:29:58 +0200
committerthickbrick2010-09-25 13:29:36 +0200
commitf6f5603b946a56059987071b7151a1c2e64c45d5 (patch)
treeb56773f75435cc58db0486b86e8617aa538f7847 /linden/indra/llui/lllineeditor.h
parentFix LLTextEditor context menu translator returning "()" when nothing is selec... (diff)
downloadmeta-impy-f6f5603b946a56059987071b7151a1c2e64c45d5.zip
meta-impy-f6f5603b946a56059987071b7151a1c2e64c45d5.tar.gz
meta-impy-f6f5603b946a56059987071b7151a1c2e64c45d5.tar.bz2
meta-impy-f6f5603b946a56059987071b7151a1c2e64c45d5.tar.xz
Fix LLLineEditor context menu translator returning "()" when nothing is selected.
New behavior is to translate the word under the mouse if nothing is selected.
Diffstat (limited to 'linden/indra/llui/lllineeditor.h')
-rw-r--r--linden/indra/llui/lllineeditor.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/linden/indra/llui/lllineeditor.h b/linden/indra/llui/lllineeditor.h
index 147b232..af37f62 100644
--- a/linden/indra/llui/lllineeditor.h
+++ b/linden/indra/llui/lllineeditor.h
@@ -107,6 +107,7 @@ public:
107 }; 107 };
108 108
109 virtual void spellReplace(SpellMenuBind* spellData); 109 virtual void spellReplace(SpellMenuBind* spellData);
110 virtual void translationReplace(const std::string &translation, const S32 orig_start, const S32 orig_length);
110 virtual void insert(std::string what,S32 wher); 111 virtual void insert(std::string what,S32 wher);
111 112
112 // LLEditMenuHandler overrides 113 // LLEditMenuHandler overrides
@@ -215,6 +216,7 @@ public:
215 // get the cursor position of the beginning/end of the prev/next word in the text 216 // get the cursor position of the beginning/end of the prev/next word in the text
216 S32 prevWordPos(S32 cursorPos) const; 217 S32 prevWordPos(S32 cursorPos) const;
217 S32 nextWordPos(S32 cursorPos) const; 218 S32 nextWordPos(S32 cursorPos) const;
219 BOOL getWordBoundriesAt(const S32 at, S32* word_begin, S32* word_length) const;
218 220
219 BOOL hasSelection() const { return (mSelectionStart != mSelectionEnd); } 221 BOOL hasSelection() const { return (mSelectionStart != mSelectionEnd); }
220 void startSelection(); 222 void startSelection();
@@ -298,6 +300,7 @@ protected:
298 LLFrameTimer mSpellTimer; 300 LLFrameTimer mSpellTimer;
299 //to keep track of what we have to remove before showing menu 301 //to keep track of what we have to remove before showing menu
300 std::vector<SpellMenuBind* > suggestionMenuItems; 302 std::vector<SpellMenuBind* > suggestionMenuItems;
303 S32 mLastContextMenuX;
301 304
302 // line history support: 305 // line history support:
303 BOOL mHaveHistory; // flag for enabled line history 306 BOOL mHaveHistory; // flag for enabled line history