diff --git a/editor/libeditor/text/nsEditorEventListeners.cpp b/editor/libeditor/text/nsEditorEventListeners.cpp index ec2b4c56466..522e6c5b191 100644 --- a/editor/libeditor/text/nsEditorEventListeners.cpp +++ b/editor/libeditor/text/nsEditorEventListeners.cpp @@ -1112,6 +1112,7 @@ nsTextEditorFocusListener::Focus(nsIDOMEvent* aEvent) // turn on selection and caret if (mEditor) { + nsCOMPtr imeEditor = do_QueryInterface(mEditor); PRUint32 flags; mEditor->GetFlags(&flags); if (! (flags & nsIPlaintextEditor::eEditorDisabledMask)) @@ -1164,7 +1165,6 @@ nsTextEditorFocusListener::Focus(nsIDOMEvent* aEvent) } } - nsCOMPtr imeEditor = do_QueryInterface(mEditor); if (imeEditor) imeEditor->NotifyIMEOnFocus(); }