[gnome-calendar] ui: integrated GcalDayView in GcalWindow
- From: Erick Pérez Castellanos <erickpc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-calendar] ui: integrated GcalDayView in GcalWindow
- Date: Thu, 4 Dec 2014 22:21:20 +0000 (UTC)
commit 09f62615507418e8234d3ec9e69da1ce583c268e
Author: Erick Pérez Castellanos <erick red gmail com>
Date: Tue Jun 4 22:39:02 2013 -0400
ui: integrated GcalDayView in GcalWindow
Initial work. Added option to GcalApplication action.
src/gcal-application.c | 7 ++++---
src/gcal-window.c | 10 ++++++----
2 files changed, 10 insertions(+), 7 deletions(-)
---
diff --git a/src/gcal-application.c b/src/gcal-application.c
index adf51e8..36621c3 100644
--- a/src/gcal-application.c
+++ b/src/gcal-application.c
@@ -296,9 +296,10 @@ gcal_application_set_app_menu (GApplication *app)
g_action_map_add_action ( G_ACTION_MAP (app), G_ACTION (priv->view));
view_as = g_menu_new ();
- g_menu_append (view_as, _("Weeks"), "app.view::week");
- g_menu_append (view_as, _("Months"), "app.view::month");
- g_menu_append (view_as, _("Years"), "app.view::year");
+ g_menu_append (view_as, _("Day"), "app.view::day");
+ g_menu_append (view_as, _("Week"), "app.view::week");
+ g_menu_append (view_as, _("Month"), "app.view::month");
+ g_menu_append (view_as, _("Year"), "app.view::year");
g_menu_append_section (app_menu, _("View as"), G_MENU_MODEL (view_as));
diff --git a/src/gcal-window.c b/src/gcal-window.c
index 7e7d0eb..b05ebad 100644
--- a/src/gcal-window.c
+++ b/src/gcal-window.c
@@ -22,10 +22,11 @@
#include "gcal-nav-bar.h"
#include "gcal-manager.h"
#include "gcal-floating-container.h"
-#include "gcal-year-view.h"
+#include "gcal-view.h"
+#include "gcal-day-view.h"
#include "gcal-month-view.h"
#include "gcal-week-view.h"
-#include "gcal-view.h"
+#include "gcal-year-view.h"
#include "gcal-event-widget.h"
#include "gcal-edit-dialog.h"
#include "gcal-enum-types.h"
@@ -318,8 +319,6 @@ gcal_window_constructed (GObject *object)
/* overlay */
priv->views_overlay = gtk_overlay_new ();
- gtk_widget_set_hexpand (priv->views_overlay, TRUE);
- gtk_widget_set_vexpand (priv->views_overlay, TRUE);
gtk_container_add (GTK_CONTAINER (priv->main_box), priv->views_overlay);
/* stack widget for holding views */
@@ -593,6 +592,9 @@ gcal_window_set_active_view (GcalWindow *window,
{
switch (view_type)
{
+ case GCAL_WINDOW_VIEW_DAY:
+ priv->views[GCAL_WINDOW_VIEW_DAY] = gcal_day_view_new ();
+ break;
case GCAL_WINDOW_VIEW_WEEK:
priv->views[GCAL_WINDOW_VIEW_WEEK] = gcal_week_view_new ();
break;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]