path: root/src
diff options
authorSamuel Rødal <>2012-03-19 14:05:41 +0100
committerQt by Nokia <>2012-03-22 16:13:21 +0100
commit787da35eb84a19f9c2b8d59b7ab93e78dd5e7cfd (patch)
tree2d70f862de52276f28275c4aafc99f1ae079fe55 /src
parent7e90df7bf5aafd09ea5ed8bcc370db6a8912d173 (diff)
Fixed QInputMethod API to use isVisible() instead of visible().
Deprecate the old API for now as not to break existing usages. Change-Id: I7abbbbe8a34951282537a9d74cded03743f44df7 Reviewed-by: Pekka Vuorela <> Reviewed-by: Lars Knoll <>
Diffstat (limited to 'src')
2 files changed, 7 insertions, 3 deletions
diff --git a/src/gui/kernel/qinputmethod.cpp b/src/gui/kernel/qinputmethod.cpp
index 9e724446ff..23ab8535a0 100644
--- a/src/gui/kernel/qinputmethod.cpp
+++ b/src/gui/kernel/qinputmethod.cpp
@@ -215,7 +215,7 @@ void QInputMethod::hide()
\sa show(), hide()
-bool QInputMethod::visible() const
+bool QInputMethod::isVisible() const
Q_D(const QInputMethod);
QPlatformInputContext *ic = d->platformInputContext();
diff --git a/src/gui/kernel/qinputmethod.h b/src/gui/kernel/qinputmethod.h
index 0acddc05e2..92ae016b97 100644
--- a/src/gui/kernel/qinputmethod.h
+++ b/src/gui/kernel/qinputmethod.h
@@ -62,7 +62,7 @@ class Q_GUI_EXPORT QInputMethod : public QObject
Q_PROPERTY(QObject *inputItem READ inputItem WRITE setInputItem NOTIFY inputItemChanged)
Q_PROPERTY(QRectF cursorRectangle READ cursorRectangle NOTIFY cursorRectangleChanged)
Q_PROPERTY(QRectF keyboardRectangle READ keyboardRectangle NOTIFY keyboardRectangleChanged)
- Q_PROPERTY(bool visible READ visible NOTIFY visibleChanged)
+ Q_PROPERTY(bool visible READ isVisible NOTIFY visibleChanged)
Q_PROPERTY(bool animating READ isAnimating NOTIFY animatingChanged)
Q_PROPERTY(QLocale locale READ locale NOTIFY localeChanged)
Q_PROPERTY(Qt::LayoutDirection inputDirection READ inputDirection NOTIFY inputDirectionChanged)
@@ -89,7 +89,11 @@ public:
- bool visible() const;
+ QT_DEPRECATED bool visible() const { return isVisible(); }
+ bool isVisible() const;
void setVisible(bool visible);
bool isAnimating() const;