~ubuntu-branches/ubuntu/trusty/manaplus/trusty-proposed

« back to all changes in this revision

Viewing changes to src/gui/registerdialog.cpp

  • Committer: Package Import Robot
  • Author(s): Patrick Matthäi, Andrei Karas, Patrick Matthäi
  • Date: 2013-05-27 09:14:03 UTC
  • mfrom: (1.1.3)
  • Revision ID: package-import@ubuntu.com-20130527091403-4b1jceqok7g2v5on
Tags: 1.3.5.26-1
[ Andrei Karas ]
* Add new files to copyright file.
* Update homepage URL.

[ Patrick Matthäi ]
* New upstream release.

Show diffs side-by-side

added added

removed removed

Lines of Context:
147
147
    mPasswordField->addKeyListener(this);
148
148
    mConfirmField->addKeyListener(this);
149
149
 
150
 
    /* TODO:
151
 
     * This is a quick and dirty way to respond to the ENTER key, regardless of
152
 
     * which text field is selected. There may be a better way now with the new
153
 
     * input system of Guichan 0.6.0. See also the login dialog.
154
 
     */
155
150
    mUserField->setActionEventId("register");
156
151
    mPasswordField->setActionEventId("register");
157
152
    mConfirmField->setActionEventId("register");
208
203
                 minUser);
209
204
            error = 1;
210
205
        }
211
 
        else if (user.length() > maxUser - 1 )
 
206
        else if (user.length() > maxUser - 1)
212
207
        {
213
208
            // Name too long
214
209
            errorMsg = strprintf
254
249
                // Reset password confirmation
255
250
                mPasswordField->setText("");
256
251
                mConfirmField->setText("");
257
 
 
258
252
                mWrongDataNoticeListener->setTarget(this->mPasswordField);
259
253
            }
260
254
 
267
261
        {
268
262
            // No errors detected, register the new user.
269
263
            mRegisterButton->setEnabled(false);
270
 
 
271
264
            mLoginData->username = mUserField->getText();
272
265
            mLoginData->password = mPasswordField->getText();
273
266
            if (mFemaleButton && mFemaleButton->isSelected())