~ubuntu-branches/debian/sid/filezilla/sid

« back to all changes in this revision

Viewing changes to src/interface/sitemanager.cpp

  • Committer: Bazaar Package Importer
  • Author(s): Adrien Cunin
  • Date: 2010-04-20 09:25:39 UTC
  • mfrom: (1.3.7 upstream)
  • Revision ID: james.westby@ubuntu.com-20100420092539-10d1003e0nm4zfyp
Tags: 3.3.2.1-1
* New upstream release
   - Really fixes previously mentioned bugs (the patches for them were not
     included in upstream 3.3.1)
* Added libgtk2.0-dev to build-deps
* Added libtinyxml-dev to build-deps, so that the system libtinyxml is used
* Added debian/README.source saying that dpatch is used
* Updated Standards-Version, no change needed

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
#include "FileZilla.h"
 
1
#include <filezilla.h>
2
2
#include "sitemanager.h"
3
3
#include "Options.h"
4
4
#include "xmlfunctions.h"
1037
1037
                if (host == _T(""))
1038
1038
                {
1039
1039
                        XRCCTRL(*this, "ID_HOST", wxTextCtrl)->SetFocus();
1040
 
                        wxMessageBox(_("You have to enter a hostname."));
 
1040
                        wxMessageBox(_("You have to enter a hostname."), _("Site Manager - Invalid data"), wxICON_EXCLAMATION, this); 
1041
1041
                        return false;
1042
1042
                }
1043
1043
 
1049
1049
                        logon_type == ACCOUNT)
1050
1050
                {
1051
1051
                        XRCCTRL(*this, "ID_LOGONTYPE", wxChoice)->SetFocus();
1052
 
                        wxMessageBox(_("'Account' logontype not supported by selected protocol"));
 
1052
                        wxMessageBox(_("'Account' logontype not supported by selected protocol"), _("Site Manager - Invalid data"), wxICON_EXCLAMATION, this);
1053
1053
                        return false;
1054
1054
                }
1055
1055
 
1058
1058
                        (logon_type == ACCOUNT || logon_type == NORMAL))
1059
1059
                {
1060
1060
                        XRCCTRL(*this, "ID_LOGONTYPE", wxChoice)->SetFocus();
1061
 
                        wxMessageBox(_("FileZilla is running in kiosk mode.\n'Normal' and 'Account' logontypes are not available in this mode."));
 
1061
                        wxMessageBox(_("FileZilla is running in kiosk mode.\n'Normal' and 'Account' logontypes are not available in this mode."), _("Site Manager - Invalid data"), wxICON_EXCLAMATION, this);
1062
1062
                        return false;
1063
1063
                }
1064
1064
 
1069
1069
                if (protocol != UNKNOWN)
1070
1070
                        server.SetProtocol(protocol);
1071
1071
 
1072
 
                unsigned long port;
1073
 
                XRCCTRL(*this, "ID_PORT", wxTextCtrl)->GetValue().ToULong(&port);
 
1072
                wxString port = XRCCTRL(*this, "ID_PORT", wxTextCtrl)->GetValue();
1074
1073
                CServerPath path;
1075
1074
                wxString error;
1076
1075
                if (!server.ParseUrl(host, port, _T(""), _T(""), error, path))
1077
1076
                {
1078
1077
                        XRCCTRL(*this, "ID_HOST", wxTextCtrl)->SetFocus();
1079
 
                        wxMessageBox(error);
 
1078
                        wxMessageBox(error, _("Site Manager - Invalid data"), wxICON_EXCLAMATION, this);
1080
1079
                        return false;
1081
1080
                }
1082
1081
 
1093
1092
                        if (XRCCTRL(*this, "ID_ENCODING", wxTextCtrl)->GetValue() == _T(""))
1094
1093
                        {
1095
1094
                                XRCCTRL(*this, "ID_ENCODING", wxTextCtrl)->SetFocus();
1096
 
                                wxMessageBox(_("Need to specify a character encoding"));
 
1095
                                wxMessageBox(_("Need to specify a character encoding"), _("Site Manager - Invalid data"), wxICON_EXCLAMATION, this);
1097
1096
                                return false;
1098
1097
                        }
1099
1098
                }
1106
1105
                        user == _T(""))
1107
1106
                {
1108
1107
                        XRCCTRL(*this, "ID_USER", wxTextCtrl)->SetFocus();
1109
 
                        wxMessageBox(_("You have to specify a user name"));
 
1108
                        wxMessageBox(_("You have to specify a user name"), _("Site Manager - Invalid data"), wxICON_EXCLAMATION, this);
1110
1109
                        return false;
1111
1110
                }
1112
1111
 
1125
1124
                        if (space_only)
1126
1125
                        {
1127
1126
                                XRCCTRL(*this, "ID_USER", wxTextCtrl)->SetFocus();
1128
 
                                wxMessageBox(_("Username cannot be a series of spaces"));
 
1127
                                wxMessageBox(_("Username cannot be a series of spaces"), _("Site Manager - Invalid data"), wxICON_EXCLAMATION, this);
1129
1128
                                return false;
1130
1129
                        }
1131
1130
                }
1135
1134
                        XRCCTRL(*this, "ID_ACCOUNT", wxTextCtrl)->GetValue() == _T(""))
1136
1135
                {
1137
1136
                        XRCCTRL(*this, "ID_ACCOUNT", wxTextCtrl)->SetFocus();
1138
 
                        wxMessageBox(_("You have to enter an account name"));
 
1137
                        wxMessageBox(_("You have to enter an account name"), _("Site Manager - Invalid data"), wxICON_EXCLAMATION, this);
1139
1138
                        return false;
1140
1139
                }
1141
1140
 
1149
1148
                        if (!remotePath.SetPath(remotePathRaw))
1150
1149
                        {
1151
1150
                                XRCCTRL(*this, "ID_REMOTEDIR", wxTextCtrl)->SetFocus();
1152
 
                                wxMessageBox(_("Default remote path cannot be parsed. Make sure it is valid and is supported by the selected servertype."));
 
1151
                                wxMessageBox(_("Default remote path cannot be parsed. Make sure it is valid and is supported by the selected servertype."), _("Site Manager - Invalid data"), wxICON_EXCLAMATION, this);
1153
1152
                                return false;
1154
1153
                        }
1155
1154
                }
1160
1159
                        if (remotePathRaw.empty() || localPath.empty())
1161
1160
                        {
1162
1161
                                XRCCTRL(*this, "ID_SYNC", wxCheckBox)->SetFocus();
1163
 
                                wxMessageBox(_("You need to enter both a local and a remote path to enable synchronized browsing for this site."));
 
1162
                                wxMessageBox(_("You need to enter both a local and a remote path to enable synchronized browsing for this site."), _("Site Manager - Invalid data"), wxICON_EXCLAMATION, this);
1164
1163
                                return false;
1165
1164
                        }
1166
1165
                }
1185
1184
                                        msg = wxString::Format(_("Remote path cannot be parsed. Make sure it is a valid absolute path and is supported by the servertype (%s) selected on the parent site."), CServer::GetNameFromServerType(pServer->m_server.GetType()).c_str());
1186
1185
                                else
1187
1186
                                        msg = _("Remote path cannot be parsed. Make sure it is a valid absolute path.");
1188
 
                                wxMessageBox(msg);
 
1187
                                wxMessageBox(msg, _("Site Manager - Invalid data"), wxICON_EXCLAMATION, this);
1189
1188
                                return false;
1190
1189
                        }
1191
1190
                }
1195
1194
                if (remotePathRaw.empty() && localPath.empty())
1196
1195
                {
1197
1196
                        XRCCTRL(*this, "ID_BOOKMARK_LOCALDIR", wxTextCtrl)->SetFocus();
1198
 
                        wxMessageBox(_("You need to enter at least one path, empty bookmarks are not supported."));
 
1197
                        wxMessageBox(_("You need to enter at least one path, empty bookmarks are not supported."), _("Site Manager - Invalid data"), wxICON_EXCLAMATION, this);
1199
1198
                        return false;
1200
1199
                }
1201
1200
 
1204
1203
                        if (remotePathRaw.empty() || localPath.empty())
1205
1204
                        {
1206
1205
                                XRCCTRL(*this, "ID_BOOKMARK_SYNC", wxCheckBox)->SetFocus();
1207
 
                                wxMessageBox(_("You need to enter both a local and a remote path to enable synchronized browsing for this bookmark."));
 
1206
                                wxMessageBox(_("You need to enter both a local and a remote path to enable synchronized browsing for this bookmark."), _("Site Manager - Invalid data"), wxICON_EXCLAMATION, this);
1208
1207
                                return false;
1209
1208
                        }
1210
1209
                }