g_signal_handlers_block_by_func(ee->value_widget, bar_pane_exif_entry_changed, ee);
gtk_entry_set_text(GTK_ENTRY(ee->value_widget), text ? text : "");
g_signal_handlers_unblock_by_func(ee->value_widget, bar_pane_exif_entry_changed, ee);
-#if GTK_CHECK_VERSION(2,12,0)
gtk_widget_set_tooltip_text(ee->box, NULL);
-#endif
}
else
{
gtk_label_set_text(GTK_LABEL(ee->value_widget), text);
-#if GTK_CHECK_VERSION(2,12,0)
gtk_widget_set_tooltip_text(ee->box, text);
-#endif
}
gtk_widget_show(entry);
ped->all_hidden = FALSE;
}
#endif
}
+
+#if !GLIB_CHECK_VERSION(2, 14, 0)
+static void hash_table_add(gpointer key, gpointer value, gpointer user_data)
+{
+ GList **list = user_data;
+ *list = g_list_prepend(*list, key);
+}
+#endif
+
+GList* hash_table_get_keys(GHashTable *hash_table)
+{
+#if GLIB_CHECK_VERSION(2, 14, 0)
+ return g_hash_table_get_keys(hash_table);
+#else
+ GList *list = NULL;
+ g_hash_table_foreach(hash_table, hash_table_add, &list);
+ return list;
+#endif
+}
+
/* vim: set shiftwidth=8 softtabstop=0 cindent cinoptions={1s: */
#define COMPAT_H
void radio_action_set_current_value(GtkRadioAction *action, gint current_value);
+GList* hash_table_get_keys(GHashTable *hash_table);
+
+#if !GTK_CHECK_VERSION(2,12,0)
+#define gtk_widget_set_tooltip_text(widget, text) /* ignored */
+#endif
+
#endif /* COMPAT_H */
/* vim: set shiftwidth=8 softtabstop=0 cindent cinoptions={1s: */
#include <gdk-pixbuf/gdk-pixbuf.h>
#include <gdk-pixbuf/gdk-pixbuf-loader.h>
+#include "compat.h"
/*
*----------------------------------------------------------------------------
if (fd && fd->modified_xmp)
{
- keys = g_hash_table_get_keys(fd->modified_xmp);
+ keys = hash_table_get_keys(fd->modified_xmp);
}
g_assert(keys);