aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorPo Lu2021-11-10 14:29:54 +0800
committerPo Lu2021-11-10 14:29:54 +0800
commit465ec29926d2fd873a22e26f3a8b395a527ba2f5 (patch)
tree88325a783a52a84771637870bd72065ee3f9eec5 /src
parent9653cbf3558df7c7318cac551e8e5d7ac8e669e2 (diff)
downloademacs-465ec29926d2fd873a22e26f3a8b395a527ba2f5.tar.gz
emacs-465ec29926d2fd873a22e26f3a8b395a527ba2f5.zip
Fix incorrect offset calculation for clipped xwidget views
* src/xwidget.c (from_embedder, to_embedder): Remove incorrect adjustment of position by view clipping.
Diffstat (limited to 'src')
-rw-r--r--src/xwidget.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/xwidget.c b/src/xwidget.c
index 4da53187068..034989b339c 100644
--- a/src/xwidget.c
+++ b/src/xwidget.c
@@ -530,8 +530,8 @@ from_embedder (GdkWindow *window, double x, double y,
530 FRAME_GTK_OUTER_WIDGET (xvw->frame), 530 FRAME_GTK_OUTER_WIDGET (xvw->frame),
531 0, 0, &xoff, &yoff); 531 0, 0, &xoff, &yoff);
532 532
533 *xout = x - (xvw->x + xvw->clip_left) - xoff; 533 *xout = x - xvw->x - xoff;
534 *yout = y - (xvw->y + xvw->clip_top) - yoff; 534 *yout = y - xvw->y - yoff;
535 } 535 }
536} 536}
537 537
@@ -562,8 +562,8 @@ to_embedder (GdkWindow *window, double x, double y,
562 FRAME_GTK_OUTER_WIDGET (xvw->frame), 562 FRAME_GTK_OUTER_WIDGET (xvw->frame),
563 0, 0, &xoff, &yoff); 563 0, 0, &xoff, &yoff);
564 564
565 *xout = x + xvw->x + xvw->clip_left + xoff; 565 *xout = x + xvw->x + xoff;
566 *yout = y + xvw->y + xvw->clip_top + yoff; 566 *yout = y + xvw->y + yoff;
567 } 567 }
568} 568}
569 569