New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
重启后窗口大小恢复默认问题 #7755
Comments
另外,对于修改方案的实现:
|
我输出了windowState, 和你说的一样, windowState加载了oldWindowState的数据. Lines 207 to 212 in f83a07f
我输出了workArea和windowState的width, height const windowState = Object.assign({}, {
isMaximized: true,
fullscreen: false,
isDevToolsOpened: false,
x: 0,
y: 0,
width: defaultWidth,
height: defaultHeight,
}, oldWindowState);
writeLog("windowStat: width " + windowState.width + ", height: " + windowState.height)
writeLog("workArea: width " + workArea.width + ", height " + workArea.height)
返回的 你可以将窗口高度拉到最大试试看能否重现. 我调小高度到1000后, 窗口大小正常了. 条件改为 if (windowState.width > workArea.width || windowState.height > workArea.height) { |
确实是这个问题,感谢指正,下个版本修复。 |
该问题是否已经被报告过了? Is there an existing issue for this?
I have searched the existing issues
该问题是否能够在默认主题(daylight/midnight)下重现? Can the issue be reproduced with the default theme (daylight/midnight)?
I was able to reproduce the issue with the default theme
该问题是否可能是由于扩展功能导致? Could the issue be due to extensions?
I've ruled out the possibility that the extension is causing the problem.
描述问题 Describe the problem
如下两行代码一直使用screen的width和height, 没有将windowState的width和height读入使用.
siyuan/app/electron/main.js
Lines 189 to 190 in f83a07f
将代码改为下面的形式, 能够在下次打开程序时套用上次的windowState的width和height.
期待的结果 Expected result
请在后续版本修正此问题, 谢谢.
截屏或者录屏演示 Screenshot or screen recording presentation
No response
版本环境 Version environment
日志文件 Log file
app.log
更多信息 More information
No response
The text was updated successfully, but these errors were encountered: