feat: add getBounds() method for BrowserView (#19370)
* implement getBounds on mac * add Linux/Win impl * add test * add docs
This commit is contained in:
parent
c06007175f
commit
42a483ad27
9 changed files with 39 additions and 0 deletions
|
@ -92,6 +92,15 @@ describe('BrowserView module', () => {
|
|||
})
|
||||
})
|
||||
|
||||
describe('BrowserView.getBounds()', () => {
|
||||
it('returns the current bounds', () => {
|
||||
view = new BrowserView()
|
||||
const bounds = { x: 10, y: 20, width: 30, height: 40 }
|
||||
view.setBounds(bounds)
|
||||
expect(view.getBounds()).to.deep.equal(bounds)
|
||||
})
|
||||
})
|
||||
|
||||
describe('BrowserWindow.setBrowserView()', () => {
|
||||
it('does not throw for valid args', () => {
|
||||
view = new BrowserView()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue