Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove dynamic keyboard event mode #653

Merged
merged 2 commits into from Oct 31, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
17 changes: 0 additions & 17 deletions packages/application/src/index.ts
Expand Up @@ -188,20 +188,6 @@ export class Application<T extends Widget = Widget> {
return this._delegate.promise;
}

/**
* Getter and setter for the bubblingKeydown experimental flag.
*
* @experimental
*/
get bubblingKeydown(): boolean {
return this._bubblingKeydown;
}
set bubblingKeydown(value: boolean) {
document.removeEventListener('keydown', this, !this._bubblingKeydown);
this._bubblingKeydown = value;
document.addEventListener('keydown', this, !this._bubblingKeydown);
}

/**
* Get a plugin description.
*
Expand Down Expand Up @@ -622,9 +608,6 @@ export class Application<T extends Widget = Widget> {
* A subclass may reimplement this method as needed.
*/
protected addEventListeners(): void {
if (this._bubblingKeydown) {
console.log('The keydown events are handled during bubbling phase');
}
document.addEventListener('contextmenu', this);
document.addEventListener('keydown', this, !this._bubblingKeydown);
window.addEventListener('resize', this);
Expand Down
2 changes: 0 additions & 2 deletions review/api/application.api.md
Expand Up @@ -17,8 +17,6 @@ export class Application<T extends Widget = Widget> {
activatePlugin(id: string): Promise<void>;
protected addEventListeners(): void;
protected attachShell(id: string): void;
get bubblingKeydown(): boolean;
set bubblingKeydown(value: boolean);
readonly commands: CommandRegistry;
readonly contextMenu: ContextMenu;
deactivatePlugin(id: string): Promise<string[]>;
Expand Down