Using sessions correctly

Discuss any topics about the editor here

Using sessions correctly

Postby feralbeagle » Sat Aug 20, 2011 8:17 pm

I would like to better understand how sessions are used.

Here is how I thought sessions worked:

    1) Name and save a session.
    2) Loading the session of than name should reopen all the tabs were open when the session was saved.
The problem is only one tab opens when I load any saved session.

    Tested on several of the latest versions of Editra.
    Tested on more than one Windows XP machine.
    Not tested on any other OS.

Maybe I'm doing it wrong?

Thanks in advance,
-Bryan
feralbeagle
Limited User
 
Posts: 2
Joined: Sat Aug 20, 2011 8:03 pm

Re: Using sessions correctly

Postby cody » Mon Aug 22, 2011 6:56 pm

Hi,

I think that the session feature needs to be reworked but here is my guess as to what is happening:

1) You open some files
2) Save session (This sets the current session to your new named one)
3) You close some files (this causes updates to your saved session)
4) Editra main window is closed (this also causes session to be updated with current files.)
5) Editra is restarted and last file(s) that were opened are shown.

Issues:
* Editra should probably not update custom sessions automatically and only do it when saved by the user

If this is not the issue your experiencing please let me know. I will try to plan to look into and improve the session management for the next release as this is something that has been put off for awhile now.

Thanks,

Cody
User avatar
cody
Site Admin
 
Posts: 1315
Joined: Mon Oct 09, 2006 2:49 am
Location: United States

Re: Using sessions correctly

Postby feralbeagle » Sat Aug 27, 2011 8:55 pm

Yes!

I was doing it wrong and consistently doing it wrong. Thank you for the explanation; it works exactly like you said.

If I want to save a particular set of open files as a session, I need to switch to a different session before changing the open file set and CLOSING.

BTW, wonderful editor and thank you for writing the cookbook. It's helped a lot.

cheers,
-Bryan
feralbeagle
Limited User
 
Posts: 2
Joined: Sat Aug 20, 2011 8:03 pm

Re: Using sessions correctly

Postby cody » Sun Aug 28, 2011 2:58 am

Hi,

I have committed the first round of changes for this for the next release. The new behavior is as follows:

*) When using the 'Default' session it will automatically just save the state when the main window exits retaining the current behavior. It is also saved during file open and close operations.

*) Any custom session must be manually saved to change what files are in it.

Not sure if it will get in before the next release but will also be adding a way to more easily be able to switch between and save sessions.
User avatar
cody
Site Admin
 
Posts: 1315
Joined: Mon Oct 09, 2006 2:49 am
Location: United States


Return to General Discussion

Who is online

Users browsing this forum: No registered users and 1 guest

cron