window: show sources dialog
This commit is contained in:
committed by
Erick Pérez Castellanos
parent
3ef048c2a0
commit
6dccbfe431
@@ -196,6 +196,9 @@ static void remove_source (GcalManager *m
|
||||
ESource *source,
|
||||
gpointer user_data);
|
||||
|
||||
static void show_source_dialog (GtkButton *button,
|
||||
gpointer user_data);
|
||||
|
||||
static void on_calendar_toggled (GObject *object,
|
||||
GParamSpec *pspec,
|
||||
gpointer user_data);
|
||||
@@ -852,6 +855,15 @@ remove_source (GcalManager *manager,
|
||||
g_hash_table_remove (priv->calendar_source_to_row, source);
|
||||
}
|
||||
|
||||
static void
|
||||
show_source_dialog (GtkButton *button,
|
||||
gpointer user_data)
|
||||
{
|
||||
GcalWindowPrivate *priv = gcal_window_get_instance_private (GCAL_WINDOW (user_data));
|
||||
|
||||
gtk_window_present (GTK_WINDOW (priv->source_dialog));
|
||||
}
|
||||
|
||||
static void
|
||||
on_calendar_toggled (GObject *object,
|
||||
GParamSpec *pspec,
|
||||
@@ -1313,6 +1325,8 @@ gcal_window_class_init(GcalWindowClass *klass)
|
||||
gtk_widget_class_bind_template_child_private (widget_class, GcalWindow, notification_action_button);
|
||||
gtk_widget_class_bind_template_child_private (widget_class, GcalWindow, notification_close_button);
|
||||
|
||||
gtk_widget_class_bind_template_callback (widget_class, show_source_dialog);
|
||||
|
||||
gtk_widget_class_bind_template_callback (widget_class, key_pressed);
|
||||
gtk_widget_class_bind_template_callback (widget_class, search_toggled);
|
||||
gtk_widget_class_bind_template_callback (widget_class, search_changed);
|
||||
|
||||
Reference in New Issue
Block a user