mirror of
https://github.com/electron/electron.git
synced 2026-05-02 03:00:22 -04:00
Match chromium's workaround when setting size of unresizable windows
This commit is contained in:
@@ -2235,6 +2235,24 @@ describe('BrowserWindow module', () => {
|
||||
assert.equal(w.isResizable(), false)
|
||||
}
|
||||
})
|
||||
|
||||
if (process.platform === 'win32') {
|
||||
it('works for a window smaller than 64x64', () => {
|
||||
w.destroy()
|
||||
w = new BrowserWindow({
|
||||
show: false,
|
||||
frame: false,
|
||||
resizable: false,
|
||||
transparent: true
|
||||
})
|
||||
w.setContentSize(60, 60)
|
||||
assertBoundsEqual(w.getContentSize(), [60, 60])
|
||||
w.setContentSize(30, 30)
|
||||
assertBoundsEqual(w.getContentSize(), [30, 30])
|
||||
w.setContentSize(10, 10)
|
||||
assertBoundsEqual(w.getContentSize(), [10, 10])
|
||||
})
|
||||
}
|
||||
})
|
||||
|
||||
describe('loading main frame state', () => {
|
||||
|
||||
Reference in New Issue
Block a user