MAK RTIspy API Documentation for HLA 4
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Slots | Signals | Public Member Functions | Protected Member Functions | Protected Attributes | Private Member Functions

Responsible for maintaining the assistant tray icon, its menu, and the notifications displayed by it. More...

+ Inheritance diagram for DtAssistantTrayIconMgr:
+ Collaboration diagram for DtAssistantTrayIconMgr:

Public Slots

void showNotifyConsole ()
 Displays the notification console with the full history of notifications which have been displayed. More...
 
void showVersionsWebpage ()
 Opens a browser to display the RTI versions web page. More...
 
void showAboutDialog ()
 Opens the RTI about dialog. More...
 
void showHelpDialog ()
 Opens the RTI help dialog. More...
 
void processHelpDialogClose ()
 Cleans up after the help dialog when it is closed. More...
 
void notification (const MAKRti::DtString &message, MAKRti::DtNotifyLevelType notifyLevel, int sourceCompId=-1, bool logOnly=false, bool forward=true)
 Displays a notification for the component with the given ID. More...
 
void notification (const MAKRti::DtString &message, MAKRti::DtNotifyLevelType notifyLevel, const MAKRti::DtString &source, bool logOnly=false, bool forward=true)
 Displays a notification with the given component name. More...
 
void showNotifyIcon ()
 Changes the tray icon to show that a notification message has been received but not acknowledged by the user, just in case they missed it. More...
 
void clearNotifyIcon ()
 Clears the notify icon if displayed. More...
 
void showWarningIcon ()
 Changes the tray icon to show that a popup dialog has been activated that needs attention by the user. More...
 
void clearWarningIcon ()
 Registers that a popup dialog has been dismissed and clears the warning icon if all popup warnings have been dismissed. More...
 
void processTrayIconActivation (QSystemTrayIcon::ActivationReason reason)
 Processes an activation event by the tray icon. More...
 
void setEnableNotifications (bool enable)
 Updates whether notifications should be enabled. More...
 
void setObservingNotifications (bool isObserving)
 Updates whether this Assistant is observing notifications from other Assistants on the network. More...
 
void sendNotifyObserveMsg ()
 Sends the notification observe message. More...
 
void pruneStaleNotifyObservers ()
 Removes old observers who have not sent a message in a while. More...
 
- Public Slots inherited from DtAssistantMgr
void displayWarningDialogs ()
 Displays all warning dialogs. More...
 

Signals

void shutdown ()
 Emitted when the user chooses to shutdown the assistant. More...
 
void displayActiveWarningDialogs ()
 Emitted if active warning dialogs should be brought to the front. More...
 
void showConfigDialog (DtPreferencesPage pageNum=DtInvalidPreferencesPage)
 Emitted when the configuration dialog should be shown. More...
 
void showFederationsDialog ()
 Emitted when the federations view dialog should be shown. More...
 
void showNetworkComponentsDialog ()
 Emitted when the network components view dialog should be shown. More...
 
void showRidConfigDialog ()
 Emitted when the RID Configuration Dialog should be shown. More...
 
- Signals inherited from DtAssistantMgr
void warningDialogDisplayed ()
 Emitted when a warning dialog is displayed. More...
 
void warningDialogDismissed ()
 Emitted when a warning dialog is dismissed. More...
 
void popupRequested (const MAKRti::DtString &text, int sourceCompId, const MAKRti::DtString &advancedText)
 Emitted when a popup dialog should be displayed. More...
 
void popupRequested (const MAKRti::DtString &text, const MAKRti::DtString &source, const MAKRti::DtString &advancedText)
 Emitted when a popup dialog should be displayed. More...
 
void notificationRequested (const MAKRti::DtString &message, MAKRti::DtNotifyLevelType notifyLevel, int sourceCompId, bool logOnly)
 Emitted when a notification should be displayed. More...
 
void notificationRequested (const MAKRti::DtString &message, MAKRti::DtNotifyLevelType notifyLevel, const MAKRti::DtString &source, bool logOnly)
 Emitted when a notification should be displayed. More...
 

Public Member Functions

 DtAssistantTrayIconMgr (std::shared_ptr< DtRtiAssistantServer > server, std::shared_ptr< DtRtiAssistantPeer > peer, DtAssistantSignalRouter &signalRouter, std::shared_ptr< DtAssistantComponentMgr > compMgr)
 Constructor. More...
 
virtual ~DtAssistantTrayIconMgr ()
 Destructor. More...
 
virtual void startShutdown ()
 Hides the tray icon at the start of shutdown. More...
 
- Public Member Functions inherited from DtAssistantMgr
 DtAssistantMgr (std::shared_ptr< DtRtiAssistantServer > server, std::shared_ptr< DtRtiAssistantPeer > peer, DtAssistantSignalRouter &signalRouter)
 Constructor. More...
 
virtual ~DtAssistantMgr ()
 Destructor. More...
 
virtual void initialize ()
 Initializes this manager just prior to beginning assistant processing. More...
 
virtual void tick ()
 Performs tasks that need to be completed periodically. More...
 
virtual bool dialogsVisible () const
 Determines if there are any visible dialogs for which this manager is responsible. More...
 
virtual void configWidget (DtAssistantConfigWidget **widget, QIcon &icon, QString &name, DtPreferencesPage &pageId)
 Retrieves a widget which will be placed in the configuration dialog for configuring user preferences. More...
 
virtual void updateConfigWidget ()
 Forces the configuration widget to be updated. More...
 
virtual void processConfigWidgetAccept ()
 Process the changes that were accepted in the configuration widget. More...
 

Protected Member Functions

virtual void loadBrowserPage (const QString &page)
 Load the given URL into the default browser. More...
 
- Protected Member Functions inherited from DtAssistantMgr
void startDialog (QDialog *dlg, bool inTaskbar, bool warningDialog)
 Sets up the given widget as a dialog. More...
 
void finishDialog (QDialog *dlg)
 Should be called prior to deleting any dialog started with startDialog. More...
 
void showDialog (QDialog *dlg)
 Shows the dialog. More...
 
void startMainWindow (QMainWindow *dlg)
 Sets up a main window dialog. More...
 
void finishMainWindow (QMainWindow *dlg)
 Should be called prior to deleting any dialog started with startMainWindow. More...
 
void showMainWindow (QMainWindow *dlg)
 Shows the dialog. More...
 
void showPopup (const MAKRti::DtString &text, int sourceCompId=-1, const MAKRti::DtString &advancedText=MAKRti::DtString::nullString())
 Displays a popup message with the given text, advanced text, and name of the given source component. More...
 
void showPopup (const MAKRti::DtString &text, const MAKRti::DtString &source, const MAKRti::DtString &advancedText=MAKRti::DtString::nullString())
 Displays a popup message with the given text, advanced text, and source name. More...
 
void displayNotification (const MAKRti::DtString &message, MAKRti::DtNotifyLevelType notifyLevel, int sourceCompId=-1)
 Displays and logs a notification from the given component. More...
 
void displayNotification (const MAKRti::DtString &message, MAKRti::DtNotifyLevelType notifyLevel, const MAKRti::DtString &source)
 Displays and logs notification with the given component name. More...
 
void logNotification (const MAKRti::DtString &message, MAKRti::DtNotifyLevelType notifyLevel, int sourceCompId=-1)
 Logs a notification from the given component, does not display. More...
 
void logNotification (const MAKRti::DtString &message, MAKRti::DtNotifyLevelType notifyLevel, const MAKRti::DtString &source)
 Logs a notification with the given component name, does not display. More...
 
virtual DtAssistantInfo assistantInfoFromAssistantMsg (const DtAssistantMsg &assistantMsg, DtInetAddrSet *interfaces=0)
 

Protected Attributes

std::shared_ptr
< DtAssistantComponentMgr
myCompMgr
 The manager that keeps track of all local RTI components. More...
 
QSystemTrayIcon * myTrayIcon
 The tray icon. More...
 
QMenu * myMenu
 The tray icon context menu. More...
 
QAction * myShowNotifyHistoryAction
 Context menu action to show the notification console. More...
 
QAction * myVersionsWebSiteAction
 Context menu action to show the RTI versions web site. More...
 
QAction * myShowPreferencesAction
 Context menu action to show the Assistant configuration preferences dialog. More...
 
QAction * myShowAboutAction
 Context menu action to show the RTI about dialog. More...
 
QAction * myShowFederationsViewAction
 Context Menu action to show the Assistant Federates View dialog. More...
 
QAction * myShowHelpAction
 Context menu action to show the help dialog. More...
 
QAction * myShutdownAllAction
 Action to exit all RTI applications on this machine. More...
 
DtAssistantNotifyDialogmyNotifyDialog
 The dialog which displays brief notification messages. More...
 
DtConsoleDialogmyNotifyConsole
 The dialog for the console widget which displays the full notification history. More...
 
DtAboutBoxmyAboutDialog
 The dialog that displays information about this version of the RTI. More...
 
QProcess * myHelpAssistant
 Help application. More...
 
bool myDisplayNotifyIcon
 Indicates that the notification icon should be displayed in the tray. More...
 
unsigned myDisplayWarningCount
 The count of the number of dialogs currently displayed which cause a warning icon to be displayed in the tray. More...
 
bool myEnableNotifications
 Whether or not notifications are disabled. More...
 
std::map< int, MAKRti::DtString > myLastNotifyNames
 Map of names previously displayed in a notification for a given component ID. More...
 
bool myObservingNotifications
 Whether notifications from other assistants are being observed. More...
 
std::map< DtAssistantInfo, bool > myNotifyObservers
 The list of remote Assistants that are observing notifications. More...
 
- Protected Attributes inherited from DtAssistantMgr
std::shared_ptr
< DtRtiAssistantServer
myServer
 The Assistant server from which new messages will arrive from local RTI components. More...
 
std::shared_ptr
< DtRtiAssistantPeer
myPeer
 The Assistant peer which communicates with other Assistants. More...
 
std::set< QDialog * > myUnparentedDialogs
 All unparented dialogs that are created by the GUI should be added to this set. More...
 
std::set< QMainWindow * > myMainWindows
 All main windows that are created by the GUI should be added to this set. More...
 
std::set< QDialog * > myWarningDialogs
 Set of the popup dialogs, either parented or unparented, which, when active, should cause a warning icon to be displayed. More...
 

Private Member Functions

 DtAssistantTrayIconMgr (DtAssistantTrayIconMgr const &)
 Copy Constructor not implemented – Copy Not Allowed! More...
 
DtAssistantTrayIconMgroperator= (DtAssistantTrayIconMgr const &)
 Assignment not implemented – Assignment Not Allowed! More...
 

Message Callbacks

static void processNotifyMsg (const DtAssistantNotifyMsg &msg, void *usr)
 Callback to process a notification message from a component. More...
 
static void processShowDialogMsg (const DtAssistantShowDialogMsg &msg, void *usr)
 Callback to process a show dialog message from a client assistant. More...
 
static void processNotifyObserveMsg (const DtAssistantNotifyObserveMsg &msg, void *usr)
 Callback to process a notification observation message. More...
 
virtual void processNotifyMsg (const DtAssistantNotifyMsg &msg)
 Called by the callback function to process notification messages. More...
 
virtual void processShowDialogMsg (const DtAssistantShowDialogMsg &msg)
 Called by the callback function to process show dialog messages. More...
 
virtual void processNotifyObserveMsg (const DtAssistantNotifyObserveMsg &msg)
 Called by the callback function to process notification observation messages. More...
 

Additional Inherited Members

- Static Protected Attributes inherited from DtAssistantMgr
static QIcon theRtiIcon
 The icons used by the RTI Assistant. More...
 
static QIcon theSmallRtiIcon
 
static QIcon theWebIcon
 
static QIcon theNotifyRtiIcon
 
static QIcon theWarningRtiIcon
 
static QIcon thePreferencesIcon
 
static QIcon theAboutIcon
 
static QIcon theHelpIcon
 
static bool theIconsAreLoaded
 Whether or not the icons have yet been loaded. More...
 

Detailed Description

Responsible for maintaining the assistant tray icon, its menu, and the notifications displayed by it.

Begins processing commands received from the user's interaction with the menu.

Constructor & Destructor Documentation

DtAssistantTrayIconMgr::DtAssistantTrayIconMgr ( std::shared_ptr< DtRtiAssistantServer server,
std::shared_ptr< DtRtiAssistantPeer peer,
DtAssistantSignalRouter signalRouter,
std::shared_ptr< DtAssistantComponentMgr compMgr 
)

Constructor.

virtual DtAssistantTrayIconMgr::~DtAssistantTrayIconMgr ( )
virtual

Destructor.

DtAssistantTrayIconMgr::DtAssistantTrayIconMgr ( DtAssistantTrayIconMgr const &  )
private

Copy Constructor not implemented – Copy Not Allowed!

Member Function Documentation

void DtAssistantTrayIconMgr::clearNotifyIcon ( )
slot

Clears the notify icon if displayed.

void DtAssistantTrayIconMgr::clearWarningIcon ( )
slot

Registers that a popup dialog has been dismissed and clears the warning icon if all popup warnings have been dismissed.

void DtAssistantTrayIconMgr::displayActiveWarningDialogs ( )
signal

Emitted if active warning dialogs should be brought to the front.

virtual void DtAssistantTrayIconMgr::loadBrowserPage ( const QString &  page)
protectedvirtual

Load the given URL into the default browser.

void DtAssistantTrayIconMgr::notification ( const MAKRti::DtString &  message,
MAKRti::DtNotifyLevelType  notifyLevel,
int  sourceCompId = -1,
bool  logOnly = false,
bool  forward = true 
)
slot

Displays a notification for the component with the given ID.

void DtAssistantTrayIconMgr::notification ( const MAKRti::DtString &  message,
MAKRti::DtNotifyLevelType  notifyLevel,
const MAKRti::DtString &  source,
bool  logOnly = false,
bool  forward = true 
)
slot

Displays a notification with the given component name.

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

Assignment not implemented – Assignment Not Allowed!

void DtAssistantTrayIconMgr::processHelpDialogClose ( )
slot

Cleans up after the help dialog when it is closed.

static void DtAssistantTrayIconMgr::processNotifyMsg ( const DtAssistantNotifyMsg msg,
void *  usr 
)
staticprotected

Callback to process a notification message from a component.

virtual void DtAssistantTrayIconMgr::processNotifyMsg ( const DtAssistantNotifyMsg msg)
protectedvirtual

Called by the callback function to process notification messages.

static void DtAssistantTrayIconMgr::processNotifyObserveMsg ( const DtAssistantNotifyObserveMsg msg,
void *  usr 
)
staticprotected

Callback to process a notification observation message.

virtual void DtAssistantTrayIconMgr::processNotifyObserveMsg ( const DtAssistantNotifyObserveMsg msg)
protectedvirtual

Called by the callback function to process notification observation messages.

static void DtAssistantTrayIconMgr::processShowDialogMsg ( const DtAssistantShowDialogMsg msg,
void *  usr 
)
staticprotected

Callback to process a show dialog message from a client assistant.

virtual void DtAssistantTrayIconMgr::processShowDialogMsg ( const DtAssistantShowDialogMsg msg)
protectedvirtual

Called by the callback function to process show dialog messages.

void DtAssistantTrayIconMgr::processTrayIconActivation ( QSystemTrayIcon::ActivationReason  reason)
slot

Processes an activation event by the tray icon.

void DtAssistantTrayIconMgr::pruneStaleNotifyObservers ( )
slot

Removes old observers who have not sent a message in a while.

void DtAssistantTrayIconMgr::sendNotifyObserveMsg ( )
slot

Sends the notification observe message.

void DtAssistantTrayIconMgr::setEnableNotifications ( bool  enable)
slot

Updates whether notifications should be enabled.

void DtAssistantTrayIconMgr::setObservingNotifications ( bool  isObserving)
slot

Updates whether this Assistant is observing notifications from other Assistants on the network.

void DtAssistantTrayIconMgr::showAboutDialog ( )
slot

Opens the RTI about dialog.

void DtAssistantTrayIconMgr::showConfigDialog ( DtPreferencesPage  pageNum = DtInvalidPreferencesPage)
signal

Emitted when the configuration dialog should be shown.

void DtAssistantTrayIconMgr::showFederationsDialog ( )
signal

Emitted when the federations view dialog should be shown.

void DtAssistantTrayIconMgr::showHelpDialog ( )
slot

Opens the RTI help dialog.

void DtAssistantTrayIconMgr::showNetworkComponentsDialog ( )
signal

Emitted when the network components view dialog should be shown.

void DtAssistantTrayIconMgr::showNotifyConsole ( )
slot

Displays the notification console with the full history of notifications which have been displayed.

void DtAssistantTrayIconMgr::showNotifyIcon ( )
slot

Changes the tray icon to show that a notification message has been received but not acknowledged by the user, just in case they missed it.

void DtAssistantTrayIconMgr::showRidConfigDialog ( )
signal

Emitted when the RID Configuration Dialog should be shown.

void DtAssistantTrayIconMgr::showVersionsWebpage ( )
slot

Opens a browser to display the RTI versions web page.

void DtAssistantTrayIconMgr::showWarningIcon ( )
slot

Changes the tray icon to show that a popup dialog has been activated that needs attention by the user.

void DtAssistantTrayIconMgr::shutdown ( )
signal

Emitted when the user chooses to shutdown the assistant.

virtual void DtAssistantTrayIconMgr::startShutdown ( )
virtual

Hides the tray icon at the start of shutdown.

Reimplemented from DtAssistantMgr.

Member Data Documentation

DtAboutBox* DtAssistantTrayIconMgr::myAboutDialog
protected

The dialog that displays information about this version of the RTI.

std::shared_ptr<DtAssistantComponentMgr> DtAssistantTrayIconMgr::myCompMgr
protected

The manager that keeps track of all local RTI components.

bool DtAssistantTrayIconMgr::myDisplayNotifyIcon
protected

Indicates that the notification icon should be displayed in the tray.

unsigned DtAssistantTrayIconMgr::myDisplayWarningCount
protected

The count of the number of dialogs currently displayed which cause a warning icon to be displayed in the tray.

bool DtAssistantTrayIconMgr::myEnableNotifications
protected

Whether or not notifications are disabled.

QProcess* DtAssistantTrayIconMgr::myHelpAssistant
protected

Help application.

std::map<int, MAKRti::DtString> DtAssistantTrayIconMgr::myLastNotifyNames
protected

Map of names previously displayed in a notification for a given component ID.

QMenu* DtAssistantTrayIconMgr::myMenu
protected

The tray icon context menu.

DtConsoleDialog* DtAssistantTrayIconMgr::myNotifyConsole
protected

The dialog for the console widget which displays the full notification history.

DtAssistantNotifyDialog* DtAssistantTrayIconMgr::myNotifyDialog
protected

The dialog which displays brief notification messages.

std::map< DtAssistantInfo, bool > DtAssistantTrayIconMgr::myNotifyObservers
protected

The list of remote Assistants that are observing notifications.

bool DtAssistantTrayIconMgr::myObservingNotifications
protected

Whether notifications from other assistants are being observed.

QAction* DtAssistantTrayIconMgr::myShowAboutAction
protected

Context menu action to show the RTI about dialog.

QAction* DtAssistantTrayIconMgr::myShowFederationsViewAction
protected

Context Menu action to show the Assistant Federates View dialog.

QAction* DtAssistantTrayIconMgr::myShowHelpAction
protected

Context menu action to show the help dialog.

QAction* DtAssistantTrayIconMgr::myShowNotifyHistoryAction
protected

Context menu action to show the notification console.

QAction* DtAssistantTrayIconMgr::myShowPreferencesAction
protected

Context menu action to show the Assistant configuration preferences dialog.

QAction* DtAssistantTrayIconMgr::myShutdownAllAction
protected

Action to exit all RTI applications on this machine.

QSystemTrayIcon* DtAssistantTrayIconMgr::myTrayIcon
protected

The tray icon.

QAction* DtAssistantTrayIconMgr::myVersionsWebSiteAction
protected

Context menu action to show the RTI versions web site.


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

Document ID: Generated on Sun Jul 20 16:15:30 EDT 2025 from SVN revision 277985
Copyright © 2005-2025 MAK Technologies Inc. All Rights Reserved (www.mak.com)