1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43
|
Description: fix dialog pop-up
This fixes the remove trash dialog pop-up that doesn't work on Gnome 3.38.
Author: Jonathan Carter <jcc@debian.org>
Origin: https://gitlab.com/bertoldia/gnome-shell-trash-extension/-/issues/25
Bug: https://gitlab.com/bertoldia/gnome-shell-trash-extension/-/issues/25
Last-Update: 2020-10-22
--- gnome-shell-extension-trash-0.2.0-git20200326.3425fcf1.orig/extension.js
+++ gnome-shell-extension-trash-0.2.0-git20200326.3425fcf1/extension.js
@@ -167,23 +167,25 @@ var ConfirmEmptyTrashDialog = GObject.re
_init(emptyMethod) {
super._init({ styleClass: null });
- let mainContentBox = new St.BoxLayout({ style_class: 'polkit-dialog-main-layout',
+ let mainContentBox = new St.BoxLayout({ style_class: `polkit-dialog-main-layout`,
vertical: false });
- this.contentLayout.add(mainContentBox, { x_fill: true, y_fill: true });
+ this.contentLayout.add_child(mainContentBox, { x_fill: true, y_fill: true });
- let messageBox = new St.BoxLayout({ style_class: 'polkit-dialog-message-layout',
+ let messageBox = new St.BoxLayout({ style_class: `polkit-dialog-message-layout`,
vertical: true });
- mainContentBox.add(messageBox, { y_align: St.Align.START });
+ mainContentBox.add_child(messageBox, { y_align: St.Align.START });
- this._subjectLabel = new St.Label({ style_class: 'polkit-dialog-headline',
+ this._subjectLabel = new St.Label({ style_class: `polkit-dialog-headline`,
+ style: `text-align: center; font-size: 1.6em; padding-bottom:1em`,
text: _("Empty Trash?") });
- messageBox.add(this._subjectLabel, { y_fill: false, y_align: St.Align.START });
+ messageBox.add_child(this._subjectLabel, { y_fill: false, y_align: St.Align.START });
- this._descriptionLabel = new St.Label({ style_class: 'polkit-dialog-description',
+ this._descriptionLabel = new St.Label({ style_class: `polkit-dialog-description`,
+ style: `text-align: center`,
text: Gettext.gettext(MESSAGE) });
- messageBox.add(this._descriptionLabel, { y_fill: true, y_align: St.Align.START });
+ messageBox.add_child(this._descriptionLabel, { y_fill: true, y_align: St.Align.START });
this.setButtons([
{
|