[Geany-devel] rewritten load_startup_files()

Dimitar Zhekov dimitar.zhekov at xxxxx
Fri Apr 22 16:59:16 UTC 2011

On Fri, 22 Apr 2011 17:24:01 +0400
Eugene Arshinov <earshinov at gmail.com> wrote:

> I must note that this version print GTK assertion in a couple
> of cases.

You only pointed one case. What are the others?

> This happens when user tries to (1) simultaneously open a project
> and load the default session and at the same time (2) has "Use
> project-based project files" preference unchecked.  [...]  So, the
> solution will be not to call load_session_project_file() here (as
> it does not do anything anyway, and default session seems to open
> even without this call).

Exactly. I was somehow under the impression that the call is needed
to load the default session, but it's actually useless. Thanks.

(But PBSF=off is really something - haven't seen it anywhere else.)

> In SM there is additional handling of:
> - if Geany is being restored by the session manager
> - new load_session_if_any_files_loaded preference

Assuming that prefs.load_session_if_any_files_loaded implies

if (libsm_client_id != NULL || (prefs.load_session && (argc <= 1 ||
	load_session_if_any_files_loaded) && cl_options.load_session &&

One of my goals was to make the inclusion of such things easier - just
change the "Load the default session" condition, update the comment
accordingly, and voila.

E-gards: Jimmy
-------------- next part --------------
A non-text attachment was scrubbed...
Name: load-startup-files-v2.1-5701.diff
Type: text/x-diff
Size: 2847 bytes
Desc: not available
URL: <http://lists.geany.org/pipermail/devel/attachments/20110422/4312efc2/attachment.diff>

More information about the Devel mailing list