Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Automatic saving/restoring #17

Open
wizonesolutions opened this issue Jul 29, 2019 · 7 comments
Open

Automatic saving/restoring #17

wizonesolutions opened this issue Jul 29, 2019 · 7 comments

Comments

@wizonesolutions
Copy link

It is possible to have this extension detect a shutdown/restart and save the windows prior, then reopen them when the system starts again? Currently, if I forget to save my session, I'm a bit out of luck.

Alternatively, I wonder if it'd be possible to integrate with the reboot dialog and have a checkbox/button for saving the session. That way, people could choose to not do so if they didn't want to. I'm obviously rather inspired by macOS with this request.

@johannesjo
Copy link
Owner

Hey there! Thanks for opening up this issue. This would require continuously saving the current session, which is not ideal, but it should be possible. Currently I don't really have time to implement such a feature, but Pull Requests would be welcome.

@rrthomas
Copy link

Two thoughts:

  1. Would it be possible to be notified of logout, e.g. by catching the SessionOver signal?
  2. Quick-and-dirty hack: copy a logout button extension, and save the session before logging out.

@johannesjo
Copy link
Owner

johannesjo commented Mar 11, 2020

@rrthomas great suggestion! Would you be willing to give it a go yourself?

@rrthomas
Copy link

rrthomas commented Mar 13, 2020

(I know basically nothing about GNOME Shell extensions, but I presume you don't know much either or you wouldn't've asked me for help!)

I tried the quick-and-dirty hack version first, as being a useful proof of concept. See https://github.com/rrthomas/gnome-shell-extension-window-session-manager

This just copies logout button code from https://gitlab.com/paddatrapper/log-out-button-gnome-extension and makes it additionally save the session "DEFAULT" on logout.

@curiousercreative
Copy link
Contributor

@rrthomas are you running your version of this?

@rrthomas
Copy link

rrthomas commented Mar 3, 2021

@curiousercreative No. I'm not sure what I found at the time with my hack, I'm sorry; but of course someone else is welcome to try it. I must say I've given up in general on GNOME's session management, and I've been trying KDE recently. (I also tried MATE and XFCE and had no luck with them either; to be clear, my aim is specifically to restart with apps on the correct virtual desktops. lwsm doesn't seem to do that reliably, at least for me.)

@nlpsuge
Copy link

nlpsuge commented Dec 13, 2021

Extends ui/endSessionDialog.js and add automatic saving and closing code seems very practical in this case.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants