ICF 3.0.5.47
Technical documentation of ICF Libraries
istdgui::CModelEditorGuiComp Class Reference

Component realizing static connection between GUI and model components. More...

#include <CModelEditorGuiComp.h>

Inheritance diagram for istdgui::CModelEditorGuiComp:
Collaboration diagram for istdgui::CModelEditorGuiComp:

Public Types

typedef icomp::CComponentBase BaseClass
 
- Public Types inherited from imod::IModelEditor
enum  ChangeFlags { CF_INIT_EDITOR = 0x3720694 }
 Data model change notification flags. More...
 

Public Member Functions

 CModelEditorGuiComp ()
 
bool IsGuiCreated () const override
 Inform if GUI was initilized.
 
bool CreateGui (QWidget *parentPtr) override
 Initialize GUI and connect it to the parent.
 
bool DestroyGui () override
 Release GUI and disconnect it from parent.
 
QWidget * GetWidget () const override
 Get access to internal QWidget object.
 
void OnTryClose (bool *ignoredPtr=nullptr) override
 Called on trying to close application.
 
void UpdateEditor (const istd::IChangeable::ChangeSet &changeSet) override
 Updates editor with model data.
 
void UpdateModelFromEditor () const override
 Updates model from editor.
 
bool IsReadOnly () const override
 Returns true if the model data can be changed.
 
void SetReadOnly (bool state) override
 Set flag that the model data can be changed.
 
- Public Member Functions inherited from icomp::CComponentBase
 CComponentBase ()
 Create component and assign it to specific context.
 
 CComponentBase (const CComponentBase &)=delete
 
CComponentBaseoperator= (const CComponentBase &)=delete
 
virtual const ICompositeComponentGetParentComponent (bool ownerOnly=false) const
 Get parent of this component.
 
virtual void * GetInterface (const istd::CClassInfo &interfaceType, const QByteArray &subId="")
 Get access to specified component interface.
 
virtual const IComponentContextGetComponentContext () const
 Get access to component context describing all application-specified component information loaded from components registry.
 
virtual void SetComponentContext (const IComponentContext *contextPtr, const ICompositeComponent *parentPtr, bool isParentOwner)
 Set component context of this component.
 
- Public Member Functions inherited from icomp::IComponent
- Public Member Functions inherited from istdgui::IGuiObject
- Public Member Functions inherited from imod::IModelEditor

Protected Member Functions

void OnComponentCreated () override
 
void OnComponentDestroyed () override
 
- Protected Member Functions inherited from icomp::CComponentBase
bool IsComponentActive () const
 Check if component is active.
 
virtual const IRealComponentStaticInfoGetComponentStaticInfo () const =0
 Get access to static info of this component.
 

Additional Inherited Members

- Static Protected Member Functions inherited from icomp::CComponentBase
static const IRealComponentStaticInfoInitStaticInfo (IComponent *componentPtr)
 
static QByteArray GetComponentId (const IComponentContext *componentContextPtr, const QByteArray &contextId=QByteArray())
 

Detailed Description

Component realizing static connection between GUI and model components.

It allows to use boundle of model and GUI-observer components as simple GUI object.

Definition at line 28 of file CModelEditorGuiComp.h.

Member Typedef Documentation

◆ BaseClass

Constructor & Destructor Documentation

◆ CModelEditorGuiComp()

istdgui::CModelEditorGuiComp::CModelEditorGuiComp ( )

Member Function Documentation

◆ CreateGui()

bool istdgui::CModelEditorGuiComp::CreateGui ( QWidget * parentPtr)
overridevirtual

Initialize GUI and connect it to the parent.

Returns
true if initialization successed.

Implements istdgui::IGuiObject.

◆ DestroyGui()

bool istdgui::CModelEditorGuiComp::DestroyGui ( )
overridevirtual

Release GUI and disconnect it from parent.

Returns
true if this operation successed.

Implements istdgui::IGuiObject.

◆ GetWidget()

QWidget * istdgui::CModelEditorGuiComp::GetWidget ( ) const
overridevirtual

Get access to internal QWidget object.

Implements istdgui::IGuiObject.

◆ IsGuiCreated()

bool istdgui::CModelEditorGuiComp::IsGuiCreated ( ) const
overridevirtual

Inform if GUI was initilized.

Implements istdgui::IGuiObject.

◆ IsReadOnly()

bool istdgui::CModelEditorGuiComp::IsReadOnly ( ) const
overridevirtual

Returns true if the model data can be changed.

Implements imod::IModelEditor.

◆ OnComponentCreated()

void istdgui::CModelEditorGuiComp::OnComponentCreated ( )
overrideprotectedvirtual

Reimplemented from icomp::CComponentBase.

◆ OnComponentDestroyed()

void istdgui::CModelEditorGuiComp::OnComponentDestroyed ( )
overrideprotectedvirtual

Reimplemented from icomp::CComponentBase.

◆ OnTryClose()

void istdgui::CModelEditorGuiComp::OnTryClose ( bool * ignoredPtr = nullptr)
overridevirtual

Called on trying to close application.

Parameters
ignoredPtrif it is not nullptr, ignoring of close is allowed. In this case implementation should set pointed value to true.

Implements istdgui::IGuiObject.

◆ SetReadOnly()

void istdgui::CModelEditorGuiComp::SetReadOnly ( bool state)
overridevirtual

Set flag that the model data can be changed.

Returns
true, if this feature is supported.

Implements imod::IModelEditor.

◆ UpdateEditor()

void istdgui::CModelEditorGuiComp::UpdateEditor ( const istd::IChangeable::ChangeSet & changeSet)
overridevirtual

Updates editor with model data.

This method will be called only if GUI is connected.

Parameters
changeSetthe same as changeSet in istd::IChangeable.

Implements imod::IModelEditor.

◆ UpdateModelFromEditor()

void istdgui::CModelEditorGuiComp::UpdateModelFromEditor ( ) const
overridevirtual

Updates model from editor.

This method will be called only if GUI is connected and model is attached.

Implements imod::IModelEditor.


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

© Witold Gantzke and Kirill Lepskiy