blockly > Toolbox > shouldDeselectItem_

Toolbox.shouldDeselectItem_() method

Decides whether the old item should be deselected.

Signature:

protected shouldDeselectItem_(oldItem: ISelectableToolboxItem | null, newItem: ISelectableToolboxItem | null): boolean;

Parameters

Parameter Type Description
oldItem ISelectableToolboxItem | null The previously selected toolbox item.
newItem ISelectableToolboxItem | null The newly selected toolbox item.

Returns:

boolean

True if the old item should be deselected, false otherwise.