#include <DebugKeysToolBar.h>
Inheritance diagram for CDebugKeysToolBar:
Public Member Functions | |
virtual void | Init () |
virtual bool | handleCommand (UINT command) |
virtual bool | handleSelChange (UINT nID) |
virtual bool | handleEditChange (UINT nID) |
virtual bool | HasButtonText (UINT nID) |
virtual void | updateUI (CCmdUI *pCmdUI) |
Public Attributes | |
QueueFillRequest | queueFillRequest |
Protected Member Functions | |
void | OnDebugKeyComboSelChange () |
Protected Attributes | |
bool | editForRobot |
CComboBox | m_wndDebugKeysCombo |
CEdit | m_wndDebugKeysNEdit |
CComboBox | m_wndDebugKeysNEditDummyCombo |
CEdit | m_wndDebugKeysSecondsEdit |
CComboBox | m_wndDebugKeysSecondsEditDummyCombo |
Private Member Functions | |
DECLARE_DYNAMIC (CDebugKeysToolBar) |
Definition at line 20 of file DebugKeysToolBar.h.
CDebugKeysToolBar::DECLARE_DYNAMIC | ( | CDebugKeysToolBar | ) | [private] |
bool CDebugKeysToolBar::handleCommand | ( | UINT | command | ) | [virtual] |
Handles control notifications which arrived in the main frame
command | The id of the control, menu, accelerator etc. |
Reimplemented from CRobotControlToolBar.
Definition at line 67 of file DebugKeysToolBar.cpp.
References CRobotControlQueuesToRobots::allRobots, DebugKey::always, OutMessage::bin, MessageQueue::clear(), QueueFillRequest::collectNSeconds, DebugKey::disabled, editForRobot, DebugKey::every_n_ms, DebugKey::every_n_times, OutFile::exists(), OutMessage::finishMessage(), CRobotControlDebugKeyTables::forPhysicalRobots, CRobotControlDebugKeyTables::forSimulatedRobots, getDebugKeyTables(), getQueues(), IDC_CLEAR_QUEUE_TO_ROBOT, IDC_DEBUGKEY_ALWAYS_RADIO, IDC_DEBUGKEY_DISABLED_RADIO, IDC_DEBUGKEY_EDIT_FOR_LOCAL, IDC_DEBUGKEY_EDIT_FOR_ROBOT, IDC_DEBUGKEY_EVERYNMS_RADIO, IDC_DEBUGKEY_EVERYNTIMES_RADIO, IDC_DEBUGKEY_IMMEDIATE_RADIO, IDC_DEBUGKEY_NTIMES_RADIO, IDC_DEBUGKEY_REALTIME_RADIO, IDC_DEBUGKEY_REJECT_RADIO, IDC_DEBUGKEY_RESET, IDC_DEBUGKEY_SEND, IDC_DEBUGKEY_STICK_IMMEDIATE_RADIO, IDC_DEBUGKEY_STICK_N_RADIO, IDC_DEBUGKEY_WLAN_N_RADIO, IDC_SAVE_QUEUE_TO_ROBOT, idDebugKeyTable, idQueueFillRequest, QueueFillRequest::immediateReadWrite, m_wndDebugKeysCombo, m_wndDebugKeysNEdit, m_wndDebugKeysSecondsEdit, QueueFillRequest::mode, MessageQueue::moveAllMessages(), DebugKey::n_times, OnDebugKeyComboSelChange(), MessageQueue::out, QueueFillRequest::overwriteOlder, queueFillRequest, QueueFillRequest::rejectAll, DebugKeyTable::reset(), QueueFillRequest::seconds, CRobotControlQueuesToRobots::selectedRobot, CRobotControlDebugKeyTables::sendForPhysicalRobots(), CRobotControlDebugKeyTables::sendForSimulatedRobots(), DebugKeyTable::set(), CRobotControlQueues::toPhysical, CRobotControlQueues::toSimulated, QueueFillRequest::toStickImmediately, and QueueFillRequest::toStickNSeconds.
bool CDebugKeysToolBar::handleEditChange | ( | UINT | nID | ) | [virtual] |
Handles change events for edit controls. That function must be called from the main frame window for all edit controls of the toolbar.
nID | the command id of the edit control |
Reimplemented from CRobotControlToolBar.
Definition at line 253 of file DebugKeysToolBar.cpp.
References editForRobot, CRobotControlDebugKeyTables::forPhysicalRobots, CRobotControlDebugKeyTables::forSimulatedRobots, getDebugKeyTables(), IDC_DEBUGKEY_N_EDIT, m_wndDebugKeysCombo, m_wndDebugKeysNEdit, and DebugKeyTable::setN().
bool CDebugKeysToolBar::handleSelChange | ( | UINT | nID | ) | [virtual] |
Handles selection change events for combo boxes. That function must be called from the main frame window for all combo boxes of the toolbar.
nID | the command id of the combo box |
Reimplemented from CRobotControlToolBar.
Definition at line 243 of file DebugKeysToolBar.cpp.
References IDC_DEBUGKEY_COMBO, and OnDebugKeyComboSelChange().
bool CDebugKeysToolBar::HasButtonText | ( | UINT | nID | ) | [virtual] |
Determines if the buttons have a text
Reimplemented from CRobotControlToolBar.
Definition at line 367 of file DebugKeysToolBar.cpp.
References IDC_DEBUGKEY_COMBO, IDC_DEBUGKEY_N_EDIT, IDC_DEBUGKEY_RESET, IDC_DEBUGKEY_SECONDS_EDIT, and IDC_DEBUGKEY_SEND.
void CDebugKeysToolBar::Init | ( | ) | [virtual] |
Initializes the tool bar
Implements CRobotControlToolBar.
Definition at line 17 of file DebugKeysToolBar.cpp.
References DebugKeyTable::getDebugKeyName(), IDB_DEBUGKEYS, IDB_DEBUGKEYS_COLD, IDC_DEBUGKEY_ALWAYS_RADIO, IDC_DEBUGKEY_COMBO, IDC_DEBUGKEY_DISABLED_RADIO, IDC_DEBUGKEY_EDIT_FOR_LOCAL, IDC_DEBUGKEY_EDIT_FOR_ROBOT, IDC_DEBUGKEY_EVERYNMS_RADIO, IDC_DEBUGKEY_EVERYNTIMES_RADIO, IDC_DEBUGKEY_IMMEDIATE_RADIO, IDC_DEBUGKEY_N_EDIT, IDC_DEBUGKEY_NTIMES_RADIO, IDC_DEBUGKEY_REALTIME_RADIO, IDC_DEBUGKEY_REJECT_RADIO, IDC_DEBUGKEY_RESET, IDC_DEBUGKEY_SECONDS_EDIT, IDC_DEBUGKEY_SEND, IDC_DEBUGKEY_STICK_IMMEDIATE_RADIO, IDC_DEBUGKEY_STICK_N_RADIO, IDC_DEBUGKEY_WLAN_N_RADIO, DebugKeyTable::numOfDebugKeysForDebugKeyToolbar, and QueueFillRequest::overwriteOlder.
void CDebugKeysToolBar::OnDebugKeyComboSelChange | ( | ) | [protected] |
Handles a selchange of the debug keys combo
Definition at line 384 of file DebugKeysToolBar.cpp.
References editForRobot, getDebugKeyTables(), m_wndDebugKeysCombo, and m_wndDebugKeysNEdit.
Referenced by handleCommand(), and handleSelChange().
void CDebugKeysToolBar::updateUI | ( | CCmdUI * | pCmdUI | ) | [virtual] |
Enables the controls in the toolbar. This function is called from the main window for all controls.
pCmdUI | An interface to the control that allows enabling/disabling, checking etc. |
Reimplemented from CRobotControlToolBar.
Definition at line 278 of file DebugKeysToolBar.cpp.
References DebugKey::always, QueueFillRequest::collectNSeconds, DebugKey::disabled, editForRobot, DebugKey::every_n_ms, DebugKey::every_n_times, CRobotControlDebugKeyTables::forPhysicalRobots, CRobotControlDebugKeyTables::forSimulatedRobots, getDebugKeyTables(), DebugKeyTable::getMode(), IDC_DEBUGKEY_ALWAYS_RADIO, IDC_DEBUGKEY_DISABLED_RADIO, IDC_DEBUGKEY_EDIT_FOR_LOCAL, IDC_DEBUGKEY_EDIT_FOR_ROBOT, IDC_DEBUGKEY_EVERYNMS_RADIO, IDC_DEBUGKEY_EVERYNTIMES_RADIO, IDC_DEBUGKEY_IMMEDIATE_RADIO, IDC_DEBUGKEY_N_EDIT, IDC_DEBUGKEY_NTIMES_RADIO, IDC_DEBUGKEY_REALTIME_RADIO, IDC_DEBUGKEY_REJECT_RADIO, IDC_DEBUGKEY_SECONDS_EDIT, IDC_DEBUGKEY_STICK_IMMEDIATE_RADIO, IDC_DEBUGKEY_STICK_N_RADIO, IDC_DEBUGKEY_WLAN_N_RADIO, QueueFillRequest::immediateReadWrite, m_wndDebugKeysCombo, QueueFillRequest::mode, DebugKey::n_times, QueueFillRequest::overwriteOlder, queueFillRequest, QueueFillRequest::rejectAll, QueueFillRequest::toStickImmediately, and QueueFillRequest::toStickNSeconds.
bool CDebugKeysToolBar::editForRobot [protected] |
determines if the debug table for the robot or for the local processes is edited
Definition at line 62 of file DebugKeysToolBar.h.
Referenced by handleCommand(), handleEditChange(), OnDebugKeyComboSelChange(), and updateUI().
CComboBox CDebugKeysToolBar::m_wndDebugKeysCombo [protected] |
A combo box for the debug keys
Definition at line 65 of file DebugKeysToolBar.h.
Referenced by handleCommand(), handleEditChange(), OnDebugKeyComboSelChange(), and updateUI().
CEdit CDebugKeysToolBar::m_wndDebugKeysNEdit [protected] |
A edit control for the parameter n of a debug key
Definition at line 67 of file DebugKeysToolBar.h.
Referenced by handleCommand(), handleEditChange(), and OnDebugKeyComboSelChange().
CComboBox CDebugKeysToolBar::m_wndDebugKeysNEditDummyCombo [protected] |
A dummy combo box for the edit control
Definition at line 69 of file DebugKeysToolBar.h.
CEdit CDebugKeysToolBar::m_wndDebugKeysSecondsEdit [protected] |
A control for editing the duration of the debug sender blocking
Definition at line 72 of file DebugKeysToolBar.h.
Referenced by handleCommand().
CComboBox CDebugKeysToolBar::m_wndDebugKeysSecondsEditDummyCombo [protected] |
A dummy combo box for the edit control
Definition at line 74 of file DebugKeysToolBar.h.
QueueFillRequest to be used
Definition at line 80 of file DebugKeysToolBar.h.
Referenced by handleCommand(), and updateUI().