mirror of
https://github.com/saitohirga/WSJT-X.git
synced 2024-11-25 13:48:42 -05:00
Update some missing i18n strings
This commit is contained in:
parent
8c7e4ba42f
commit
bcff949025
@ -289,6 +289,7 @@ set (wsjt_qt_CXXSRCS
|
|||||||
logbook/AD1CCty.cpp
|
logbook/AD1CCty.cpp
|
||||||
logbook/WorkedBefore.cpp
|
logbook/WorkedBefore.cpp
|
||||||
logbook/Multiplier.cpp
|
logbook/Multiplier.cpp
|
||||||
|
Network/NetworkAccessManager.cpp
|
||||||
)
|
)
|
||||||
|
|
||||||
set (wsjt_qtmm_CXXSRCS
|
set (wsjt_qtmm_CXXSRCS
|
||||||
@ -1138,6 +1139,7 @@ if (UPDATE_TRANSLATIONS)
|
|||||||
qt5_create_translation (
|
qt5_create_translation (
|
||||||
QM_FILES ${wsjt_qt_UISRCS} ${wsjtx_UISRCS} ${wsjt_qt_CXXSRCS} ${wsjtx_CXXSRCS}
|
QM_FILES ${wsjt_qt_UISRCS} ${wsjtx_UISRCS} ${wsjt_qt_CXXSRCS} ${wsjtx_CXXSRCS}
|
||||||
${TS_FILES}
|
${TS_FILES}
|
||||||
|
OPTIONS -I${CMAKE_CURRENT_SOURCE_DIR}
|
||||||
)
|
)
|
||||||
else ()
|
else ()
|
||||||
qt5_add_translation (QM_FILES ${TS_FILES})
|
qt5_add_translation (QM_FILES ${TS_FILES})
|
||||||
|
@ -292,7 +292,7 @@ EqualizationToolsDialog::impl::impl (EqualizationToolsDialog * self
|
|||||||
| QDialogButtonBox::RestoreDefaults | QDialogButtonBox::Close
|
| QDialogButtonBox::RestoreDefaults | QDialogButtonBox::Close
|
||||||
, Qt::Vertical}
|
, Qt::Vertical}
|
||||||
{
|
{
|
||||||
setWindowTitle (windowTitle () + ' ' + tr (title));
|
setWindowTitle (windowTitle () + ' ' + tr ("Equalization Tools"));
|
||||||
resize (500, 600);
|
resize (500, 600);
|
||||||
{
|
{
|
||||||
SettingsGroup g {settings_, title};
|
SettingsGroup g {settings_, title};
|
||||||
|
@ -4,8 +4,6 @@
|
|||||||
#include <QNetworkAccessManager>
|
#include <QNetworkAccessManager>
|
||||||
#include <QList>
|
#include <QList>
|
||||||
#include <QSslError>
|
#include <QSslError>
|
||||||
#include <QNetworkReply>
|
|
||||||
#include <QString>
|
|
||||||
|
|
||||||
#include "widgets/MessageBox.hpp"
|
#include "widgets/MessageBox.hpp"
|
||||||
|
|
||||||
@ -18,58 +16,18 @@ class QWidget;
|
|||||||
class NetworkAccessManager
|
class NetworkAccessManager
|
||||||
: public QNetworkAccessManager
|
: public QNetworkAccessManager
|
||||||
{
|
{
|
||||||
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
NetworkAccessManager (QWidget * parent)
|
explicit NetworkAccessManager (QWidget * parent);
|
||||||
: QNetworkAccessManager (parent)
|
|
||||||
{
|
|
||||||
// handle SSL errors that have not been cached as allowed
|
|
||||||
// exceptions and offer them to the user to add to the ignored
|
|
||||||
// exception cache
|
|
||||||
connect (this, &QNetworkAccessManager::sslErrors, [this, &parent] (QNetworkReply * reply, QList<QSslError> const& errors) {
|
|
||||||
QString message;
|
|
||||||
QList<QSslError> new_errors;
|
|
||||||
for (auto const& error: errors)
|
|
||||||
{
|
|
||||||
if (!allowed_ssl_errors_.contains (error))
|
|
||||||
{
|
|
||||||
new_errors << error;
|
|
||||||
message += '\n' + reply->request ().url ().toDisplayString () + ": "
|
|
||||||
+ error.errorString ();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (new_errors.size ())
|
|
||||||
{
|
|
||||||
QString certs;
|
|
||||||
for (auto const& cert : reply->sslConfiguration ().peerCertificateChain ())
|
|
||||||
{
|
|
||||||
certs += cert.toText () + '\n';
|
|
||||||
}
|
|
||||||
if (MessageBox::Ignore == MessageBox::query_message (parent, tr ("Network SSL Errors"), message, certs, MessageBox::Abort | MessageBox::Ignore))
|
|
||||||
{
|
|
||||||
// accumulate new SSL error exceptions that have been allowed
|
|
||||||
allowed_ssl_errors_.append (new_errors);
|
|
||||||
reply->ignoreSslErrors (allowed_ssl_errors_);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
// no new exceptions so silently ignore the ones already allowed
|
|
||||||
reply->ignoreSslErrors (allowed_ssl_errors_);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
QNetworkReply * createRequest (Operation operation, QNetworkRequest const& request, QIODevice * outgoing_data = nullptr) override
|
QNetworkReply * createRequest (Operation, QNetworkRequest const&, QIODevice * = nullptr) override;
|
||||||
{
|
|
||||||
auto reply = QNetworkAccessManager::createRequest (operation, request, outgoing_data);
|
|
||||||
// errors are usually certificate specific so passing all cached
|
|
||||||
// exceptions here is ok
|
|
||||||
reply->ignoreSslErrors (allowed_ssl_errors_);
|
|
||||||
return reply;
|
|
||||||
}
|
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
void filter_SSL_errors (QNetworkReply * reply, QList<QSslError> const& errors);
|
||||||
|
|
||||||
|
QWidget * parent_widget_;
|
||||||
QList<QSslError> allowed_ssl_errors_;
|
QList<QSslError> allowed_ssl_errors_;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -88,7 +88,7 @@ SampleDownloader::impl::impl (QSettings * settings
|
|||||||
, directory_ {configuration, network_manager}
|
, directory_ {configuration, network_manager}
|
||||||
, button_box_ {QDialogButtonBox::Close, Qt::Vertical}
|
, button_box_ {QDialogButtonBox::Close, Qt::Vertical}
|
||||||
{
|
{
|
||||||
setWindowTitle (windowTitle () + ' ' + tr (title));
|
setWindowTitle (windowTitle () + ' ' + tr ("Download Samples"));
|
||||||
resize (500, 600);
|
resize (500, 600);
|
||||||
{
|
{
|
||||||
SettingsGroup g {settings_, title};
|
SettingsGroup g {settings_, title};
|
||||||
@ -111,7 +111,7 @@ SampleDownloader::impl::impl (QSettings * settings
|
|||||||
details_layout_.setMargin (0);
|
details_layout_.setMargin (0);
|
||||||
details_layout_.addRow (tr ("Base URL for samples:"), &url_line_edit_);
|
details_layout_.addRow (tr ("Base URL for samples:"), &url_line_edit_);
|
||||||
details_layout_.addRow (tr ("Only use HTTP:"), &http_only_check_box_);
|
details_layout_.addRow (tr ("Only use HTTP:"), &http_only_check_box_);
|
||||||
http_only_check_box_.setToolTip (tr ("Check this is you get SSL/TLS errors"));
|
http_only_check_box_.setToolTip (tr ("Check this if you get SSL/TLS errors"));
|
||||||
details_widget_.setLayout (&details_layout_);
|
details_widget_.setLayout (&details_layout_);
|
||||||
|
|
||||||
main_layout_.addLayout (&left_layout_, 0, 0);
|
main_layout_.addLayout (&left_layout_, 0, 0);
|
||||||
|
@ -684,7 +684,7 @@ void HamlibTransceiver::do_stop ()
|
|||||||
TRACE_CAT ("HamlibTransceiver", "state:" << state () << "reversed =" << reversed_);
|
TRACE_CAT ("HamlibTransceiver", "state:" << state () << "reversed =" << reversed_);
|
||||||
}
|
}
|
||||||
|
|
||||||
auto HamlibTransceiver::get_vfos (bool for_split) const -> std::tuple<vfo_t, vfo_t>
|
std::tuple<vfo_t, vfo_t> HamlibTransceiver::get_vfos (bool for_split) const
|
||||||
{
|
{
|
||||||
if (get_vfo_works_ && rig_->caps->get_vfo)
|
if (get_vfo_works_ && rig_->caps->get_vfo)
|
||||||
{
|
{
|
||||||
|
@ -12,10 +12,10 @@ namespace
|
|||||||
// human readable strings for each Region enumeration value
|
// human readable strings for each Region enumeration value
|
||||||
char const * const region_names[] =
|
char const * const region_names[] =
|
||||||
{
|
{
|
||||||
"All",
|
QT_TRANSLATE_NOOP ("IARURegions", "All"),
|
||||||
"Region 1",
|
QT_TRANSLATE_NOOP ("IARURegions", "Region 1"),
|
||||||
"Region 2",
|
QT_TRANSLATE_NOOP ("IARURegions", "Region 2"),
|
||||||
"Region 3",
|
QT_TRANSLATE_NOOP ("IARURegions", "Region 3"),
|
||||||
};
|
};
|
||||||
std::size_t constexpr region_names_size = sizeof (region_names) / sizeof (region_names[0]);
|
std::size_t constexpr region_names_size = sizeof (region_names) / sizeof (region_names[0]);
|
||||||
}
|
}
|
||||||
@ -34,7 +34,7 @@ char const * IARURegions::name (Region r)
|
|||||||
return region_names[static_cast<int> (r)];
|
return region_names[static_cast<int> (r)];
|
||||||
}
|
}
|
||||||
|
|
||||||
auto IARURegions::value (QString const& s) -> Region
|
IARURegions::Region IARURegions::value (QString const& s)
|
||||||
{
|
{
|
||||||
auto end = region_names + region_names_size;
|
auto end = region_names + region_names_size;
|
||||||
auto p = std::find_if (region_names, end
|
auto p = std::find_if (region_names, end
|
||||||
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user