MAK RTIspy API Documentation for HLA Evolved
List of all members | Public Slots | Signals | Public Member Functions | Protected Member Functions | Protected Attributes | Private Member Functions
DtAssistantConfigDialog Class Reference

Qt dialog which allows a user to change the Assistant configuration. More...

+ Inheritance diagram for DtAssistantConfigDialog:
+ Collaboration diagram for DtAssistantConfigDialog:

Public Slots

virtual void changePage (QListWidgetItem *current, QListWidgetItem *previous)
 Changes which page is currently displayed.
virtual void enableAccept (int)
 Enable the accept button due to the validity of the current settings.
virtual void disableAccept (int)
 Disable the accept button due to the validity of the current settings.

Signals

void applied ()
 Emitted when the apply button is clicked.

Public Member Functions

 DtAssistantConfigDialog (QWidget *parent=0, Qt::WindowFlags f=0)
 Constructor.
virtual ~DtAssistantConfigDialog ()
 Destructor.
virtual void addConfigWidget (DtAssistantConfigWidget *widget, const QIcon &icon, const QString &name, DtPreferencesPage pageId)
 Adds a widget to a new page in the dialog, using the given icon and name for the contents bar on the side.
virtual void completeDialogSetup ()
 Completes the setup of the dialog.
virtual QWidgetconfigWidget (DtPreferencesPage pageId)
 Returns the widget on the given page.
virtual void setPage (DtPreferencesPage pageId)
 Sets the currently displayed page.

Protected Member Functions

virtual void enableOrDisableAccept ()
 Enables or disables the accept button, as appropriate.
virtual void showEvent (QShowEvent *event)
 Catch show events so that the first time the dialog is shown we can do some additional configuration.

Protected Attributes

bool myWasAccepted
 Stores the acceptance state of the last execution.
QListWidget * myContentsWidget
 The contents panel which allows the user to select the configuration page they would like to view.
QStackedWidget * myPagesWidget
 The stacked widget which holds all of the configuration pages and displays the currently selected one.
std::map< DtPreferencesPage,
unsigned int > 
myPageNumbers
 Mapping of page IDs to page numbers.
QDialogButtonBox * myButtonBox
 The dialogs button box.
std::vector
< DtAssistantConfigWidget * > 
myConfigWidgets
 Widgets for each configuration page in the dialog.
std::vector< bool > myEnableAccept
 The current settings for each widget on whether or not acceptance of the dialog should be allowed.
std::vector< QString > myDisableAcceptReasons
 The current reasons for each widget why acceptance of the dialog should not be allowed.
QSignalMapper * myEnableAcceptMapper
 Maps signals from configuration widgets to enable the accept button button.
QSignalMapper * myDisableAcceptMapper
 Maps signals from configuration widgets to disable the accept button.
int myCurrentPage
 The current page.
bool myFirstShowing
 The first time the dialog is shown, do some additional configuration.

Private Member Functions

 DtAssistantConfigDialog (DtAssistantConfigDialog const &)
 Copy constructor not implemented.
DtAssistantConfigDialogoperator= (DtAssistantConfigDialog const &)
 Assignment operator not implemented.

Detailed Description

Qt dialog which allows a user to change the Assistant configuration.

Constructor & Destructor Documentation

DtAssistantConfigDialog::DtAssistantConfigDialog ( QWidget parent = 0,
Qt::WindowFlags  f = 0 
)
DtAssistantConfigDialog::~DtAssistantConfigDialog ( )
virtual

Destructor.

DtAssistantConfigDialog::DtAssistantConfigDialog ( DtAssistantConfigDialog const &  )
private

Copy constructor not implemented.

Member Function Documentation

void DtAssistantConfigDialog::addConfigWidget ( DtAssistantConfigWidget widget,
const QIcon &  icon,
const QString &  name,
DtPreferencesPage  pageId 
)
virtual

Adds a widget to a new page in the dialog, using the given icon and name for the contents bar on the side.

Widgets will be added and paged in order as this method is called.

References connect(), myConfigWidgets, myContentsWidget, myDisableAcceptMapper, myDisableAcceptReasons, myEnableAccept, myEnableAcceptMapper, myPageNumbers, and myPagesWidget.

Referenced by DtAssistantPreferencesViewMgr::initialize().

void DtAssistantConfigDialog::applied ( )
signal

Emitted when the apply button is clicked.

Referenced by DtAssistantConfigDialog().

void DtAssistantConfigDialog::changePage ( QListWidgetItem *  current,
QListWidgetItem *  previous 
)
virtualslot

Changes which page is currently displayed.

References myButtonBox, myContentsWidget, myCurrentPage, and myPagesWidget.

Referenced by DtAssistantConfigDialog().

void DtAssistantConfigDialog::completeDialogSetup ( )
virtual

Completes the setup of the dialog.

All widgets should be added with addConfigWidget prior to calling this method.

References DtConnectionsPage, myButtonBox, myContentsWidget, myPagesWidget, and setPage().

Referenced by DtAssistantPreferencesViewMgr::initialize().

QWidget * DtAssistantConfigDialog::configWidget ( DtPreferencesPage  pageId)
virtual

Returns the widget on the given page.

References myConfigWidgets, and myPageNumbers.

void DtAssistantConfigDialog::disableAccept ( int  page)
virtualslot

Disable the accept button due to the validity of the current settings.

References enableOrDisableAccept(), myConfigWidgets, myDisableAcceptReasons, and myEnableAccept.

Referenced by DtAssistantConfigDialog().

void DtAssistantConfigDialog::enableAccept ( int  page)
virtualslot

Enable the accept button due to the validity of the current settings.

References enableOrDisableAccept(), myDisableAcceptReasons, and myEnableAccept.

Referenced by DtAssistantConfigDialog().

void DtAssistantConfigDialog::enableOrDisableAccept ( )
protectedvirtual

Enables or disables the accept button, as appropriate.

References myButtonBox, myDisableAcceptReasons, and myEnableAccept.

Referenced by disableAccept(), and enableAccept().

DtAssistantConfigDialog& DtAssistantConfigDialog::operator= ( DtAssistantConfigDialog const &  )
private

Assignment operator not implemented.

void DtAssistantConfigDialog::setPage ( DtPreferencesPage  pageId)
virtual

Sets the currently displayed page.

References myContentsWidget, and myPageNumbers.

Referenced by completeDialogSetup(), and DtAssistantPreferencesViewMgr::showConfigDialog().

void DtAssistantConfigDialog::showEvent ( QShowEvent *  event)
protectedvirtual

Catch show events so that the first time the dialog is shown we can do some additional configuration.

References myContentsWidget, and myFirstShowing.

Member Data Documentation

QDialogButtonBox* DtAssistantConfigDialog::myButtonBox
protected
std::vector<DtAssistantConfigWidget*> DtAssistantConfigDialog::myConfigWidgets
protected

Widgets for each configuration page in the dialog.

Referenced by addConfigWidget(), configWidget(), and disableAccept().

QListWidget* DtAssistantConfigDialog::myContentsWidget
protected

The contents panel which allows the user to select the configuration page they would like to view.

Referenced by addConfigWidget(), changePage(), completeDialogSetup(), DtAssistantConfigDialog(), setPage(), and showEvent().

int DtAssistantConfigDialog::myCurrentPage
protected

The current page.

Referenced by changePage().

QSignalMapper* DtAssistantConfigDialog::myDisableAcceptMapper
protected

Maps signals from configuration widgets to disable the accept button.

Referenced by addConfigWidget(), and DtAssistantConfigDialog().

std::vector<QString> DtAssistantConfigDialog::myDisableAcceptReasons
protected

The current reasons for each widget why acceptance of the dialog should not be allowed.

Referenced by addConfigWidget(), disableAccept(), enableAccept(), and enableOrDisableAccept().

std::vector<bool> DtAssistantConfigDialog::myEnableAccept
protected

The current settings for each widget on whether or not acceptance of the dialog should be allowed.

Referenced by addConfigWidget(), disableAccept(), enableAccept(), and enableOrDisableAccept().

QSignalMapper* DtAssistantConfigDialog::myEnableAcceptMapper
protected

Maps signals from configuration widgets to enable the accept button button.

Referenced by addConfigWidget(), and DtAssistantConfigDialog().

bool DtAssistantConfigDialog::myFirstShowing
protected

The first time the dialog is shown, do some additional configuration.

Referenced by showEvent().

std::map<DtPreferencesPage, unsigned int> DtAssistantConfigDialog::myPageNumbers
protected

Mapping of page IDs to page numbers.

Referenced by addConfigWidget(), configWidget(), and setPage().

QStackedWidget* DtAssistantConfigDialog::myPagesWidget
protected

The stacked widget which holds all of the configuration pages and displays the currently selected one.

Referenced by addConfigWidget(), changePage(), completeDialogSetup(), and DtAssistantConfigDialog().

bool DtAssistantConfigDialog::myWasAccepted
protected

Stores the acceptance state of the last execution.


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

Document ID: Generated on Tue May 7 16:26:47 EDT 2013 from SVN revision 126903
Copyright © 2005-2013 VT MÄK Inc. All Rights Reserved (www.mak.com)