mirror of
https://github.com/rustdesk/rustdesk.git
synced 2024-11-28 07:39:36 +08:00
Merge pull request #5300 from dignow/fix/render_texture_instance
Fix/render texture instance
This commit is contained in:
commit
9121de746f
@ -116,11 +116,7 @@ class _RemotePageState extends State<RemotePage>
|
||||
Wakelock.enable();
|
||||
}
|
||||
// Register texture.
|
||||
if (mainGetLocalBoolOptionSync(kOptionOpenNewConnInTabs)) {
|
||||
_renderTexture = renderTexture;
|
||||
} else {
|
||||
_renderTexture = RenderTexture();
|
||||
}
|
||||
_renderTexture = RenderTexture();
|
||||
_renderTexture.create(sessionId);
|
||||
|
||||
_ffi.ffiModel.updateEventListener(sessionId, widget.id);
|
||||
|
@ -582,8 +582,6 @@ class WindowActionPanelState extends State<WindowActionPanel>
|
||||
}
|
||||
await windowManager.hide();
|
||||
} else {
|
||||
renderTexture.destroy();
|
||||
|
||||
// it's safe to hide the subwindow
|
||||
final controller = WindowController.fromWindowId(kWindowId!);
|
||||
if (Platform.isMacOS && await controller.isFullScreen()) {
|
||||
|
@ -38,9 +38,4 @@ class RenderTexture {
|
||||
_textureKey = -1;
|
||||
}
|
||||
}
|
||||
|
||||
static final RenderTexture instance = RenderTexture();
|
||||
}
|
||||
|
||||
// Global instance for separate texture
|
||||
final renderTexture = RenderTexture.instance;
|
||||
|
Loading…
Reference in New Issue
Block a user