Свойство top
override
Ссылка на верхнее окно в иерархии окон.
Если этот WindowBase является самым верхним WindowBase, top вернет ссылку на сам WindowBase.
// Add an IFrame to the current window. IFrameElement myIFrame = new IFrameElement(); window.document.body.elements.add(myIFrame); // Add an IFrame inside of the other IFrame. IFrameElement innerIFrame = new IFrameElement(); myIFrame.elements.add(innerIFrame); print(myIframe.contentWindow.top == window) // 'true' print(innerIFrame.contentWindow.top == window) // 'true' print(window.top == window) // 'true'
Реализация
WindowBase? get top => _convertNativeToDart_Window(this._get_top);
© 2012 the Dart project authors
Licensed under the BSD 3-Clause "New" or "Revised" License.
https://api.dart.dev/stable/2.18.5/dart-html/Window/top.html