From fedbee566107f89acab946d5ebd4ef3f5f6d7bdb Mon Sep 17 00:00:00 2001 From: Christian Persch Date: Mon, 9 Aug 2004 10:35:24 +0000 Subject: Only use this for gtk < 2.5.1, and just add a few #defines otherwise. 2004-08-09 Christian Persch * lib/widgets/ephy-label.c: * lib/widgets/ephy-label.h: Only use this for gtk < 2.5.1, and just add a few #defines otherwise. --- ChangeLog | 8 ++++++++ lib/widgets/ephy-label.c | 9 ++++++++- lib/widgets/ephy-label.h | 15 +++++++++++++++ 3 files changed, 31 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index efb2e8463..436719893 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2004-08-09 Christian Persch + + * lib/widgets/ephy-label.c: + * lib/widgets/ephy-label.h: + + Only use this for gtk < 2.5.1, and just add a few + #defines otherwise. + 2004-08-09 Christian Persch * src/bookmarks/ephy-topics-selector.c: diff --git a/lib/widgets/ephy-label.c b/lib/widgets/ephy-label.c index 97c3e1878..70f6b03fb 100644 --- a/lib/widgets/ephy-label.c +++ b/lib/widgets/ephy-label.c @@ -23,13 +23,18 @@ * GTK+ at ftp://ftp.gtk.org/pub/gtk/. */ +#include + +#if !GTK_CHECK_VERSION (2, 5, 1) + #ifdef HAVE_CONFIG_H #include #endif +#include "ephy-label.h" + #include #include -#include "ephy-label.h" #include #include #include @@ -3446,3 +3451,5 @@ ephy_label_do_popup (EphyLabel *label, popup_position_func, label, 0, gtk_get_current_event_time ()); } + +#endif /* !GTK_CHECK_VERSION (2, 5, 1) */ diff --git a/lib/widgets/ephy-label.h b/lib/widgets/ephy-label.h index d8ac386d4..0ac2504a0 100644 --- a/lib/widgets/ephy-label.h +++ b/lib/widgets/ephy-label.h @@ -26,6 +26,20 @@ #ifndef __EPHY_LABEL_H__ #define __EPHY_LABEL_H__ +#include + +#if GTK_CHECK_VERSION (2, 5, 1) + +#include + +#define ephy_label_new gtk_label_new +#define ephy_label_set_ellipsize gtk_label_set_ellipsize +#define ephy_label_set_text gtk_label_set_text +#define ephy_label_set_selectable gtk_label_set_selectable +#define ephy_label_set_use_markup gtk_label_set_use_markup +#define EPHY_LABEL GTK_LABEL + +#else #include #include @@ -168,5 +182,6 @@ guint ephy_label_parse_uline (EphyLabel *label, } #endif /* __cplusplus */ +#endif /* GTK_CHECK_VERSION (2, 5, 1) */ #endif /* __EPHY_LABEL_H__ */ -- cgit v1.2.3