modalDialog: Remove some unused code

No need to figure out an x_alignment variable that hasn't been used
since commit 0722c06275 ...
This commit is contained in:
Florian Müllner 2018-03-03 00:31:00 +01:00 committed by Florian Müllner
parent bdde2476d2
commit 526834e39b

View File

@ -100,21 +100,8 @@ var ModalDialog = new Lang.Class({
setButtons(buttons) { setButtons(buttons) {
this.clearButtons(); this.clearButtons();
for (let i = 0; i < buttons.length; i++) { for (let buttonInfo of buttons)
let buttonInfo = buttons[i];
let x_alignment;
if (buttons.length == 1)
x_alignment = St.Align.END;
else if (i == 0)
x_alignment = St.Align.START;
else if (i == buttons.length - 1)
x_alignment = St.Align.END;
else
x_alignment = St.Align.MIDDLE;
this.addButton(buttonInfo); this.addButton(buttonInfo);
}
}, },
addButton(buttonInfo) { addButton(buttonInfo) {