summaryrefslogtreecommitdiffstats
path: root/src/gui/kernel/qwindow.cpp
diff options
context:
space:
mode:
authorSamuel Rødal <samuel.rodal@digia.com>2012-12-05 17:38:58 +0100
committerThe Qt Project <gerrit-noreply@qt-project.org>2012-12-06 20:37:13 +0100
commit7da7bbcd874197054df5e5691d41d4e2dbe55f4a (patch)
tree4886798813f949e2b96f4341d36704485a1c6656 /src/gui/kernel/qwindow.cpp
parent675676aba1e71410fa6cfca430ab9bd64ebdcdaa (diff)
Removed requestOrientation() API from QWindow.
There are no proper implementations of this API, and as it stands it only acts to confuse anyone who stumbles across it. It will be better to revisit the full cross platform orientation API story for 5.1. Change-Id: Iff7054a32c6e5e4ad0cc0493a5e4ecc35a6ec4f3 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@digia.com> Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com> Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
Diffstat (limited to 'src/gui/kernel/qwindow.cpp')
-rw-r--r--src/gui/kernel/qwindow.cpp69
1 files changed, 10 insertions, 59 deletions
diff --git a/src/gui/kernel/qwindow.cpp b/src/gui/kernel/qwindow.cpp
index aaf2b25ad4..b1fd2d3f6b 100644
--- a/src/gui/kernel/qwindow.cpp
+++ b/src/gui/kernel/qwindow.cpp
@@ -89,23 +89,16 @@ QT_BEGIN_NAMESPACE
buffers to support double and triple buffering, as well as depth and stencil
buffers. To release a window's memory resources, call the destroy() function.
- \section1 Window and content orientation
-
- QWindow has reportContentOrientationChange() and
- requestWindowOrientation() that can be used to specify the
- layout of the window contents in relation to the screen. The
- window orientation determines the actual buffer layout of the
- window, and the windowing system uses this value to rotate the
- window before it ends up on the display, and to ensure that input
- coordinates are in the correct coordinate space relative to the
- application.
-
- On the other hand, the content orientation is simply a hint to the
- windowing system about which orientation the window contents are in.
- It's useful when you wish to keep the same buffer layout, but rotate
- the contents instead, especially when doing rotation animations
- between different orientations. The windowing system might use this
- value to determine the layout of system popups or dialogs.
+ \section1 Content orientation
+
+ QWindow has reportContentOrientationChange() that can be used to specify
+ the layout of the window contents in relation to the screen. The content
+ orientation is simply a hint to the windowing system about which
+ orientation the window contents are in. It's useful when you wish to keep
+ the same window size, but rotate the contents instead, especially when
+ doing rotation animations between different orientations. The windowing
+ system might use this value to determine the layout of system popups or
+ dialogs.
\section1 Visibility and Windowing system exposure.
@@ -743,8 +736,6 @@ bool QWindow::isActive() const
to compute the necessary transform.
The default value is Qt::PrimaryOrientation
-
- \sa requestOrientation(), QScreen::orientation()
*/
void QWindow::reportContentOrientationChange(Qt::ScreenOrientation orientation)
{
@@ -766,46 +757,6 @@ Qt::ScreenOrientation QWindow::contentOrientation() const
}
/*!
- Requests the given window \a orientation.
-
- The window \a orientation specifies how the window should be rotated
- by the window manager in order to be displayed. Input events will
- be correctly mapped to the given \a orientation.
-
- The return value is false if the system doesn't support the given
- \a orientation (for example when requesting a portrait orientation
- on a device that only handles landscape buffers, typically a desktop
- system).
-
- If the return value is false, call \l orientation() to get the actual
- supported orientation.
-
- \sa orientation(), reportContentOrientationChange(), QScreen::orientation()
-*/
-bool QWindow::requestOrientation(Qt::ScreenOrientation orientation)
-{
- Q_D(QWindow);
- if (!d->platformWindow)
- create();
- Q_ASSERT(d->platformWindow);
- d->windowOrientation = d->platformWindow->requestWindowOrientation(orientation);
- return d->windowOrientation == orientation;
-}
-
-/*!
- Returns the actual window orientation.
-
- The default value is Qt::PrimaryOrientation.
-
- \sa requestOrientation()
-*/
-Qt::ScreenOrientation QWindow::orientation() const
-{
- Q_D(const QWindow);
- return d->windowOrientation;
-}
-
-/*!
Returns the ratio between physical pixels and device-independent pixels
for the window. This value is dependent on the screen the window is on,
and may change when the window is moved.