NDEVR
API Documentation
DesignObjectDialogLookup

Manages the creation and lookup of DesignObjectDialog instances for design objects. More...

Public Member Functions

 DesignObjectDialogLookup (QTModelManager *model_manager)
 Constructs a DesignObjectDialogLookup with the given model manager.
virtual DesignObjectDialogcreateDesignObjectDialog (const DynamicPointer< QTDesignObject > &object, const ShowPropertiesSettings &settings)
 Creates a new DesignObjectDialog for the given object and settings.
void setDropArea (const std::function< DropArea(const QCustomDockWidget *dock_widget)> &drop_area)
 Sets the callback that determines the drop area for a dock widget.
void setReference (const std::function< SectionWidget *(const QCustomDockWidget *dock_widget)> &drop_area)
 Sets the callback that determines the reference section widget for docking.
virtual DockWidget< DesignObjectDialog > * setupDesignDock (const ShowPropertiesSettings &settings, ContainerWidgetBase *container)
 Creates or retrieves a docked DesignObjectDialog for the given settings.
virtual DockWidget< DesignObjectDialog > * showModelProperties (const ShowPropertiesSettings &settings, ContainerWidgetBase *container)
 Called when we want to show the dialog for editing a specific object using application default editing dialogs.
void updateLayout (ContainerWidgetBase *container)
 Updates the layout of all managed dialog dock widgets within the container.

Detailed Description

Manages the creation and lookup of DesignObjectDialog instances for design objects.

Tracks which dialogs are currently shown and reuses or creates dock widgets as needed when the user requests to view or edit object properties.

Definition at line 17 of file DesignObjectDialogLookup.h.

Constructor & Destructor Documentation

◆ DesignObjectDialogLookup()

DesignObjectDialogLookup::DesignObjectDialogLookup ( QTModelManager * model_manager)

Constructs a DesignObjectDialogLookup with the given model manager.

Parameters
[in]model_managerThe model manager providing scene data and object access.

Member Function Documentation

◆ createDesignObjectDialog()

virtual DesignObjectDialog * DesignObjectDialogLookup::createDesignObjectDialog ( const DynamicPointer< QTDesignObject > & object,
const ShowPropertiesSettings & settings )
virtual

Creates a new DesignObjectDialog for the given object and settings.

Parameters
[in]objectThe target design object.
[in]settingsThe property display settings.
Returns
Pointer to the newly created DesignObjectDialog.

◆ setDropArea()

void DesignObjectDialogLookup::setDropArea ( const std::function< DropArea(const QCustomDockWidget *dock_widget)> & drop_area)
inline

Sets the callback that determines the drop area for a dock widget.

Parameters
[in]drop_areaA function returning the DropArea for a given dock widget.

Definition at line 52 of file DesignObjectDialogLookup.h.

◆ setReference()

void DesignObjectDialogLookup::setReference ( const std::function< SectionWidget *(const QCustomDockWidget *dock_widget)> & drop_area)
inline

Sets the callback that determines the reference section widget for docking.

Parameters
[in]drop_areaA function returning the SectionWidget reference for a given dock widget.

Definition at line 57 of file DesignObjectDialogLookup.h.

◆ setupDesignDock()

virtual DockWidget< DesignObjectDialog > * DesignObjectDialogLookup::setupDesignDock ( const ShowPropertiesSettings & settings,
ContainerWidgetBase * container )
virtual

Creates or retrieves a docked DesignObjectDialog for the given settings.

Parameters
[in]settingsThe property display settings.
[in]containerThe container widget to dock the dialog into.
Returns
Pointer to the dock widget containing the dialog.

◆ showModelProperties()

virtual DockWidget< DesignObjectDialog > * DesignObjectDialogLookup::showModelProperties ( const ShowPropertiesSettings & settings,
ContainerWidgetBase * container )
virtual

Called when we want to show the dialog for editing a specific object using application default editing dialogs.

This can be called for creating new objects, editing existing objects, etc based on the provided settings

Parameters
[in]settings- The information used to generate the editing dialog
[in]containerThe container widget to dock the dialog into.
Returns
Pointer to the dock widget containing the dialog.

◆ updateLayout()

void DesignObjectDialogLookup::updateLayout ( ContainerWidgetBase * container)

Updates the layout of all managed dialog dock widgets within the container.

Parameters
[in]containerThe container widget to update layouts in.

The documentation for this class was generated from the following file: