[6fc8f95bc6465849249d974d53eecc56c00ffda0fc3c7024bfa5b8e4d794b072/gnome-3-36] inhibitShortcutsDialog: Enable line wrapping for additional label
- From: Florian Müllner <fmuellner src gnome org>
- To: commits-list gnome org
- Cc: 
- Subject: [6fc8f95bc6465849249d974d53eecc56c00ffda0fc3c7024bfa5b8e4d794b072/gnome-3-36] inhibitShortcutsDialog: Enable line wrapping for additional label
- Date: Tue,  7 Jul 2020 19:10:59 +0000 (UTC)
commit d0d91c49b8c3c7cfd78d076c7c9ac40f77b00e87
Author: Jonas Dreßler <verdre v0yd nl>
Date:   Sun Jun 28 22:28:57 2020 +0200
    inhibitShortcutsDialog: Enable line wrapping for additional label
    
    The inhibitShortcutsDialog can show an additional label which explains
    how to restore shortcuts. This label is not managed by the
    MessageDialogContent, so we need to enable line wrapping and disable
    ellipsization ourselves.
    
    Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2616
    
    https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1336
 js/ui/inhibitShortcutsDialog.js | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
---
diff --git a/js/ui/inhibitShortcutsDialog.js b/js/ui/inhibitShortcutsDialog.js
index 14731daa5a..ac86eea49e 100644
--- a/js/ui/inhibitShortcutsDialog.js
+++ b/js/ui/inhibitShortcutsDialog.js
@@ -1,5 +1,5 @@
 /* exported InhibitShortcutsDialog */
-const { Clutter, Gio, GLib, GObject, Gtk, Meta, Shell, St } = imports.gi;
+const { Clutter, Gio, GLib, GObject, Gtk, Meta, Pango, Shell, St } = imports.gi;
 
 const Dialog = imports.ui.dialog;
 const ModalDialog = imports.ui.modalDialog;
@@ -90,6 +90,8 @@ var InhibitShortcutsDialog = GObject.registerClass({
                 text: _('You can restore shortcuts by pressing %s.').format(restoreAccel),
                 style_class: 'message-dialog-description',
             });
+            restoreLabel.clutter_text.ellipsize = Pango.EllipsizeMode.NONE;
+            restoreLabel.clutter_text.line_wrap = true;
             content.add_child(restoreLabel);
         }
 
[
Date Prev][
Date Next]   [
Thread Prev][
Thread Next]   
[
Thread Index]
[
Date Index]
[
Author Index]