forked from Ivasoft/DSView
fix: fix: Switching to a new device without stopping the current device
This commit is contained in:
@@ -1518,6 +1518,10 @@ namespace pv
|
||||
{
|
||||
dsv_info("The data save confirm end, auto switch to the new device.");
|
||||
_is_auto_switch_device = false;
|
||||
|
||||
if (_session->is_working())
|
||||
_session->stop_capture();
|
||||
|
||||
_session->set_default_device();
|
||||
}
|
||||
}
|
||||
@@ -1855,10 +1859,17 @@ namespace pv
|
||||
if (confirm_to_store_data())
|
||||
{
|
||||
_is_auto_switch_device = true;
|
||||
|
||||
if (_session->is_working())
|
||||
_session->stop_capture();
|
||||
|
||||
on_save();
|
||||
}
|
||||
else
|
||||
{
|
||||
{
|
||||
if (_session->is_working())
|
||||
_session->stop_capture();
|
||||
|
||||
_session->set_default_device();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -177,7 +177,7 @@ namespace pv
|
||||
assert(!_is_saving);
|
||||
|
||||
if (_is_working){
|
||||
dsv_info("The current device is working, now to stop it.");
|
||||
dsv_info("SigSession::set_default_device(),The current device is working, now to stop it.");
|
||||
dsv_info("SigSession::set_default_device(), stop capture");
|
||||
stop_capture();
|
||||
}
|
||||
|
||||
@@ -201,7 +201,7 @@ void Header::mousePressEvent(QMouseEvent *event)
|
||||
|
||||
for(auto t : traces){
|
||||
if (t->signal_type() == LOGIC_SIGNAL && _view.session().is_working()){
|
||||
// Disable to set trigger when capturing.
|
||||
// Disable set trigger from left pannel when capturing.
|
||||
break;
|
||||
}
|
||||
if (t->mouse_press(width(), event->pos()))
|
||||
|
||||
Reference in New Issue
Block a user