diff options
| author | Carl Hetherington <cth@carlh.net> | 2022-11-01 20:58:10 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2022-11-02 01:17:13 +0100 |
| commit | 0d7d4fb3472a30f7706baab0703114ec32d5a2af (patch) | |
| tree | 6b57993e0b3e899c62368f333378a8791ac800eb /src/wx | |
| parent | 98a8b5835aca46d8abb6f59513a56648f2c234ba (diff) | |
Add passive mode option to TMS upload.
Disabling this fixes TMS upload with some FTP servers
(reported on a Synology NAS).
Diffstat (limited to 'src/wx')
| -rw-r--r-- | src/wx/full_config_dialog.cc | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/src/wx/full_config_dialog.cc b/src/wx/full_config_dialog.cc index 1aeacd3ca..1eb87d93e 100644 --- a/src/wx/full_config_dialog.cc +++ b/src/wx/full_config_dialog.cc @@ -696,6 +696,10 @@ private: _tms_protocol = new wxChoice (_panel, wxID_ANY); table->Add (_tms_protocol, 1, wxEXPAND); + _tms_passive = new CheckBox(_panel, _("Passive mode")); + table->Add(_tms_passive, 1, wxEXPAND); + table->AddSpacer(0); + add_label_to_sizer (table, _panel, _("IP address"), true, 0, wxLEFT | wxRIGHT | wxALIGN_CENTRE_VERTICAL); _tms_ip = new wxTextCtrl (_panel, wxID_ANY); table->Add (_tms_ip, 1, wxEXPAND); @@ -717,6 +721,8 @@ private: _upload->Bind (wxEVT_CHECKBOX, boost::bind(&TMSPage::upload_changed, this)); _tms_protocol->Bind (wxEVT_CHOICE, boost::bind (&TMSPage::tms_protocol_changed, this)); + _tms_passive->bind(&TMSPage::tms_passive_changed, this); + _tms_ip->Bind (wxEVT_TEXT, boost::bind (&TMSPage::tms_ip_changed, this)); _tms_path->Bind (wxEVT_TEXT, boost::bind (&TMSPage::tms_path_changed, this)); _tms_user->Bind (wxEVT_TEXT, boost::bind (&TMSPage::tms_user_changed, this)); @@ -729,10 +735,13 @@ private: checked_set (_upload, config->upload_after_make_dcp()); checked_set (_tms_protocol, static_cast<int>(config->tms_protocol())); + checked_set(_tms_passive, config->tms_protocol() == FileTransferProtocol::FTP && config->tms_passive()); checked_set (_tms_ip, config->tms_ip ()); checked_set (_tms_path, config->tms_path ()); checked_set (_tms_user, config->tms_user ()); checked_set (_tms_password, config->tms_password ()); + + _tms_passive->Enable(config->tms_protocol() == FileTransferProtocol::FTP); } void upload_changed () @@ -745,6 +754,11 @@ private: Config::instance()->set_tms_protocol(static_cast<FileTransferProtocol>(_tms_protocol->GetSelection())); } + void tms_passive_changed() + { + Config::instance()->set_tms_passive(_tms_passive->get()); + } + void tms_ip_changed () { Config::instance()->set_tms_ip (wx_to_std (_tms_ip->GetValue ())); @@ -766,6 +780,7 @@ private: } CheckBox* _upload; + CheckBox* _tms_passive; wxChoice* _tms_protocol; wxTextCtrl* _tms_ip; wxTextCtrl* _tms_path; |
