Skip to content

Commit

Permalink
Fix screen geometry to account for rotation when snapping.
Browse files Browse the repository at this point in the history
  • Loading branch information
BrentBradburn authored and monsta committed Mar 18, 2018
1 parent 48b4fc3 commit b198f90
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions capplets/display/xrandr-capplet.c
Expand Up @@ -1153,6 +1153,7 @@ list_edges_for_output (MateRROutputInfo *output, GArray *edges)
int x, y, w, h;

mate_rr_output_info_get_geometry (output, &x, &y, &w, &h);
get_geometry(output, &w, &h); // accounts for rotation

/* Top, Bottom, Left, Right */
add_edge (output, x, y, x + w, y, edges);
Expand Down Expand Up @@ -1351,6 +1352,7 @@ static void
get_output_rect (MateRROutputInfo *output, GdkRectangle *rect)
{
mate_rr_output_info_get_geometry (output, &rect->x, &rect->y, &rect->width, &rect->height);
get_geometry (output, &rect->width, &rect->height); // accounts for rotation
}

static gboolean
Expand Down

0 comments on commit b198f90

Please sign in to comment.