emailuis/nmailuiwidgets/src/nmeditortextedit.cpp
changeset 75 47d84de1c893
parent 59 16ed8d08d0b1
--- a/emailuis/nmailuiwidgets/src/nmeditortextedit.cpp	Fri Sep 17 08:27:21 2010 +0300
+++ b/emailuis/nmailuiwidgets/src/nmeditortextedit.cpp	Mon Oct 04 00:05:37 2010 +0300
@@ -154,6 +154,27 @@
 }
 
 /*!
+ *  Returns true if this widget has the input focus.
+ */
+bool NmEditorTextEdit::hasInputFocus() const
+{
+    NM_FUNCTION;
+
+    bool ret = false;
+    
+    HbInputMethod *inputMethod = HbInputMethod::activeInputMethod();
+    
+    if (inputMethod) {
+        HbInputFocusObject *focusObject = inputMethod->focusObject();
+        if (focusObject) {
+            ret = (focusObject->object() == this);
+        }
+    }
+    
+    return ret; 
+}
+
+/*!
  *  Returns the rectangle for the cursor.
  */
 QRectF NmEditorTextEdit::rectForCursorPosition() const