<table><tr><td style="">kossebau created this revision.<br />Restricted Application added projects: Plasma, Frameworks.<br />Restricted Application added subscribers: Frameworks, 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/D6054" rel="noreferrer">View Revision</a></tr></table><br /><div><strong>REVISION SUMMARY</strong><div><p>The constructor of QFlags which was intended to handle literal "0"<br />
as commonly used indicator of no-flags-set has been done with a<br />
trick based on pointer types. Which these days of nullptr existing and<br />
compilers pushing to use that sadly fired back and, instead of<br />
allowing convenient code with commonly understood literal "0" values,<br />
resulted in quite some code using "nullptr" to indicate a QFLags-based<br />
type value with no flags set, which can be puzzling for humans<br />
reading the code.</p>
<p>To improve the code again, instead of "nullptr" are used:</p>
<ul class="remarkup-list">
<li class="remarkup-list-item">enum item representing the 0=no-flag-set value, if existing</li>
<li class="remarkup-list-item">explicit default constructor</li>
</ul></div></div><br /><div><strong>REPOSITORY</strong><div><div>R278 KWindowSystem</div></div></div><br /><div><strong>BRANCH</strong><div><div>nonullptrforflagsplease</div></div></div><br /><div><strong>REVISION DETAIL</strong><div><a href="https://phabricator.kde.org/D6054" rel="noreferrer">https://phabricator.kde.org/D6054</a></div></div><br /><div><strong>AFFECTED FILES</strong><div><div>autotests/kstartupinfo_unittest.cpp<br />
autotests/kwindowinfox11test.cpp<br />
autotests/kwindowsystemx11test.cpp<br />
autotests/netwininfotestwm.cpp<br />
src/kstartupinfo.cpp<br />
src/kwindowinfo.cpp<br />
src/kwindowinfo.h<br />
src/kwindowsystem.h<br />
src/platforms/xcb/kwindowinfo.cpp<br />
src/platforms/xcb/kwindowsystem.cpp<br />
src/platforms/xcb/netwm.cpp<br />
src/platforms/xcb/netwm.h</div></div></div><br /><div><strong>To: </strong>kossebau, Plasma, graesslin<br /><strong>Cc: </strong>plasma-devel, Frameworks, ZrenBot, spstarr, progwolff, lesliezhai, ali-mohamed, jensreuterberg, abetts, sebas, apol, mart, lukas<br /></div>