mirror of
https://github.com/zoriya/noctalia-shell.git
synced 2026-08-15 18:43:59 +00:00
Multi-Monitors: new setting to explicitely disable panels to appear on screen without bar.
On my setup this saves about 130MB per 1080p monitor where the bar is not shown. I only interact with noctalia on my main screen.
This commit is contained in:
@@ -393,6 +393,16 @@ Item {
|
||||
|
||||
// Execute pending callback if any
|
||||
if (pendingCallback) {
|
||||
if (!Settings.data.general.allowPanelsOnScreenWithoutBar) {
|
||||
// If we explicitely disabled panels on screen without bar, check if bar is configured
|
||||
// for this screen, and fallback to primary screen if necessary
|
||||
var monitors = Settings.data.bar.monitors || [];
|
||||
const hasBar = monitors.length === 0 || monitors.includes(detectedScreen?.name);
|
||||
if (!hasBar) {
|
||||
detectedScreen = Quickshell.screens[0];
|
||||
}
|
||||
}
|
||||
|
||||
Logger.d("IPC", "Executing pending IPC callback on screen:", detectedScreen.name);
|
||||
pendingCallback(detectedScreen);
|
||||
pendingCallback = null;
|
||||
|
||||
Reference in New Issue
Block a user