diff options
author | Milan Crha <mcrha@redhat.com> | 2007-12-04 19:08:15 +0800 |
---|---|---|
committer | Milan Crha <mcrha@src.gnome.org> | 2007-12-04 19:08:15 +0800 |
commit | 7dafe33520316eadd8ee9df234ba8eb5e6333160 (patch) | |
tree | 7997ba4b8ce7f26bff810a7ef84a0282c5a8c31b /plugins/itip-formatter/itip-view.c | |
parent | f4d3ee5d5923e8a91b45fc6dd8eb8fb2857f41de (diff) | |
download | gsoc2013-evolution-7dafe33520316eadd8ee9df234ba8eb5e6333160.tar gsoc2013-evolution-7dafe33520316eadd8ee9df234ba8eb5e6333160.tar.gz gsoc2013-evolution-7dafe33520316eadd8ee9df234ba8eb5e6333160.tar.bz2 gsoc2013-evolution-7dafe33520316eadd8ee9df234ba8eb5e6333160.tar.lz gsoc2013-evolution-7dafe33520316eadd8ee9df234ba8eb5e6333160.tar.xz gsoc2013-evolution-7dafe33520316eadd8ee9df234ba8eb5e6333160.tar.zst gsoc2013-evolution-7dafe33520316eadd8ee9df234ba8eb5e6333160.zip |
** Fix for bug #220846
2007-12-04 Milan Crha <mcrha@redhat.com>
** Fix for bug #220846
* itip-view.h:
* itip-view.c: (itip_view_set_show_free_time_check),
(itip_view_get_free_time_check_state), (struct _ItipViewPrivate),
(itip_view_init):
* itip-formatter.c: (view_response_cb), (format_itip_object):
New option to accept meeting request as free time.
svn path=/trunk/; revision=34640
Diffstat (limited to 'plugins/itip-formatter/itip-view.c')
-rw-r--r-- | plugins/itip-formatter/itip-view.c | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/plugins/itip-formatter/itip-view.c b/plugins/itip-formatter/itip-view.c index fb60c4fa31..28596c2fba 100644 --- a/plugins/itip-formatter/itip-view.c +++ b/plugins/itip-formatter/itip-view.c @@ -122,6 +122,9 @@ struct _ItipViewPrivate { GtkWidget *update_check; gboolean update_show; + GtkWidget *options_box; + GtkWidget *free_time_check; + GtkWidget *button_box; gboolean buttons_sensitive; @@ -1109,6 +1112,13 @@ itip_view_init (ItipView *view) g_signal_connect (priv->recur_check, "toggled", G_CALLBACK (recur_toggled_cb), view); + priv->options_box = gtk_vbox_new (FALSE, 2); + gtk_widget_show (priv->options_box); + gtk_box_pack_start (GTK_BOX (vbox), priv->options_box, FALSE, FALSE, 0); + + priv->free_time_check = gtk_check_button_new_with_mnemonic (_("Show time as _free")); + gtk_box_pack_start (GTK_BOX (priv->options_box), priv->free_time_check, FALSE, FALSE, 0); + /* The buttons for actions */ priv->button_box = gtk_hbutton_box_new (); gtk_button_box_set_layout (GTK_BUTTON_BOX (priv->button_box), GTK_BUTTONBOX_END); @@ -2095,3 +2105,25 @@ itip_view_set_show_recur_check (ItipView *view, gboolean show) gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (view->priv->recur_check), FALSE); } } + +void +itip_view_set_show_free_time_check (ItipView *view, gboolean show) +{ + g_return_if_fail (view != NULL); + g_return_if_fail (ITIP_IS_VIEW (view)); + + if (show) + gtk_widget_show (view->priv->free_time_check); + else { + gtk_widget_hide (view->priv->free_time_check); + gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (view->priv->free_time_check), FALSE); + } +} + +gboolean +itip_view_get_free_time_check_state (ItipView *view) +{ + g_return_val_if_fail (view != NULL, FALSE); + + return gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (view->priv->free_time_check)); +} |