From 3bc9f66336f817b352e9d58a5aa2abd461316e3e Mon Sep 17 00:00:00 2001 From: sowens99 Date: Mon, 20 Sep 2021 09:49:51 -0400 Subject: [PATCH] Inscribe StickWidget ellipse in square Previously, it was not clear where the boundary of the StickWidget was when interacting outside of the circle. This aims to restore the gray square present in the Wx-era. --- Source/Core/DolphinQt/TAS/StickWidget.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Source/Core/DolphinQt/TAS/StickWidget.cpp b/Source/Core/DolphinQt/TAS/StickWidget.cpp index 7339e9ce52..26f806971a 100644 --- a/Source/Core/DolphinQt/TAS/StickWidget.cpp +++ b/Source/Core/DolphinQt/TAS/StickWidget.cpp @@ -47,6 +47,9 @@ void StickWidget::paintEvent(QPaintEvent* event) const int diameter = std::min(width(), height()) - PADDING * 2; + // inscribe the StickWidget inside a square + painter.fillRect(PADDING, PADDING, diameter, diameter, Qt::lightGray); + painter.setBrush(Qt::white); painter.drawEllipse(PADDING, PADDING, diameter, diameter);