]> sigrok.org Git - pulseview.git/commitdiff
Rename "always zoom-to-fit" to "zoom-to-fit during acquisition"
authorSoeren Apel <redacted>
Mon, 19 Jun 2017 19:31:23 +0000 (21:31 +0200)
committerUwe Hermann <redacted>
Wed, 5 Jul 2017 22:37:08 +0000 (00:37 +0200)
pv/dialogs/settings.cpp
pv/dialogs/settings.hpp
pv/globalsettings.cpp
pv/globalsettings.hpp
pv/views/trace/view.cpp

index d3ed1f4eb086e639096bacd896c25f889b92ea95..ef916f1a57c842c9d34475eb4d7760b077c4dc63 100644 (file)
@@ -149,9 +149,9 @@ QWidget *Settings::get_view_settings_form(QWidget *parent) const
                SLOT(on_view_colouredBG_changed(int)));
        trace_view_layout->addRow(tr("Use coloured trace &background"), cb);
 
-       cb = create_checkbox(GlobalSettings::Key_View_AlwaysZoomToFit,
-               SLOT(on_view_alwaysZoomToFit_changed(int)));
-       trace_view_layout->addRow(tr("Constantly perform &zoom-to-fit during capture"), cb);
+       cb = create_checkbox(GlobalSettings::Key_View_ZoomToFitDuringAcq,
+               SLOT(on_view_zoomToFitDuringAcq_changed(int)));
+       trace_view_layout->addRow(tr("Constantly perform &zoom-to-fit during acquisition"), cb);
 
        cb = create_checkbox(GlobalSettings::Key_View_ZoomToFitAfterAcq,
                SLOT(on_view_zoomToFitAfterAcq_changed(int)));
@@ -380,10 +380,10 @@ void Settings::on_page_changed(QListWidgetItem *current, QListWidgetItem *previo
        pages->setCurrentIndex(page_list->row(current));
 }
 
-void Settings::on_view_alwaysZoomToFit_changed(int state)
+void Settings::on_view_zoomToFitDuringAcq_changed(int state)
 {
        GlobalSettings settings;
-       settings.setValue(GlobalSettings::Key_View_AlwaysZoomToFit, state ? true : false);
+       settings.setValue(GlobalSettings::Key_View_ZoomToFitDuringAcq, state ? true : false);
 }
 
 void Settings::on_view_zoomToFitAfterAcq_changed(int state)
index d981c8bd74cfa12f29759da662e10f3dd1450f2e..6477757f7f60e58f29ad48fcd791d359f6e4af7b 100644 (file)
@@ -50,7 +50,7 @@ public:
 
 private Q_SLOTS:
        void on_page_changed(QListWidgetItem *current, QListWidgetItem *previous);
-       void on_view_alwaysZoomToFit_changed(int state);
+       void on_view_zoomToFitDuringAcq_changed(int state);
        void on_view_zoomToFitAfterAcq_changed(int state);
        void on_view_colouredBG_changed(int state);
        void on_view_stickyScrolling_changed(int state);
index 7fd1249cfd5d4fd525251ea03dca6b58186f76ff..915eaebcc9bee7df37981770f158117b60ffcd42 100644 (file)
@@ -25,7 +25,7 @@ using std::multimap;
 
 namespace pv {
 
-const QString GlobalSettings::Key_View_AlwaysZoomToFit = "View_AlwaysZoomToFit";
+const QString GlobalSettings::Key_View_ZoomToFitDuringAcq = "View_ZoomToFitDuringAcq";
 const QString GlobalSettings::Key_View_ZoomToFitAfterAcq = "View_ZoomToFitAfterAcq";
 const QString GlobalSettings::Key_View_ColouredBG = "View_ColouredBG";
 const QString GlobalSettings::Key_View_StickyScrolling = "View_StickyScrolling";
index b2b3626ed05febc0e7c7b51c9491a75aa826a496..eb964fa2c677b802fe077e2da34de722328d6328 100644 (file)
@@ -38,7 +38,7 @@ class GlobalSettings : public QSettings
        Q_OBJECT
 
 public:
-       static const QString Key_View_AlwaysZoomToFit;
+       static const QString Key_View_ZoomToFitDuringAcq;
        static const QString Key_View_ZoomToFitAfterAcq;
        static const QString Key_View_ColouredBG;
        static const QString Key_View_StickyScrolling;
index 972b379d9dad1682318da2be20aa021999c2f109..0b5eef74e27a21b2164d980ee8a18f19644bb02d 100644 (file)
@@ -1316,7 +1316,7 @@ void View::capture_state_updated(int state)
                // Activate "always zoom to fit" if the setting is enabled and we're
                // the main view of this session (other trace views may be used for
                // zooming and we don't want to mess them up)
-               bool state = settings.value(GlobalSettings::Key_View_AlwaysZoomToFit).toBool();
+               bool state = settings.value(GlobalSettings::Key_View_ZoomToFitDuringAcq).toBool();
                if (is_main_view_ && state) {
                        always_zoom_to_fit_ = true;
                        always_zoom_to_fit_changed(always_zoom_to_fit_);