blob: 45ea1e0af3c98e9db2284e982725b3d0c4c29ec5 [file] [log] [blame]
Alexandre Lision624b1a82016-09-11 19:29:01 -04001/*
Sébastien Blin029ffa82019-01-02 17:43:48 -05002 * Copyright (C) 2016-2019 Savoir-faire Linux Inc.
Alexandre Lision624b1a82016-09-11 19:29:01 -04003 * 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 Kostiukbe7e2e42019-07-26 17:44:12 -040022//Jami
Alexandre Lision624b1a82016-09-11 19:29:01 -040023#import "LoadingWCProtocol.h"
24#import "LoadingWCDelegate.h"
25#import "AbstractLoadingWC.h"
26
Kateryna Kostiukbe7e2e42019-07-26 17:44:12 -040027#import "string"
28
29namespace lrc {
30 namespace api {
31 class NewAccountModel;
32 }
33}
34
Alexandre Lision624b1a82016-09-11 19:29:01 -040035@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 Kostiukbe7e2e42019-07-26 17:44:12 -040065@property lrc::api::NewAccountModel* accountModel;
66@property std::string accountToMigrate;
Alexandre Lision624b1a82016-09-11 19:29:01 -040067
68@end