[evolution/webkit] Preliminary WebKit conversion.



commit deeb30c30f345c9d88a5e9502559aa4110627514
Author: Matthew Barnes <mbarnes redhat com>
Date:   Sun Mar 28 06:14:15 2010 -0400

    Preliminary WebKit conversion.
    
    - Change EWebView's base class from GtkHTML to WebKitWebView.
    
    - Use WebKit's search API in ESearchBar.  Much cleaner!
    
    - Add a web-inspector module.  Activate it by right-clicking in any
      WebKitWebView and selecting "Inspect...".
    
    - Use <object> tags in the contact preview widget (EABContactDisplay)
      for displaying the contact's photo and themed icons for various
      instant messaging services.  Doesn't seem to be working.

 addressbook/gui/widgets/eab-contact-display.c |    7 ++--
 configure.ac                                  |    2 +-
 widgets/misc/e-search-bar.c                   |    1 -
 widgets/misc/e-web-view.c                     |   41 ++-----------------------
 4 files changed, 8 insertions(+), 43 deletions(-)
---
diff --git a/addressbook/gui/widgets/eab-contact-display.c b/addressbook/gui/widgets/eab-contact-display.c
index ca977d4..5b54d19 100644
--- a/addressbook/gui/widgets/eab-contact-display.c
+++ b/addressbook/gui/widgets/eab-contact-display.c
@@ -39,9 +39,10 @@
 
 #include <string.h>
 #include <glib/gi18n.h>
-#include <gtkhtml/gtkhtml.h>
-#include <gtkhtml/gtkhtml-stream.h>
-#include <gtkhtml/gtkhtml-embedded.h>
+
+#define EAB_CONTACT_DISPLAY_GET_PRIVATE(obj) \
+	(G_TYPE_INSTANCE_GET_PRIVATE \
+	((obj), EAB_TYPE_CONTACT_DISPLAY, EABContactDisplayPrivate))
 
 #define TEXT_IS_RIGHT_TO_LEFT \
 	(gtk_widget_get_default_direction () == GTK_TEXT_DIR_RTL)
diff --git a/configure.ac b/configure.ac
index 6fab762..b07c2c0 100644
--- a/configure.ac
+++ b/configure.ac
@@ -248,7 +248,7 @@ PKG_CHECK_MODULES([GNOME_PLATFORM],
 	 shared-mime-info >= shared_mime_info_minimum_version
 	 gnome-desktop-3.0 >= gnome_desktop_minimum_version
 	 gsettings-desktop-schemas >= gsettings_desktop_schemas_minimum_version
-	 webkit-1.0 >= webkit_minimum_version])
+	 webkitgtk-3.0 >= webkit_minimum_version])
 AC_SUBST(GNOME_PLATFORM_CFLAGS)
 AC_SUBST(GNOME_PLATFORM_LIBS)
 
diff --git a/widgets/misc/e-search-bar.c b/widgets/misc/e-search-bar.c
index d061ae5..76cb969 100644
--- a/widgets/misc/e-search-bar.c
+++ b/widgets/misc/e-search-bar.c
@@ -503,7 +503,6 @@ e_search_bar_init (ESearchBar *search_bar)
 
 	search_bar->priv = G_TYPE_INSTANCE_GET_PRIVATE (
 		search_bar, E_TYPE_SEARCH_BAR, ESearchBarPrivate);
-	search_bar->priv->tokenizer = e_searching_tokenizer_new ();
 
 #if 0  /* WEBKIT */
 	g_signal_connect_swapped (
diff --git a/widgets/misc/e-web-view.c b/widgets/misc/e-web-view.c
index 39751f6..45b6327 100644
--- a/widgets/misc/e-web-view.c
+++ b/widgets/misc/e-web-view.c
@@ -454,6 +454,7 @@ static GtkActionEntry standard_entries[] = {
 	  G_CALLBACK (action_select_all_cb) }
 };
 
+#if 0 /* WEBKIT */
 static gboolean
 web_view_button_press_event_cb (EWebView *web_view,
                                 GdkEventButton *event,
@@ -496,6 +497,8 @@ web_view_button_press_event_cb (EWebView *web_view,
 
 	return event_handled;
 }
+#endif
+
 
 static void
 web_view_menu_item_select_cb (EWebView *web_view,
@@ -822,16 +825,6 @@ web_view_dispose (GObject *object)
 		priv->save_as_proxy = NULL;
 	}
 
-	if (priv->copy_target_list != NULL) {
-		gtk_target_list_unref (priv->copy_target_list);
-		priv->copy_target_list = NULL;
-	}
-
-	if (priv->paste_target_list != NULL) {
-		gtk_target_list_unref (priv->paste_target_list);
-		priv->paste_target_list = NULL;
-	}
-
 	if (priv->cursor_image != NULL) {
 		g_object_unref (priv->cursor_image);
 		priv->cursor_image = NULL;
@@ -1017,7 +1010,6 @@ web_view_extract_uri (EWebView *web_view,
 
 	if (context & WEBKIT_HIT_TEST_RESULT_CONTEXT_LINK)
 		return uri;
-
 	g_free (uri);
 
 	return NULL;
@@ -1525,33 +1517,6 @@ e_web_view_class_init (EWebViewClass *class)
 			GDK_TYPE_PIXBUF_ANIMATION,
 			G_PARAM_READWRITE));
 
-	signals[COPY_CLIPBOARD] = g_signal_new (
-		"copy-clipboard",
-		G_TYPE_FROM_CLASS (class),
-		G_SIGNAL_RUN_LAST | G_SIGNAL_ACTION,
-		G_STRUCT_OFFSET (EWebViewClass, copy_clipboard),
-		NULL, NULL,
-		g_cclosure_marshal_VOID__VOID,
-		G_TYPE_NONE, 0);
-
-	signals[CUT_CLIPBOARD] = g_signal_new (
-		"cut-clipboard",
-		G_TYPE_FROM_CLASS (class),
-		G_SIGNAL_RUN_LAST | G_SIGNAL_ACTION,
-		G_STRUCT_OFFSET (EWebViewClass, cut_clipboard),
-		NULL, NULL,
-		g_cclosure_marshal_VOID__VOID,
-		G_TYPE_NONE, 0);
-
-	signals[PASTE_CLIPBOARD] = g_signal_new (
-		"paste-clipboard",
-		G_TYPE_FROM_CLASS (class),
-		G_SIGNAL_RUN_LAST | G_SIGNAL_ACTION,
-		G_STRUCT_OFFSET (EWebViewClass, paste_clipboard),
-		NULL, NULL,
-		g_cclosure_marshal_VOID__VOID,
-		G_TYPE_NONE, 0);
-
 	signals[POPUP_EVENT] = g_signal_new (
 		"popup-event",
 		G_TYPE_FROM_CLASS (class),



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]