enable transparency when vibrancy is enabled on Windows

This commit is contained in:
Eugene Pankov 2018-08-24 23:16:09 +02:00
parent 594597e93d
commit a10c6e6251
2 changed files with 6 additions and 2 deletions

View File

@ -233,6 +233,10 @@ start = () => {
} }
} }
if (process.platform == 'win32' && (configData.appearance || {}).vibrancy) {
options.transparent = true
}
if (process.platform == 'linux') { if (process.platform == 'linux') {
options.backgroundColor = '#131d27' options.backgroundColor = '#131d27'
} }
@ -243,7 +247,7 @@ start = () => {
app.window.once('ready-to-show', () => { app.window.once('ready-to-show', () => {
if (process.platform == 'darwin') { if (process.platform == 'darwin') {
app.window.setVibrancy('dark') app.window.setVibrancy('dark')
} else if (process.platform == 'windows') { } else if (process.platform == 'win32' && (configData.appearance || {}).vibrancy) {
setWindowVibrancy(true) setWindowVibrancy(true)
} }
app.window.show() app.window.show()

View File

@ -44,7 +44,7 @@ ngb-tabset.vertical(type='tabs', [activeId]='activeTab')
br br
.btn-group( .btn-group(
'[(ngModel)]'='config.store.appearance.vibrancy' '[(ngModel)]'='config.store.appearance.vibrancy'
'(ngModelChange)'='config.save()' '(ngModelChange)'='config.save(); (hostApp.platform === Platform.Windows && config.requestRestart())'
ngbRadioGroup ngbRadioGroup
) )
label.btn.btn-secondary(ngbButtonLabel) label.btn.btn-secondary(ngbButtonLabel)