summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--docs/reference/endless/endless-sections.txt4
-rw-r--r--endless/eospagemanager.c191
-rw-r--r--endless/eospagemanager.h18
-rw-r--r--endless/eostopbar-private.h7
-rw-r--r--endless/eostopbar.c97
-rw-r--r--endless/eoswindow.c76
-rw-r--r--test/smoke-tests/app-window.js41
7 files changed, 430 insertions, 4 deletions
diff --git a/docs/reference/endless/endless-sections.txt b/docs/reference/endless/endless-sections.txt
index a81d852..5400315 100644
--- a/docs/reference/endless/endless-sections.txt
+++ b/docs/reference/endless/endless-sections.txt
@@ -55,6 +55,10 @@ eos_page_manager_get_page_actions
eos_page_manager_set_page_actions
eos_page_manager_get_page_custom_toolbox_widget
eos_page_manager_set_page_custom_toolbox_widget
+eos_page_manager_get_page_left_topbar_widget
+eos_page_manager_set_page_left_topbar_widget
+eos_page_manager_get_page_center_topbar_widget
+eos_page_manager_set_page_center_topbar_widget
eos_page_manager_get_page_background_uri
eos_page_manager_set_page_background_uri
eos_page_manager_get_transition_duration
diff --git a/endless/eospagemanager.c b/endless/eospagemanager.c
index c4508a6..5f92634 100644
--- a/endless/eospagemanager.c
+++ b/endless/eospagemanager.c
@@ -101,6 +101,8 @@ struct _EosPageManagerPageInfo
gboolean fake_page_actions_visible;
GtkWidget *custom_toolbox_widget;
gchar *background_uri;
+ GtkWidget *left_topbar_widget;
+ GtkWidget *center_topbar_widget;
};
struct _EosPageManagerPrivate
@@ -149,6 +151,8 @@ enum
CHILD_PROP_PAGE_ACTIONS,
CHILD_PROP_CUSTOM_TOOLBOX_WIDGET,
CHILD_PROP_BACKGROUND_URI,
+ CHILD_PROP_LEFT_TOPBAR_WIDGET,
+ CHILD_PROP_CENTER_TOPBAR_WIDGET,
NCHILDPROPS
};
@@ -164,6 +168,16 @@ page_info_free (EosPageManagerPageInfo *info)
}
/*
+ * TODO
+static void
+top_bars_unref (EosPageManagerPageInfo *info)
+{
+ g_object_unref (GTK_WIDGET (info->left_topbar_widget));
+ g_object_unref (GTK_WIDGET (info->center_topbar_widget));
+}
+*/
+
+/*
* find_page_info_by_widget:
* @self: the page manager
* @page: the page to look for
@@ -313,6 +327,18 @@ eos_page_manager_set_property (GObject *object,
}
}
+/*
+static void
+eos_page_manager_dispose (GObject *object)
+{
+ EosPageManager *self = EOS_PAGE_MANAGER (object);
+
+ g_list_foreach (self->priv->page_info, (GFunc)top_bars_unref, NULL);
+
+ G_OBJECT_CLASS (eos_page_manager_parent_class)->dispose (object);
+}
+*/
+
static void
eos_page_manager_finalize (GObject *object)
{
@@ -541,6 +567,18 @@ eos_page_manager_get_child_property (GtkContainer *container,
child));
break;
+ case CHILD_PROP_LEFT_TOPBAR_WIDGET:
+ g_value_set_object (value,
+ eos_page_manager_get_page_left_topbar_widget (self,
+ child));
+ break;
+
+ case CHILD_PROP_CENTER_TOPBAR_WIDGET:
+ g_value_set_object (value,
+ eos_page_manager_get_page_center_topbar_widget (self,
+ child));
+ break;
+
default:
GTK_CONTAINER_WARN_INVALID_CHILD_PROPERTY_ID (container,
property_id, pspec);
@@ -577,6 +615,16 @@ eos_page_manager_set_child_property (GtkContainer *container,
g_value_get_object (value));
break;
+ case CHILD_PROP_LEFT_TOPBAR_WIDGET:
+ eos_page_manager_set_page_left_topbar_widget (self, child,
+ g_value_get_object (value));
+ break;
+
+ case CHILD_PROP_CENTER_TOPBAR_WIDGET:
+ eos_page_manager_set_page_center_topbar_widget (self, child,
+ g_value_get_object (value));
+ break;
+
default:
GTK_CONTAINER_WARN_INVALID_CHILD_PROPERTY_ID (container,
property_id, pspec);
@@ -594,6 +642,7 @@ eos_page_manager_class_init (EosPageManagerClass *klass)
object_class->get_property = eos_page_manager_get_property;
object_class->set_property = eos_page_manager_set_property;
+ // object_class->dispose = eos_page_manager_dispose;
object_class->finalize = eos_page_manager_finalize;
/* Pass all size requesting and allocation on to the stack */
@@ -717,6 +766,32 @@ eos_page_manager_class_init (EosPageManagerClass *klass)
G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS);
/**
+ * EosPageManager:left-topbar-widget:
+ *
+ * The left topbar widget belonging to this page, to be displayed on the
+ * left portion of the top bar when the page is displaying. Setting this to
+ * %NULL indicates that there should be no left topbar widget.
+ */
+ eos_page_manager_child_props[CHILD_PROP_LEFT_TOPBAR_WIDGET] =
+ g_param_spec_object ("left-topbar-widget", "Left topbar widget",
+ "Left topbar widget displayed left of the topbar",
+ GTK_TYPE_WIDGET,
+ G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS);
+
+ /**
+ * EosPageManager:center-topbar-widget:
+ *
+ * The center topbar widget belonging to this page, to be displayed on the
+ * middle portion of the top bar when the page is displaying. Setting this to
+ * %NULL indicates that there should be no center topbar widget.
+ */
+ eos_page_manager_child_props[CHILD_PROP_CENTER_TOPBAR_WIDGET] =
+ g_param_spec_object ("center-topbar-widget", "Center topbar widget",
+ "Center topbar widget displayed in the middle of the topbar",
+ GTK_TYPE_WIDGET,
+ G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS);
+
+ /**
* EosPageManager:background-uri:
*
* The URI for the image file for the background of this page. Setting this to
@@ -1076,6 +1151,122 @@ eos_page_manager_set_page_custom_toolbox_widget (EosPageManager *self,
}
/**
+ * eos_page_manager_get_page_left_topbar_widget:
+ * @self: the page manager
+ * @page: the page to be queried
+ *
+ * Retrieves @page's left topbar widget, if it has one.
+ * See #EosPageManager:left-topbar-widget for more information.
+ *
+ * Returns: (transfer none): the left topbar #GtkWidget of @page, or %NULL if there is none.
+ */
+GtkWidget *
+eos_page_manager_get_page_left_topbar_widget (EosPageManager *self,
+ GtkWidget *page)
+{
+ g_return_val_if_fail (self != NULL && EOS_IS_PAGE_MANAGER (self), NULL);
+ g_return_val_if_fail (page != NULL && GTK_IS_WIDGET (page), NULL);
+
+ EosPageManagerPageInfo *info = find_page_info_by_widget (self, page);
+ g_return_val_if_fail (info != NULL, NULL);
+
+ return info->left_topbar_widget;
+}
+
+/**
+ * eos_page_manager_set_page_left_topbar_widget:
+ * @self: the page manager
+ * @page: the page
+ * @left_topbar_widget: (allow-none): left topbar widget for @page
+ *
+ * Sets the left topbar widget to be displayed for this @page.
+ * See #EosPageManager:left-topbar-widget for more information.
+ */
+void
+eos_page_manager_set_page_left_topbar_widget (EosPageManager *self,
+ GtkWidget *page,
+ GtkWidget *left_topbar_widget)
+{
+ g_return_if_fail (self != NULL && EOS_IS_PAGE_MANAGER (self));
+ g_return_if_fail (page != NULL && GTK_IS_WIDGET (page));
+ g_return_if_fail (left_topbar_widget == NULL ||
+ GTK_IS_WIDGET (left_topbar_widget));
+
+ EosPageManagerPageInfo *info = find_page_info_by_widget (self, page);
+ g_return_if_fail (info != NULL);
+
+ if (info->left_topbar_widget == left_topbar_widget)
+ return;
+
+ if (info->left_topbar_widget)
+ g_object_unref (info->left_topbar_widget);
+
+ g_object_ref (left_topbar_widget);
+ info->left_topbar_widget = left_topbar_widget;
+
+ gtk_container_child_notify (GTK_CONTAINER (self), page,
+ "left-topbar-widget");
+}
+
+/**
+ * eos_page_manager_get_page_center_topbar_widget:
+ * @self: the page manager
+ * @page: the page to be queried
+ *
+ * Retrieves @page's center topbar widget, if it has one.
+ * See #EosPageManager:center-topbar-widget for more information.
+ *
+ * Returns: (transfer none): the center topbar #GtkWidget of @page, or %NULL if there is none.
+ */
+ GtkWidget *
+ eos_page_manager_get_page_center_topbar_widget (EosPageManager *self,
+ GtkWidget *page)
+{
+ g_return_val_if_fail (self != NULL && EOS_IS_PAGE_MANAGER (self), NULL);
+ g_return_val_if_fail (page != NULL && GTK_IS_WIDGET (page), NULL);
+
+ EosPageManagerPageInfo *info = find_page_info_by_widget (self, page);
+ g_return_val_if_fail (info != NULL, NULL);
+
+ return info->center_topbar_widget;
+}
+
+/**
+ * eos_page_manager_set_page_center_topbar_widget:
+ * @self: the page manager
+ * @page: the page
+ * @center_topbar_widget: (allow-none): center topbar widget for @page
+ *
+ * Sets the center topbar widget to be displayed for this @page.
+ * See #EosPageManager:center-topbar-widget for more information.
+ */
+void
+eos_page_manager_set_page_center_topbar_widget (EosPageManager *self,
+ GtkWidget *page,
+ GtkWidget *center_topbar_widget)
+{
+ g_return_if_fail (self != NULL && EOS_IS_PAGE_MANAGER (self));
+ g_return_if_fail (page != NULL && GTK_IS_WIDGET (page));
+ g_return_if_fail (center_topbar_widget == NULL ||
+ GTK_IS_WIDGET (center_topbar_widget));
+
+ EosPageManagerPageInfo *info = find_page_info_by_widget (self, page);
+ g_return_if_fail (info != NULL);
+
+ if (info->center_topbar_widget == center_topbar_widget)
+ return;
+
+ if (info->center_topbar_widget)
+ g_object_unref (info->center_topbar_widget);
+
+ g_object_ref (center_topbar_widget);
+ info->center_topbar_widget = center_topbar_widget;
+
+ gtk_container_child_notify (GTK_CONTAINER (self), page,
+ "center-topbar-widget");
+}
+
+/**
* eos_page_manager_get_page_background_uri:
* @self: the page manager
* @page: the page to be queried
diff --git a/endless/eospagemanager.h b/endless/eospagemanager.h
index 7814b24..db6a693 100644
--- a/endless/eospagemanager.h
+++ b/endless/eospagemanager.h
@@ -133,6 +133,24 @@ void eos_page_manager_set_page_custom_toolbox_widget (EosPageManage
GtkWidget *custom_toolbox_widget);
EOS_SDK_ALL_API_VERSIONS
+GtkWidget *eos_page_manager_get_page_left_topbar_widget (EosPageManager *self,
+ GtkWidget *page);
+
+EOS_SDK_ALL_API_VERSIONS
+void eos_page_manager_set_page_left_topbar_widget (EosPageManager *self,
+ GtkWidget *page,
+ GtkWidget *left_topbar_widget);
+
+EOS_SDK_ALL_API_VERSIONS
+GtkWidget *eos_page_manager_get_page_center_topbar_widget (EosPageManager *self,
+ GtkWidget *page);
+
+EOS_SDK_ALL_API_VERSIONS
+void eos_page_manager_set_page_center_topbar_widget (EosPageManager *self,
+ GtkWidget *page,
+ GtkWidget *center_topbar_widget);
+
+EOS_SDK_ALL_API_VERSIONS
void eos_page_manager_set_transition_duration (EosPageManager *self,
guint duration);
diff --git a/endless/eostopbar-private.h b/endless/eostopbar-private.h
index 800c8de..02ac6c7 100644
--- a/endless/eostopbar-private.h
+++ b/endless/eostopbar-private.h
@@ -51,6 +51,13 @@ GType eos_top_bar_get_type (void) G_GNUC_CONST;
GtkWidget *eos_top_bar_new (void);
+void eos_top_bar_set_left_widget (EosTopBar *self,
+ GtkWidget *left_top_bar_widget);
+
+void
+eos_top_bar_set_center_widget (EosTopBar *self,
+ GtkWidget *center_top_bar_widget);
+
G_END_DECLS
#endif /* EOS_TOP_BAR_H */
diff --git a/endless/eostopbar.c b/endless/eostopbar.c
index ff0f26f..d8516bd 100644
--- a/endless/eostopbar.c
+++ b/endless/eostopbar.c
@@ -6,6 +6,17 @@
#include <glib-object.h>
#include <gtk/gtk.h>
+/*
+ * SECTION:topbar
+ * @short_description: The top bar of the window, above the main area of your
+ * application.
+ * @title: TopBar
+ *
+ * The #EosTopBar has three different areas that can be managed through this
+ * class: a left widget, center widget, and action buttons area.
+ *
+ * The action buttons area contain "minimize" and "close" buttons.
+ */
#define _EOS_STYLE_CLASS_TOP_BAR "top-bar"
#define _EOS_TOP_BAR_HEIGHT_PX 36
#define _EOS_TOP_BAR_BUTTON_PADDING_PX 3
@@ -18,6 +29,11 @@ G_DEFINE_TYPE (EosTopBar, eos_top_bar, GTK_TYPE_EVENT_BOX)
struct _EosTopBarPrivate
{
GtkWidget *actions_hbox;
+ GtkWidget *left_top_bar_attach;
+ GtkWidget *center_top_bar_attach;
+
+ GtkWidget *left_top_bar_widget;
+ GtkWidget *center_top_bar_widget;
GtkWidget *minimize_button;
GtkWidget *minimize_icon;
@@ -105,9 +121,19 @@ eos_top_bar_init (EosTopBar *self)
gtk_widget_set_hexpand (GTK_WIDGET (self), TRUE);
- self->priv->actions_hbox = gtk_box_new(GTK_ORIENTATION_HORIZONTAL, 0);
+ self->priv->actions_hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0);
gtk_widget_set_hexpand (self->priv->actions_hbox, TRUE);
+ self->priv->left_top_bar_attach = gtk_alignment_new (0.5, 0.5, 0.0, 0.0);
+ self->priv->center_top_bar_attach = gtk_alignment_new (0.5, 0.5, 0.0, 0.0);
+
+ /* TODO Remove foreground override; for now, it is useful for smoke tests */
+ GdkRGBA gray = {0.75, 0.75, 0.75, 1.0};
+ gtk_widget_override_color (self->priv->left_top_bar_attach,
+ GTK_STATE_FLAG_NORMAL, &gray);
+ gtk_widget_override_color (self->priv->center_top_bar_attach,
+ GTK_STATE_FLAG_NORMAL, &gray);
+
/* TODO implement adding actions and widgets to the actions_hbox */
self->priv->minimize_button = gtk_button_new ();
@@ -126,6 +152,13 @@ eos_top_bar_init (EosTopBar *self)
gtk_button_set_image (GTK_BUTTON (self->priv->close_button),
self->priv->close_icon);
+ gtk_box_pack_start (GTK_BOX (self->priv->actions_hbox),
+ self->priv->left_top_bar_attach,
+ FALSE, FALSE, _EOS_TOP_BAR_BUTTON_PADDING_PX);
+ gtk_box_pack_start (GTK_BOX (self->priv->actions_hbox),
+ self->priv->center_top_bar_attach,
+ TRUE, FALSE, _EOS_TOP_BAR_BUTTON_PADDING_PX);
+
gtk_box_pack_end (GTK_BOX (self->priv->actions_hbox),
self->priv->close_button,
FALSE, FALSE, _EOS_TOP_BAR_BUTTON_PADDING_PX);
@@ -149,3 +182,65 @@ eos_top_bar_new (void)
{
return GTK_WIDGET (g_object_new (EOS_TYPE_TOP_BAR, NULL));
}
+
+/*
+ * eos_top_bar_set_left_widget:
+ * @self: the top bar
+ * @left_top_bar_widget: the left top bar widget to be set
+ *
+ * Sets the left widget in the top bar.
+ */
+void
+eos_top_bar_set_left_widget (EosTopBar *self,
+ GtkWidget *left_top_bar_widget)
+{
+ g_return_if_fail (EOS_IS_TOP_BAR (self));
+ g_return_if_fail (left_top_bar_widget == NULL || GTK_IS_WIDGET (left_top_bar_widget));
+
+ EosTopBarPrivate *priv = self->priv;
+
+ if (priv->left_top_bar_widget == left_top_bar_widget)
+ return;
+
+ if (priv->left_top_bar_widget)
+ gtk_container_remove (GTK_CONTAINER (priv->left_top_bar_attach),
+ priv->left_top_bar_widget);
+
+ priv->left_top_bar_widget = left_top_bar_widget;
+ if (left_top_bar_widget)
+ {
+ gtk_container_add (GTK_CONTAINER (priv->left_top_bar_attach),
+ priv->left_top_bar_widget);
+ }
+}
+
+/*
+ * eos_top_bar_set_center_widget:
+ * @self: the top bar
+ * @center_top_bar_widget: the center top bar widget to be set
+ *
+ * Sets the center widget in the top bar.
+ */
+void
+eos_top_bar_set_center_widget (EosTopBar *self,
+ GtkWidget *center_top_bar_widget)
+{
+ g_return_if_fail (EOS_IS_TOP_BAR (self));
+ g_return_if_fail (center_top_bar_widget == NULL || GTK_IS_WIDGET (center_top_bar_widget));
+
+ EosTopBarPrivate *priv = self->priv;
+
+ if (priv->center_top_bar_widget == center_top_bar_widget)
+ return;
+
+ if (priv->center_top_bar_widget)
+ gtk_container_remove (GTK_CONTAINER (priv->center_top_bar_attach),
+ priv->center_top_bar_widget);
+
+ priv->center_top_bar_widget = center_top_bar_widget;
+ if (center_top_bar_widget)
+ {
+ gtk_container_add (GTK_CONTAINER (priv->center_top_bar_attach),
+ priv->center_top_bar_widget);
+ }
+}
diff --git a/endless/eoswindow.c b/endless/eoswindow.c
index d2c3ea9..571aebb 100644
--- a/endless/eoswindow.c
+++ b/endless/eoswindow.c
@@ -64,6 +64,8 @@ struct _EosWindowPrivate
GtkWidget *current_page;
gulong child_page_actions_handler;
gulong child_custom_toolbox_handler;
+ gulong child_left_topbar_handler;
+ gulong child_center_topbar_handler;
gulong child_background_handler;
GtkCssProvider *background_provider;
const gchar *current_background_uri;
@@ -130,6 +132,59 @@ update_page_toolbox (EosWindow *self)
}
}
+/**
+ * update_page_left_topbar:
+ * @self: the window
+ *
+ * Ensures that the currently shown state of the left topbar is in line with
+ * the child properties of the currently showing page.
+ */
+static void
+update_page_left_topbar (EosWindow *self)
+{
+ EosPageManager *pm = EOS_PAGE_MANAGER (self->priv->page_manager);
+ EosTopBar *tb = EOS_TOP_BAR (self->priv->top_bar);
+ GtkWidget *page = self->priv->current_page;
+
+ if (page != NULL)
+ {
+ GtkWidget *left_topbar_widget =
+ GTK_WIDGET (eos_page_manager_get_page_left_topbar_widget (pm, page));
+ eos_top_bar_set_left_widget (tb, left_topbar_widget);
+ gtk_widget_show (self->priv->top_bar);
+ }
+ else
+ {
+ eos_top_bar_set_left_widget (tb, NULL);
+ }
+}
+
+/**
+ * update_page_center_topbar:
+ * @self: the window
+ *
+ * Ensures that the currently-shown state of the center topbar is in line with
+ * the child properties of the currently-showing page.
+ */
+static void
+update_page_center_topbar (EosWindow *self)
+{
+ EosPageManager *pm = EOS_PAGE_MANAGER (self->priv->page_manager);
+ EosTopBar *tb = EOS_TOP_BAR (self->priv->top_bar);
+ GtkWidget *page = self->priv->current_page;
+
+ if (page != NULL)
+ {
+ GtkWidget *center_topbar_widget =
+ GTK_WIDGET (eos_page_manager_get_page_center_topbar_widget (pm, page));
+ eos_top_bar_set_center_widget (tb, center_topbar_widget);
+ }
+ else
+ {
+ eos_top_bar_set_center_widget (tb, NULL);
+ }
+}
+
static void
sync_stack_animation (EosWindow *self)
{
@@ -208,8 +263,8 @@ update_page_background (EosWindow *self)
* update_page:
* @self: the window
*
- * Ensures that the state of the window and the window's main area are in line
- * with the currently showing page and its child properties.
+ * Ensures that the state of the window, the window's main area and top bar are
+ * in line with the currently showing page and its child properties.
*/
static void
update_page (EosWindow *self)
@@ -224,6 +279,10 @@ update_page (EosWindow *self)
self->priv->child_custom_toolbox_handler);
g_signal_handler_disconnect (self->priv->current_page,
self->priv->child_background_handler);
+ g_signal_handler_disconnect (self->priv->current_page,
+ self->priv->child_left_topbar_handler);
+ g_signal_handler_disconnect (self->priv->current_page,
+ self->priv->child_center_topbar_handler);
}
self->priv->current_page = eos_page_manager_get_visible_page (pm);
@@ -231,6 +290,8 @@ update_page (EosWindow *self)
update_page_actions (self);
update_page_toolbox (self);
sync_stack_animation (self);
+ update_page_left_topbar (self);
+ update_page_center_topbar (self);
update_page_background (self);
p_stack_set_transition_type (P_STACK (self->priv->background_stack),
P_STACK_TRANSITION_TYPE_NONE);
@@ -247,6 +308,16 @@ update_page (EosWindow *self)
"child-notify::custom-toolbox-widget",
G_CALLBACK (update_page_toolbox),
self);
+ self->priv->child_left_topbar_handler =
+ g_signal_connect_swapped (self->priv->current_page,
+ "child-notify::left-topbar-widget",
+ G_CALLBACK (update_page_left_topbar),
+ self);
+ self->priv->child_center_topbar_handler =
+ g_signal_connect_swapped (self->priv->current_page,
+ "child-notify::center-topbar-widget",
+ G_CALLBACK (update_page_center_topbar),
+ self);
self->priv->child_background_handler =
g_signal_connect_swapped (self->priv->current_page,
"child-notify::background-uri",
@@ -390,6 +461,7 @@ eos_window_show (GtkWidget *widget)
GTK_WIDGET_CLASS (eos_window_parent_class)->show (widget);
if (self->priv->top_bar != NULL)
gtk_widget_show_all (self->priv->top_bar);
+
}
/* The top bar is an internal child, so include it in our list of internal
diff --git a/test/smoke-tests/app-window.js b/test/smoke-tests/app-window.js
index e05ae5a..42381a8 100644
--- a/test/smoke-tests/app-window.js
+++ b/test/smoke-tests/app-window.js
@@ -108,6 +108,36 @@ const Toolbox = new Lang.Class ({
}
});
+const LeftTopbar = new Lang.Class ({
+ Name: 'LeftTopBar',
+ Extends: Gtk.Grid,
+
+ _init: function(props) {
+ props = props || {};
+ props.orientation = Gtk.Orientation.VERTICAL;
+ this.parent(props);
+
+ this._label = new Gtk.Label({ label: 'The Left Topbar' });
+
+ this.add(this._label);
+ }
+});
+
+const CenterTopbar = new Lang.Class ({
+ Name: 'CenterTopBar',
+ Extends: Gtk.Grid,
+
+ _init: function(props) {
+ props = props || {};
+ props.orientation = Gtk.Orientation.VERTICAL;
+ this.parent(props);
+
+ this._label = new Gtk.Label({ label: 'The Center Topbar' });
+
+ this.add(this._label);
+ }
+});
+
const TestApplication = new Lang.Class ({
Name: 'TestApplication',
Extends: Endless.Application,
@@ -154,15 +184,24 @@ const TestApplication = new Lang.Class ({
this._toolbox.switch2.active);
}));
+ this._left_topbar = new LeftTopbar();
+
+ this._center_topbar = new CenterTopbar();
+
this._pm.add(this._page0, {
name: "page0",
background_uri: CAT_BACKGROUND_PATH,
- custom_toolbox_widget: this._toolbox
+ custom_toolbox_widget: this._toolbox,
+ left_topbar_widget: this._left_topbar,
+ center_topbar_widget: this._center_topbar
});
+
this._pm.add(this._page1, {
name: "page1",
background_uri: DOG_BACKGROUND_PATH,
custom_toolbox_widget: this._toolbox,
+ left_topbar_widget: this._left_topbar,
+ center_topbar_widget: this._center_topbar,
page_actions: true
});