[gnome-shell/wip/fmuellner/replace-app-menu: 10/10] panel: Restrict app menu width
- From: Florian Müllner <fmuellner src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell/wip/fmuellner/replace-app-menu: 10/10] panel: Restrict app menu width
- Date: Tue, 5 Feb 2019 01:16:21 +0000 (UTC)
commit 605c7b3d4b62523e7dee3bfa597acb7543d90078
Author: Florian Müllner <fmuellner gnome org>
Date: Tue Feb 5 01:11:43 2019 +0100
panel: Restrict app menu width
Window titles aren't restricted in length, so the menu may end up unwieldily
width. Commit 0bec76b6ee therefore limited the app context menus, but that
got accidentally dropped in commit 0ded0dbfd5. Add back the limitation and
extend it to the new app menu as well.
https://gitlab.gnome.org/GNOME/gnome-shell/issues/624
data/theme/gnome-shell-sass/_common.scss | 5 +++++
js/ui/panel.js | 2 ++
2 files changed, 7 insertions(+)
---
diff --git a/data/theme/gnome-shell-sass/_common.scss b/data/theme/gnome-shell-sass/_common.scss
index b7d052bcc..7b77fce20 100644
--- a/data/theme/gnome-shell-sass/_common.scss
+++ b/data/theme/gnome-shell-sass/_common.scss
@@ -1107,6 +1107,11 @@ StScrollBar {
.label-shadow { color: transparent; }
}
+ .app-menu,
+ .app-well-menu {
+ max-width: 27.25em;
+ }
+
.aggregate-menu {
min-width: 21em;
.popup-menu-icon { padding: 0 4px; }
diff --git a/js/ui/panel.js b/js/ui/panel.js
index e267a55b5..1b36528cd 100644
--- a/js/ui/panel.js
+++ b/js/ui/panel.js
@@ -78,6 +78,8 @@ class AppMenu extends PopupMenu.PopupMenu {
constructor(sourceActor) {
super(sourceActor, 0.0, St.Side.TOP);
+ this.actor.add_style_class_name('app-menu');
+
this._app = null;
this._appSystem = Shell.AppSystem.get_default();
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]