MCPcopy Index your code
hub / github.com/DreamSourceLab/DSView / OnMessage

Method OnMessage

DSView/pv/mainwindow.cpp:1786–2131  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1784 }
1785
1786 void MainWindow::OnMessage(int msg)
1787 {
1788 switch (msg)
1789 {
1790 case DSV_MSG_DEVICE_LIST_UPDATED:
1791 {
1792 _sampling_bar->update_device_list();
1793 break;
1794 }
1795 case DSV_MSG_START_COLLECT_WORK_PREV:
1796 {
1797 if (_device_agent->get_work_mode() == LOGIC)
1798 _trigger_widget->try_commit_trigger();
1799 else if (_device_agent->get_work_mode() == DSO)
1800 _dso_trigger_widget->check_setting();
1801
1802 _view->capture_init();
1803 _view->on_state_changed(false);
1804 break;
1805 }
1806 case DSV_MSG_START_COLLECT_WORK:
1807 {
1808 update_toolbar_view_status();
1809 _view->on_state_changed(false);
1810 _protocol_widget->update_view_status();
1811 break;
1812 }
1813 case DSV_MSG_COLLECT_END:
1814 {
1815 prgRate(0);
1816 _view->repeat_unshow();
1817 _view->on_state_changed(true);
1818 break;
1819 }
1820 case DSV_MSG_END_COLLECT_WORK:
1821 {
1822 update_toolbar_view_status();
1823 _protocol_widget->update_view_status();
1824 break;
1825 }
1826 case DSV_MSG_CURRENT_DEVICE_CHANGE_PREV:
1827 {
1828 if (_msg != NULL){
1829 _msg->close();
1830 _msg = NULL;
1831 }
1832 _view->hide_calibration();
1833
1834 _protocol_widget->del_all_protocol();
1835 _view->reload();
1836 break;
1837 }
1838 case DSV_MSG_CURRENT_DEVICE_CHANGED:
1839 {
1840 reset_all_view();
1841 load_device_config();
1842 update_title_bar_text();
1843 _sampling_bar->update_device_list();

Callers

nothing calls this directly

Calls 15

update_device_listMethod · 0.80
get_work_modeMethod · 0.80
try_commit_triggerMethod · 0.80
check_settingMethod · 0.80
closeMethod · 0.80
hide_calibrationMethod · 0.80
del_all_protocolMethod · 0.80
dsl_connectedMethod · 0.80
is_hardwareMethod · 0.80
get_deviceMethod · 0.80
device_updatedMethod · 0.80
device_event_objectMethod · 0.80

Tested by

no test coverage detected