Skip to content

Commit

Permalink
refactor!: Add setSelectedItem() to IToolbox.
Browse files Browse the repository at this point in the history
  • Loading branch information
gonfunko committed Nov 8, 2024
1 parent 631190c commit 716276a
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion core/interfaces/i_toolbox.ts
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ export interface IToolbox extends IRegistrable {
setVisible(isVisible: boolean): void;

/**
* Selects the toolbox item by it's position in the list of toolbox items.
* Selects the toolbox item by its position in the list of toolbox items.
*
* @param position The position of the item to select.
*/
Expand All @@ -107,6 +107,14 @@ export interface IToolbox extends IRegistrable {
*/
getSelectedItem(): IToolboxItem | null;

/**
* Sets the selected item.
*
* @param item The toolbox item to select, or null to remove the current
* selection.
*/
setSelectedItem(item: IToolboxItem | null): void;

/** Disposes of this toolbox. */
dispose(): void;
}

0 comments on commit 716276a

Please sign in to comment.