From 7ec4d1a109aa0048cb597889d7b9f27fd216e933 Mon Sep 17 00:00:00 2001 From: Bill Somerville Date: Mon, 27 Jul 2015 18:11:06 +0000 Subject: [PATCH] Qt 5.5 compliance The header QMetaType must now be included explicitly if no other header includes QObject. Adjust band combo box layout settings to ensure it is rendered at minimum content size otherwise it stretches the signal meter width to an ugly extent. Also retired the "frequencies" settings file key so that upgrades and downgrades between 1.5 and 1.6 no longer require rebuilding the working frequencies list. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@5727 ab8295b8-cf94-4d9e-aec4-7959e3be5d79 --- Configuration.cpp | 10 +++++++--- WFPalette.hpp | 1 + mainwindow.ui | 15 ++++++--------- 3 files changed, 14 insertions(+), 12 deletions(-) diff --git a/Configuration.cpp b/Configuration.cpp index c95ce9a53..7999c72cd 100644 --- a/Configuration.cpp +++ b/Configuration.cpp @@ -1202,9 +1202,13 @@ void Configuration::impl::read_settings () macros_.setStringList (settings_->value ("Macros", QStringList {"TNX 73 GL"}).toStringList ()); - if (settings_->contains ("frequencies")) + if (settings_->contains ("FrequenciesForModes")) { - frequencies_.frequency_list (settings_->value ("frequencies").value ()); + frequencies_.frequency_list (settings_->value ("FrequenciesForModes").value ()); + } + else + { + frequencies_.reset_to_defaults (); } stations_.station_list (settings_->value ("stations").value ()); @@ -1297,7 +1301,7 @@ void Configuration::impl::write_settings () settings_->setValue ("After73", id_after_73_); settings_->setValue ("TxQSYAllowed", tx_QSY_allowed_); settings_->setValue ("Macros", macros_.stringList ()); - settings_->setValue ("frequencies", QVariant::fromValue (frequencies_.frequency_list ())); + settings_->setValue ("FrequenciesForModes", QVariant::fromValue (frequencies_.frequency_list ())); settings_->setValue ("stations", QVariant::fromValue (stations_.station_list ())); settings_->setValue ("toRTTY", log_as_RTTY_); settings_->setValue ("dBtoComments", report_in_comments_); diff --git a/WFPalette.hpp b/WFPalette.hpp index 271ca5357..69a2b85fd 100644 --- a/WFPalette.hpp +++ b/WFPalette.hpp @@ -1,6 +1,7 @@ #ifndef W_F_PALETTE_HPP__ #define W_F_PALETTE_HPP__ +#include #include #include #include diff --git a/mainwindow.ui b/mainwindow.ui index a965ada8a..724dd9023 100644 --- a/mainwindow.ui +++ b/mainwindow.ui @@ -6,8 +6,8 @@ 0 0 - 934 - 565 + 786 + 475 @@ -2236,12 +2236,6 @@ QPushButton[state="ok"] { - - - 0 - 0 - - Select operating band or frequency in MHz @@ -2251,6 +2245,9 @@ QPushButton[state="ok"] { QComboBox::NoInsert + + QComboBox::AdjustToMinimumContentsLength + @@ -2264,7 +2261,7 @@ QPushButton[state="ok"] { 0 0 - 934 + 786 21