protected virtual void OnEnable() { if (this._windowAdapter == null) { this._windowAdapter = new EditorWindowAdapter(this); } this._windowAdapter.OnEnable(); RenderBox rootRenderBox; using (this._windowAdapter.getScope()) { rootRenderBox = this.createRenderBox(); } if (rootRenderBox != null) { this._windowAdapter.attachRootRenderBox(rootRenderBox); return; } Widget rootWidget; using (this._windowAdapter.getScope()) { rootWidget = this.createWidget(); } this._windowAdapter.attachRootWidget(rootWidget); }
public override IDisposable getScope() { WindowAdapter oldInstance = (WindowAdapter) _instance; _instance = this; if (this._binding == null) { this._binding = new WidgetsBinding(); } SchedulerBinding._instance = this._binding; return new WindowDisposable(this, oldInstance); }
void OnEnable() { if (this._windowAdapter == null) { this._windowAdapter = new EditorWindowAdapter(this); } this._windowAdapter.OnEnable(); var rootRenderBox = this.rootRenderBox(); if (rootRenderBox != null) { this._windowAdapter.attachRootRenderBox(rootRenderBox); return; } this._windowAdapter.attachRootWidget(this.rootWidget()); }
public WindowDisposable(WindowAdapter window) { this._window = window; }
public WindowDisposable(WindowAdapter window, WindowAdapter oldWindow) { this._window = window; this._oldWindow = oldWindow; }