//public NSLayoutConstraint LocationPickerWidthConstraintProperty //{ // get // { // return LocationPickerWidthConstraint; // } //} //public NSLayoutConstraint MapCCodePickerWidthConstraintProperty //{ // get // { // return MapCCodePickerWidthConstraint; // } //} public override void ViewDidAppear(bool animated) { base.ViewDidAppear(animated); StepActivated?.Invoke(this, new MultiStepProcessStepEventArgs { Index = StepIndex }); if (!Settings.AnyClassificationChosen()) { var alert = UIAlertController.Create("Please Choose a Classification", "A minimum of one classification is required.", UIAlertControllerStyle.Alert); alert.AddAction(UIAlertAction.Create("Ok", UIAlertActionStyle.Cancel, (obj) => { RegistrationViewController registrationVC = (RegistrationViewController)((MultiStepProcessHorizontalViewController)this.ParentViewController).ContainerViewController; var finalStep = registrationVC.Steps.FirstOrDefault(); registrationVC._pageViewController.SetViewControllers(new[] { finalStep as UIViewController }, UIPageViewControllerNavigationDirection.Reverse, true, (finished) => { if (finished) { //finalStep.StepActivated(this, new MultiStepProcessStepEventArgs()); } }); })); //alert.AddAction(UIAlertAction.Create("Snooze", UIAlertActionStyle.Default, action => Snooze())); //if (alert.PopoverPresentationController != null) // alert.PopoverPresentationController.BarButtonItem = myItem; PresentViewController(alert, animated: true, completionHandler: () => { }); } }
public override void ViewDidAppear(bool animated) { base.ViewDidAppear(animated); StepActivated?.Invoke(this, new MultiStepProcessStepEventArgs { Index = StepIndex }); }
public override void ViewDidAppear(bool animated) { base.ViewDidAppear(animated); _shareStepView.QuestionText.Text = CreateSurveyController.SurveyModel.question.text; StepActivated?.Invoke(this, new MultiStepProcessStepEventArgs { Index = StepIndex }); }
public override void ViewDidAppear(bool animated) { base.ViewDidAppear(animated); StepActivated?.Invoke(this, new MultiStepProcessStepEventArgs { Index = StepIndex }); //Register events View.AddGestureRecognizer(HideKeyboardGesture); CompleteRegistrationButton.TouchUpInside += CompleteRegistrationButton_TouchUpInside; HoursTextField.EditingDidEnd += HoursTextField_EditingDidEnd; }
//public FavoriteClassificationsStepViewModel() { } public override void ViewDidAppear(bool animated) { base.ViewDidAppear(animated); StepActivated?.Invoke(this, new MultiStepProcessStepEventArgs { Index = StepIndex }); //var tm = new System.Threading.Timer(new System.Threading.TimerCallback((state) => //{ // this.InvokeOnMainThread(new Action(() => // { // SimpleCollectionViewController ctrl = new SimpleCollectionViewController(new GridLayout()); // ctrl.ModalTransitionStyle = UIModalTransitionStyle.CrossDissolve; // this.PresentViewController(ctrl, true, null); // })); //}), null, 1000, System.Threading.Timeout.Infinite); }
public override void ViewDidAppear(bool animated) { base.ViewDidAppear(animated); this.RestrictRotation(UIInterfaceOrientationMask.Portrait); var feedCellHeight = Utils.getHeightForFeedCell(CreateSurveyController.SurveyModel, View.Frame.Width); feedCell = new FeedCollectionViewCell(new CGRect(0, 0, View.Frame.Width, feedCellHeight)); Utils.BindFeedCell(feedCell, CreateSurveyController.SurveyModel, 0, this, true); UIScrollView scrollView = new UIScrollView(); scrollView.Frame = new CGRect(0, 70, View.Frame.Width, View.Frame.Height - 70); scrollView.ContentSize = new CGSize(View.Frame.Width, feedCellHeight); scrollView.LayoutIfNeeded(); scrollView.AutoresizingMask = UIViewAutoresizing.FlexibleWidth; scrollView.AddSubview(feedCell); View.AddSubview(scrollView); //View.SubviewsDoNotTranslateAutoresizingMaskIntoConstraints(); //View.AddConstraints( // scrollView.WithSameCenterX(View), // scrollView.AtTopOf(View, 70), // scrollView.AtLeftOf(View), // scrollView.AtRightOf(View), // scrollView.Height().EqualTo(feedCellHeight), // feedCell.WithSameCenterX(scrollView), // feedCell.AtTopOf(scrollView), // feedCell.AtLeftOf(scrollView), // feedCell.AtRightOf(scrollView), // feedCell.Height().EqualTo(feedCellHeight) //); StepActivated?.Invoke(this, new MultiStepProcessStepEventArgs { Index = StepIndex }); }
public override void ViewDidAppear(bool animated) { base.ViewDidAppear(animated); StepActivated?.Invoke(this, new MultiStepProcessStepEventArgs { Index = StepIndex }); if (!Settings.AnyClassificationChosen()) { var alert = UIAlertController.Create("Please Choose a Classification", "A minimum of one classification is required.", UIAlertControllerStyle.Alert); alert.AddAction(UIAlertAction.Create("Ok", UIAlertActionStyle.Cancel, (obj) => { RegistrationViewController registrationVC = (RegistrationViewController)((MultiStepProcessHorizontalViewController)this.ParentViewController).ContainerViewController; var firstStep = registrationVC.Steps.FirstOrDefault(); registrationVC._pageViewController.SetViewControllers(new[] { firstStep as UIViewController }, UIPageViewControllerNavigationDirection.Reverse, true, (finished) => { if (finished) { //finalStep.StepActivated(this, new MultiStepProcessStepEventArgs()); } }); })); PresentViewController(alert, animated: true, completionHandler: () => { }); } //(UIKeyboard.WillHideNotification, KeyBoardDownNotification); //Register for events View.AddGestureRecognizer(HideKeyboardGesture); NextButton.TouchUpInside += NextButton_TouchUpInside; EmailTextField.EditingDidEnd += EmailTextField_EditingDidEnd; PasswordTextField.EditingDidEnd += PasswordTextField_EditingDidEnd; FirstNameTextField.EditingDidEnd += FirstNameTextField_EditingDidEnd; LastNameTextField.EditingDidEnd += LastNameTextField_EditingDidEnd; HomeAirportTextField.EditingDidEnd += HomeAirportTextField_EditingDidEnd; CompanyTextField.EditingDidEnd += CompanyTextField_EditingDidEnd; PhoneTextField.EditingDidEnd += PhoneTextField_EditingDidEnd; EmailTextField.AttributedPlaceholder = new NSAttributedString( "EMAIL (Username)", font: EmailTextField.Font, foregroundColor: UIColor.White ); PasswordTextField.AttributedPlaceholder = new NSAttributedString( "PASSWORD", font: PasswordTextField.Font, foregroundColor: UIColor.White ); ReEmailTextField.AttributedPlaceholder = new NSAttributedString( "RE-ENTER EMAIL", font: ReEmailTextField.Font, foregroundColor: UIColor.White ); RePasswordTextField.AttributedPlaceholder = new NSAttributedString( "RE-ENTER PASSWORD", font: RePasswordTextField.Font, foregroundColor: UIColor.White ); FirstNameTextField.AttributedPlaceholder = new NSAttributedString( "FIRST NAME", font: FirstNameTextField.Font, foregroundColor: UIColor.White ); LastNameTextField.AttributedPlaceholder = new NSAttributedString( "LAST NAME", font: LastNameTextField.Font, foregroundColor: UIColor.White ); HomeAirportTextField.AttributedPlaceholder = new NSAttributedString( "HOME AIRPORT (Optional)", font: HomeAirportTextField.Font, foregroundColor: UIColor.White ); CompanyTextField.AttributedPlaceholder = new NSAttributedString( "COMPANY (Optional)", font: CompanyTextField.Font, foregroundColor: UIColor.White ); PhoneTextField.AttributedPlaceholder = new NSAttributedString( "MOBILE PHONE", font: PhoneTextField.Font, foregroundColor: UIColor.White ); }
public override void ViewDidAppear(bool animated) { base.ViewDidAppear(animated); base.ViewDidAppear(animated); // This screen name value will remain set on the tracker and sent with // hits until it is set to a new value or to null. Gai.SharedInstance.DefaultTracker.Set(GaiConstants.ScreenName, "Page View"); Gai.SharedInstance.DefaultTracker.Send(DictionaryBuilder.CreateAppView().Build()); StepActivated?.Invoke(this, new MultiStepProcessStepEventArgs { Index = StepIndex }); bool needsToReturnToPreviousStep = false; //Ensure required fields are input string validationMessage = string.Empty; if (Settings.Email == null || Settings.Email == string.Empty) { validationMessage = "Please input a valid email address"; needsToReturnToPreviousStep = true; } if (Settings.Password == null || Settings.Password == string.Empty) { validationMessage = "Please input a valid password"; needsToReturnToPreviousStep = true; } if (Settings.FirstName == null || Settings.FirstName == string.Empty) { validationMessage = "Please input your first name"; needsToReturnToPreviousStep = true; } if (Settings.LastName == null || Settings.LastName == string.Empty) { validationMessage = "Please input your last name"; needsToReturnToPreviousStep = true; } if (Settings.Phone == null || Settings.Phone == string.Empty) { validationMessage = "Please input your cell phone number"; needsToReturnToPreviousStep = true; } if (Settings.LocationPickerSelectedId == 0) { validationMessage = "Please select your location"; needsToReturnToPreviousStep = true; } if (needsToReturnToPreviousStep) { HelperMethods.SendBasicAlert("Validation", validationMessage); RegistrationViewController registrationVC = (RegistrationViewController)((MultiStepProcessHorizontalViewController)this.ParentViewController).ContainerViewController; var secondStep = registrationVC.Steps[1]; InvokeOnMainThread(() => { registrationVC._pageViewController.SetViewControllers(new[] { secondStep as UIViewController }, UIPageViewControllerNavigationDirection.Reverse, true, (finished) => { if (finished) { //finalStep.StepActivated(this, new MultiStepProcessStepEventArgs()); } }); }); } //Register events PilotSwitch.ValueChanged += PilotSwitch_ValueChanged; NextButton.TouchUpInside += NextButton_TouchUpInside; }