summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMartin <mso@fedoraproject.org>2010-08-07 08:34:04 (GMT)
committerMartin <mso@fedoraproject.org>2010-08-07 08:34:04 (GMT)
commita9b6f283503890d7d29862a10f57740e4378e8ef (patch)
treeab036c7c0b3bf12ffa4cad548bf76c70356785fb
parent942fc7c7169d96fe3c0730793967b84e63fa8d61 (diff)
downloadnodoka-a9b6f283503890d7d29862a10f57740e4378e8ef.zip
nodoka-a9b6f283503890d7d29862a10f57740e4378e8ef.tar.gz
nodoka-a9b6f283503890d7d29862a10f57740e4378e8ef.tar.xz
Bring back support for GtkCombo (deprecated since GTK+ 2.4).
-rw-r--r--gtk-nodoka-engine/src/GTKEngine/nodoka_style.c12
-rw-r--r--gtk-nodoka-engine/src/GTKEngine/support.h1
2 files changed, 9 insertions, 4 deletions
diff --git a/gtk-nodoka-engine/src/GTKEngine/nodoka_style.c b/gtk-nodoka-engine/src/GTKEngine/nodoka_style.c
index bbe819a..d2572cc 100644
--- a/gtk-nodoka-engine/src/GTKEngine/nodoka_style.c
+++ b/gtk-nodoka-engine/src/GTKEngine/nodoka_style.c
@@ -173,7 +173,8 @@ nodoka_style_draw_flat_box (DRAW_ARGS)
height += style->ythickness*2;
if (widget && gtk_widget_get_parent (widget)
- && (GTK_IS_COMBO_BOX_ENTRY (gtk_widget_get_parent (widget))
+ && (NDK_IS_COMBO (gtk_widget_get_parent (widget))
+ || GTK_IS_COMBO_BOX_ENTRY (gtk_widget_get_parent (widget))
|| GTK_IS_SPIN_BUTTON (widget)))
{
width += style->xthickness;
@@ -273,7 +274,8 @@ nodoka_style_draw_shadow (DRAW_ARGS)
nodoka_set_widget_parameters (widget, style, state_type, &params);
if (widget && gtk_widget_get_parent (widget)
- && (GTK_IS_COMBO_BOX_ENTRY (gtk_widget_get_parent (widget))
+ && (NDK_IS_COMBO (gtk_widget_get_parent (widget))
+ || GTK_IS_COMBO_BOX_ENTRY (gtk_widget_get_parent (widget))
|| GTK_IS_SPIN_BUTTON (widget)))
{
width += style->xthickness;
@@ -636,7 +638,8 @@ nodoka_style_draw_box (DRAW_ARGS)
boolean shadows = TRUE;
if ((widget && gtk_widget_get_parent (widget)
- && (GTK_IS_COMBO_BOX_ENTRY (gtk_widget_get_parent (widget)))))
+ && (NDK_IS_COMBO (gtk_widget_get_parent (widget))
+ || GTK_IS_COMBO_BOX_ENTRY (gtk_widget_get_parent (widget)))))
{
if (nodoka_style->roundness > 0)
@@ -1746,7 +1749,8 @@ nodoka_style_draw_focus (GtkStyle * style, GdkWindow * window,
{
padding += 2;
if ((widget && gtk_widget_get_parent (widget)
- && (GTK_IS_COMBO_BOX_ENTRY (gtk_widget_get_parent (widget)))))
+ && (NDK_IS_COMBO (gtk_widget_get_parent (widget))
+ || GTK_IS_COMBO_BOX_ENTRY (gtk_widget_get_parent (widget)))))
{
if (nodoka_style->roundness > 0)
diff --git a/gtk-nodoka-engine/src/GTKEngine/support.h b/gtk-nodoka-engine/src/GTKEngine/support.h
index e721c75..a49393a 100644
--- a/gtk-nodoka-engine/src/GTKEngine/support.h
+++ b/gtk-nodoka-engine/src/GTKEngine/support.h
@@ -42,6 +42,7 @@
#define NDK_IS_ETREE(object) ((object) && ndk_object_is_a ((GObject*)(object), "ETree"))
#define NDK_IS_ETABLE(object) ((object) && ndk_object_is_a ((GObject*)(object), "ETable"))
+#define NDK_IS_COMBO(object) ((object) && ndk_object_is_a ((GObject*)(object), "GtkCombo"))
G_GNUC_INTERNAL GtkTextDirection nodoka_get_direction (GtkWidget * widget);