mirror of
https://github.com/morgan9e/dash-to-panel
synced 2026-04-14 00:04:17 +09:00
Fix hide-overview-on-startup on GNOME 50
This commit is contained in:
@@ -61,6 +61,18 @@ export default class DashToPanelExtension extends Extension {
|
|||||||
async enable() {
|
async enable() {
|
||||||
DTP_EXTENSION = this
|
DTP_EXTENSION = this
|
||||||
SETTINGS = this.getSettings('org.gnome.shell.extensions.dash-to-panel')
|
SETTINGS = this.getSettings('org.gnome.shell.extensions.dash-to-panel')
|
||||||
|
|
||||||
|
if (
|
||||||
|
SETTINGS.get_boolean('hide-overview-on-startup') &&
|
||||||
|
Main.layoutManager._startingUp
|
||||||
|
) {
|
||||||
|
Main.sessionMode.hasOverview = false
|
||||||
|
startupCompleteHandler = Main.layoutManager.connect(
|
||||||
|
'startup-complete',
|
||||||
|
() => (Main.sessionMode.hasOverview = this._realHasOverview),
|
||||||
|
)
|
||||||
|
}
|
||||||
|
|
||||||
DESKTOPSETTINGS = new Gio.Settings({
|
DESKTOPSETTINGS = new Gio.Settings({
|
||||||
schema_id: 'org.gnome.desktop.interface',
|
schema_id: 'org.gnome.desktop.interface',
|
||||||
})
|
})
|
||||||
@@ -107,21 +119,6 @@ export default class DashToPanelExtension extends Extension {
|
|||||||
SETTINGS.set_int('extension-version', this.metadata.version)
|
SETTINGS.set_int('extension-version', this.metadata.version)
|
||||||
}
|
}
|
||||||
|
|
||||||
Main.layoutManager.startInOverview = !SETTINGS.get_boolean(
|
|
||||||
'hide-overview-on-startup',
|
|
||||||
)
|
|
||||||
|
|
||||||
if (
|
|
||||||
SETTINGS.get_boolean('hide-overview-on-startup') &&
|
|
||||||
Main.layoutManager._startingUp
|
|
||||||
) {
|
|
||||||
Main.sessionMode.hasOverview = false
|
|
||||||
startupCompleteHandler = Main.layoutManager.connect(
|
|
||||||
'startup-complete',
|
|
||||||
() => (Main.sessionMode.hasOverview = this._realHasOverview),
|
|
||||||
)
|
|
||||||
}
|
|
||||||
|
|
||||||
this.enableGlobalStyles()
|
this.enableGlobalStyles()
|
||||||
|
|
||||||
let completeEnable = () => {
|
let completeEnable = () => {
|
||||||
|
|||||||
Reference in New Issue
Block a user