D24862: Port one of session management connections state to a custom API

Vlad Zahorodnii <[email protected]>
Newsgroups gmane.comp.kde.devel.kwin
Message-ID <[email protected]>
zzag added inline comments.

INLINE COMMENTS

> sm.cpp:377-384
> +        case static_cast<uint>(SessionState::Saving):
> +            setState(SessionState::Saving);
> +            break;
> +        case static_cast<uint>(SessionState::Quitting):
> +            setState(SessionState::Quitting);
> +            break;
> +        default:

Style: Case labels should not be indented.

---

Also, I'd prefer to be more explicit about the conversion between "d-bus enums" and our enums, i.e. use integer values in the case labels.

Another way to implement this method without encoding "d-bus enum" values in our types is to use a static QVector and value() method.

I don't have a strong opinion though. It's up to you whether to leave this method as is. However, please fix the coding style issue.

REPOSITORY
  R108 KWin

BRANCH
  master

REVISION DETAIL
  https://phabricator.kde.org/D24862

To: davidedmundson, #kwin, zzag, apol
Cc: romangg, zzag, kwin, LeGast00n, The-Feren-OS-Dev, sbergeron, jraleigh, fbampaloukas, GB_2, mkulinski, ragreen, jackyalcine, iodelay, crozbo, bwowk, ZrenBot, ngraham, alexeymin, himcesjf, lesliezhai, ali-mohamed, hardening, jensreuterberg, abetts, sebas, apol, ahiemstra, mart
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.