Branch: refs/heads/master Author: Colomban Wendling ban@herbesfolles.org Committer: Colomban Wendling ban@herbesfolles.org Date: Thu, 18 Dec 2014 01:42:05 UTC Commit: d80ee82072a188297c4a3d1bd304e65741f7a4f0 https://github.com/geany/geany/commit/d80ee82072a188297c4a3d1bd304e65741f7a4...
Log Message: ----------- Select the default scheme in the Color Scheme dialog by default
Always select the default scheme by default in the Color Scheme dialog not to end up selecting none in case of broken or nonexistent configuration. This matches which scheme is actually used, and fixes use of an uninitialized iter when no scheme would be selected.
Modified Paths: -------------- src/highlighting.c
Modified: src/highlighting.c 5 lines changed, 4 insertions(+), 1 deletions(-) =================================================================== @@ -1249,7 +1249,10 @@ static void add_color_scheme_item(GtkListStore *store, SCHEME_FILE, fn, -1); g_free(markup);
- if (utils_str_equal(fn, editor_prefs.color_scheme) && current_iter) + /* select the current iter if the the color scheme matches, or if it's the + * default (fn == NULL), in case of bad config file. the default theme is + * first anyway so if a later scheme matches it will override default */ + if ((! fn || utils_str_equal(fn, editor_prefs.color_scheme)) && current_iter) *current_iter = iter; }
-------------- This E-Mail was brought to you by github_commit_mail.py (Source: https://github.com/geany/infrastructure).