Permalink
Browse files

Replace deprecated GTK+ symbols

Signed-off-by: Matthew Brush <matt@xfce.org>
  • Loading branch information...
1 parent 75d0fbb commit 8d562e62c9496a8d8f012665d2dec416086db91a @MarkTr MarkTr committed with Jan 26, 2012
View
@@ -82,7 +82,7 @@ dnl *** Check for required packages ***
dnl ***********************************
XDT_CHECK_PACKAGE([GLIB], [glib-2.0], [2.12.0])
XDT_CHECK_PACKAGE([GTHREAD], [gthread-2.0], [2.12.0])
-XDT_CHECK_PACKAGE([GTK], [gtk+-2.0], [2.10.0])
+XDT_CHECK_PACKAGE([GTK], [gtk+-2.0], [2.18.0])
XDT_CHECK_PACKAGE([GTKSOURCEVIEW], [gtksourceview-2.0])
dnl **********************************
@@ -578,7 +578,8 @@ mousepad_document_get_tab_label (MousepadDocument *document)
button = gtk_button_new ();
gtk_button_set_focus_on_click (GTK_BUTTON (button), FALSE);
gtk_button_set_relief (GTK_BUTTON (button), GTK_RELIEF_NONE);
- GTK_WIDGET_UNSET_FLAGS (button, GTK_CAN_DEFAULT | GTK_CAN_FOCUS);
+ gtk_widget_set_can_default(GTK_WIDGET(button), FALSE);
+ gtk_widget_set_can_focus(GTK_WIDGET(button), FALSE);
/* make button a bit smaller */
style = gtk_rc_style_new ();
@@ -457,7 +457,7 @@ mousepad_encoding_dialog_combo_changed (GtkComboBox *combo,
gint id;
/* get the selected item */
- if (GTK_WIDGET_SENSITIVE (combo) && gtk_combo_box_get_active_iter (combo, &iter))
+ if (gtk_widget_get_sensitive (GTK_WIDGET(combo)) && gtk_combo_box_get_active_iter (combo, &iter))
{
/* get the id */
gtk_tree_model_get (GTK_TREE_MODEL (dialog->store), &iter, COLUMN_ID, &id, -1);
@@ -469,7 +469,7 @@ mousepad_print_page_setup_dialog (GtkWidget *button,
/* get the toplevel of the button */
toplevel = gtk_widget_get_toplevel (button);
- if (G_UNLIKELY (!GTK_WIDGET_TOPLEVEL (toplevel)))
+ if (G_UNLIKELY (!gtk_widget_is_toplevel (toplevel)))
toplevel = NULL;
/* get the print settings */
@@ -475,7 +475,7 @@ mousepad_search_bar_highlight_timeout (gpointer user_data)
GtkEditable *
mousepad_search_bar_entry (MousepadSearchBar *bar)
{
- if (bar && GTK_WIDGET_HAS_FOCUS (bar->entry))
+ if (bar && gtk_widget_has_focus (bar->entry))
return GTK_EDITABLE (bar->entry);
else
return NULL;
@@ -105,7 +105,7 @@ static void mousepad_window_statusbar_filetype_toggled (GtkCheckM
/* notebook signals */
static void mousepad_window_notebook_switch_page (GtkNotebook *notebook,
- GtkNotebookPage *page,
+ GtkWidget *page,
guint page_num,
MousepadWindow *window);
static void mousepad_window_notebook_reordered (GtkNotebook *notebook,
@@ -787,7 +787,7 @@ mousepad_window_configure_event (GtkWidget *widget,
g_source_remove (window->save_geometry_timer_id);
/* check if we should schedule another save timer */
- if (GTK_WIDGET_VISIBLE (widget))
+ if (gtk_widget_get_visible (widget))
{
/* save the geometry one second after the last configure event */
window->save_geometry_timer_id = g_timeout_add_full (G_PRIORITY_LOW, 1000, mousepad_window_save_geometry_timer,
@@ -911,7 +911,7 @@ mousepad_window_save_geometry_timer (gpointer user_data)
if (G_LIKELY (remember_geometry))
{
/* check if the window is still visible */
- if (GTK_WIDGET_VISIBLE (window))
+ if (gtk_widget_get_visible (GTK_WIDGET(window)))
{
/* determine the current state of the window */
state = gdk_window_get_state (GTK_WIDGET (window)->window);
@@ -1402,7 +1402,7 @@ mousepad_window_populate_statusbar_popup (MousepadWindow *window,
**/
static void
mousepad_window_notebook_switch_page (GtkNotebook *notebook,
- GtkNotebookPage *page,
+ GtkWidget *page,
guint page_num,
MousepadWindow *window)
{

0 comments on commit 8d562e6

Please sign in to comment.