overlay: Don't offset the main window snapshot

We need the node without an offset applied.

Fixes the rose picture being offset in tests/testoverlay
This commit is contained in:
Timm Bäder 2019-01-13 05:41:43 +01:00
parent 4dc8ab58a3
commit d098cd5865

View File

@ -722,9 +722,7 @@ gtk_overlay_snapshot (GtkWidget *widget,
GtkSnapshot *child_snapshot;
child_snapshot = gtk_snapshot_new ();
gtk_snapshot_offset (child_snapshot, main_alloc.x, main_alloc.y);
gtk_widget_snapshot (main_widget, child_snapshot);
gtk_snapshot_offset (child_snapshot, -main_alloc.x, -main_alloc.y);
main_widget_node = gtk_snapshot_free_to_node (child_snapshot);
}