Clean up a few build warnings
Mostly just missing casts and removing a couple now unused functions and variables.
This commit is contained in:
parent
39dcfcab0b
commit
19354f86c1
|
@ -533,7 +533,6 @@ save_dialog_response_cb (XedFileChooserDialog *dialog,
|
||||||
{
|
{
|
||||||
XedTab *tab;
|
XedTab *tab;
|
||||||
XedWindow *window;
|
XedWindow *window;
|
||||||
GtkSourceFile *file;
|
|
||||||
GFile *location;
|
GFile *location;
|
||||||
gchar *parse_name;
|
gchar *parse_name;
|
||||||
GtkSourceNewlineType newline_type;
|
GtkSourceNewlineType newline_type;
|
||||||
|
|
|
@ -282,26 +282,6 @@ on_auto_save_interval_changed (GSettings *settings,
|
||||||
g_list_free (docs);
|
g_list_free (docs);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
|
||||||
on_wrap_mode_changed (GSettings *settings,
|
|
||||||
const gchar *key,
|
|
||||||
XedSettings *xs)
|
|
||||||
{
|
|
||||||
GtkWrapMode wrap_mode;
|
|
||||||
GList *views, *l;
|
|
||||||
|
|
||||||
wrap_mode = g_settings_get_enum (settings, key);
|
|
||||||
|
|
||||||
views = xed_app_get_views (XED_APP (g_application_get_default ()));
|
|
||||||
|
|
||||||
for (l = views; l != NULL; l = g_list_next (l))
|
|
||||||
{
|
|
||||||
gtk_text_view_set_wrap_mode (GTK_TEXT_VIEW (l->data), wrap_mode);
|
|
||||||
}
|
|
||||||
|
|
||||||
g_list_free (views);
|
|
||||||
}
|
|
||||||
|
|
||||||
static void
|
static void
|
||||||
on_syntax_highlighting_changed (GSettings *settings,
|
on_syntax_highlighting_changed (GSettings *settings,
|
||||||
const gchar *key,
|
const gchar *key,
|
||||||
|
|
|
@ -7,7 +7,6 @@ G_DEFINE_TYPE (XedViewGutterRenderer, xed_view_gutter_renderer, GTK_SOURCE_TYPE_
|
||||||
static void
|
static void
|
||||||
xed_view_gutter_renderer_class_init (XedViewGutterRendererClass *klass)
|
xed_view_gutter_renderer_class_init (XedViewGutterRendererClass *klass)
|
||||||
{
|
{
|
||||||
GtkSourceGutterRendererClass *renderer_class = GTK_SOURCE_GUTTER_RENDERER_CLASS (klass);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
|
|
@ -1197,7 +1197,6 @@ create_menu_bar_and_toolbar (XedWindow *window,
|
||||||
GtkUIManager *manager;
|
GtkUIManager *manager;
|
||||||
GtkRecentManager *recent_manager;
|
GtkRecentManager *recent_manager;
|
||||||
GError *error = NULL;
|
GError *error = NULL;
|
||||||
gchar *ui_file;
|
|
||||||
GtkWidget *tool_item;
|
GtkWidget *tool_item;
|
||||||
GtkWidget *tool_box;
|
GtkWidget *tool_box;
|
||||||
GtkWidget *box;
|
GtkWidget *box;
|
||||||
|
@ -2170,7 +2169,7 @@ show_overview_map_changed (GObject *object,
|
||||||
map_frame = GTK_FRAME (object);
|
map_frame = GTK_FRAME (object);
|
||||||
action = gtk_action_group_get_action (window->priv->always_sensitive_action_group, "ViewOverviewMap");
|
action = gtk_action_group_get_action (window->priv->always_sensitive_action_group, "ViewOverviewMap");
|
||||||
|
|
||||||
if (gtk_widget_get_visible (map_frame))
|
if (gtk_widget_get_visible (GTK_WIDGET (map_frame)))
|
||||||
{
|
{
|
||||||
overveiw_map_visible = TRUE;
|
overveiw_map_visible = TRUE;
|
||||||
}
|
}
|
||||||
|
@ -2223,7 +2222,7 @@ notebook_switch_page (GtkNotebook *book,
|
||||||
|
|
||||||
if (window->priv->show_overview_map_id)
|
if (window->priv->show_overview_map_id)
|
||||||
{
|
{
|
||||||
g_signal_handler_disconnect (xed_view_frame_get_map_frame (_xed_tab_get_view_frame (window->priv->active_tab)), window->priv->show_overview_map_id);
|
g_signal_handler_disconnect (xed_view_frame_get_map_frame (XED_VIEW_FRAME (_xed_tab_get_view_frame (window->priv->active_tab))), window->priv->show_overview_map_id);
|
||||||
window->priv->show_overview_map_id = 0;
|
window->priv->show_overview_map_id = 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -2253,7 +2252,7 @@ notebook_switch_page (GtkNotebook *book,
|
||||||
update_languages_menu (window);
|
update_languages_menu (window);
|
||||||
|
|
||||||
view = xed_tab_get_view (tab);
|
view = xed_tab_get_view (tab);
|
||||||
map_frame = xed_view_frame_get_map_frame (_xed_tab_get_view_frame (tab));
|
map_frame = xed_view_frame_get_map_frame (XED_VIEW_FRAME (_xed_tab_get_view_frame (tab)));
|
||||||
|
|
||||||
/* sync the statusbar */
|
/* sync the statusbar */
|
||||||
update_cursor_position_statusbar (GTK_TEXT_BUFFER (xed_tab_get_document (tab)), window);
|
update_cursor_position_statusbar (GTK_TEXT_BUFFER (xed_tab_get_document (tab)), window);
|
||||||
|
@ -2360,15 +2359,6 @@ set_sensitivity_according_to_window_state (XedWindow *window)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
|
||||||
update_tab_autosave (GtkWidget *widget,
|
|
||||||
gpointer data)
|
|
||||||
{
|
|
||||||
XedTab *tab = XED_TAB(widget);
|
|
||||||
gboolean *enabled = (gboolean *) data;
|
|
||||||
xed_tab_set_auto_save_enabled (tab, *enabled);
|
|
||||||
}
|
|
||||||
|
|
||||||
static void
|
static void
|
||||||
analyze_tab_state (XedTab *tab,
|
analyze_tab_state (XedTab *tab,
|
||||||
XedWindow *window)
|
XedWindow *window)
|
||||||
|
@ -2444,7 +2434,7 @@ update_can_close (XedWindow *window)
|
||||||
GList *l;
|
GList *l;
|
||||||
gboolean can_close = TRUE;
|
gboolean can_close = TRUE;
|
||||||
|
|
||||||
tabs = xed_notebook_get_all_tabs (priv->notebook);
|
tabs = xed_notebook_get_all_tabs (XED_NOTEBOOK (priv->notebook));
|
||||||
|
|
||||||
for (l = tabs; l != NULL; l = g_list_next (l))
|
for (l = tabs; l != NULL; l = g_list_next (l))
|
||||||
{
|
{
|
||||||
|
@ -2947,7 +2937,7 @@ notebook_tab_removed (XedNotebook *notebook,
|
||||||
--window->priv->num_tabs;
|
--window->priv->num_tabs;
|
||||||
|
|
||||||
view = xed_tab_get_view (tab);
|
view = xed_tab_get_view (tab);
|
||||||
frame = _xed_tab_get_view_frame (tab);
|
frame = XED_VIEW_FRAME (_xed_tab_get_view_frame (tab));
|
||||||
doc = xed_tab_get_document (tab);
|
doc = xed_tab_get_document (tab);
|
||||||
|
|
||||||
g_signal_handlers_disconnect_by_func (tab, G_CALLBACK (sync_name), window);
|
g_signal_handlers_disconnect_by_func (tab, G_CALLBACK (sync_name), window);
|
||||||
|
@ -3150,7 +3140,7 @@ side_panel_size_allocate (GtkWidget *widget,
|
||||||
GtkAllocation *allocation,
|
GtkAllocation *allocation,
|
||||||
XedWindow *window)
|
XedWindow *window)
|
||||||
{
|
{
|
||||||
if (!xed_paned_get_is_animating (window->priv->hpaned))
|
if (!xed_paned_get_is_animating (XED_PANED (window->priv->hpaned)))
|
||||||
{
|
{
|
||||||
window->priv->side_panel_size = allocation->width;
|
window->priv->side_panel_size = allocation->width;
|
||||||
}
|
}
|
||||||
|
@ -3161,7 +3151,7 @@ bottom_panel_size_allocate (GtkWidget *widget,
|
||||||
GtkAllocation *allocation,
|
GtkAllocation *allocation,
|
||||||
XedWindow *window)
|
XedWindow *window)
|
||||||
{
|
{
|
||||||
if (!xed_paned_get_is_animating (window->priv->vpaned))
|
if (!xed_paned_get_is_animating (XED_PANED (window->priv->vpaned)))
|
||||||
{
|
{
|
||||||
window->priv->bottom_panel_size = allocation->height;
|
window->priv->bottom_panel_size = allocation->height;
|
||||||
}
|
}
|
||||||
|
@ -3282,7 +3272,7 @@ bottom_panel_item_removed (XedPanel *panel,
|
||||||
{
|
{
|
||||||
GtkAction *action;
|
GtkAction *action;
|
||||||
|
|
||||||
xed_paned_close (window->priv->vpaned, 2);
|
xed_paned_close (XED_PANED (window->priv->vpaned), 2);
|
||||||
gtk_revealer_set_reveal_child (GTK_REVEALER (window->priv->bottom_pane_button_revealer), FALSE);
|
gtk_revealer_set_reveal_child (GTK_REVEALER (window->priv->bottom_pane_button_revealer), FALSE);
|
||||||
action = gtk_action_group_get_action (window->priv->panes_action_group, "ViewBottomPane");
|
action = gtk_action_group_get_action (window->priv->panes_action_group, "ViewBottomPane");
|
||||||
gtk_action_set_sensitive (action, FALSE);
|
gtk_action_set_sensitive (action, FALSE);
|
||||||
|
|
Loading…
Reference in New Issue