Skip to content

Commit

Permalink
Merge pull request rustdesk#5752 from dignow/fix/restore_texture_offs…
Browse files Browse the repository at this point in the history
…et_linux

fix, set texture widget offset to int on linux
  • Loading branch information
rustdesk authored Sep 19, 2023
2 parents 7e5b81f + cb1a062 commit 83daa70
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions flutter/lib/desktop/pages/remote_page.dart
Original file line number Diff line number Diff line change
Expand Up @@ -576,11 +576,13 @@ class _ImagePaintState extends State<ImagePaint> {
late final Widget imageWidget;
if (c.size.width > 0 && c.size.height > 0) {
if (widget.useTextureRender) {
final x = Platform.isLinux ? c.x.toInt().toDouble() : c.x;
final y = Platform.isLinux ? c.y.toInt().toDouble() : c.y;
imageWidget = Stack(
children: [
Positioned(
left: c.x,
top: c.y,
left: x,
top: y,
width: c.getDisplayWidth() * s,
height: c.getDisplayHeight() * s,
child: Texture(
Expand Down

0 comments on commit 83daa70

Please sign in to comment.