There was a bug that the transient_for children stack was incorrect.
1. Win_C1 set transient_for to Win_P already
2. Create Win_C2
3. Set Win_C2's transient_for to Win_P
4. Show Win_C2
5. Set Win_C1's transient_for to Win_P again
Above scenario, We exptected the window stack as below.
[Top] Win_C1 -> Win_C2 -> Win_P [Bottom]
But, window stack was Win_C2 -> Win_C1 -> Win_P.
This will fix this issue.
Change-Id: I1048bf5bbb492f52db5423ee610c2afe0e8e7097
top = e_client_below_get(top);
continue;
}
+ else
+ {
+ // check transient_for stack
+ int ec_id = eina_list_data_idx(ec->parent->transients, ec);
+ int top_id = eina_list_data_idx(ec->parent->transients, top);
+ if (ec_id < top_id)
+ {
+ top = e_client_below_get(top);
+ continue;
+ }
+ }
}
if (top->transient_for_always_on_top)
{