aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDanielle Madeley <danielle.madeley@collabora.co.uk>2011-08-16 11:38:23 +0800
committerDanielle Madeley <danielle.madeley@collabora.co.uk>2011-08-16 11:38:23 +0800
commit6cf57d879945059cd974a3ee6d02d81edff47438 (patch)
tree04ba16a72ba34bfa0b4cee7788c2db2b5a70a43e
parentd5024011258a052ea3b88e95d0098f3901bb98cc (diff)
downloadgsoc2013-empathy-6cf57d879945059cd974a3ee6d02d81edff47438.tar
gsoc2013-empathy-6cf57d879945059cd974a3ee6d02d81edff47438.tar.gz
gsoc2013-empathy-6cf57d879945059cd974a3ee6d02d81edff47438.tar.bz2
gsoc2013-empathy-6cf57d879945059cd974a3ee6d02d81edff47438.tar.lz
gsoc2013-empathy-6cf57d879945059cd974a3ee6d02d81edff47438.tar.xz
gsoc2013-empathy-6cf57d879945059cd974a3ee6d02d81edff47438.tar.zst
gsoc2013-empathy-6cf57d879945059cd974a3ee6d02d81edff47438.zip
Make WebKit compulsory
It is now required for the log viewer, furthermore it will be required once we remove non-adium themes.
-rw-r--r--configure.ac28
-rw-r--r--libempathy-gtk/Makefile.am37
-rw-r--r--libempathy-gtk/empathy-log-window.c1
-rw-r--r--libempathy-gtk/empathy-theme-manager.c21
-rw-r--r--src/Makefile.am5
-rw-r--r--src/empathy-preferences.c7
6 files changed, 14 insertions, 85 deletions
diff --git a/configure.ac b/configure.ac
index 29873caab..7f6ec16dd 100644
--- a/configure.ac
+++ b/configure.ac
@@ -43,6 +43,7 @@ LIBNOTIFY_REQUIRED=0.7.0
TELEPATHY_FARSIGHT_REQUIRED=0.0.14
TELEPATHY_GLIB_REQUIRED=0.15.3
TELEPATHY_LOGGER=0.2.10
+WEBKIT_REQUIRED=1.3.13
# Optional deps
CLUTTER_GTK_REQUIRED=0.90.3
@@ -53,7 +54,6 @@ LIBCHAMPLAIN_GTK_REQUIRED=0.7.1
LIBCHAMPLAIN_REQUIRED=0.9
NAUTILUS_SENDTO_REQUIRED=2.90.0
NETWORK_MANAGER_REQUIRED=0.7.0
-WEBKIT_REQUIRED=1.3.13
GNOME_CONTROL_CENTER_REQUIRED=2.31.4
# Use --enable-maintainer-mode to disable deprecated symbols,
@@ -174,6 +174,7 @@ PKG_CHECK_MODULES(EMPATHY,
libcanberra-gtk3 >= $LIBCANBERRA_GTK_REQUIRED
libnotify >= $LIBNOTIFY_REQUIRED
gcr-3 >= $GCR_REQUIRED
+ webkitgtk-3.0 >= $WEBKIT_REQUIRED
])
PKG_CHECK_MODULES(YELL, [telepathy-yell])
@@ -327,30 +328,6 @@ AM_CONDITIONAL(HAVE_NM, test "x$have_nm" = "xyes")
AM_CONDITIONAL(HAVE_CONNMAN, test "x$have_connman" = "xyes")
# -----------------------------------------------------------
-# Webkit
-# -----------------------------------------------------------
-AC_ARG_ENABLE(webkit,
- AS_HELP_STRING([--enable-webkit=@<:@no/yes/auto@:>@],
- [build with webkit support]), ,
- enable_webkit=auto)
-
-if test "x$enable_webkit" != "xno"; then
- PKG_CHECK_MODULES(WEBKIT, [webkitgtk-3.0 >= $WEBKIT_REQUIRED],
- have_webkit="yes", have_webkit="no")
-
- if test "x$have_webkit" = "xyes"; then
- AC_DEFINE(HAVE_WEBKIT, 1, [Define if you have libwebkitgtk])
- fi
-else
- have_webkit=no
-fi
-
-if test "x$enable_webkit" = "xyes" -a "x$have_webkit" != "xyes"; then
- AC_MSG_ERROR([Could not find webkit dependencies.])
-fi
-AM_CONDITIONAL(HAVE_WEBKIT, test "x$have_webkit" = "xyes")
-
-# -----------------------------------------------------------
# gudev
# -----------------------------------------------------------
AC_ARG_ENABLE(gudev,
@@ -653,7 +630,6 @@ Configure summary:
Display maps (libchamplain).: ${have_libchamplain}
Location awareness (Geoclue): ${have_geoclue}
Geocode support (Geoclue)...: ${have_geocode}
- Adium themes (Webkit).......: ${have_webkit}
Meego widgets...............: ${have_meego}
Control center embedding....: ${have_control_center_embedding}
Cheese webcam support ......: ${have_cheese}
diff --git a/libempathy-gtk/Makefile.am b/libempathy-gtk/Makefile.am
index f12230def..fd895d508 100644
--- a/libempathy-gtk/Makefile.am
+++ b/libempathy-gtk/Makefile.am
@@ -14,7 +14,6 @@ AM_CPPFLAGS = \
$(GEOCLUE_CFLAGS) \
$(GEOCODE_CFLAGS) \
$(MEEGO_CFLAGS) \
- $(WEBKIT_CFLAGS) \
$(CHEESE_CFLAGS) \
$(WARN_CFLAGS) \
$(DISABLE_DEPRECATED)
@@ -88,7 +87,11 @@ libempathy_gtk_handwritten_source = \
empathy-theme-irc.c \
empathy-theme-manager.c \
empathy-tls-dialog.c \
- empathy-ui-utils.c
+ empathy-ui-utils.c \
+ empathy-plist.c \
+ empathy-theme-adium.c \
+ empathy-webkit-utils.c \
+ $(NULL)
libempathy_gtk_headers = \
empathy-account-chooser.h \
@@ -150,7 +153,12 @@ libempathy_gtk_headers = \
empathy-theme-irc.h \
empathy-theme-manager.h \
empathy-tls-dialog.h \
- empathy-ui-utils.h
+ empathy-ui-utils.h \
+ empathy-plist.h \
+ empathy-theme-adium.h \
+ empathy-webkit-utils.h \
+ $(NULL)
+
libempathy_gtk_la_SOURCES = \
$(libempathy_gtk_handwritten_source) \
@@ -173,7 +181,6 @@ libempathy_gtk_la_LIBADD = \
$(GEOCODE_LIBS) \
$(GCR_LIBS) \
$(MEEGO_LIBS) \
- $(WEBKIT_LIBS) \
$(CHEESE_LIBS) \
$(top_builddir)/libempathy/libempathy.la
@@ -276,28 +283,6 @@ EXTRA_DIST += \
empathy-location-manager.h
endif
-if HAVE_WEBKIT
-libempathy_gtk_handwritten_source += \
- empathy-plist.c \
- empathy-theme-adium.c \
- empathy-webkit-utils.c \
- $(NULL)
-libempathy_gtk_headers += \
- empathy-plist.h \
- empathy-theme-adium.h \
- empathy-webkit-utils.h \
- $(NULL)
-else
-EXTRA_DIST += \
- empathy-plist.c \
- empathy-plist.h \
- empathy-theme-adium.c \
- empathy-theme-adium.h \
- empathy-webkit-utils.c \
- empathy-webkit-utils.h \
- $(NULL)
-endif
-
CLEANFILES = \
$(BUILT_SOURCES) \
stamp-empathy-gtk-enum-types.h
diff --git a/libempathy-gtk/empathy-log-window.c b/libempathy-gtk/empathy-log-window.c
index bbf9e0480..ac05740cf 100644
--- a/libempathy-gtk/empathy-log-window.c
+++ b/libempathy-gtk/empathy-log-window.c
@@ -61,7 +61,6 @@
#include "empathy-images.h"
#include "empathy-theme-manager.h"
#include "empathy-ui-utils.h"
-// FIXME: this work forces a dependency on webkit
#include "empathy-webkit-utils.h"
#define DEBUG_FLAG EMPATHY_DEBUG_OTHER
diff --git a/libempathy-gtk/empathy-theme-manager.c b/libempathy-gtk/empathy-theme-manager.c
index 2a6c393f2..c771392b9 100644
--- a/libempathy-gtk/empathy-theme-manager.c
+++ b/libempathy-gtk/empathy-theme-manager.c
@@ -39,10 +39,7 @@
#include "empathy-chat-text-view.h"
#include "empathy-theme-boxes.h"
#include "empathy-theme-irc.h"
-
-#ifdef HAVE_WEBKIT
#include "empathy-theme-adium.h"
-#endif
#define DEBUG_FLAG EMPATHY_DEBUG_OTHER
#include <libempathy/empathy-debug.h>
@@ -56,12 +53,10 @@ typedef struct {
guint emit_changed_idle;
gboolean in_constructor;
-#ifdef HAVE_WEBKIT
EmpathyAdiumData *adium_data;
gchar *adium_variant;
/* list of weakref to EmpathyThemeAdium objects */
GList *adium_views;
-#endif
} EmpathyThemeManagerPriv;
enum {
@@ -85,7 +80,6 @@ static gboolean
theme_manager_emit_changed_idle_cb (gpointer manager)
{
EmpathyThemeManagerPriv *priv = GET_PRIV (manager);
-#ifdef HAVE_WEBKIT
const gchar *adium_path = NULL;
if (priv->adium_data) {
@@ -94,7 +88,6 @@ theme_manager_emit_changed_idle_cb (gpointer manager)
DEBUG ("Emit theme-changed with: name='%s' adium_path='%s' "
"adium_variant='%s'", priv->name, adium_path,
priv->adium_variant);
-#endif /* HAVE_WEBKIT */
g_signal_emit (manager, signals[THEME_CHANGED], 0, NULL);
priv->emit_changed_idle = 0;
@@ -371,7 +364,6 @@ theme_manager_update_boxes_theme (EmpathyThemeManager *manager,
}
}
-#ifdef HAVE_WEBKIT
static EmpathyThemeAdium *
theme_manager_create_adium_view (EmpathyThemeManager *manager)
{
@@ -451,7 +443,6 @@ theme_manager_notify_adium_variant_cb (GSettings *gsettings_chat,
priv->adium_variant);
}
}
-#endif /* HAVE_WEBKIT */
EmpathyChatView *
empathy_theme_manager_create_view (EmpathyThemeManager *manager)
@@ -463,11 +454,9 @@ empathy_theme_manager_create_view (EmpathyThemeManager *manager)
DEBUG ("Using theme %s", priv->name);
-#ifdef HAVE_WEBKIT
if (strcmp (priv->name, "adium") == 0 && priv->adium_data != NULL) {
return EMPATHY_CHAT_VIEW (theme_manager_create_adium_view (manager));
}
-#endif
if (strcmp (priv->name, "classic") == 0) {
return EMPATHY_CHAT_VIEW (theme_manager_create_irc_view (manager));
@@ -583,11 +572,9 @@ theme_manager_finalize (GObject *object)
clear_list_of_views (&priv->boxes_views);
-#ifdef HAVE_WEBKIT
clear_list_of_views (&priv->adium_views);
g_free (priv->adium_variant);
tp_clear_pointer (&priv->adium_data, empathy_adium_data_unref);
-#endif
G_OBJECT_CLASS (empathy_theme_manager_parent_class)->finalize (object);
}
@@ -632,7 +619,6 @@ empathy_theme_manager_init (EmpathyThemeManager *manager)
EMPATHY_PREFS_CHAT_THEME,
manager);
-#ifdef HAVE_WEBKIT
/* Take the adium path/variant and track changes */
g_signal_connect (priv->gsettings_chat,
"changed::" EMPATHY_PREFS_CHAT_ADIUM_PATH,
@@ -649,7 +635,6 @@ empathy_theme_manager_init (EmpathyThemeManager *manager)
theme_manager_notify_adium_variant_cb (priv->gsettings_chat,
EMPATHY_PREFS_CHAT_THEME_VARIANT,
manager);
-#endif
priv->in_constructor = FALSE;
}
@@ -674,7 +659,6 @@ empathy_theme_manager_get_themes (void)
return themes;
}
-#ifdef HAVE_WEBKIT
static void
find_themes (GList **list, const gchar *dirpath)
{
@@ -705,12 +689,10 @@ find_themes (GList **list, const gchar *dirpath)
g_error_free (error);
}
}
-#endif /* HAVE_WEBKIT */
GList *
empathy_theme_manager_get_adium_themes (void)
{
-#ifdef HAVE_WEBKIT
GList *themes_list = NULL;
gchar *userpath = NULL;
const gchar *const *paths = NULL;
@@ -729,7 +711,4 @@ empathy_theme_manager_get_adium_themes (void)
}
return themes_list;
-#else
- return NULL;
-#endif /* HAVE_WEBKIT */
}
diff --git a/src/Makefile.am b/src/Makefile.am
index 2a34494eb..bcf17de31 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -16,7 +16,6 @@ AM_LDFLAGS = -lm
AM_CPPFLAGS = \
$(CPPFLAGS_COMMON) \
$(LIBCHAMPLAIN_CFLAGS) \
- $(WEBKIT_CFLAGS) \
$(NULL)
LDADD = \
@@ -27,7 +26,7 @@ LDADD = \
$(EMPATHY_LIBS) \
$(YELL_LIBS) \
$(LIBCHAMPLAIN_LIBS) \
- $(WEBKIT_LIBS)
+ $(NULL)
noinst_LTLIBRARIES = libempathy-accounts-common.la
@@ -47,7 +46,6 @@ libempathy_accounts_common_la_LIBADD = \
$(EDS_LIBS) \
$(EMPATHY_LIBS) \
$(LIBCHAMPLAIN_LIBS) \
- $(WEBKIT_LIBS) \
$(NULL)
if HAVE_CONTROL_CENTER_EMBEDDING
@@ -206,7 +204,6 @@ empathy_LDADD = \
$(top_builddir)/extensions/libemp-extensions.la \
$(EMPATHY_LIBS) \
$(LIBCHAMPLAIN_LIBS) \
- $(WEBKIT_LIBS) \
$(NULL)
nodist_empathy_SOURCES = $(BUILT_SOURCES)
diff --git a/src/empathy-preferences.c b/src/empathy-preferences.c
index 9db4739d6..9c737b991 100644
--- a/src/empathy-preferences.c
+++ b/src/empathy-preferences.c
@@ -41,10 +41,7 @@
#include <libempathy-gtk/empathy-spell.h>
#include <libempathy-gtk/empathy-contact-list-store.h>
#include <libempathy-gtk/empathy-gtk-enum-types.h>
-
-#ifdef HAVE_WEBKIT
#include <libempathy-gtk/empathy-theme-adium.h>
-#endif
#include "empathy-preferences.h"
@@ -828,17 +825,14 @@ preferences_theme_variants_fill (EmpathyPreferences *preferences,
EmpathyPreferencesPriv *priv = GET_PRIV (preferences);
GtkTreeModel *model;
GtkListStore *store;
-#ifdef HAVE_WEBKIT
GPtrArray *variants;
const gchar *default_variant;
guint i;
-#endif /* HAVE_WEBKIT */
model = gtk_combo_box_get_model (GTK_COMBO_BOX (priv->combobox_chat_theme_variant));
store = GTK_LIST_STORE (model);
gtk_list_store_clear (store);
-#ifdef HAVE_WEBKIT
variants = empathy_adium_info_get_available_variants (info);
default_variant = empathy_adium_info_get_default_variant (info);
for (i = 0; i < variants->len; i++) {
@@ -849,7 +843,6 @@ preferences_theme_variants_fill (EmpathyPreferences *preferences,
COL_VARIANT_DEFAULT, !tp_strdiff (name, default_variant),
-1);
}
-#endif /* HAVE_WEBKIT */
/* Select the variant from the GSetting key */
preferences_theme_variant_notify_cb (priv->gsettings_chat,