diff --git a/Classes/WizardViewController.h b/Classes/WizardViewController.h index 3d0223b2c..2e8123690 100644 --- a/Classes/WizardViewController.h +++ b/Classes/WizardViewController.h @@ -41,6 +41,11 @@ @property (nonatomic, retain) IBOutlet UIButton *backButton; @property (nonatomic, retain) IBOutlet UIButton *startButton; +@property (nonatomic, retain) IBOutlet UIButton *createAccountButton; +@property (nonatomic, retain) IBOutlet UIButton *connectAccountButton; +@property (nonatomic, retain) IBOutlet UIButton *externalAccountButton; + +@property (nonatomic, retain) IBOutlet UIImageView *choiceViewLogoImageView; @property (nonatomic, retain) IBOutlet UITapGestureRecognizer *viewTapGestureRecognizer; diff --git a/Classes/WizardViewController.m b/Classes/WizardViewController.m index f11d51a34..01408d249 100644 --- a/Classes/WizardViewController.m +++ b/Classes/WizardViewController.m @@ -51,6 +51,11 @@ typedef enum _ViewElement { @synthesize backButton; @synthesize startButton; +@synthesize createAccountButton; +@synthesize connectAccountButton; +@synthesize externalAccountButton; + +@synthesize choiceViewLogoImageView; @synthesize viewTapGestureRecognizer; @@ -86,6 +91,11 @@ typedef enum _ViewElement { [backButton release]; [startButton release]; + [createAccountButton release]; + [connectAccountButton release]; + [externalAccountButton release]; + + [choiceViewLogoImageView release]; [historyViews release]; @@ -205,7 +215,11 @@ static UICompositeViewDescription *compositeDescription = nil; [WizardViewController cleanTextField:connectAccountView]; [WizardViewController cleanTextField:externalAccountView]; [WizardViewController cleanTextField:validateAccountView]; - [self changeView:welcomeView back:FALSE animation:FALSE]; + if ([[LinphoneManager instance] lpConfigBoolForKey:@"hide_wizard_welcome_view_preference"] == true) { + [self changeView:choiceView back:FALSE animation:FALSE]; + } else { + [self changeView:welcomeView back:FALSE animation:FALSE]; + } [waitView setHidden:TRUE]; } @@ -252,9 +266,28 @@ static UICompositeViewDescription *compositeDescription = nil; if (view == validateAccountView) { [backButton setEnabled:FALSE]; + } else if (view == choiceView) { + if ([[LinphoneManager instance] lpConfigBoolForKey:@"hide_wizard_welcome_view_preference"] == true) { + [backButton setEnabled:FALSE]; + } else { + [backButton setEnabled:TRUE]; + } } else { [backButton setEnabled:TRUE]; } + + if (view == choiceView) { + if ([[LinphoneManager instance] lpConfigBoolForKey:@"show_wizard_logo_in_choice_view_preference"] == true) { + [choiceViewLogoImageView setHidden:FALSE]; + } + if ([[LinphoneManager instance] lpConfigBoolForKey:@"hide_wizard_custom_account_button_preference"] == true) { + [externalAccountButton setHidden:TRUE]; + if ([[LinphoneManager instance] lpConfigBoolForKey:@"show_wizard_logo_in_choice_view_preference"] == true) { + [createAccountButton setCenter: [connectAccountButton center]]; + } + [connectAccountButton setCenter: [externalAccountButton center]]; + } + } // Animation if(animation && [[LinphoneManager instance] lpConfigBoolForKey:@"animations_preference"] == true) { diff --git a/Classes/en.lproj/WizardViews.xib b/Classes/en.lproj/WizardViews.xib index d1584ea80..2cb5a395b 100644 --- a/Classes/en.lproj/WizardViews.xib +++ b/Classes/en.lproj/WizardViews.xib @@ -2,13 +2,13 @@ 1536 - 11E53 - 2840 - 1138.47 - 569.00 + 12C60 + 2844 + 1187.34 + 625.00 com.apple.InterfaceBuilder.IBCocoaTouchPlugin - 1926 + 1930 IBProxyObject @@ -43,6 +43,7 @@ 311 {{60, 80}, {201, 129}} + _NS:9 1 @@ -52,7 +53,7 @@ IBCocoaTouchFramework - + NSImage setup_welcome_logo.png @@ -62,6 +63,7 @@ 319 {{31, 230}, {258, 40}} + _NS:9 NO @@ -102,6 +104,7 @@ 282 {{40, 290}, {240, 44}} + _NS:9 NO YES @@ -130,6 +133,7 @@ {320, 394} + _NS:9 @@ -142,11 +146,29 @@ 274 + + + -2147483337 + {{59, 72}, {201, 129}} + + + + _NS:9 + 1 + NO + + Linphone setup assistant icon + + + IBCocoaTouchFramework + + 311 {{31, 34}, {258, 40}} + _NS:9 NO @@ -173,7 +195,8 @@ 319 {{33, 141}, {255, 50}} - + + _NS:9 NO @@ -220,6 +243,7 @@ 319 {{33, 205}, {255, 50}} + _NS:9 NO @@ -245,6 +269,7 @@ 319 {{33, 269}, {255, 50}} + _NS:9 NO @@ -267,13 +292,14 @@ {320, 394} + _NS:9 IBCocoaTouchFramework - + 274 @@ -497,14 +523,13 @@ {320, 394} - _NS:9 IBCocoaTouchFramework - + 274 @@ -646,14 +671,13 @@ {320, 394} - _NS:9 IBCocoaTouchFramework - + 274 @@ -826,14 +850,13 @@ {320, 394} - _NS:9 IBCocoaTouchFramework - + 274 @@ -975,7 +998,6 @@ {320, 394} - _NS:9 @@ -1032,6 +1054,38 @@ 112 + + + externalAccountButton + + + + 133 + + + + connectAccountButton + + + + 134 + + + + createAccountButton + + + + 135 + + + + choiceViewLogoImageView + + + + 136 + onCreateAccountClick: @@ -1234,6 +1288,7 @@ + choiceView @@ -1461,6 +1516,12 @@ title + + 128 + + + choiceViewLogoImage + @@ -1483,6 +1544,7 @@ com.apple.InterfaceBuilder.IBCocoaTouchPlugin com.apple.InterfaceBuilder.IBCocoaTouchPlugin com.apple.InterfaceBuilder.IBCocoaTouchPlugin + com.apple.InterfaceBuilder.IBCocoaTouchPlugin com.apple.InterfaceBuilder.IBCocoaTouchPlugin com.apple.InterfaceBuilder.IBCocoaTouchPlugin com.apple.InterfaceBuilder.IBCocoaTouchPlugin @@ -1533,9 +1595,229 @@ - 127 + 136 + + + + + TPMultiLayoutViewController + UIViewController + + UIView + UIView + + + + landscapeView + UIView + + + portraitView + UIView + + + + IBProjectSource + ./Classes/TPMultiLayoutViewController.h + + + + TUNinePatch + NSObject + + IBProjectSource + ./Classes/TUNinePatch.h + + + + UILinphoneButton + UIButton + + TUNinePatch + TUNinePatch + + + + backgroundNinePatch + TUNinePatch + + + backgroundOverNinePatch + TUNinePatch + + + + IBProjectSource + ./Classes/UILinphoneButton.h + + + + UILinphoneTextField + UITextField + + backgroundNinePatch + TUNinePatch + + + backgroundNinePatch + + backgroundNinePatch + TUNinePatch + + + + IBProjectSource + ./Classes/UILinphoneTextField.h + + + + WizardViewController + TPMultiLayoutViewController + + id + id + id + id + id + id + id + id + id + id + id + + + + onBackClick: + id + + + onCancelClick: + id + + + onCheckValidationClick: + id + + + onConnectAccountClick: + id + + + onCreateAccountClick: + id + + + onExternalAccountClick: + id + + + onRegisterClick: + id + + + onSignInClick: + id + + + onSignInExternalClick: + id + + + onStartClick: + id + + + onViewTap: + id + + + + UIButton + UIView + UIImageView + UIButton + UIView + UIScrollView + UIButton + UIView + UIButton + UIView + UIButton + UIView + UITapGestureRecognizer + UIView + UIView + + + + backButton + UIButton + + + choiceView + UIView + + + choiceViewLogoImageView + UIImageView + + + connectAccountButton + UIButton + + + connectAccountView + UIView + + + contentView + UIScrollView + + + createAccountButton + UIButton + + + createAccountView + UIView + + + externalAccountButton + UIButton + + + externalAccountView + UIView + + + startButton + UIButton + + + validateAccountView + UIView + + + viewTapGestureRecognizer + UITapGestureRecognizer + + + waitView + UIView + + + welcomeView + UIView + + + + IBProjectSource + ./Classes/WizardViewController.h + + + - 0 IBCocoaTouchFramework YES @@ -1546,6 +1828,6 @@ {542, 88} {179, 161} - 1926 + 1930