js: Don't pass extra arguments to add_actor

It's clear that this was supposed to be passed to our own 'add' monkey
patch, but we missed. Remove the ignored arguments.

https://bugzilla.gnome.org/show_bug.cgi?id=680216
This commit is contained in:
Jasper St. Pierre 2012-07-18 20:15:04 -04:00
parent ef218c95fc
commit 19e4c953ef
3 changed files with 11 additions and 48 deletions

View File

@ -284,11 +284,7 @@ const UserList = new Lang.Class({
this._box = new St.BoxLayout({ vertical: true, this._box = new St.BoxLayout({ vertical: true,
style_class: 'login-dialog-user-list' }); style_class: 'login-dialog-user-list' });
this.actor.add_actor(this._box, this.actor.add_actor(this._box);
{ x_fill: true,
y_fill: true,
x_align: St.Align.START,
y_align: St.Align.MIDDLE });
this._items = {}; this._items = {};
this.actor.connect('key-focus-in', Lang.bind(this, this._moveFocusToItems)); this.actor.connect('key-focus-in', Lang.bind(this, this._moveFocusToItems));
@ -551,10 +547,7 @@ const SessionListItem = new Lang.Class({
this._box = new St.BoxLayout({ style_class: 'login-dialog-session-list-item-box' }); this._box = new St.BoxLayout({ style_class: 'login-dialog-session-list-item-box' });
this.actor.add_actor(this._box, this.actor.add_actor(this._box);
{ expand: true,
x_fill: true,
y_fill: true });
this.actor.connect('clicked', Lang.bind(this, this._onClicked)); this.actor.connect('clicked', Lang.bind(this, this._onClicked));
this._dot = new St.DrawingArea({ style_class: 'login-dialog-session-list-item-dot' }); this._dot = new St.DrawingArea({ style_class: 'login-dialog-session-list-item-dot' });
@ -565,10 +558,7 @@ const SessionListItem = new Lang.Class({
let label = new St.Label({ style_class: 'login-dialog-session-list-item-label', let label = new St.Label({ style_class: 'login-dialog-session-list-item-label',
text: name }); text: name });
this._box.add_actor(label, this._box.add_actor(label);
{ expand: true,
x_fill: true,
y_fill: true });
}, },
setShowDot: function(show) { setShowDot: function(show) {
@ -612,10 +602,7 @@ const SessionList = new Lang.Class({
x_fill: true, x_fill: true,
y_fill: true }); y_fill: true });
let box = new St.BoxLayout(); let box = new St.BoxLayout();
this._button.add_actor(box, this._button.add_actor(box);
{ x_fill: true,
y_fill: true,
expand: true });
this._triangle = new St.Label({ style_class: 'login-dialog-session-list-triangle', this._triangle = new St.Label({ style_class: 'login-dialog-session-list-triangle',
text: '\u25B8' }); text: '\u25B8' });
@ -623,30 +610,18 @@ const SessionList = new Lang.Class({
let label = new St.Label({ style_class: 'login-dialog-session-list-label', let label = new St.Label({ style_class: 'login-dialog-session-list-label',
text: _("Session...") }); text: _("Session...") });
box.add_actor(label, box.add_actor(label);
{ x_fill: true,
y_fill: true,
expand: true });
this._button.connect('clicked', this._button.connect('clicked',
Lang.bind(this, this._onClicked)); Lang.bind(this, this._onClicked));
this._box.add_actor(this._button, this._box.add_actor(this._button);
{ x_fill: true,
y_fill: true,
expand: true });
this._scrollView = new St.ScrollView({ style_class: 'login-dialog-session-list-scroll-view'}); this._scrollView = new St.ScrollView({ style_class: 'login-dialog-session-list-scroll-view'});
this._scrollView.set_policy(Gtk.PolicyType.NEVER, this._scrollView.set_policy(Gtk.PolicyType.NEVER,
Gtk.PolicyType.AUTOMATIC); Gtk.PolicyType.AUTOMATIC);
this._box.add_actor(this._scrollView, this._box.add_actor(this._scrollView);
{ x_fill: true,
y_fill: true,
expand: true });
this._itemList = new St.BoxLayout({ style_class: 'login-dialog-session-item-list', this._itemList = new St.BoxLayout({ style_class: 'login-dialog-session-item-list',
vertical: true }); vertical: true });
this._scrollView.add_actor(this._itemList, this._scrollView.add_actor(this._itemList);
{ x_fill: true,
y_fill: true,
expand: true });
this._scrollView.hide(); this._scrollView.hide();
this.isOpen = false; this.isOpen = false;
this._populate(); this._populate();
@ -714,11 +689,7 @@ const SessionList = new Lang.Class({
let [sessionName, sessionDescription] = Gdm.get_session_name_and_description(ids[i]); let [sessionName, sessionDescription] = Gdm.get_session_name_and_description(ids[i]);
let item = new SessionListItem(ids[i], sessionName); let item = new SessionListItem(ids[i], sessionName);
this._itemList.add_actor(item.actor, this._itemList.add_actor(item.actor);
{ x_align: St.Align.START,
y_align: St.Align.START,
x_fill: true,
y_fill: true });
this._items[ids[i]] = item; this._items[ids[i]] = item;
if (!this._activeSessionId) if (!this._activeSessionId)

View File

@ -279,11 +279,7 @@ const EndSessionDialog = new Lang.Class({
scrollView.hide(); scrollView.hide();
this._applicationList = new St.BoxLayout({ vertical: true }); this._applicationList = new St.BoxLayout({ vertical: true });
scrollView.add_actor(this._applicationList, scrollView.add_actor(this._applicationList);
{ x_fill: true,
y_fill: true,
x_align: St.Align.START,
y_align: St.Align.MIDDLE });
this._applicationList.connect('actor-added', this._applicationList.connect('actor-added',
Lang.bind(this, function() { Lang.bind(this, function() {

View File

@ -470,11 +470,7 @@ const ShellProcessesDialog = new Lang.Class({
scrollView.hide(); scrollView.hide();
this._applicationList = new St.BoxLayout({ vertical: true }); this._applicationList = new St.BoxLayout({ vertical: true });
scrollView.add_actor(this._applicationList, scrollView.add_actor(this._applicationList);
{ x_fill: true,
y_fill: true,
x_align: St.Align.START,
y_align: St.Align.MIDDLE });
this._applicationList.connect('actor-added', this._applicationList.connect('actor-added',
Lang.bind(this, function() { Lang.bind(this, function() {