Skip to content

Commit

Permalink
1. Not move windows while in Overview 2. Fix after dropping the dialo…
Browse files Browse the repository at this point in the history
…g, the dialog disappears
  • Loading branch information
nlpsuge committed Feb 7, 2023
1 parent 51438b9 commit 8ef7f45
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
4 changes: 2 additions & 2 deletions moveSession.js
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -250,8 +250,8 @@ var MoveSession = class {
_changeWorkspace(metaWindow, desktop_number) {
const currentFocusedWindow = global.display.get_focus_window();
metaWindow.change_workspace_by_index(desktop_number, false);
if (currentFocusedWindow === metaWindow) {
this._log.debug(`Refocusing the previous focused window ${metaWindow.get_title()}`);
if (currentFocusedWindow === metaWindow && !Main.layoutManager._inOverview) {
this._log.debug(`Following the previous focused window ${metaWindow.get_title()}`);
Main.activateWindow(metaWindow, DateUtils.get_current_time());
}
}
Expand Down
6 changes: 6 additions & 0 deletions ui/autoclose.js
Original file line number Diff line number Diff line change
Expand Up @@ -720,6 +720,12 @@ var RunningApplicationListWindow = GObject.registerClass({
this.state = state
}

destroy() {
// This function is called when drag is canceled, but the dialog should be always shown.
// So we override it but do nothing. And there is a `destroyDialog()` which can be used to destroy the dialog anyway.
// TODO This function is also called after releasing the left button, which is wired, I probably misuse something in this class.
}

destroyDialog() {
this.hide();
super.destroy();
Expand Down

0 comments on commit 8ef7f45

Please sign in to comment.