why does wm.IsWindowOnTop(xid) return false when the window is set as "Always on Top"
this is because GetTopMostValidWindowInViewport() does not return the xid which is equal to the "Always on Top" window.
please see unity-shared/PluginAdapter.cpp:604
unity::PluginAdapter::IsWindowOnTop (this=0xcc5b30, window_id=65011720) at /build/buildd/unity-7.1.2+13.10.20131014.1/unity-shared/PluginAdapter.cpp:604 604 { (gdb) list 599 600 return false; 601 } 602 603 bool PluginAdapter::IsWindowOnTop(Window window_id) const 604 { 605 if (window_id == GetTopMostValidWindowInViewport()) 606 return true; 607 608 return false; (gdb) display window_id 13: window_id = 65011720 (gdb) print GetTopMostValidWindowInViewport() $17 = 46137350 (gdb)
why does wm.IsWindowOnTo p(xid) return false when the window is set as "Always on Top"
this is because GetTopMostValid WindowInViewpor t() does not return the xid which is equal to the "Always on Top" window.
please see unity-shared/ PluginAdapter. cpp:604
unity:: PluginAdapter: :IsWindowOnTop (this=0xcc5b30, window_id=65011720) at /build/ buildd/ unity-7. 1.2+13. 10.20131014. 1/unity- shared/ PluginAdapter. cpp:604 :IsWindowOnTop( Window window_id) const WindowInViewpor t()) WindowInViewpor t()
604 {
(gdb) list
599
600 return false;
601 }
602
603 bool PluginAdapter:
604 {
605 if (window_id == GetTopMostValid
606 return true;
607
608 return false;
(gdb) display window_id
13: window_id = 65011720
(gdb) print GetTopMostValid
$17 = 46137350
(gdb)