--- pyanaconda/ui/gui/spokes/keyboard.py | 12 ++++++++++++ pyanaconda/ui/gui/spokes/keyboard.ui | 15 +++++++++++++++ 2 files changed, 27 insertions(+), 0 deletions(-) diff --git a/pyanaconda/ui/gui/spokes/keyboard.py b/pyanaconda/ui/gui/spokes/keyboard.py index de56be4..3e502b4 100644 --- a/pyanaconda/ui/gui/spokes/keyboard.py +++ b/pyanaconda/ui/gui/spokes/keyboard.py @@ -36,6 +36,14 @@ class AddLayoutDialog(UIObject): mainWidgetName = "addLayoutDialog" uiFile = "spokes/keyboard.ui" + def populate(self): + self._store = self.builder.get_object("newLayoutStore") + #XXX: will use values from the libxklavier + self._addLayout(self._store, "English (US)") + self._addLayout(self._store, "Czech") + self._addLayout(self._store, "Czech (qwerty)") + self._addLayout(self._store, "values from libxklavier") + def run(self): rc = self.window.run() self.window.destroy() @@ -47,6 +55,9 @@ class AddLayoutDialog(UIObject): def on_cancel_clicked(self, *args): print "CANCELING" + def _addLayout(self, store, name): + store.append([name]) + class KeyboardSpoke(NormalSpoke): builderObjects = ["addedLayoutStore", "keyboardWindow", "addImage", "removeImage", "upImage", "downImage", "settingsImage"] @@ -98,6 +109,7 @@ class KeyboardSpoke(NormalSpoke): def on_add_clicked(self, button): dialog = AddLayoutDialog(self.data) dialog.setup() + dialog.populate() print "RESPONSE = %s" % dialog.run() def on_remove_clicked(self, button): diff --git a/pyanaconda/ui/gui/spokes/keyboard.ui b/pyanaconda/ui/gui/spokes/keyboard.ui index e5ab795..f8bc067 100644 --- a/pyanaconda/ui/gui/spokes/keyboard.ui +++ b/pyanaconda/ui/gui/spokes/keyboard.ui @@ -110,6 +110,21 @@ <child internal-child="selection"> <object class="GtkTreeSelection" id="newLayoutSelection"/> </child> + <child> + <object class="GtkTreeViewColumn" id="name"> + <property name="title" translatable="yes">Name</property> + <property name="expand">True</property> + <property name="clickable">True</property> + <property name="sort_column_id">0</property> + <child> + <object class="GtkCellRendererText" id="newLayoutRenderer"> + </object> + <attributes> + <attribute name="text">0</attribute> + </attributes> + </child> + </object> + </child> </object> </child> </object> -- 1.7.4.4 _______________________________________________ Anaconda-devel-list mailing list Anaconda-devel-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/anaconda-devel-list