ADTF  3.18.2
cQtWindow

Basic IWindow implementation. More...

Inheritance diagram for cQtWindow:
[legend]

Public Member Functions

QString GetStateIdentifier () const override
 Returns The user defined window state identifier. More...
 
void OnLoadState ([[maybe_unused]] const QString &strStateFolder) override
 Callback function to load the internal window state from the given folder strStateFolder. More...
 
void OnSaveState ([[maybe_unused]] const QString &strStateFolder) const override
 Callback function to save the internal window state to the given folder strStateFolder. More...
 
QString GetHelpLink () const override
 Returns a filesystem help link to the windows documentation page. More...
 
- Public Member Functions inherited from IQtXSystem::IWindowState
virtual void OnLoadState (const QString &strStateFolder)=0
 Callback function to load the internal window state from the given folder strStateFolder. More...
 
virtual void OnSaveState (const QString &strStateFolder) const =0
 Callback function to save the internal window state to the given folder strStateFolder. More...
 

Protected Member Functions

void EnableWindowState ()
 Enables the Window state callbacks. More...
 
bool IsWindowStateEnabled () const
 
- Protected Member Functions inherited from cQtWindow
 cQtWindow ()=default
 default CTOR
 
virtual ~cQtWindow ()=default
 default DTOR
 
virtual QWidget * CreateView ()=0
 Callback you have to implement and return a newly QWidget which will be embed to the oParentWidget of the Create. More...
 
virtual void ReleaseView ()=0
 Callback you have to implement to cleanup while destroying of the parents window. More...
 
tResult Create (const char *strWindowID, QWidget &oParentWidget) override
 Callback which in called within the applications main th thread to create a window. More...
 
tResult Destroy (QWidget &) override
 Callback which in called within the applications main th thread to deliver a destroy message to the windows implementation. More...
 
tResult OnIdle () override
 Callback for actions within a idle thread. More...
 
tResult OnTimer () override
 Callback for actions within a steady timer. More...
 
- Protected Member Functions inherited from IQtXSystem::IWindowState
 ~IWindowState ()=default
 protected DTOR
 
- Protected Member Functions inherited from IQtXSystem::IHelp
 ~IHelp ()=default
 protected DTOR
 

Private Attributes

bool m_bWindowStateEnabled = false
 State for enabled window state.
 

Additional Inherited Members

- Protected Attributes inherited from cQtWindow
adtf::base::property_variable< adtf::util::cString > m_strTitle
 title property variable will be set while window creating
 

Detailed Description

Basic IWindow implementation.

This implementation is used to provide callbacks on creation and destroying widget while IWindow::Create call.

The Create method will call the CreateView first and embed your created widget to the oParentWidget. Additionally it will implement the riddler::IQtXSystem::IWindowState and the spider::IQtXSystem::IHelp interface.

See also
adtf::ui::spider::IQtXSystem, riddler::IQtXSystem::IWindowState, Qt5 Video Display Plugin

Definition at line 124 of file xsystem_qtwindow.h.

Member Function Documentation

◆ EnableWindowState()

void EnableWindowState ( )
inlineprotected

Enables the Window state callbacks.

We recommend to use this only within your filters CTOR.

See also
adtf::ui::riddler::IQtXSystem::IWindowState

Definition at line 168 of file xsystem_qtwindow.h.

References cQtWindow::m_bWindowStateEnabled.

◆ GetHelpLink()

QString GetHelpLink ( ) const
inlineoverridevirtual

Returns a filesystem help link to the windows documentation page.

Return values
emptyThe link will be ignored.
not-emptyThe filesystem help link to the windows documentation page.

Implements IQtXSystem::IHelp.

Definition at line 156 of file xsystem_qtwindow.h.

◆ GetStateIdentifier()

QString GetStateIdentifier ( ) const
inlineoverridevirtual

Returns The user defined window state identifier.

Returns
The state identifier.
See also
adtf::ui::riddler::qt_ui_filter::GetStateIdentifier, adtf::ui::riddler::qt_ui_service::GetStateIdentifier
Remarks
This callback will be only served if EnableWindowState call is made before!

Implements IQtXSystem::IWindowState.

Definition at line 133 of file xsystem_qtwindow.h.

◆ IsWindowStateEnabled()

bool IsWindowStateEnabled ( ) const
inlineprotected
Return values
trueEnableWindowState was called
falseEnableWindowState was not called

Definition at line 176 of file xsystem_qtwindow.h.

References cQtWindow::m_bWindowStateEnabled.

◆ OnLoadState()

void OnLoadState ( [[maybe_unused] ] const QString &  strStateFolder)
inlineoverride

Callback function to load the internal window state from the given folder strStateFolder.

We recommend to use QSettings to save and load a window state file.

void cMyFilter::OnLoadState(const QString& strStateFolder)
{
QSettings oSettings(strStateFolder + "/my_window_state.settings", QSettings::IniFormat);
oSettings.beginGroup("my_window");
// read your state from the settings file as created within OnSaveState
oSettings.endGroup();
}
Parameters
[in]strStateFolderThe folder to save the window state files to.
Remarks
This callback will be only served if EnableWindowState call is made before!

Definition at line 141 of file xsystem_qtwindow.h.

◆ OnSaveState()

void OnSaveState ( [[maybe_unused] ] const QString &  strStateFolder) const
inlineoverride

Callback function to save the internal window state to the given folder strStateFolder.

We recommend to use QSettings to save and load a window state file.

void cMyFilter::OnSaveState(const QString& strStateFolder) const
{
QSettings oSettings(strStateFolder + "/my_window_state.settings", QSettings::IniFormat);
oSettings.beginGroup("my_window");
// save your window state to the settings file.
oSettings.endGroup();
}
Parameters
[in]strStateFolderThe folder to save the window state files to.
Remarks
This callback will be only served if EnableWindowState call is made before!

Definition at line 149 of file xsystem_qtwindow.h.