<table><tr><td style="">graesslin created this revision.<br />graesslin added reviewers: KWin, Plasma, sebas.<br />Restricted Application added a project: Plasma.<br />Restricted Application added a subscriber: plasma-devel.
</td><a style="text-decoration: none; padding: 4px 8px; margin: 0 8px 8px; float: right; color: #464C5C; font-weight: bold; border-radius: 3px; background-color: #F7F7F9; background-image: linear-gradient(to bottom,#fff,#f1f0f1); display: inline-block; border: 1px solid rgba(71,87,120,.2);" href="https://phabricator.kde.org/D8699" rel="noreferrer">View Revision</a></tr></table><br /><div><strong>REVISION SUMMARY</strong><div><p>This change introduces an OrientationSensor class which wraps a<br />
QOrientationSensor. The OrientationSensor is hold by Screens and gets<br />
enabled if Screens knows about an internal (e.g. LVDS) display which<br />
supports rotation. In addition the OrientationSensor holds an KSni to<br />
enable/disable the automatic rotation support.</p>

<p>The drm platform plugin is adjusted to make use of the OrientationSensor.<br />
The API is defined in a way that this can also be implemented on other<br />
platforms supporting rotation. Most important are hwcomposer and X11<br />
standalone. The latter should be straight forward as rotation is provided<br />
through XRandR. The former needs addition for rotation support first.</p></div></div><br /><div><strong>TEST PLAN</strong><div><p>Rotated my Yoga 12</p></div></div><br /><div><strong>BRANCH</strong><div><div>automatic-rotation</div></div></div><br /><div><strong>REVISION DETAIL</strong><div><a href="https://phabricator.kde.org/D8699" rel="noreferrer">https://phabricator.kde.org/D8699</a></div></div><br /><div><strong>AFFECTED FILES</strong><div><div>CMakeLists.txt<br />
autotests/CMakeLists.txt<br />
orientation_sensor.cpp<br />
orientation_sensor.h<br />
plugins/platforms/drm/drm_object_plane.h<br />
plugins/platforms/drm/drm_output.cpp<br />
plugins/platforms/drm/drm_output.h<br />
plugins/platforms/drm/screens_drm.cpp<br />
plugins/platforms/drm/screens_drm.h<br />
screens.cpp<br />
screens.h<br />
tests/CMakeLists.txt<br />
tests/orientationtest.cpp</div></div></div><br /><div><strong>To: </strong>graesslin, KWin, Plasma, sebas<br /><strong>Cc: </strong>plasma-devel, ZrenBot, progwolff, lesliezhai, ali-mohamed, jensreuterberg, abetts, sebas, apol, mart<br /></div>