[gnome-boxes] Add button to add password
- From: Zeeshan Ali Khattak <zeeshanak src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-boxes] Add button to add password
- Date: Thu, 8 Dec 2011 17:22:00 +0000 (UTC)
commit d5c3d0a4f363099653393cd25ca0519ca8eb6039
Author: Zeeshan Ali (Khattak) <zeeshanak gnome org>
Date: Tue Dec 6 13:57:29 2011 +0200
Add button to add password
According to the UI design, we should have a button that user clicks to
add password. This patch adds such a button.
https://bugzilla.gnome.org/show_bug.cgi?id=665803
src/unattended-installer.vala | 10 +++++++++-
1 files changed, 9 insertions(+), 1 deletions(-)
---
diff --git a/src/unattended-installer.vala b/src/unattended-installer.vala
index 0b03a68..fc21e15 100644
--- a/src/unattended-installer.vala
+++ b/src/unattended-installer.vala
@@ -147,10 +147,18 @@ private abstract class Boxes.UnattendedInstaller: InstallerMedia {
table.attach_defaults (label, 1, 2, 2, 3);
password_entry = new Gtk.Entry ();
password_entry.visibility = false;
+ password_entry.visible = true;
password_entry.text = "";
password_entry.halign = Gtk.Align.START;
password_entry.valign = Gtk.Align.CENTER;
- table.attach_defaults (password_entry, 2, 3, 2, 3);
+ var button = new Gtk.Button.with_mnemonic (_("_Add Passord"));
+ button.valign = Gtk.Align.CENTER;
+ table.attach_defaults (button, 2, 3, 2, 3);
+ button.clicked.connect (() => {
+ table.remove (button);
+ table.attach_defaults (password_entry, 2, 3, 2, 3);
+ password_entry.is_focus = true;
+ });
}
protected virtual void clean_up () throws GLib.Error {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]