I have a function like bellow:
_move_windows_side_by_side = function (winid1, winid2) {
let win1 = this._get_window_by_wid(winid1);
let win2 = this._get_window_by_wid(winid2);
let work_area = win1.get_work_area_current_monitor();
//check if both are in current workspace
//check if both are in same monitor
let work_area_width = work_area.width;
let work_area_height = work_area.height;
let window_height = work_area_height;
let window_width = work_area_width / 2;
GLib.idle_add(GLib.PRIORITY_DEFAULT_IDLE, () => {
win1.move_resize_frame(1, 0, 0, window_width, window_height);
return GLib.SOURCE_REMOVE;
});
GLib.idle_add(GLib.PRIORITY_DEFAULT_IDLE, () => {
win2.move_resize_frame(1, window_width, 0, window_width, window_height);
return GLib.SOURCE_REMOVE;
});
}
I was assuming that these will be tiled as DevDocs says:
Returns the matching tiled window on the same monitor as this. This is
the topmost tiled window in a complementary tile mode that is:
on the same monitor; on the same workspace; spanning the remaining monitor width; there is no 3rd window stacked between both tiled windows that's partially visible in the common edge.
In my case get_tile_match()
does not return the other Meta.Window
.
What do I need to do that when i call _move_windows_side_by_side = function (winid1, winid2)
, winid1 will have matching tile winid2 and vice versa.