[longomatch] Create a notebook to hold the different kinds of properties that the dashboard editor will manage.
- From: Andoni Morales Alastruey <amorales src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [longomatch] Create a notebook to hold the different kinds of properties that the dashboard editor will manage.
- Date: Fri, 17 Apr 2015 16:23:45 +0000 (UTC)
commit c4b7a170fdef5d75e7ed54acdb6bdc162f19b93e
Author: Xavi Artigas <xartigas fluendo com>
Date: Mon Apr 13 18:41:33 2015 +0200
Create a notebook to hold the different kinds of properties that the dashboard editor will manage.
It only has one page as of now, and page 2 is used to hide all current properties.
LongoMatch.GUI/Gui/Component/DashboardWidget.cs | 8 ++--
.../LongoMatch.Gui.Component.DashboardWidget.cs | 48 +++++++++++++++----
LongoMatch.GUI/gtk-gui/gui.stetic | 37 +++++++++++++--
3 files changed, 75 insertions(+), 18 deletions(-)
---
diff --git a/LongoMatch.GUI/Gui/Component/DashboardWidget.cs b/LongoMatch.GUI/Gui/Component/DashboardWidget.cs
index 676e3a4..0bb2bd7 100644
--- a/LongoMatch.GUI/Gui/Component/DashboardWidget.cs
+++ b/LongoMatch.GUI/Gui/Component/DashboardWidget.cs
@@ -88,7 +88,7 @@ namespace LongoMatch.Gui.Component
Edited = false;
Mode = TagMode.Predefined;
// Initialize to a sane default value.
- tagproperties.Sensitive = false;
+ propertiesnotebook.Page = 1;
}
protected override void OnDestroyed ()
@@ -159,7 +159,7 @@ namespace LongoMatch.Gui.Component
Edited = false;
// Start with disabled widget until something get selected
tagproperties.Tagger = null;
- tagproperties.Sensitive = false;
+ propertiesnotebook.Page = 1;
tagproperties.Dashboard = value;
popupbutton.Active = value.DisablePopupWindow;
}
@@ -341,11 +341,11 @@ namespace LongoMatch.Gui.Component
if (taggers.Count == 1) {
selected = taggers [0];
tagproperties.Tagger = taggers [0];
- tagproperties.Sensitive = true;
+ propertiesnotebook.Page = 0;
} else {
selected = null;
tagproperties.Tagger = null;
- tagproperties.Sensitive = false;
+ propertiesnotebook.Page = 1;
}
}
diff --git a/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.DashboardWidget.cs
b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.DashboardWidget.cs
index e203b91..bf4654d 100644
--- a/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.DashboardWidget.cs
+++ b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.DashboardWidget.cs
@@ -112,7 +112,13 @@ namespace LongoMatch.Gui.Component
private global::Gtk.Alignment tagpropertiesalignment;
+ private global::Gtk.Notebook propertiesnotebook;
+
private global::LongoMatch.Gui.Component.CategoryProperties tagproperties;
+
+ private global::Gtk.Label label2;
+
+ private global::Gtk.Label label3;
protected virtual void Build ()
{
@@ -533,27 +539,49 @@ namespace LongoMatch.Gui.Component
this.tagpropertiesalignment.Name = "tagpropertiesalignment";
this.tagpropertiesalignment.BorderWidth = ((uint)(6));
// Container child tagpropertiesalignment.Gtk.Container+ContainerChild
+ this.propertiesnotebook = new global::Gtk.Notebook ();
+ this.propertiesnotebook.CanFocus = true;
+ this.propertiesnotebook.Name = "propertiesnotebook";
+ this.propertiesnotebook.CurrentPage = 0;
+ this.propertiesnotebook.ShowBorder = false;
+ this.propertiesnotebook.ShowTabs = false;
+ // Container child propertiesnotebook.Gtk.Notebook+NotebookChild
this.tagproperties = new global::LongoMatch.Gui.Component.CategoryProperties ();
- this.tagproperties.Sensitive = false;
this.tagproperties.Events = ((global::Gdk.EventMask)(256));
this.tagproperties.Name = "tagproperties";
this.tagproperties.Edited = false;
- this.tagpropertiesalignment.Add (this.tagproperties);
+ this.propertiesnotebook.Add (this.tagproperties);
+ // Notebook tab
+ this.label2 = new global::Gtk.Label ();
+ this.label2.Name = "label2";
+ this.label2.LabelProp = global::Mono.Unix.Catalog.GetString ("page1");
+ this.propertiesnotebook.SetTabLabel (this.tagproperties, this.label2);
+ this.label2.ShowAll ();
+ // Notebook tab
+ global::Gtk.Label w52 = new global::Gtk.Label ();
+ w52.Visible = true;
+ this.propertiesnotebook.Add (w52);
+ this.label3 = new global::Gtk.Label ();
+ this.label3.Name = "label3";
+ this.label3.LabelProp = global::Mono.Unix.Catalog.GetString ("page2");
+ this.propertiesnotebook.SetTabLabel (w52, this.label3);
+ this.label3.ShowAll ();
+ this.tagpropertiesalignment.Add (this.propertiesnotebook);
w50.Add (this.tagpropertiesalignment);
this.propertiesscrolledwindow.Add (w50);
this.vbox10.Add (this.propertiesscrolledwindow);
- global::Gtk.Box.BoxChild w54 = ((global::Gtk.Box.BoxChild)(this.vbox10
[this.propertiesscrolledwindow]));
- w54.Position = 2;
+ global::Gtk.Box.BoxChild w56 = ((global::Gtk.Box.BoxChild)(this.vbox10
[this.propertiesscrolledwindow]));
+ w56.Position = 2;
this.propertiesalignment.Add (this.vbox10);
this.propertiesframe.Add (this.propertiesalignment);
this.rightbox.Add (this.propertiesframe);
- global::Gtk.Box.BoxChild w57 = ((global::Gtk.Box.BoxChild)(this.rightbox
[this.propertiesframe]));
- w57.Position = 0;
+ global::Gtk.Box.BoxChild w59 = ((global::Gtk.Box.BoxChild)(this.rightbox
[this.propertiesframe]));
+ w59.Position = 0;
this.hbox2.Add (this.rightbox);
- global::Gtk.Box.BoxChild w58 = ((global::Gtk.Box.BoxChild)(this.hbox2
[this.rightbox]));
- w58.Position = 1;
- w58.Expand = false;
- w58.Fill = false;
+ global::Gtk.Box.BoxChild w60 = ((global::Gtk.Box.BoxChild)(this.hbox2
[this.rightbox]));
+ w60.Position = 1;
+ w60.Expand = false;
+ w60.Fill = false;
this.Add (this.hbox2);
if ((this.Child != null)) {
this.Child.ShowAll ();
diff --git a/LongoMatch.GUI/gtk-gui/gui.stetic b/LongoMatch.GUI/gtk-gui/gui.stetic
index f495d22..c60f085 100644
--- a/LongoMatch.GUI/gtk-gui/gui.stetic
+++ b/LongoMatch.GUI/gtk-gui/gui.stetic
@@ -743,11 +743,40 @@ Sort by competition</property>
<property name="MemberName" />
<property name="BorderWidth">6</property>
<child>
- <widget class="LongoMatch.Gui.Component.CategoryProperties"
id="tagproperties">
+ <widget class="Gtk.Notebook" id="propertiesnotebook">
<property name="MemberName" />
- <property name="Sensitive">False</property>
- <property name="Events">ButtonPressMask</property>
- <property name="Edited">False</property>
+ <property name="CanFocus">True</property>
+ <property name="CurrentPage">0</property>
+ <property name="ShowBorder">False</property>
+ <property name="ShowTabs">False</property>
+ <child>
+ <widget class="LongoMatch.Gui.Component.CategoryProperties"
id="tagproperties">
+ <property name="MemberName" />
+ <property name="Events">ButtonPressMask</property>
+ <property name="Edited">False</property>
+ </widget>
+ </child>
+ <child>
+ <widget class="Gtk.Label" id="label2">
+ <property name="MemberName" />
+ <property name="LabelProp" translatable="yes">page1</property>
+ </widget>
+ <packing>
+ <property name="type">tab</property>
+ </packing>
+ </child>
+ <child>
+ <placeholder />
+ </child>
+ <child>
+ <widget class="Gtk.Label" id="label3">
+ <property name="MemberName" />
+ <property name="LabelProp" translatable="yes">page2</property>
+ </widget>
+ <packing>
+ <property name="type">tab</property>
+ </packing>
+ </child>
</widget>
</child>
</widget>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]