Skip to content
This repository has been archived by the owner on Jul 23, 2020. It is now read-only.

Commit

Permalink
QGtkScreen: Disable DPR workaround for newer GTK+ versions
Browse files Browse the repository at this point in the history
This fixes Telegram Desktop's image overlays in Fedora 27, probably
Creator menu positioning, and a lot of other things
  • Loading branch information
rburchell committed Nov 17, 2017
1 parent bdbf1ac commit b71b2c4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/qgtkscreen.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,8 @@ QGtkScreen::QGtkScreen(GdkMonitor *monitor)
QRect QGtkScreen::availableGeometry() const
{
qreal dpr = 1.0;
#if defined(GDK_WINDOWING_WAYLAND) && !GTK_CHECK_VERSION(3, 22, 25)
GdkDisplay *dpy = gdk_display_get_default();
#ifdef GDK_WINDOWING_WAYLAND
// Workaround for https://bugzilla.gnome.org/show_bug.cgi?id=788497
if (GDK_IS_WAYLAND_DISPLAY(dpy)) {
dpr = devicePixelRatio();
Expand All @@ -62,8 +62,8 @@ QRect QGtkScreen::availableGeometry() const
QRect QGtkScreen::geometry() const
{
qreal dpr = 1.0;
#if defined(GDK_WINDOWING_WAYLAND) && !GTK_CHECK_VERSION(3, 22, 25)
GdkDisplay *dpy = gdk_display_get_default();
#ifdef GDK_WINDOWING_WAYLAND
// Workaround for https://bugzilla.gnome.org/show_bug.cgi?id=788497
if (GDK_IS_WAYLAND_DISPLAY(dpy)) {
dpr = devicePixelRatio();
Expand Down

0 comments on commit b71b2c4

Please sign in to comment.