[epiphany] Update for latest GTK+ 3.x release.
- From: Xan Lopez <xan src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [epiphany] Update for latest GTK+ 3.x release.
- Date: Sat, 11 Sep 2010 13:24:20 +0000 (UTC)
commit e46901eb21ddd73117ab28e0260c651698e7255b
Author: Xan Lopez <xan gnome org>
Date: Sat Sep 11 22:23:56 2010 +0900
Update for latest GTK+ 3.x release.
configure.ac | 2 +-
lib/widgets/ephy-location-entry.c | 10 +++---
lib/widgets/ephy-node-view.c | 8 ++--
src/bookmarks/ephy-bookmark-action.c | 6 ++--
src/bookmarks/ephy-bookmarks-editor.c | 2 +-
src/ephy-find-toolbar.c | 34 ++++++++++----------
src/ephy-history-window.c | 4 +-
src/ephy-main.c | 2 +-
src/ephy-window.c | 56 ++++++++++++++++----------------
src/pdm-dialog.c | 2 +-
10 files changed, 63 insertions(+), 63 deletions(-)
---
diff --git a/configure.ac b/configure.ac
index 4f1ab51..656acda 100644
--- a/configure.ac
+++ b/configure.ac
@@ -94,7 +94,7 @@ if test "$enable_maintainer_mode" = "yes"; then
fi
GLIB_REQUIRED=2.19.7
-GTK_REQUIRED=2.90.4
+GTK_REQUIRED=2.90.7
LIBXML_REQUIRED=2.6.12
LIBXSLT_REQUIRED=1.1.7
LIBSTARTUP_NOTIFICATION_REQUIRED=0.5
diff --git a/lib/widgets/ephy-location-entry.c b/lib/widgets/ephy-location-entry.c
index a2bdc44..f1028b5 100644
--- a/lib/widgets/ephy-location-entry.c
+++ b/lib/widgets/ephy-location-entry.c
@@ -476,7 +476,7 @@ entry_key_press_cb (GtkEntry *entry,
{
guint state = event->state & gtk_accelerator_get_default_mod_mask ();
- if (event->keyval == GDK_Escape && state == 0)
+ if (event->keyval == GDK_KEY_Escape && state == 0)
{
ephy_location_entry_reset_internal (lentry, TRUE);
/* don't return TRUE since we want to cancel the autocompletion popup too */
@@ -494,9 +494,9 @@ entry_key_press_after_cb (GtkEntry *entry,
guint state = event->state & gtk_accelerator_get_default_mod_mask ();
- if ((event->keyval == GDK_Return ||
- event->keyval == GDK_KP_Enter ||
- event->keyval == GDK_ISO_Enter) &&
+ if ((event->keyval == GDK_KEY_Return ||
+ event->keyval == GDK_KEY_KP_Enter ||
+ event->keyval == GDK_KEY_ISO_Enter) &&
(state == GDK_CONTROL_MASK ||
state == (GDK_CONTROL_MASK | GDK_SHIFT_MASK)))
{
@@ -508,7 +508,7 @@ entry_key_press_after_cb (GtkEntry *entry,
return TRUE;
}
- if ((event->keyval == GDK_Down || event->keyval == GDK_KP_Down)
+ if ((event->keyval == GDK_KEY_Down || event->keyval == GDK_KEY_KP_Down)
&& state == 0)
{
/* If we are focusing the entry, with the cursor at the end of it
diff --git a/lib/widgets/ephy-node-view.c b/lib/widgets/ephy-node-view.c
index 1e7fd5c..91ef650 100644
--- a/lib/widgets/ephy-node-view.c
+++ b/lib/widgets/ephy-node-view.c
@@ -611,10 +611,10 @@ ephy_node_view_key_press_cb (GtkTreeView *treeview,
{
gboolean handled = FALSE;
- if (event->keyval == GDK_space ||
- event->keyval == GDK_Return ||
- event->keyval == GDK_KP_Enter ||
- event->keyval == GDK_ISO_Enter)
+ if (event->keyval == GDK_KEY_space ||
+ event->keyval == GDK_KEY_Return ||
+ event->keyval == GDK_KEY_KP_Enter ||
+ event->keyval == GDK_KEY_ISO_Enter)
{
if (view->priv->toggle_column >= 0)
{
diff --git a/src/bookmarks/ephy-bookmark-action.c b/src/bookmarks/ephy-bookmark-action.c
index 241b378..f6a432f 100644
--- a/src/bookmarks/ephy-bookmark-action.c
+++ b/src/bookmarks/ephy-bookmark-action.c
@@ -410,9 +410,9 @@ entry_key_press_cb (GtkEntry *entry,
{
guint state = event->state & gtk_accelerator_get_default_mod_mask ();
- if ((event->keyval == GDK_Return ||
- event->keyval == GDK_KP_Enter ||
- event->keyval == GDK_ISO_Enter) &&
+ if ((event->keyval == GDK_KEY_Return ||
+ event->keyval == GDK_KEY_KP_Enter ||
+ event->keyval == GDK_KEY_ISO_Enter) &&
state == GDK_CONTROL_MASK)
{
#if GTK_CHECK_VERSION (2,21,0)
diff --git a/src/bookmarks/ephy-bookmarks-editor.c b/src/bookmarks/ephy-bookmarks-editor.c
index 6a7c27b..2f81b8c 100644
--- a/src/bookmarks/ephy-bookmarks-editor.c
+++ b/src/bookmarks/ephy-bookmarks-editor.c
@@ -1500,7 +1500,7 @@ key_pressed_cb (EphyNodeView *view,
EphyBookmarksEditorPrivate *priv = editor->priv;
GtkAction *action;
- if (event->keyval == GDK_Delete || event->keyval == GDK_KP_Delete)
+ if (event->keyval == GDK_KEY_Delete || event->keyval == GDK_KEY_KP_Delete)
{
action = gtk_action_group_get_action (priv->action_group, "Delete");
if (gtk_action_get_sensitive (action))
diff --git a/src/ephy-find-toolbar.c b/src/ephy-find-toolbar.c
index c9fb2c4..a3ebd9c 100644
--- a/src/ephy-find-toolbar.c
+++ b/src/ephy-find-toolbar.c
@@ -200,12 +200,12 @@ tab_search_key_press_cb (EphyEmbed *embed,
/* check for / and ' which open the find toolbar in text resp. link mode */
if (gtk_widget_get_visible (widget) == FALSE)
{
- if (event->keyval == GDK_slash)
+ if (event->keyval == GDK_KEY_slash)
{
ephy_find_toolbar_open (toolbar, FALSE, TRUE);
return TRUE;
}
- else if (event->keyval == GDK_apostrophe)
+ else if (event->keyval == GDK_KEY_apostrophe)
{
ephy_find_toolbar_open (toolbar, TRUE, TRUE);
return TRUE;
@@ -329,23 +329,23 @@ entry_key_press_event_cb (GtkEntry *entry,
handled = TRUE;
switch (event->keyval)
{
- case GDK_Up:
- case GDK_KP_Up:
+ case GDK_KEY_Up:
+ case GDK_KEY_KP_Up:
scroll_lines (priv->web_view, -1);
break;
- case GDK_Down:
- case GDK_KP_Down:
+ case GDK_KEY_Down:
+ case GDK_KEY_KP_Down:
scroll_lines (priv->web_view, 1);
break;
- case GDK_Page_Up:
- case GDK_KP_Page_Up:
+ case GDK_KEY_Page_Up:
+ case GDK_KEY_KP_Page_Up:
scroll_pages (priv->web_view, -1);
break;
- case GDK_Page_Down:
- case GDK_KP_Page_Down:
+ case GDK_KEY_Page_Down:
+ case GDK_KEY_KP_Page_Down:
scroll_pages (priv->web_view, 1);
break;
- case GDK_Escape:
+ case GDK_KEY_Escape:
/* Hide the toolbar when ESC is pressed */
ephy_find_toolbar_request_close (toolbar);
break;
@@ -355,16 +355,16 @@ entry_key_press_event_cb (GtkEntry *entry,
}
}
else if ((event->state & mask) == GDK_CONTROL_MASK &&
- (event->keyval == GDK_Return ||
- event->keyval == GDK_KP_Enter ||
- event->keyval == GDK_ISO_Enter))
+ (event->keyval == GDK_KEY_Return ||
+ event->keyval == GDK_KEY_KP_Enter ||
+ event->keyval == GDK_KEY_ISO_Enter))
{
handled = ephy_find_toolbar_activate_link (toolbar, event->state);
}
else if ((event->state & mask) == GDK_SHIFT_MASK &&
- (event->keyval == GDK_Return ||
- event->keyval == GDK_KP_Enter ||
- event->keyval == GDK_ISO_Enter))
+ (event->keyval == GDK_KEY_Return ||
+ event->keyval == GDK_KEY_KP_Enter ||
+ event->keyval == GDK_KEY_ISO_Enter))
{
handled = TRUE;
g_signal_emit (toolbar, signals[PREVIOUS], 0);
diff --git a/src/ephy-history-window.c b/src/ephy-history-window.c
index 4500c15..6fabfbd 100644
--- a/src/ephy-history-window.c
+++ b/src/ephy-history-window.c
@@ -815,8 +815,8 @@ key_pressed_cb (EphyNodeView *view,
{
switch (event->keyval)
{
- case GDK_Delete:
- case GDK_KP_Delete:
+ case GDK_KEY_Delete:
+ case GDK_KEY_KP_Delete:
cmd_delete (NULL, editor);
return TRUE;
diff --git a/src/ephy-main.c b/src/ephy-main.c
index b4e55d6..dd7b69f 100644
--- a/src/ephy-main.c
+++ b/src/ephy-main.c
@@ -641,7 +641,7 @@ main (int argc,
/* Get a timestamp manually if need be */
if (user_time == 0)
{
- user_time = slowly_and_stupidly_obtain_timestamp (gdk_display);
+ user_time = slowly_and_stupidly_obtain_timestamp (GDK_DISPLAY_XDISPLAY (gdk_display_get_default ()));
}
/* sets the name to appear in the window list applet when grouping windows */
diff --git a/src/ephy-window.c b/src/ephy-window.c
index d5c7511..0f8a666 100644
--- a/src/ephy-window.c
+++ b/src/ephy-window.c
@@ -359,38 +359,38 @@ static const struct
const gchar *action;
gboolean fromToolbar;
} extra_keybindings [] = {
- { GDK_s, GDK_CONTROL_MASK, "FileSaveAs", FALSE },
- { GDK_R, GDK_CONTROL_MASK |
+ { GDK_KEY_s, GDK_CONTROL_MASK, "FileSaveAs", FALSE },
+ { GDK_KEY_R, GDK_CONTROL_MASK |
GDK_SHIFT_MASK, "ViewReload", FALSE },
/* Support all the MSIE tricks as well ;) */
- { GDK_F5, 0, "ViewReload", FALSE },
- { GDK_F5, GDK_CONTROL_MASK, "ViewReload", FALSE },
- { GDK_F5, GDK_SHIFT_MASK, "ViewReload", FALSE },
- { GDK_F5, GDK_CONTROL_MASK |
+ { GDK_KEY_F5, 0, "ViewReload", FALSE },
+ { GDK_KEY_F5, GDK_CONTROL_MASK, "ViewReload", FALSE },
+ { GDK_KEY_F5, GDK_SHIFT_MASK, "ViewReload", FALSE },
+ { GDK_KEY_F5, GDK_CONTROL_MASK |
GDK_SHIFT_MASK, "ViewReload", FALSE },
- { GDK_KP_Add, GDK_CONTROL_MASK, "ViewZoomIn", FALSE },
- { GDK_KP_Subtract, GDK_CONTROL_MASK, "ViewZoomOut", FALSE },
- { GDK_equal, GDK_CONTROL_MASK, "ViewZoomIn", FALSE },
- { GDK_KP_0, GDK_CONTROL_MASK, "ViewZoomNormal", FALSE },
+ { GDK_KEY_KP_Add, GDK_CONTROL_MASK, "ViewZoomIn", FALSE },
+ { GDK_KEY_KP_Subtract, GDK_CONTROL_MASK, "ViewZoomOut", FALSE },
+ { GDK_KEY_equal, GDK_CONTROL_MASK, "ViewZoomIn", FALSE },
+ { GDK_KEY_KP_0, GDK_CONTROL_MASK, "ViewZoomNormal", FALSE },
/* These keys are a bit strange: when pressed with no modifiers, they emit
* KP_PageUp/Down Control; when pressed with Control+Shift they are KP_9/3,
* when NumLock is on they are KP_9/3 and with NumLock and Control+Shift
* They're KP_PageUp/Down again!
*/
- { GDK_KP_Left, GDK_MOD1_MASK /*Alt*/, "NavigationBack", TRUE },
- { GDK_KP_4, GDK_MOD1_MASK /*Alt*/, "NavigationBack", TRUE },
- { GDK_KP_Right, GDK_MOD1_MASK /*Alt*/, "NavigationForward", TRUE },
- { GDK_KP_6, GDK_MOD1_MASK /*Alt*/, "NavigationForward", TRUE },
- { GDK_KP_Up, GDK_MOD1_MASK /*Alt*/, "NavigationUp", TRUE },
- { GDK_KP_8, GDK_MOD1_MASK /*Alt*/, "NavigationUp", TRUE },
- { GDK_KP_Page_Up, GDK_CONTROL_MASK, "TabsPrevious", FALSE },
- { GDK_KP_9, GDK_CONTROL_MASK, "TabsPrevious", FALSE },
- { GDK_KP_Page_Down, GDK_CONTROL_MASK, "TabsNext", FALSE },
- { GDK_KP_3, GDK_CONTROL_MASK, "TabsNext", FALSE },
- { GDK_KP_Page_Up, GDK_SHIFT_MASK | GDK_CONTROL_MASK, "TabsMoveLeft", FALSE },
- { GDK_KP_9, GDK_SHIFT_MASK | GDK_CONTROL_MASK, "TabsMoveLeft", FALSE },
- { GDK_KP_Page_Down, GDK_SHIFT_MASK | GDK_CONTROL_MASK, "TabsMoveRight", FALSE },
- { GDK_KP_3, GDK_SHIFT_MASK | GDK_CONTROL_MASK, "TabsMoveRight", FALSE },
+ { GDK_KEY_KP_Left, GDK_MOD1_MASK /*Alt*/, "NavigationBack", TRUE },
+ { GDK_KEY_KP_4, GDK_MOD1_MASK /*Alt*/, "NavigationBack", TRUE },
+ { GDK_KEY_KP_Right, GDK_MOD1_MASK /*Alt*/, "NavigationForward", TRUE },
+ { GDK_KEY_KP_6, GDK_MOD1_MASK /*Alt*/, "NavigationForward", TRUE },
+ { GDK_KEY_KP_Up, GDK_MOD1_MASK /*Alt*/, "NavigationUp", TRUE },
+ { GDK_KEY_KP_8, GDK_MOD1_MASK /*Alt*/, "NavigationUp", TRUE },
+ { GDK_KEY_KP_Page_Up, GDK_CONTROL_MASK, "TabsPrevious", FALSE },
+ { GDK_KEY_KP_9, GDK_CONTROL_MASK, "TabsPrevious", FALSE },
+ { GDK_KEY_KP_Page_Down, GDK_CONTROL_MASK, "TabsNext", FALSE },
+ { GDK_KEY_KP_3, GDK_CONTROL_MASK, "TabsNext", FALSE },
+ { GDK_KEY_KP_Page_Up, GDK_SHIFT_MASK | GDK_CONTROL_MASK, "TabsMoveLeft", FALSE },
+ { GDK_KEY_KP_9, GDK_SHIFT_MASK | GDK_CONTROL_MASK, "TabsMoveLeft", FALSE },
+ { GDK_KEY_KP_Page_Down, GDK_SHIFT_MASK | GDK_CONTROL_MASK, "TabsMoveRight", FALSE },
+ { GDK_KEY_KP_3, GDK_SHIFT_MASK | GDK_CONTROL_MASK, "TabsMoveRight", FALSE },
#ifdef HAVE_X11_XF86KEYSYM_H
{ XF86XK_Back, 0, "NavigationBack", TRUE },
{ XF86XK_Favorites, 0, "GoBookmarks", FALSE },
@@ -919,7 +919,7 @@ ephy_window_key_press_event (GtkWidget *widget,
* widget), otherwise the event follows the normal handling path.
*/
- if (event->keyval == GDK_Escape && modifier == 0)
+ if (event->keyval == GDK_KEY_Escape && modifier == 0)
{
/* Always pass Escape to both the widget, and the parent */
shortcircuit = TRUE;
@@ -929,9 +929,9 @@ ephy_window_key_press_event (GtkWidget *widget,
(modifier == GDK_CONTROL_MASK) &&
event->length > 0 &&
/* But don't pass Ctrl+Enter twice */
- event->keyval != GDK_Return &&
- event->keyval != GDK_KP_Enter &&
- event->keyval != GDK_ISO_Enter)
+ event->keyval != GDK_KEY_Return &&
+ event->keyval != GDK_KEY_KP_Enter &&
+ event->keyval != GDK_KEY_ISO_Enter)
{
/* Pass CTRL+letter characters to the widget */
shortcircuit = TRUE;
diff --git a/src/pdm-dialog.c b/src/pdm-dialog.c
index 7824627..aae26c0 100644
--- a/src/pdm-dialog.c
+++ b/src/pdm-dialog.c
@@ -589,7 +589,7 @@ pdm_key_pressed_cb (GtkTreeView *treeview,
GdkEventKey *event,
PdmActionInfo *action)
{
- if (event->keyval == GDK_Delete || event->keyval == GDK_KP_Delete)
+ if (event->keyval == GDK_KEY_Delete || event->keyval == GDK_KEY_KP_Delete)
{
pdm_cmd_delete_selection (action);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]