From 213e62a7a0afe188660d2d4210e8976f9050c971 Mon Sep 17 00:00:00 2001 From: X512 Date: Sun, 28 Jun 2020 21:19:52 +0900 Subject: [PATCH] Input: fix MouseView drawing BeginPicture/EndPicture do not save state so origin should be restored after recording picture. BView::Draw use PushState internally so origin is added and cause problem. hrev54347 fixed behavior when recording picture so state change is affected. It revealed #16317 bug. Fixes #16317. Change-Id: Iee69631ce83fea5ea73c99b492b8cf67d1b148c7 Reviewed-on: https://review.haiku-os.org/c/haiku/+/2960 Reviewed-by: waddlesplash --- src/preferences/input/MouseView.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/preferences/input/MouseView.cpp b/src/preferences/input/MouseView.cpp index 19db856afe..edef4ab9fb 100644 --- a/src/preferences/input/MouseView.cpp +++ b/src/preferences/input/MouseView.cpp @@ -377,5 +377,6 @@ MouseView::_CreateButtonsPicture() FillShape(&mouseShape, B_SOLID_HIGH); EndPicture(); + SetOrigin(0, 0); SetScale(1); }