[gnome-shell] keyring: Don't use setButtons
- From: Jasper St. Pierre <jstpierre src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell] keyring: Don't use setButtons
- Date: Wed, 26 Dec 2012 03:19:09 +0000 (UTC)
commit ac202cbdd376231a5a03b861e3dcb57cfce85150
Author: Jasper St. Pierre <jstpierre mecheye net>
Date: Fri Dec 21 11:04:57 2012 -0500
keyring: Don't use setButtons
https://bugzilla.gnome.org/show_bug.cgi?id=690594
js/ui/components/keyring.js | 20 ++++++++------------
1 files changed, 8 insertions(+), 12 deletions(-)
---
diff --git a/js/ui/components/keyring.js b/js/ui/components/keyring.js
index ef53c0b..74c9c38 100644
--- a/js/ui/components/keyring.js
+++ b/js/ui/components/keyring.js
@@ -60,18 +60,14 @@ const KeyringDialog = new Lang.Class({
this._controlTable = null;
- let buttons = [{ label: '',
- action: Lang.bind(this, this._onCancelButton),
- key: Clutter.Escape
- },
- { label: '',
- action: Lang.bind(this, this._onContinueButton),
- default: true
- }]
-
- this.setButtons(buttons);
- this._cancelButton = buttons[0].button;
- this._continueButton = buttons[1].button;
+
+ this._cancelButton = this.addButton({ label: '',
+ action: Lang.bind(this, this._onCancelButton),
+ key: Clutter.Escape });
+ this._continueButton = this.addButton({ label: '',
+ action: Lang.bind(this, this._onContinueButton),
+ default: true },
+ { expand: true, x_fill: false, x_align: St.Align.END });
this.prompt.bind_property('cancel-label', this._cancelButton, 'label', GObject.BindingFlags.SYNC_CREATE);
this.prompt.bind_property('continue-label', this._continueButton, 'label', GObject.BindingFlags.SYNC_CREATE);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]