YesPlayMusic
YesPlayMusic copied to clipboard
Linux 无法记忆窗口大小
如题,上一个版本没问题,更新了就出问题了。无论调节为多少,重新启动软件时窗口大小都会被重置。
控制台没有任何输出。
环境:
- Arch Linux : KDE Plasma 5.22 on X11
- 客户端 0.4.0 版本
另外打开控制台时总会报错:
一样的问题,而且不能根据系统的缩放进行相应的缩放 这是全屏的效果
我也遇到了一样的问题,目测是因为(这个版本的) KDE 下(这个版本的) electron 没有正确运行这两个回调函数 https://github.com/qier222/YesPlayMusic/blob/a9b05d66a6bc756c4335edd3c6160b02d2b24a41/src/background.js#L327-L333 我现在的 workaround 是在这两个回调函数后加上
this.window.on('close', () => {
this.store.set('window', this.window.getBounds());
});
这个回调可以正确执行;另一个 workaround 是在 ~/.config/yesplaymusic/
下新建 config.json
,然后手动存储窗口信息:
{
"window": {
"x": 228,
"y": 73,
"width": 1080,
"height": 721
}
}
这是我的 screenfetch
██████████████████ ████████
██████████████████ ████████ OS: Manjaro 21.2.6 Qonos
██████████████████ ████████ Kernel: x86_64 Linux 5.15.32-1-MANJARO
██████████████████ ████████ Uptime: 12h 0m
████████ ████████ Packages: 2124
████████ ████████ ████████ Shell: bash
████████ ████████ ████████ Resolution: 1920x1080
████████ ████████ ████████ DE: KDE 5.92.0 / Plasma 5.24.4
████████ ████████ ████████ WM: KWin
████████ ████████ ████████ GTK Theme: Breath [GTK2/3]
████████ ████████ ████████ Icon Theme: WhiteSur
████████ ████████ ████████ Disk: 567G / 1.8T (32%)
████████ ████████ ████████ CPU: Intel Core i5-1035G1 @ 8x 3.6GHz [68.0°C]
████████ ████████ ████████ GPU: NVIDIA GeForce MX250