]> sigrok.org Git - pulseview.git/commitdiff
Session: Add error messages
authorSoeren Apel <redacted>
Fri, 23 Feb 2018 23:13:13 +0000 (00:13 +0100)
committerSoeren Apel <redacted>
Fri, 23 Feb 2018 23:13:13 +0000 (00:13 +0100)
pv/session.cpp

index 4d72af3347472d530533ccf08ec78ed576713d94..a9bb554efd08a34e14b3375955b0ee6679ae31ea 100644 (file)
@@ -352,8 +352,7 @@ void Session::select_device(shared_ptr<devices::Device> device)
                else
                        set_default_device();
        } catch (const QString &e) {
-               main_bar_->session_error(tr("Failed to Select Device"),
-                       tr("Failed to Select Device"));
+               main_bar_->session_error(tr("Failed to select device"), e);
        }
 }
 
@@ -401,6 +400,7 @@ void Session::set_device(shared_ptr<devices::Device> device)
                device_->open();
        } catch (const QString &e) {
                device_.reset();
+               main_bar_->session_error(tr("Failed to open device"), e);
        }
 
        if (device_) {