| 1013 | } |
| 1014 | |
| 1015 | void SamplingBar::reload() |
| 1016 | { |
| 1017 | QString iconPath = GetIconPath(); |
| 1018 | |
| 1019 | _action_loop->setVisible(false); |
| 1020 | |
| 1021 | int mode = _device_agent->get_work_mode(); |
| 1022 | if (mode == LOGIC) |
| 1023 | { |
| 1024 | if (_device_agent->is_file()){ |
| 1025 | _mode_action->setVisible(false); |
| 1026 | } |
| 1027 | else |
| 1028 | { |
| 1029 | update_mode_icon(); |
| 1030 | _mode_action->setVisible(true); |
| 1031 | _action_repeat->setVisible(true); |
| 1032 | |
| 1033 | if (_session->is_loop_mode() && _device_agent->is_stream_mode() == false |
| 1034 | && _device_agent->is_hardware()){ |
| 1035 | _session->set_collect_mode(COLLECT_SINGLE); |
| 1036 | } |
| 1037 | |
| 1038 | if (_device_agent->is_stream_mode() || _device_agent->is_demo()) |
| 1039 | _action_loop->setVisible(true); |
| 1040 | } |
| 1041 | _run_stop_action->setVisible(true); |
| 1042 | _instant_action->setVisible(true); |
| 1043 | } |
| 1044 | else if (mode == ANALOG) |
| 1045 | { |
| 1046 | _mode_action->setVisible(false); |
| 1047 | _run_stop_action->setVisible(true); |
| 1048 | _instant_action->setVisible(false); |
| 1049 | } |
| 1050 | else if (mode == DSO) |
| 1051 | { |
| 1052 | _mode_action->setVisible(false); |
| 1053 | _run_stop_action->setVisible(true); |
| 1054 | _instant_action->setVisible(true); |
| 1055 | } |
| 1056 | |
| 1057 | retranslateUi(); |
| 1058 | reStyle(); |
| 1059 | update(); |
| 1060 | } |
| 1061 | |
| 1062 | void SamplingBar::on_collect_mode() |
| 1063 | { |
no test coverage detected