summaryrefslogtreecommitdiff
path: root/src/wx/simple_video_view.cc
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2021-11-20 22:36:06 +0100
committerCarl Hetherington <cth@carlh.net>2021-11-20 22:44:24 +0100
commit54255e8a535d08055e526888a6d4d2f4aa68c203 (patch)
treee3e9621fd7ba05adea6ca589b92909079115d6df /src/wx/simple_video_view.cc
parent2d2af972a53a2c11b95469058803b4eaed2d3c01 (diff)
Fix incorrect scaling of the simple view with hidpi screens (#2128).
Diffstat (limited to 'src/wx/simple_video_view.cc')
-rw-r--r--src/wx/simple_video_view.cc2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/wx/simple_video_view.cc b/src/wx/simple_video_view.cc
index 1ac56bbfe..f4ff9a4eb 100644
--- a/src/wx/simple_video_view.cc
+++ b/src/wx/simple_video_view.cc
@@ -65,6 +65,8 @@ SimpleVideoView::paint ()
{
_state_timer.set("paint-panel");
wxPaintDC dc (_panel);
+ auto scale = 1 / dpi_scale_factor (_panel);
+ dc.SetLogicalScale (scale, scale);
auto const panel_size = _panel->GetSize ();