1. 29 Sep, 2020 1 commit
  2. 25 Sep, 2020 1 commit
  3. 22 Sep, 2020 1 commit
  4. 17 Sep, 2020 1 commit
    • David Edmundson's avatar
      Systemd Startup · 256b6e17
      David Edmundson authored
      Summary:
      This brings numerous advantages such as:
      
      - easier admin configuration with drop-ins, overrides and multiple
      hooks throughout (and only having to learn one tool)
      
      - session cleanup on exit, avoiding that occasional part where shutdown
      hangs
      
       - startup that actually knows when things are up
      
       - race free autostart and DBus activation at once
      
       - logs that rotate are split by service and usable
      
       - resource management through slices and cgroups (the part I want)
      
      Over the past 2 years I've been trying to tidy up and encapsulate the
      relevant parts of startup into the binary plasma-session so that we can
      just runtime swap out that one part and supporting both paths will be
      easy.
      
      Support is toggleable via cmake flag, as it seems like it should be a
      distro decision, especially as we will require a specific systemd with
      the xdg-generator.
      
      KDED/kwin/other services are attached to the relevant repo.
      
      Task T11914
      
      Differential Revision: https://phabricator.kde.org/D28305
      
      squash
      256b6e17
  5. 16 Sep, 2020 1 commit
  6. 01 Sep, 2020 1 commit
    • David Edmundson's avatar
      [ksmserver] Use UpdateLaunchEnvJob to sync SESSION_MANAGER env · d24cef54
      David Edmundson authored
      ksmserver starts in plasma-session. It currently sets the
      SESSION_MANAGER env back to just kinit and plasma-session which is then
      used for anything else that plasma-session starts.
      
      This is after start-plasma has synced the environment to DBus/systemd.
      
      By using the shared UpdateLaunchEnvJob we can sync all these places.
      
      BUG: 425982
      d24cef54
  7. 16 Jun, 2020 1 commit
  8. 26 May, 2020 1 commit
    • Adriaan de Groot's avatar
      Fix finding _IceTransNoListen. · 0c4ad7f1
      Adriaan de Groot authored
      This is a patch carried by FreeBSD for a long time; I may have submitted it upstream before.
      
      libICE is **not** in the standary library search paths on FreeBSD, so using the straight-up name *ICE* in `check_library_exists()` won't find it -- even though libICE has previously been found, probably by `find_package(X11)`
      
      Use the full path, which is what `${X11_ICE_LIB}` should hold.
      0c4ad7f1
  9. 29 Apr, 2020 2 commits
  10. 24 Apr, 2020 1 commit
  11. 23 Apr, 2020 1 commit
  12. 08 Apr, 2020 1 commit
  13. 06 Apr, 2020 2 commits
  14. 02 Apr, 2020 1 commit
  15. 29 Mar, 2020 1 commit
    • Aleix Pol Gonzalez's avatar
      Remove unused file · 184cee85
      Aleix Pol Gonzalez authored
      Summary: Still included dcop, hadn't been compiled in years I presume.
      
      Test Plan: All good and normal
      
      Reviewers: #plasma, davidedmundson
      
      Reviewed By: #plasma, davidedmundson
      
      Subscribers: plasma-devel
      
      Tags: #plasma
      
      Differential Revision: https://phabricator.kde.org/D28385
      184cee85
  16. 18 Mar, 2020 1 commit
  17. 02 Mar, 2020 1 commit
    • David Edmundson's avatar
      [plasma-session] Load startup and shutdown on demand · 3c34dfa9
      David Edmundson authored
      Summary:
      Currently startplasma spawns plasma-session then sits around waiting for
      that to finish
      
      plasma-session spawns all the startup then also just sits around doing
      nothing
      
      This patch makes plasma-session spawn all the startup and then quit.
      
      It also splits the owner of the org.kde.shutdown interface to be on
      demand. plasma-shutdown asks ksmserver to quit and then if applicable
      runs the shutdown scripts or not.
      
      Startplasma then knows when to exit by monitoring the DBus service
      status directly.
      
      The benefits are that we save some resources by not needing
      plasma-session lingering about.
      
      It also means the shutdown interface is re-usable as-is when the pending
      systemd startup method is used.
      
      Test Plan:
      Logged in and:
       - ran killall ksmserver, session ended as before
       - logged out and cancelled due to unsaved changes
       - logged out and completed logout
       - logged out and rebooted
      
      Reviewers: #plasma, apol
      
      Reviewed By: apol
      
      Subscribers: apol, plasma-devel
      
      Tags: #plasma
      
      Differential Revision: https://phabricator.kde.org/D27629
      3c34dfa9
  18. 04 Feb, 2020 1 commit
  19. 31 Jan, 2020 1 commit
  20. 30 Dec, 2019 1 commit
  21. 01 Nov, 2019 1 commit
    • David Edmundson's avatar
      [ksmserver] Signal session management state to kwin directly · 09cad25f
      David Edmundson authored
      Summary:
      Kwin had to have two ICE connections in order to track state
      indepdendently of it's session saving.
      
      This replaces that with a more direct DBus protocol allowing for both
      simplification on the kwin side as well as comunicating the logout state
      better for effects.
      
      Whilst this code temporarily complicates things, now we have this
      interface the next step is drop all the isWM() stuff and do kwin
      specific session management also over this interface. See T11882
      
      Test Plan:
      Added qdebug into kwin
      started logging out with an unsaved file, cancelled shutdown
      started logging out with, discarded file
      
      Reviewers: #kwin, apol
      
      Reviewed By: apol
      
      Subscribers: broulik, apol, plasma-devel
      
      Tags: #plasma
      
      Differential Revision: https://phabricator.kde.org/D24945
      09cad25f
  22. 31 Oct, 2019 1 commit
  23. 22 Oct, 2019 1 commit
    • David Edmundson's avatar
      [ksmserver] Drop unused logout effect widget · 9b857cce
      David Edmundson authored
      Summary:
      At some point there was an effect in kwin to fade to a grey (with a
      weird vigenette effect) as one logs out.
      
      This was signalled with a fake offscreen window with a special window
      ID.
      
      The kwin effect has gone, deleted in Plasma 5.8 with
      af80a546bfe258b54468b159bb8cf78f16ca9ebf
      
      (Kwin still contains an effect called logout, but that's merely for the
      logout prompt)
      
      I intend to replace this logout effect but as I'm going to start from
      scratch we may as well communicate from ksmserver -> kwin with a new API
      that works on wayland and and solves some other issues all in one.
      
      Test Plan: Compiles
      
      Reviewers: #plasma, #kwin, apol
      
      Reviewed By: apol
      
      Subscribers: plasma-devel
      
      Tags: #plasma
      
      Differential Revision: https://phabricator.kde.org/D24759
      9b857cce
  24. 12 Oct, 2019 1 commit
    • Yuri Chornoivan's avatar
      Fix minor EBN issues · f9355ee6
      Yuri Chornoivan authored
      Summary: Include duplication, no newline at the end of file and missing argument to the i18n() call
      
      Test Plan: Should work fine but needs a review for i18n() calls
      
      Reviewers: #plasma, apol
      
      Reviewed By: apol
      
      Subscribers: apol, plasma-devel
      
      Tags: #plasma
      
      Differential Revision: https://phabricator.kde.org/D24580
      f9355ee6
  25. 04 Sep, 2019 1 commit
  26. 10 Jul, 2019 2 commits
    • Stefan Brüns's avatar
      Split ksmserver into a small application that handles startup and ksmserver · 6bab1f51
      Stefan Brüns authored
      This allows new startup procedures to use a session manager and also
      allows us to slowly replace the session manager without breaking plasma.
      
      Following on from the previous refactor, Startup and Shutdown are moved
      from kmserver and the previous calls into KSMserver are replaced with
      DBus calls.
      
      Reviewers: #plasma, davidedmundson
      
      Reviewed By: #plasma, davidedmundson
      
      Subscribers: plasma-devel
      
      Tags: #plasma
      
      Differential Revision: https://phabricator.kde.org/D21995
      6bab1f51
    • Stefan Brüns's avatar
      [ksmserver] Remove obsolete KDELibs4Support dependency · 7fa46fa7
      Stefan Brüns authored
      Summary:
      The inhibition was dysfunctional, as powerdevil delays the inhibition
      by 5 seconds (and is already stopped when the delay times out). Also
      powerdevil handles concurrent user session shutdowns and sleep requests
      itself, so the code is obsolete.
      
      As KDELibs4Support pulled in a number of Frameworks, we have to
      explicitly add these now.
      
      Reviewers: #plasma, broulik, davidedmundson
      
      Reviewed By: #plasma, davidedmundson
      
      Subscribers: apol, sitter, anthonyfieroni, plasma-devel
      
      Tags: #plasma
      
      Differential Revision: https://phabricator.kde.org/D22296
      7fa46fa7
  27. 12 Jun, 2019 2 commits
    • David Edmundson's avatar
      [ksmserver] Drop internal loading of alternative window managers · e8947310
      David Edmundson authored
      Summary:
      ksmserver's loading of other window manager relies on files in
      share/windowmanagers/$name.desktop with the Exec line of the window
      manager.
      
      This was something previously installed by plasma-desktop and removed in
      2016. All this code path is now redundant as well as the wmChanged DBus
      method used by the deleted KCM.
      
      Setting KDEWM manually will still work as before.
      
      Test Plan:
      Logged in
      Got kwin as before
      
      Reviewers: #plasma, broulik, apol
      
      Reviewed By: #plasma, broulik, apol
      
      Subscribers: plasma-devel
      
      Tags: #plasma
      
      Differential Revision: https://phabricator.kde.org/D21758
      e8947310
    • David Edmundson's avatar
      [ksmserver] Drop multi X screen support · 0916d970
      David Edmundson authored
      Summary:
      We don't support multi X screen anymore in the rest of plasma. Cleans up
      a bit of code.
      
      Having multiple monitors via xrandr will still work as before.
      
      Test Plan: Compiles
      
      Reviewers: #plasma, apol
      
      Reviewed By: apol
      
      Subscribers: plasma-devel
      
      Tags: #plasma
      
      Differential Revision: https://phabricator.kde.org/D21757
      0916d970
  28. 03 Jun, 2019 1 commit
  29. 15 Feb, 2019 1 commit
    • David Edmundson's avatar
      [ksmserver] Restore legacy sessions · b4ddae94
      David Edmundson authored
      Summary:
      KSMServer has two modes, the slightly ancient mode (XSMP), and the
      really ancient legacy mode (XSM).
      
      When startup was rewritten in 96a595f1
      we accidentally dropped the call that invokes restore of the legacy
      session as well as the normal mode.
      
      BUG: 404318
      
      Reviewers: #plasma, broulik
      
      Reviewed By: #plasma, broulik
      
      Subscribers: broulik, plasma-devel
      
      Tags: #plasma
      
      Differential Revision: https://phabricator.kde.org/D19028
      b4ddae94
  30. 21 Jan, 2019 1 commit
    • David Edmundson's avatar
      Handle ShutdowntypeDefault in KSMserver legacy code · fc2d0c4f
      David Edmundson authored
      Summary:
      In the ksmserver porting most code was moved to explicitly calling
      logout or shutdown methods rather than a random enum.
      
      A legacy code path remained for compatibility. This path is used by the
      containmentactions, in the refactor handling of
      KWorkspace::ShutdownTypeDefault was lost.
      
      BUG: 403466
      Fixed-in: 5.15.0
      
      Test Plan:
      Set different default modes
      Logged out using containment actions
      
      Reviewers: #plasma, broulik
      
      Reviewed By: #plasma, broulik
      
      Subscribers: ngraham, plasma-devel
      
      Tags: #plasma
      
      Differential Revision: https://phabricator.kde.org/D18435
      fc2d0c4f
  31. 08 Nov, 2018 2 commits
    • David Edmundson's avatar
      [ksmserver] Remove blocking call introspecting KDED · c8ed48fc
      David Edmundson authored
      Summary:
      We don't need to introspect at runtime as KDED installs the interface
      XML file.
      
      Oddly KDED's package is called KDED not KF5KDED, hence the separate
      find_package, I don't know if that's a bug in frameworks or not.
      
      Test Plan: Compiles
      
      Reviewers: #plasma, romangg
      
      Reviewed By: #plasma, romangg
      
      Subscribers: plasma-devel
      
      Tags: #plasma
      
      Differential Revision: https://phabricator.kde.org/D16628
      c8ed48fc
    • David Edmundson's avatar
      [ksmserver] Split xsession logout and shutdown into separate classes · 008d58cf
      David Edmundson authored
      Summary:
      This commit splits ksmserver's xsession shutdown logic from performing
      the actual shutdown and running shutdown scripts and implement proposed
      org.kde.Shutdown interface.
      
      Intended longer term target is to move this to a separate executable.
      
      KSMServer's existing logout dbus method still exists for compatibility
      forwarding to the new interface.
      
      There are 2 minor behavioural changes.
      
      The shutdownMode property (which doesn't seem to do anything and is not
      exposed in our UI) is not kept.
      
      If you shutdown /whilst/ starting up somehow, previously we delayed
      showing the logout prompt, we now delay performing the actual logout.
      
      Test Plan:
      Logged out / shut down using the old API
      Logged out / shut down using the new DBus API
      
      Reviewers: #plasma, apol, romangg
      
      Reviewed By: #plasma, apol, romangg
      
      Subscribers: romangg, apol, plasma-devel
      
      Tags: #plasma
      
      Differential Revision: https://phabricator.kde.org/D16277
      008d58cf
  32. 01 Nov, 2018 1 commit
    • David Edmundson's avatar
      [ksmserver] Simplify call to kcminit · 8c85bfa6
      David Edmundson authored
      Summary:
      kcminit had a slot to start processing something and a signal to emit
      when it's finished.
      
      For DBus that's quite bad practice as it can leave you hanging in the
      case of a kcminit crashing. It's better to use the return of the
      original call to signal when something is done.
      
      From ksmserver we can then just use DBus timeouts set on the interface
      than a secondary timer.
      
      We also remove a pointless blocking call to kcminit introspecting
      everything, if kcminit is not running it will return with an error
      immediately which is no slower than checking first if it's not running
      and faster if it is.
      
      Test Plan:
      Logged in
      Session logs showed kcminit ran
      
      Reviewers: #plasma, broulik
      
      Reviewed By: #plasma, broulik
      
      Subscribers: zzag, plasma-devel
      
      Tags: #plasma
      
      Differential Revision: https://phabricator.kde.org/D16587
      8c85bfa6
  33. 31 Oct, 2018 1 commit
    • David Edmundson's avatar
      [ksmserver] Fix session restore check · e53e3e17
      David Edmundson authored
      Summary:
      The old code checked ksmserver->defaultSession in the Startup
      constructor before ksmserver was set up by main.cpp
      
      This refactor moves it to the job, so we'll be checking if we're
      restoring or not after ksmserver has been set up by main.cpp as well as
      making the initial code path a bit clearer.
      
      Test Plan:
      Logged in with session restore
      Logged in with a default session
      
      Reviewers: ahartmetz
      
      Reviewed By: ahartmetz
      
      Subscribers: ahartmetz, plasma-devel
      
      Tags: #plasma
      
      Differential Revision: https://phabricator.kde.org/D16550
      e53e3e17
  34. 30 Oct, 2018 2 commits
    • David Edmundson's avatar
      [ksmserver] Add missing license · 50815c0c
      David Edmundson authored
      50815c0c
    • David Edmundson's avatar
      [ksmserver] Rewrite Startup · 96a595f1
      David Edmundson authored
      Summary:
      The code is effectively 3 startup phases each of which has some parallel
      methods that need to be complete before moving onto the next phase.
      
      The old code had a tonne of methods all of which tracking what state
      we're in and trying to start the next method in the chain handling
      things out of order.
      
      This simplifies everything into 3 composite kjobs. A lot more classes,
      but each one tiny with the flow more readable.
      
      Code should be effectively the same. The startup sound is moved ever so
      slightly earlier to be when phase 2 starts rather than just after
      kcminit2 finishes (midway through the old phase 2), but no significant
      behavioural changes here.
      
      Test Plan: Logged in with session restore and without
      
      Reviewers: #plasma, apol
      
      Reviewed By: apol
      
      Subscribers: apol, broulik, anthonyfieroni, plasma-devel
      
      Tags: #plasma
      
      Differential Revision: https://phabricator.kde.org/D16231
      96a595f1