Alexandre Lision | 624b1a8 | 2016-09-11 19:29:01 -0400 | [diff] [blame] | 1 | /* |
Sébastien Blin | 029ffa8 | 2019-01-02 17:43:48 -0500 | [diff] [blame] | 2 | * Copyright (C) 2016-2019 Savoir-faire Linux Inc. |
Alexandre Lision | 624b1a8 | 2016-09-11 19:29:01 -0400 | [diff] [blame] | 3 | * Author: Alexandre Lision <alexandre.lision@savoirfairelinux.com> |
| 4 | * |
| 5 | * This program is free software; you can redistribute it and/or modify |
| 6 | * it under the terms of the GNU General Public License as published by |
| 7 | * the Free Software Foundation; either version 3 of the License, or |
| 8 | * (at your option) any later version. |
| 9 | * |
| 10 | * This program is distributed in the hope that it will be useful, |
| 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 13 | * GNU General Public License for more details. |
| 14 | * |
| 15 | * You should have received a copy of the GNU General Public License |
| 16 | * along with this program; if not, write to the Free Software |
| 17 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. |
| 18 | */ |
| 19 | |
| 20 | #import <Cocoa/Cocoa.h> |
| 21 | |
Kateryna Kostiuk | be7e2e4 | 2019-07-26 17:44:12 -0400 | [diff] [blame^] | 22 | //Jami |
Alexandre Lision | 624b1a8 | 2016-09-11 19:29:01 -0400 | [diff] [blame] | 23 | #import "LoadingWCProtocol.h" |
| 24 | #import "LoadingWCDelegate.h" |
| 25 | #import "AbstractLoadingWC.h" |
| 26 | |
Kateryna Kostiuk | be7e2e4 | 2019-07-26 17:44:12 -0400 | [diff] [blame^] | 27 | #import "string" |
| 28 | |
| 29 | namespace lrc { |
| 30 | namespace api { |
| 31 | class NewAccountModel; |
| 32 | } |
| 33 | } |
| 34 | |
Alexandre Lision | 624b1a8 | 2016-09-11 19:29:01 -0400 | [diff] [blame] | 35 | @protocol MigrateRingAccountsDelegate <LoadingWCDelegate> |
| 36 | |
| 37 | -(void) migrationDidCompleteWithError; |
| 38 | -(void) migrationDidComplete; |
| 39 | |
| 40 | @end |
| 41 | |
| 42 | @interface MigrateRingAccountsWC : AbstractLoadingWC <LoadingWCProtocol> |
| 43 | |
| 44 | /** |
| 45 | * password string contained in passwordField. |
| 46 | */ |
| 47 | @property (retain) NSString* password; |
| 48 | |
| 49 | /** |
| 50 | * passwordConfirmation string contained in passwordConfirmationField. |
| 51 | */ |
| 52 | @property (retain) NSString* passwordConfirmation; |
| 53 | |
| 54 | /** |
| 55 | * computed properties calculated by password string contained in |
| 56 | * passwordField and passwordCOnfirmation string contained |
| 57 | * inpasswordConfirmationField |
| 58 | * This is a KVO method to bind the text with the OK Button |
| 59 | * if password.length is > 0 AND passwordConfirmation.length > 0 |
| 60 | * AND password isEqualsToString passwordCOnfirmationbutton is enabled, |
| 61 | * otherwise disabled |
| 62 | */ |
| 63 | @property (readonly) BOOL validatePasswords; |
| 64 | |
Kateryna Kostiuk | be7e2e4 | 2019-07-26 17:44:12 -0400 | [diff] [blame^] | 65 | @property lrc::api::NewAccountModel* accountModel; |
| 66 | @property std::string accountToMigrate; |
Alexandre Lision | 624b1a8 | 2016-09-11 19:29:01 -0400 | [diff] [blame] | 67 | |
| 68 | @end |