aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristian Persch <chpe@cvs.gnome.org>2004-08-09 18:35:24 +0800
committerChristian Persch <chpe@src.gnome.org>2004-08-09 18:35:24 +0800
commitfedbee566107f89acab946d5ebd4ef3f5f6d7bdb (patch)
tree22998102da72b72b9d6720dd54a7718fd71e1b1e
parentdfa44d593b805613c57550eda9863e24e3235645 (diff)
downloadgsoc2013-epiphany-fedbee566107f89acab946d5ebd4ef3f5f6d7bdb.tar
gsoc2013-epiphany-fedbee566107f89acab946d5ebd4ef3f5f6d7bdb.tar.gz
gsoc2013-epiphany-fedbee566107f89acab946d5ebd4ef3f5f6d7bdb.tar.bz2
gsoc2013-epiphany-fedbee566107f89acab946d5ebd4ef3f5f6d7bdb.tar.lz
gsoc2013-epiphany-fedbee566107f89acab946d5ebd4ef3f5f6d7bdb.tar.xz
gsoc2013-epiphany-fedbee566107f89acab946d5ebd4ef3f5f6d7bdb.tar.zst
gsoc2013-epiphany-fedbee566107f89acab946d5ebd4ef3f5f6d7bdb.zip
Only use this for gtk < 2.5.1, and just add a few #defines otherwise.
2004-08-09 Christian Persch <chpe@cvs.gnome.org> * 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.
-rw-r--r--ChangeLog8
-rw-r--r--lib/widgets/ephy-label.c9
-rw-r--r--lib/widgets/ephy-label.h15
3 files changed, 31 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index efb2e8463..436719893 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,13 @@
2004-08-09 Christian Persch <chpe@cvs.gnome.org>
+ * 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 <chpe@cvs.gnome.org>
+
* src/bookmarks/ephy-topics-selector.c:
(ephy_topics_selector_get_type), (ephy_topics_selector_apply),
(provide_toggle), (ephy_topics_selector_constructor),
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 <gtk/gtkversion.h>
+
+#if !GTK_CHECK_VERSION (2, 5, 1)
+
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
+#include "ephy-label.h"
+
#include <math.h>
#include <string.h>
-#include "ephy-label.h"
#include <gtk/gtkmain.h>
#include <gtk/gtkwindow.h>
#include <gdk/gdkkeysyms.h>
@@ -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 <gtk/gtkversion.h>
+
+#if GTK_CHECK_VERSION (2, 5, 1)
+
+#include <gtk/gtklabel.h>
+
+#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 <gdk/gdk.h>
#include <gtk/gtkmisc.h>
@@ -168,5 +182,6 @@ guint ephy_label_parse_uline (EphyLabel *label,
}
#endif /* __cplusplus */
+#endif /* GTK_CHECK_VERSION (2, 5, 1) */
#endif /* __EPHY_LABEL_H__ */