Class MenuAddFolderHooker
java.lang.Object
net.datenwerke.rs.tsreportarea.client.tsreportarea.hookers.MenuAddFolderHooker
- All Implemented Interfaces:
Hook,TsFavoriteMenuHook
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanaddContextMenuEntries(Menu menu, List<AbstractTsDiskNodeDto> items, ItemSelector selector, TsDiskMainComponent mainComponent) booleanconfigureToolbarButton(DwTextButton button, List<AbstractTsDiskNodeDto> items, TsDiskMainComponent mainComponent) Configures the properties and behavior of a toolbar button for this action.createToolbarButton(ToolbarService toolbarService) Creates a new toolbar button instance for this action.voidCleans up any handler registrations or event listeners associated with this action.
-
Constructor Details
-
MenuAddFolderHooker
-
-
Method Details
-
addContextMenuEntries
public boolean addContextMenuEntries(Menu menu, List<AbstractTsDiskNodeDto> items, ItemSelector selector, TsDiskMainComponent mainComponent) - Specified by:
addContextMenuEntriesin interfaceTsFavoriteMenuHook
-
configureToolbarButton
public boolean configureToolbarButton(DwTextButton button, List<AbstractTsDiskNodeDto> items, TsDiskMainComponent mainComponent) Configures the properties and behavior of a toolbar button for this action. This method is called when the button needs to be customized based on the current selection or application state.- Specified by:
configureToolbarButtonin interfaceTsFavoriteMenuHook- Parameters:
button- the button to be configureditems- the currently selected disk node items (may be empty)mainComponent- the main disk component for context- Returns:
- true if the button should be enabled, false if it should be disabled
-
createToolbarButton
Creates a new toolbar button instance for this action. This method is typically called during toolbar initialization to create the visual representation of this action.- Specified by:
createToolbarButtonin interfaceTsFavoriteMenuHook- Parameters:
toolbarService- the toolbar service for button creation utilities- Returns:
- a configured DwTextButton instance, or null if no button should be displayed
-
removeHandlerRegistration
public void removeHandlerRegistration()Cleans up any handler registrations or event listeners associated with this action. This method is called when the action is being disposed or when the component containing the action is being destroyed to prevent memory leaks.- Specified by:
removeHandlerRegistrationin interfaceTsFavoriteMenuHook
-