aboutsummaryrefslogtreecommitdiffstats
path: root/mail/em-format-html-display.c
diff options
context:
space:
mode:
authorERDI Gergo <cactus@cactus.rulez.org>2004-01-07 22:29:08 +0800
committerÉRDI Gergo <cactus@src.gnome.org>2004-01-07 22:29:08 +0800
commite2b0897d8088cb4c118f4564e9f6de2845de3176 (patch)
tree23af259b80ece4d26fe94085123f326e7f60582b /mail/em-format-html-display.c
parent79373d6650bfb2f10b91772e10aafcd52badfb26 (diff)
downloadgsoc2013-evolution-e2b0897d8088cb4c118f4564e9f6de2845de3176.tar
gsoc2013-evolution-e2b0897d8088cb4c118f4564e9f6de2845de3176.tar.gz
gsoc2013-evolution-e2b0897d8088cb4c118f4564e9f6de2845de3176.tar.bz2
gsoc2013-evolution-e2b0897d8088cb4c118f4564e9f6de2845de3176.tar.lz
gsoc2013-evolution-e2b0897d8088cb4c118f4564e9f6de2845de3176.tar.xz
gsoc2013-evolution-e2b0897d8088cb4c118f4564e9f6de2845de3176.tar.zst
gsoc2013-evolution-e2b0897d8088cb4c118f4564e9f6de2845de3176.zip
Emit a hover-url signal when the user mouses over a URL, ...
2004-01-04 ERDI Gergo <cactus@cactus.rulez.org> * em-folder-view.c (emfv_on_url_cb): Emit a hover-url signal when the user mouses over a URL, ... (emfv_hover_url_impl): ... and use BonoboUI to change the status bar message... (em_folder_view_set_statusbar): ... unless we are asked not to, ... * mail-component.c (impl_createControls): ... like in the case of the mail component, ... (view_hover_url_cb): ... that uses the ActivityHandler to do the same Add these together, and #127536 is neatly solved. 2004-01-05 ERDI Gergo <cactus@cactus.rulez.org> * e-task-bar.c (init): Create a separate label to the left of the progress messages... (e_task_bar_message): ...and allow components to set it... * e-activity-handler.c (e_activity_handler_message): ...through this new ActivityHandler method svn path=/trunk/; revision=24086
Diffstat (limited to 'mail/em-format-html-display.c')
-rw-r--r--mail/em-format-html-display.c20
1 files changed, 20 insertions, 0 deletions
diff --git a/mail/em-format-html-display.c b/mail/em-format-html-display.c
index eaccf32e47..2c9b3c513e 100644
--- a/mail/em-format-html-display.c
+++ b/mail/em-format-html-display.c
@@ -106,6 +106,7 @@ struct _EMFormatHTMLDisplayPrivate {
static int efhd_html_button_press_event (GtkWidget *widget, GdkEventButton *event, EMFormatHTMLDisplay *efh);
static void efhd_html_link_clicked (GtkHTML *html, const char *url, EMFormatHTMLDisplay *efhd);
+static void efhd_html_on_url (GtkHTML *html, const char *url, EMFormatHTMLDisplay *efhd);
struct _attach_puri {
EMFormatPURI puri;
@@ -140,6 +141,7 @@ static void efhd_builtin_init(EMFormatHTMLDisplayClass *efhc);
enum {
EFHD_LINK_CLICKED,
EFHD_POPUP_EVENT,
+ EFHD_ON_URL,
EFHD_LAST_SIGNAL,
};
@@ -290,6 +292,16 @@ efhd_class_init(GObjectClass *klass)
GDK_TYPE_EVENT | G_SIGNAL_TYPE_STATIC_SCOPE,
G_TYPE_POINTER, G_TYPE_POINTER);
+ efhd_signals[EFHD_ON_URL] =
+ g_signal_new("on_url",
+ G_TYPE_FROM_CLASS(klass),
+ G_SIGNAL_RUN_LAST,
+ G_STRUCT_OFFSET(EMFormatHTMLDisplayClass, on_url),
+ NULL, NULL,
+ gtk_marshal_VOID__STRING,
+ G_TYPE_NONE, 1,
+ G_TYPE_STRING);
+
efhd_builtin_init((EMFormatHTMLDisplayClass *)klass);
}
@@ -324,6 +336,7 @@ EMFormatHTMLDisplay *em_format_html_display_new(void)
g_signal_connect(efhd->formathtml.html, "iframe_created", G_CALLBACK(efhd_iframe_created), efhd);
g_signal_connect(efhd->formathtml.html, "link_clicked", G_CALLBACK(efhd_html_link_clicked), efhd);
+ g_signal_connect(efhd->formathtml.html, "on_url", G_CALLBACK(efhd_html_on_url), efhd);
g_signal_connect(efhd->formathtml.html, "button_press_event", G_CALLBACK(efhd_html_button_press_event), efhd);
return efhd;
@@ -593,6 +606,13 @@ efhd_html_link_clicked (GtkHTML *html, const char *url, EMFormatHTMLDisplay *efh
}
static void
+efhd_html_on_url (GtkHTML *html, const char *url, EMFormatHTMLDisplay *efhd)
+{
+ d(printf("on_url event '%s'\n", url));
+ g_signal_emit((GObject *)efhd, efhd_signals[EFHD_ON_URL], 0, url);
+}
+
+static void
efhd_complete(EMFormat *emf)
{
EMFormatHTMLDisplay *efhd = (EMFormatHTMLDisplay *)emf;