Unity sends initial GDK_CONFIGURE event with position as (0,0)
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Compiz Core |
Fix Released
|
Medium
|
Sam Spilsbury | ||
compiz (Ubuntu) |
Fix Released
|
Undecided
|
Sam Spilsbury | ||
Oneiric |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
= SRU TESTCASE =
Old Behaviour:
1. Run testcase
2. Notice that it reports 2 sets of x and y values of 0,0
Fixed behaviour:
1. Run testacse
2. Notice that it reports 2 sets of x and y values which reflect the actual window position
= Problem =
After creating a top-level GTK widget, the window manager sends GDK_CONFIGURE with the position as (0,0) even though the initial position is already set to a different value.
= Environment =
* Ubuntu 11.10 (Oneiric) i386
* Unity - 4.22.0-0ubuntu3
= Impact =
This causes issues for applications that rely on this GDK_CONFIGURE to locate their app window.
= Steps to reproduce =
1. Compile gdkconfig.cpp: g++ -o gdktest gdkconfig.cpp `pkg-config --libs gtk+-2.0` `pkg-config --cflags gtk+-2.0`
2. Launch it from a terminal
3. Observe output from terminal
4. Click "OK" to launch a new window
5. Observe logs, you should see something like this:
popup window created gdkwindow -- 7063232
GDK_CONFIGURE : window -- 7063232, x -- 250, y -- 250, width -- 200, height -- 200
GDK_CONFIGURE : window -- 7063232, x -- 0, y -- 0, width -- 200, height -- 200
GDK_CONFIGURE : window -- 7063232, x -- 0, y -- 0, width -- 200, height -- 200
GDK_CONFIGURE : window -- 7063232, x -- 0, y -- 0, width -- 200, height -- 200
GDK_CONFIGURE : window -- 7063232, x -- 251, y -- 275, width -- 200, height -- 200
When running under Natty or Unity-2D, GDK_CONFIGURE is never set to 0,0.
= Original text =
when using unity 3d on ubuntu, after creating a top-level gtk widget, the window manager sends GDK_CONFIGURE with position as (0,0) although I have set the initial position to some different value.
This dose not happen on gnome/unity 2d environment. It will cause seriously issue when we rely on this event to locate our window.
Source code attached, you could compile it and launch it from terminal, the GDK_CONFIGURE event will be printed out.
Related branches
- Gord Allott (community): Approve
-
Diff: 41 lines (+4/-20)1 file modifiedsrc/window.cpp (+4/-20)
- Stéphane Graber: Approve
-
Diff: 308 lines (+278/-0)5 files modifieddebian/changelog (+13/-0)
debian/patches/fix_890947_synthetic_notifications.patch (+43/-0)
debian/patches/fix_focus_on_wrong_window_896762.patch (+20/-0)
debian/patches/java_offset_frame_extents_878934.patch (+199/-0)
debian/patches/series (+3/-0)
affects: | ubuntuone-client → unity (Ubuntu) |
Changed in unity: | |
status: | New → Confirmed |
Changed in unity (Ubuntu): | |
status: | New → Confirmed |
Changed in unity: | |
importance: | Undecided → Low |
Changed in unity (Ubuntu): | |
importance: | Undecided → Low |
description: | updated |
summary: |
- unity 3d window manager send initial GDK_CONFIGURE event with position - as (0,0) + Unity sends initial GDK_CONFIGURE event with position as (0,0) |
description: | updated |
description: | updated |
description: | updated |
no longer affects: | unity (Ubuntu) |
no longer affects: | unity (Ubuntu Oneiric) |
no longer affects: | unity |
affects: | compiz → compiz-core |
Changed in compiz (Ubuntu): | |
status: | In Progress → Triaged |
status: | Triaged → Fix Committed |
Changed in compiz-core: | |
status: | New → Fix Committed |
Changed in compiz-core: | |
milestone: | none → 0.9.7 |
tags: |
added: verification-done removed: verification-needed |
Changed in compiz-core: | |
status: | Fix Committed → Fix Released |
Thanks Sam! generic) and tested and it fixed this bug for me.
I compiled that into a package in my ppa (ppa:tellis/
Attaching a debdiff.