gint width, height;
if (!view->loading_text) {
- const gchar *loading_text = _("Loading...");
+ const gchar *loading_text = _("Loading…");
PangoLayout *layout;
PangoFontDescription *font_desc;
PangoRectangle logical_rect;
view->scale,
&tmp_region);
- if (tmp_region) {
+ if (tmp_region && !gdk_region_empty (tmp_region)) {
new_sel->covered_region = gdk_region_copy (tmp_region);
}
}
static void
clear_selection (EvView *view)
{
- g_list_foreach (view->selection_info.selections, (GFunc)selection_free, NULL);
- g_list_free (view->selection_info.selections);
- view->selection_info.selections = NULL;
+ if (view->selection_info.selections) {
+ g_list_foreach (view->selection_info.selections, (GFunc)selection_free, NULL);
+ g_list_free (view->selection_info.selections);
+ view->selection_info.selections = NULL;
+
+ g_signal_emit (view, signals[SIGNAL_SELECTION_CHANGED], 0, NULL);
+ }
view->selection_info.in_selection = FALSE;
if (view->pixbuf_cache)
ev_pixbuf_cache_set_selection_list (view->pixbuf_cache, NULL);
- g_signal_emit (view, signals[SIGNAL_SELECTION_CHANGED], 0, NULL);
}
void