Merge branch 'develop' of pwmt.org:zathura into develop

This commit is contained in:
Sebastian Ramacher 2012-03-01 13:58:54 +01:00
commit d85d6a1996
2 changed files with 17 additions and 12 deletions

View file

@ -512,6 +512,7 @@ cb_zathura_page_widget_button_release_event(GtkWidget* widget, GdkEventButton* b
} else { } else {
redraw_rect(ZATHURA_PAGE(widget), &priv->selection); redraw_rect(ZATHURA_PAGE(widget), &priv->selection);
zathura_rectangle_t tmp = priv->selection; zathura_rectangle_t tmp = priv->selection;
tmp.x1 /= priv->page->document->scale; tmp.x1 /= priv->page->document->scale;
tmp.x2 /= priv->page->document->scale; tmp.x2 /= priv->page->document->scale;
tmp.y1 /= priv->page->document->scale; tmp.y1 /= priv->page->document->scale;
@ -523,6 +524,7 @@ cb_zathura_page_widget_button_release_event(GtkWidget* widget, GdkEventButton* b
g_free(text); g_free(text);
} }
} }
priv->selection.x1 = -1; priv->selection.x1 = -1;
priv->selection.y1 = -1; priv->selection.y1 = -1;
priv->selection.x2 = -1; priv->selection.x2 = -1;

View file

@ -150,7 +150,8 @@ zathura_init(int argc, char* argv[])
config_load_default(zathura); config_load_default(zathura);
/* load global configuration files */ /* load global configuration files */
girara_list_t* config_dirs = girara_split_path_array(girara_get_xdg_path(XDG_CONFIG_DIRS)); char* config_path = girara_get_xdg_path(XDG_CONFIG_DIRS);
girara_list_t* config_dirs = girara_split_path_array(config_path);
ssize_t size = girara_list_size(config_dirs) - 1; ssize_t size = girara_list_size(config_dirs) - 1;
for (; size >= 0; --size) { for (; size >= 0; --size) {
const char* dir = girara_list_nth(config_dirs, size); const char* dir = girara_list_nth(config_dirs, size);
@ -159,6 +160,7 @@ zathura_init(int argc, char* argv[])
g_free(file); g_free(file);
} }
girara_list_free(config_dirs); girara_list_free(config_dirs);
g_free(config_path);
config_load_file(zathura, GLOBAL_RC); config_load_file(zathura, GLOBAL_RC);
@ -302,6 +304,7 @@ zathura_free(zathura_t* zathura)
} }
/* free registered plugins */ /* free registered plugins */
girara_list_free(zathura->plugins.type_plugin_mapping);
girara_list_free(zathura->plugins.plugins); girara_list_free(zathura->plugins.plugins);
girara_list_free(zathura->plugins.path); girara_list_free(zathura->plugins.path);