summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMerov Linden <merov@lindenlab.com>2013-03-06 18:44:02 -0800
committerMerov Linden <merov@lindenlab.com>2013-03-06 18:44:02 -0800
commit4458986cf22a749d3387085a70ea07930519b8ab (patch)
treeeec3daa0ed42e858b12a90a9e83ebdc969e58c88
parente42e6bc68ae0b0f7a0bd2ca6f500ba783cc201a3 (diff)
CHUI-705 : Fixed! Force hide context menu when deleting line editor widget
-rw-r--r--indra/llui/lllineeditor.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/indra/llui/lllineeditor.cpp b/indra/llui/lllineeditor.cpp
index 2e64be89fa..6976b06a92 100644
--- a/indra/llui/lllineeditor.cpp
+++ b/indra/llui/lllineeditor.cpp
@@ -202,6 +202,14 @@ LLLineEditor::LLLineEditor(const LLLineEditor::Params& p)
LLLineEditor::~LLLineEditor()
{
mCommitOnFocusLost = FALSE;
+
+ // Make sure no context menu linger around once the widget is deleted
+ LLContextMenu* menu = static_cast<LLContextMenu*>(mContextMenuHandle.get());
+ if (menu)
+ {
+ menu->hide();
+ }
+ setContextMenu(NULL);
// calls onCommit() while LLLineEditor still valid
gFocusMgr.releaseFocusIfNeeded( this );