replace activity/desktop event to context event

This commit is contained in:
Eon S. Jeon 2019-02-24 15:46:33 +09:00
parent b07a2c92f3
commit 5c619a633d
2 changed files with 5 additions and 10 deletions

View File

@ -189,10 +189,10 @@ class KWinDriver implements IDriver {
this.control.onScreenResized(screen)); this.control.onScreenResized(screen));
this.connect(workspace.currentActivityChanged, (activity: string) => this.connect(workspace.currentActivityChanged, (activity: string) =>
this.control.onCurrentActivityChanged(activity)); this.control.onCurrentContextChanged(this.getCurrentContext()));
this.connect(workspace.currentDesktopChanged, (desktop: number, client: KWin.Client) => this.connect(workspace.currentDesktopChanged, (desktop: number, client: KWin.Client) =>
this.control.onCurrentDesktopChanged(desktop)); this.control.onCurrentContextChanged(this.getCurrentContext()));
this.connect(workspace.clientAdded, (client: KWin.Client) => { this.connect(workspace.clientAdded, (client: KWin.Client) => {
const handler = () => { const handler = () => {

View File

@ -33,18 +33,13 @@ class TilingController {
this.engine.arrange(); this.engine.arrange();
} }
public onScreenResized(screen: number): void { public onScreenResized(screen: any): void {
debugObj(() => ["onScreenResized", {screen}]); debugObj(() => ["onScreenResized", {screen}]);
this.engine.arrange(); this.engine.arrange();
} }
public onCurrentActivityChanged(activity: string): void { public onCurrentContextChanged(context: IDriverContext): void {
debugObj(() => ["onCurrentActivityChanged", {activity}]); debugObj(() => ["onCurrentContextChanged", {context}]);
this.engine.arrange();
}
public onCurrentDesktopChanged(desktop: number): void {
debugObj(() => ["onCurrentDesktopChanged", {desktop}]);
this.engine.arrange(); this.engine.arrange();
} }