void ReleaseDesignerOutlets () { if (previewView != null) { previewView.Dispose (); previewView = null; } }
void ReleaseDesignerOutlets () { if (imgLabel != null) { imgLabel.Dispose (); imgLabel = null; } if (lblBrewery != null) { lblBrewery.Dispose (); lblBrewery = null; } if (lblName != null) { lblName.Dispose (); lblName = null; } if (lblNumberOfServings != null) { lblNumberOfServings.Dispose (); lblNumberOfServings = null; } if (sideColor != null) { sideColor.Dispose (); sideColor = null; } }
void ReleaseDesignerOutlets () { if (MainPage != null) { MainPage.Dispose (); MainPage = null; } }
void ReleaseDesignerOutlets() { if (placeholderView != null) { placeholderView.Dispose (); placeholderView = null; } }
void ReleaseDesignerOutlets () { if (beerSelectionRatingPlaceholder != null) { beerSelectionRatingPlaceholder.Dispose (); beerSelectionRatingPlaceholder = null; } if (btnBack != null) { btnBack.Dispose (); btnBack = null; } if (btnSend != null) { btnSend.Dispose (); btnSend = null; } if (tbxFeedback != null) { tbxFeedback.Dispose (); tbxFeedback = null; } if (userInterfaceRatingPlaceholder != null) { userInterfaceRatingPlaceholder.Dispose (); userInterfaceRatingPlaceholder = null; } }
void ReleaseDesignerOutlets () { if (bottomBar != null) { bottomBar.Dispose (); bottomBar = null; } if (btnBack != null) { btnBack.Dispose (); btnBack = null; } if (btnTakePhoto != null) { btnTakePhoto.Dispose (); btnTakePhoto = null; } if (btnToggleFlash != null) { btnToggleFlash.Dispose (); btnToggleFlash = null; } if (imgPhoto != null) { imgPhoto.Dispose (); imgPhoto = null; } if (topBar != null) { topBar.Dispose (); topBar = null; } }
void ReleaseDesignerOutlets() { if (LoginView != null) { LoginView.Dispose (); LoginView = null; } }
void ReleaseDesignerOutlets () { if (AudioUnitTableView != null) { AudioUnitTableView.Dispose (); AudioUnitTableView = null; } if (NoViewLabel != null) { NoViewLabel.Dispose (); NoViewLabel = null; } if (PlayButton != null) { PlayButton.Dispose (); PlayButton = null; } if (PresetTableView != null) { PresetTableView.Dispose (); PresetTableView = null; } if (ViewContainer != null) { ViewContainer.Dispose (); ViewContainer = null; } }
void ReleaseDesignerOutlets () { if (CameraView != null) { CameraView.Dispose (); CameraView = null; } }
void ReleaseDesignerOutlets() { if (lblEigenschapName != null) { lblEigenschapName.Dispose (); lblEigenschapName = null; } if (vwCheckBoxHolder != null) { vwCheckBoxHolder.Dispose (); vwCheckBoxHolder = null; } }
void ReleaseDesignerOutlets() { if (lblTotemName != null) { lblTotemName.Dispose (); lblTotemName = null; } if (vwCheckbox != null) { vwCheckbox.Dispose (); vwCheckbox = null; } }
void ReleaseDesignerOutlets() { if (lblProfile != null) { lblProfile.Dispose (); lblProfile = null; } if (vwCheckbox != null) { vwCheckbox.Dispose (); vwCheckbox = null; } }
void ReleaseDesignerOutlets() { if (noDataDetail != null) { noDataDetail.Dispose (); noDataDetail = null; } if (noDataTitle != null) { noDataTitle.Dispose (); noDataTitle = null; } if (tableBackgroundView != null) { tableBackgroundView.Dispose (); tableBackgroundView = null; } }
void ReleaseDesignerOutlets() { if (ImageView != null) { ImageView.Dispose (); ImageView = null; } if (SelectButton != null) { SelectButton.Dispose (); SelectButton = null; } if (SelectedOverlay != null) { SelectedOverlay.Dispose (); SelectedOverlay = null; } }
void ReleaseDesignerOutlets () { if (PlayButton != null) { PlayButton.Dispose (); PlayButton = null; } if (ProgressView != null) { ProgressView.Dispose (); ProgressView = null; } if (VideoView != null) { VideoView.Dispose (); VideoView = null; } }
void ReleaseDesignerOutlets () { if (DoubleTouchImage != null) { DoubleTouchImage.Dispose (); DoubleTouchImage = null; } if (DragImage != null) { DragImage.Dispose (); DragImage = null; } if (TouchImage != null) { TouchImage.Dispose (); TouchImage = null; } if (TouchStatus != null) { TouchStatus.Dispose (); TouchStatus = null; } if (TouchView != null) { TouchView.Dispose (); TouchView = null; } }
public RoutedViewHost(NSView targetView) { NSView viewLastAdded = null; ViewContractObservable = Observable.Return(default(string)); var vmAndContract = Observable.CombineLatest( this.WhenAnyObservable(x => x.Router.CurrentViewModel), this.WhenAnyObservable(x => x.ViewContractObservable), (vm, contract) => new { ViewModel = vm, Contract = contract, }); vmAndContract.Subscribe(x => { if (viewLastAdded != null) viewLastAdded.RemoveFromSuperview(); if (x.ViewModel == null) { if (DefaultContent != null) targetView.AddSubview(DefaultContent.View); return; } var viewLocator = ViewLocator ?? ReactiveUI.ViewLocator.Current; var view = viewLocator.ResolveView(x.ViewModel, x.Contract) ?? viewLocator.ResolveView(x.ViewModel, null); view.ViewModel = x.ViewModel; if (view is NSViewController) { viewLastAdded = ((NSViewController)view).View; } else if (view is NSView) { viewLastAdded = (NSView)view; } else { throw new Exception(String.Format("'{0}' must be an NSViewController or NSView", view.GetType().FullName)); } targetView.AddSubview(viewLastAdded); }, RxApp.DefaultExceptionHandler.OnNext); }
void ReleaseDesignerOutlets () { if (btnCheckIn != null) { btnCheckIn.Dispose (); btnCheckIn = null; } if (btnClose != null) { btnClose.Dispose (); btnClose = null; } if (lblBeerName != null) { lblBeerName.Dispose (); lblBeerName = null; } if (lblDate != null) { lblDate.Dispose (); lblDate = null; } if (ratingView != null) { ratingView.Dispose (); ratingView = null; } if (scanBarcodeView != null) { scanBarcodeView.Dispose (); scanBarcodeView = null; } if (starView != null) { starView.Dispose (); starView = null; } }
void ReleaseDesignerOutlets () { if (BoyButton != null) { BoyButton.Dispose (); BoyButton = null; } if (BubbleImg != null) { BubbleImg.Dispose (); BubbleImg = null; } if (BubbleImgTopOffset != null) { BubbleImgTopOffset.Dispose (); BubbleImgTopOffset = null; } if (ContinueBtn != null) { ContinueBtn.Dispose (); ContinueBtn = null; } if (GirlButton != null) { GirlButton.Dispose (); GirlButton = null; } if (Input != null) { Input.Dispose (); Input = null; } if (NavBarBlendView != null) { NavBarBlendView.Dispose (); NavBarBlendView = null; } if (NavBarBlendViewHeightConstraint != null) { NavBarBlendViewHeightConstraint.Dispose (); NavBarBlendViewHeightConstraint = null; } if (NickName != null) { NickName.Dispose (); NickName = null; } if (SwitchSignUpType != null) { SwitchSignUpType.Dispose (); SwitchSignUpType = null; } if (ThemeSelectorContainerView != null) { ThemeSelectorContainerView.Dispose (); ThemeSelectorContainerView = null; } }
public static void SetNeedsLayout(this _View view) { view.NeedsLayout = true; }
/// <summary> /// Add view to parent. /// </summary> /// <param name="parent">Parent view</param> /// <param name="child">Child view to add</param> public static void AddChild(this _View parent, _View child) { parent.AddSubview(child); }
void ReleaseDesignerOutlets() { if (btnAddRemoveFriend != null) { btnAddRemoveFriend.Dispose(); btnAddRemoveFriend = null; } if (btnClose != null) { btnClose.Dispose(); btnClose = null; } if (ivScoreImage != null) { ivScoreImage.Dispose(); ivScoreImage = null; } if (ivUserImage != null) { ivUserImage.Dispose(); ivUserImage = null; } if (lblFriendsInfo != null) { lblFriendsInfo.Dispose(); lblFriendsInfo = null; } if (lblRankCategory != null) { lblRankCategory.Dispose(); lblRankCategory = null; } if (lblScoreValue != null) { lblScoreValue.Dispose(); lblScoreValue = null; } if (lblUserName != null) { lblUserName.Dispose(); lblUserName = null; } if (tvFeedItems != null) { tvFeedItems.Dispose(); tvFeedItems = null; } if (vBasis != null) { vBasis.Dispose(); vBasis = null; } if (vUserInfoHeader != null) { vUserInfoHeader.Dispose(); vUserInfoHeader = null; } }
/// <summary> /// Return First parent of the view of specified T type. /// </summary> /// <typeparam name="T"></typeparam> /// <param name="view"></param> /// <returns>First parent of the view of specified T type.</returns> public static T FindFirstParent <T>(this _View view) where T : class => FindFirstParent <T>(view, includeCurrent : false);
public static void Hide(this UIView view) { view.Hidden = true; }
internal static void SendViewInitialized(this VisualElement self, TNativeView nativeView) { ViewInitialized?.Invoke(self, new ViewInitializedEventArgs { View = self, NativeView = nativeView }); }
public ViewModelViewHostLegacy(NSView targetView) { if (targetView == null) { throw new ArgumentNullException("targetView"); } NSView viewLastAdded = null; ViewContractObservable = Observable.Return(default(string)); var vmAndContract = Observable.CombineLatest( this.WhenAny(x => x.ViewModel, x => x.Value), this.WhenAnyObservable(x => x.ViewContractObservable), (vm, contract) => new { ViewModel = vm, Contract = contract, }); vmAndContract.Subscribe(x => { if (viewLastAdded != null) { viewLastAdded.RemoveFromSuperview(); } if (ViewModel == null) { if (DefaultContent != null) { targetView.AddSubview(DefaultContent.View); } return; } // get an instance of the view controller for the supplied VM + Contract var viewLocator = ViewLocator ?? ReactiveUI.ViewLocator.Current; var viewController = viewLocator.ResolveView(x.ViewModel, x.Contract); // if not found, throw if (viewController == null) { var message = String.Format("Unable to resolve view for \"{0}\"", x.ViewModel.GetType()); if (x.Contract != null) { message += String.Format(" and contract \"{0}\"", x.Contract.GetType()); } message += "."; throw new Exception(message); } // set the VM on the controller and stash a copy of the added view viewController.ViewModel = x.ViewModel; viewLastAdded = ((NSViewController)viewController).View; // sanity check, view controllers are expect to have a view if (viewLastAdded == null) { var message = string.Format("No view associated with view controller {0}.", viewController.GetType()); throw new Exception(message); } if (AddAutoLayoutConstraintsToSubView) { // see https://developer.apple.com/library/ios/documentation/userexperience/conceptual/AutolayoutPG/AdoptingAutoLayout/AdoptingAutoLayout.html viewLastAdded.TranslatesAutoresizingMaskIntoConstraints = false; } targetView.AddSubview(viewLastAdded); if (AddAutoLayoutConstraintsToSubView) { // Add edge constraints so that subview trails changes in parent addEdgeConstraint(NSLayoutAttribute.Left, targetView, viewLastAdded); addEdgeConstraint(NSLayoutAttribute.Right, targetView, viewLastAdded); addEdgeConstraint(NSLayoutAttribute.Top, targetView, viewLastAdded); addEdgeConstraint(NSLayoutAttribute.Bottom, targetView, viewLastAdded); } }); }
void addEdgeConstraint(NSLayoutAttribute edge, NSView parentView, NSView subView) { var constraint = NSLayoutConstraint.Create(subView, edge, NSLayoutRelation.Equal, parentView, edge, 1, 0); parentView.AddConstraint(constraint); }
void ReleaseDesignerOutlets() { if (btnAdd != null) { btnAdd.Dispose(); btnAdd = null; } if (btnDelete != null) { btnDelete.Dispose(); btnDelete = null; } if (btnEndDate != null) { btnEndDate.Dispose(); btnEndDate = null; } if (btnEndTime != null) { btnEndTime.Dispose(); btnEndTime = null; } if (btnRepeat != null) { btnRepeat.Dispose(); btnRepeat = null; } if (btnStartDate != null) { btnStartDate.Dispose(); btnStartDate = null; } if (btnStartTime != null) { btnStartTime.Dispose(); btnStartTime = null; } if (lbEndDate != null) { lbEndDate.Dispose(); lbEndDate = null; } if (lbRepeat != null) { lbRepeat.Dispose(); lbRepeat = null; } if (lbStartDate != null) { lbStartDate.Dispose(); lbStartDate = null; } if (lbTimes != null) { lbTimes.Dispose(); lbTimes = null; } if (lbTitle != null) { lbTitle.Dispose(); lbTitle = null; } if (tfEndDate != null) { tfEndDate.Dispose(); tfEndDate = null; } if (tfEndTime != null) { tfEndTime.Dispose(); tfEndTime = null; } if (tfRepeat != null) { tfRepeat.Dispose(); tfRepeat = null; } if (tfStartDate != null) { tfStartDate.Dispose(); tfStartDate = null; } if (tfStartTime != null) { tfStartTime.Dispose(); tfStartTime = null; } if (tfTimes != null) { tfTimes.Dispose(); tfTimes = null; } if (tfTitle != null) { tfTitle.Dispose(); tfTitle = null; } if (vContent != null) { vContent.Dispose(); vContent = null; } }
void ReleaseDesignerOutlets() { if (MKMapViewAbout != null) { MKMapViewAbout.Dispose(); MKMapViewAbout = null; } if (ScrollViewAbout != null) { ScrollViewAbout.Dispose(); ScrollViewAbout = null; } if (UIButtonAccepConditions != null) { UIButtonAccepConditions.Dispose(); UIButtonAccepConditions = null; } if (UIButtonCallUs != null) { UIButtonCallUs.Dispose(); UIButtonCallUs = null; } if (UIButtonContactSend != null) { UIButtonContactSend.Dispose(); UIButtonContactSend = null; } if (UIButtonPactiaCom != null) { UIButtonPactiaCom.Dispose(); UIButtonPactiaCom = null; } if (UIImageViewBusiness1 != null) { UIImageViewBusiness1.Dispose(); UIImageViewBusiness1 = null; } if (UIImageViewBusiness1Logo != null) { UIImageViewBusiness1Logo.Dispose(); UIImageViewBusiness1Logo = null; } if (UIImageViewBusiness2 != null) { UIImageViewBusiness2.Dispose(); UIImageViewBusiness2 = null; } if (UIImageViewBusiness2Logo != null) { UIImageViewBusiness2Logo.Dispose(); UIImageViewBusiness2Logo = null; } if (UIImageViewBusiness3 != null) { UIImageViewBusiness3.Dispose(); UIImageViewBusiness3 = null; } if (UIImageViewBusiness3Logo != null) { UIImageViewBusiness3Logo.Dispose(); UIImageViewBusiness3Logo = null; } if (UIImageViewBusiness4 != null) { UIImageViewBusiness4.Dispose(); UIImageViewBusiness4 = null; } if (UIImageViewBusiness4Logo != null) { UIImageViewBusiness4Logo.Dispose(); UIImageViewBusiness4Logo = null; } if (UIImageViewBusiness5 != null) { UIImageViewBusiness5.Dispose(); UIImageViewBusiness5 = null; } if (UIImageViewBusiness5Logo != null) { UIImageViewBusiness5Logo.Dispose(); UIImageViewBusiness5Logo = null; } if (UIImageViewBusiness6 != null) { UIImageViewBusiness6.Dispose(); UIImageViewBusiness6 = null; } if (UIImageViewBusiness6Logo != null) { UIImageViewBusiness6Logo.Dispose(); UIImageViewBusiness6Logo = null; } if (UIImageViewFacebook != null) { UIImageViewFacebook.Dispose(); UIImageViewFacebook = null; } if (UIImageViewInstagram != null) { UIImageViewInstagram.Dispose(); UIImageViewInstagram = null; } if (UIImageViewLinkedln != null) { UIImageViewLinkedln.Dispose(); UIImageViewLinkedln = null; } if (UIImageViewPactiaVideo != null) { UIImageViewPactiaVideo.Dispose(); UIImageViewPactiaVideo = null; } if (UIImageViewYoutube != null) { UIImageViewYoutube.Dispose(); UIImageViewYoutube = null; } if (UILabelBusiness1Description != null) { UILabelBusiness1Description.Dispose(); UILabelBusiness1Description = null; } if (UILabelBusiness1Title != null) { UILabelBusiness1Title.Dispose(); UILabelBusiness1Title = null; } if (UILabelBusiness2Description != null) { UILabelBusiness2Description.Dispose(); UILabelBusiness2Description = null; } if (UILabelBusiness2Title != null) { UILabelBusiness2Title.Dispose(); UILabelBusiness2Title = null; } if (UILabelBusiness3Description != null) { UILabelBusiness3Description.Dispose(); UILabelBusiness3Description = null; } if (UILabelBusiness3Title != null) { UILabelBusiness3Title.Dispose(); UILabelBusiness3Title = null; } if (UILabelBusiness4Description != null) { UILabelBusiness4Description.Dispose(); UILabelBusiness4Description = null; } if (UILabelBusiness4Title != null) { UILabelBusiness4Title.Dispose(); UILabelBusiness4Title = null; } if (UILabelBusiness5Description != null) { UILabelBusiness5Description.Dispose(); UILabelBusiness5Description = null; } if (UILabelBusiness5Title != null) { UILabelBusiness5Title.Dispose(); UILabelBusiness5Title = null; } if (UILabelBusiness6Description != null) { UILabelBusiness6Description.Dispose(); UILabelBusiness6Description = null; } if (UILabelBusiness6Title != null) { UILabelBusiness6Title.Dispose(); UILabelBusiness6Title = null; } if (UILabelPactiaTitle != null) { UILabelPactiaTitle.Dispose(); UILabelPactiaTitle = null; } if (UISwitchContactAcceptConditions != null) { UISwitchContactAcceptConditions.Dispose(); UISwitchContactAcceptConditions = null; } if (UITextFieldContactUser != null) { UITextFieldContactUser.Dispose(); UITextFieldContactUser = null; } if (UITextFileldContactBusinessName != null) { UITextFileldContactBusinessName.Dispose(); UITextFileldContactBusinessName = null; } if (UITextFileldContactEmail != null) { UITextFileldContactEmail.Dispose(); UITextFileldContactEmail = null; } if (UITextFileldContactMessage != null) { UITextFileldContactMessage.Dispose(); UITextFileldContactMessage = null; } if (UITextFileldContactPhoneNumber != null) { UITextFileldContactPhoneNumber.Dispose(); UITextFileldContactPhoneNumber = null; } if (UIViewBusiness1 != null) { UIViewBusiness1.Dispose(); UIViewBusiness1 = null; } if (UIViewBusiness2 != null) { UIViewBusiness2.Dispose(); UIViewBusiness2 = null; } if (UIViewBusiness3 != null) { UIViewBusiness3.Dispose(); UIViewBusiness3 = null; } if (UIViewBusiness4 != null) { UIViewBusiness4.Dispose(); UIViewBusiness4 = null; } if (UIViewBusiness5 != null) { UIViewBusiness5.Dispose(); UIViewBusiness5 = null; } if (UIViewBusiness6 != null) { UIViewBusiness6.Dispose(); UIViewBusiness6 = null; } if (UIViewSocial != null) { UIViewSocial.Dispose(); UIViewSocial = null; } }
void ReleaseDesignerOutlets() { if (btnSeleccionarImagen != null) { btnSeleccionarImagen.Dispose(); btnSeleccionarImagen = null; } if (ImagenEmpresa != null) { ImagenEmpresa.Dispose(); ImagenEmpresa = null; } if (imgPais != null) { imgPais.Dispose(); imgPais = null; } if (lblPais != null) { lblPais.Dispose(); lblPais = null; } if (txtAño != null) { txtAño.Dispose(); txtAño = null; } if (txtCiudad != null) { txtCiudad.Dispose(); txtCiudad = null; } if (txtCompañia != null) { txtCompañia.Dispose(); txtCompañia = null; } if (txtCorreo != null) { txtCorreo.Dispose(); txtCorreo = null; } if (txtMes != null) { txtMes.Dispose(); txtMes = null; } if (txtPuesto != null) { txtPuesto.Dispose(); txtPuesto = null; } if (txtWebSite != null) { txtWebSite.Dispose(); txtWebSite = null; } if (vwAño != null) { vwAño.Dispose(); vwAño = null; } if (vwCiudad != null) { vwCiudad.Dispose(); vwCiudad = null; } if (vwCompañia != null) { vwCompañia.Dispose(); vwCompañia = null; } if (vwCorreo != null) { vwCorreo.Dispose(); vwCorreo = null; } if (vwMes != null) { vwMes.Dispose(); vwMes = null; } if (vwPais != null) { vwPais.Dispose(); vwPais = null; } if (vwPuesto != null) { vwPuesto.Dispose(); vwPuesto = null; } if (vwWebSite != null) { vwWebSite.Dispose(); vwWebSite = null; } }
void ReleaseDesignerOutlets() { if (bottomBarHeight != null) { bottomBarHeight.Dispose (); bottomBarHeight = null; } if (btnMore != null) { btnMore.Dispose (); btnMore = null; } if (btnReturn != null) { btnReturn.Dispose (); btnReturn = null; } if (btnSearch != null) { btnSearch.Dispose (); btnSearch = null; } if (btnVind != null) { btnVind.Dispose (); btnVind = null; } if (imgMore != null) { imgMore.Dispose (); imgMore = null; } if (imgReturn != null) { imgReturn.Dispose (); imgReturn = null; } if (imgSearch != null) { imgSearch.Dispose (); imgSearch = null; } if (imgVind != null) { imgVind.Dispose (); imgVind = null; } if (lblNumberSelected != null) { lblNumberSelected.Dispose (); lblNumberSelected = null; } if (lblTitle != null) { lblTitle.Dispose (); lblTitle = null; } if (tblEigenschappen != null) { tblEigenschappen.Dispose (); tblEigenschappen = null; } if (txtSearch != null) { txtSearch.Dispose (); txtSearch = null; } if (vwBottomBar != null) { vwBottomBar.Dispose (); vwBottomBar = null; } if (vwSearchBar != null) { vwSearchBar.Dispose (); vwSearchBar = null; } }
public static bool IsVisible(this UIView view) { return(view.Hidden == false); }
/// <summary> /// Displays all the visual descendants of <paramref name="view"/> for diagnostic purposes. /// </summary> public static string ShowDescendants(this _View view, StringBuilder sb = null, string spacing = "", _View viewOfInterest = null) { sb = sb ?? new StringBuilder(); AppendView(view); spacing += " "; foreach (var child in view.Subviews) { ShowDescendants(child, sb, spacing, viewOfInterest); } return(sb.ToString()); StringBuilder AppendView(_View innerView) { var name = (innerView as IFrameworkElement)?.Name; var namePart = string.IsNullOrEmpty(name) ? "" : $"-'{name}'"; var uiElement = innerView as UIElement; var desiredSize = uiElement?.DesiredSize.ToString() ?? "<native/unk>"; var fe = innerView as IFrameworkElement; return(sb .Append(spacing) .Append(innerView == viewOfInterest ? "*>" : ">") .Append(innerView.ToString() + namePart) .Append($"-({innerView.Frame.Width}x{innerView.Frame.Height})@({innerView.Frame.X},{innerView.Frame.Y})") .Append($" d:{desiredSize}") #if __IOS__ .Append($" {(innerView.Hidden ? "Hidden" : "Visible")}") #endif .Append(fe != null ? $" HA={fe.HorizontalAlignment},VA={fe.VerticalAlignment}" : "") .Append(fe != null && fe.Margin != default ? $" Margin={fe.Margin}" : "") .Append(fe != null && fe.TryGetBorderThickness(out var b) && b != default ? $" Border={b}" : "") .Append(fe != null && fe.TryGetPadding(out var p) && p != default ? $" Padding={p}" : "") .Append(uiElement != null ? $" DesiredSize={uiElement.DesiredSize}" : "") .Append(uiElement?.NeedsClipToSlot ?? false ? " CLIPPED_TO_SLOT" : "") .Append(innerView is TextBlock textBlock ? $" Text=\"{textBlock.Text}\"" : "") .AppendLine()); } }
public static void Show(this UIView view) { view.Hidden = false; }
void ReleaseDesignerOutlets() { if (ScrollViewPortfolio != null) { ScrollViewPortfolio.Dispose(); ScrollViewPortfolio = null; } if (UILabelPortfolioBusinessContent1 != null) { UILabelPortfolioBusinessContent1.Dispose(); UILabelPortfolioBusinessContent1 = null; } if (UILabelPortfolioBusinessContent2 != null) { UILabelPortfolioBusinessContent2.Dispose(); UILabelPortfolioBusinessContent2 = null; } if (UILabelPortfolioBusinessContent3 != null) { UILabelPortfolioBusinessContent3.Dispose(); UILabelPortfolioBusinessContent3 = null; } if (UILabelPortfolioBusinessContent4 != null) { UILabelPortfolioBusinessContent4.Dispose(); UILabelPortfolioBusinessContent4 = null; } if (UILabelPortfolioBusinessContent5 != null) { UILabelPortfolioBusinessContent5.Dispose(); UILabelPortfolioBusinessContent5 = null; } if (UILabelPortfolioBusinessContent6 != null) { UILabelPortfolioBusinessContent6.Dispose(); UILabelPortfolioBusinessContent6 = null; } if (UILabelPortfolioBusinessTitle1 != null) { UILabelPortfolioBusinessTitle1.Dispose(); UILabelPortfolioBusinessTitle1 = null; } if (UILabelPortfolioBusinessTitle2 != null) { UILabelPortfolioBusinessTitle2.Dispose(); UILabelPortfolioBusinessTitle2 = null; } if (UILabelPortfolioBusinessTitle3 != null) { UILabelPortfolioBusinessTitle3.Dispose(); UILabelPortfolioBusinessTitle3 = null; } if (UILabelPortfolioBusinessTitle4 != null) { UILabelPortfolioBusinessTitle4.Dispose(); UILabelPortfolioBusinessTitle4 = null; } if (UILabelPortfolioBusinessTitle5 != null) { UILabelPortfolioBusinessTitle5.Dispose(); UILabelPortfolioBusinessTitle5 = null; } if (UILabelPortfolioBusinessTitle6 != null) { UILabelPortfolioBusinessTitle6.Dispose(); UILabelPortfolioBusinessTitle6 = null; } if (UILabelPortfolioTitle != null) { UILabelPortfolioTitle.Dispose(); UILabelPortfolioTitle = null; } if (UIViewPortfolioBusiness1 != null) { UIViewPortfolioBusiness1.Dispose(); UIViewPortfolioBusiness1 = null; } if (UIViewPortfolioBusiness2 != null) { UIViewPortfolioBusiness2.Dispose(); UIViewPortfolioBusiness2 = null; } if (UIViewPortfolioBusiness3 != null) { UIViewPortfolioBusiness3.Dispose(); UIViewPortfolioBusiness3 = null; } if (UIViewPortfolioBusiness4 != null) { UIViewPortfolioBusiness4.Dispose(); UIViewPortfolioBusiness4 = null; } if (UIViewPortfolioBusiness5 != null) { UIViewPortfolioBusiness5.Dispose(); UIViewPortfolioBusiness5 = null; } if (UIViewPortfolioBusiness6 != null) { UIViewPortfolioBusiness6.Dispose(); UIViewPortfolioBusiness6 = null; } }
/// <inheritdoc/> public override void WillMoveToSuperview(NSView newsuper)
void ReleaseDesignerOutlets() { if (btnCloseBg != null) { btnCloseBg.Dispose(); btnCloseBg = null; } if (btnCloseBgBottom != null) { btnCloseBgBottom.Dispose(); btnCloseBgBottom = null; } if (CloseButton != null) { CloseButton.Dispose(); CloseButton = null; } if (MainView != null) { MainView.Dispose(); MainView = null; } if (MessageText != null) { MessageText.Dispose(); MessageText = null; } if (PointsText != null) { PointsText.Dispose(); PointsText = null; } if (RoundImage != null) { RoundImage.Dispose(); RoundImage = null; } if (TableHeightConstraint != null) { TableHeightConstraint.Dispose(); TableHeightConstraint = null; } if (TableView != null) { TableView.Dispose(); TableView = null; } if (TopViewContainer != null) { TopViewContainer.Dispose(); TopViewContainer = null; } if (vWhiteBackground != null) { vWhiteBackground.Dispose(); vWhiteBackground = null; } }
public static void RoundCorners(this _View thisButton, float radius = 2, float borderThickness = 0, _Color borderColor = null) { thisButton.AddBorder(borderThickness, borderColor); thisButton.Layer.CornerRadius = radius; }
/// <summary> /// Invalidates the layout of the selected view. For iOS, calls the SetNeedsLayout method. /// </summary> /// <param name="view">The view to invalidate.</param> public static void InvalidateMeasure(this _View view) { view.SetNeedsLayout(); }
void ReleaseDesignerOutlets() { if (addressLabel != null) { addressLabel.Dispose(); addressLabel = null; } if (addressLabelView != null) { addressLabelView.Dispose(); addressLabelView = null; } if (btnBack != null) { btnBack.Dispose(); btnBack = null; } if (btnChangePassword != null) { btnChangePassword.Dispose(); btnChangePassword = null; } if (btnEditProfileImage != null) { btnEditProfileImage.Dispose(); btnEditProfileImage = null; } if (btnFilter != null) { btnFilter.Dispose(); btnFilter = null; } if (emailLableView != null) { emailLableView.Dispose(); emailLableView = null; } if (img_lock_icon != null) { img_lock_icon.Dispose(); img_lock_icon = null; } if (img_provider_icon != null) { img_provider_icon.Dispose(); img_provider_icon = null; } if (lblAddress != null) { lblAddress.Dispose(); lblAddress = null; } if (lblConsumerToProvider != null) { lblConsumerToProvider.Dispose(); lblConsumerToProvider = null; } if (lblEmail != null) { lblEmail.Dispose(); lblEmail = null; } if (lblEmailAddress != null) { lblEmailAddress.Dispose(); lblEmailAddress = null; } if (lblMobileNumber != null) { lblMobileNumber.Dispose(); lblMobileNumber = null; } if (lblName != null) { lblName.Dispose(); lblName = null; } if (lblTitle != null) { lblTitle.Dispose(); lblTitle = null; } if (ProfileHeaderView != null) { ProfileHeaderView.Dispose(); ProfileHeaderView = null; } if (ProfileImage != null) { ProfileImage.Dispose(); ProfileImage = null; } if (ProfileWall != null) { ProfileWall.Dispose(); ProfileWall = null; } if (UserProfileView != null) { UserProfileView.Dispose(); UserProfileView = null; } }
/// <summary> /// Invalidates the layout of the selected view. For iOS, calls the SetNeedsLayout method. /// </summary> /// <param name="view">The view to invalidate.</param> public static void InvalidateArrange(this _View view) { InvalidateMeasure(view); }
public static T AddTo <T>(this T thisView, _View toAddTo) where T : _View { toAddTo.AddSubview(thisView); return(thisView); }
public static void AddToViewBottom(this _View thisView, _View toAddTo) { toAddTo.AddToBottom(thisView); }
public ViewModelViewHost(NSView targetView) { if (targetView == null) throw new ArgumentNullException("targetView"); NSView viewLastAdded = null; ViewContractObservable = Observable.Return(default(string)); var vmAndContract = Observable.CombineLatest( this.WhenAny(x => x.ViewModel, x => x.Value), this.WhenAnyObservable(x => x.ViewContractObservable), (vm, contract) => new { ViewModel = vm, Contract = contract, }); vmAndContract.Subscribe(x => { if (viewLastAdded != null) viewLastAdded.RemoveFromSuperview(); if (ViewModel == null) { if (DefaultContent != null) targetView.AddSubview(DefaultContent.View); return; } // get an instance of the view controller for the supplied VM + Contract var viewLocator = ViewLocator ?? ReactiveUI.ViewLocator.Current; var viewController = viewLocator.ResolveView(x.ViewModel, x.Contract); // if not found, throw if (viewController == null) { var message = String.Format("Unable to resolve view for \"{0}\"", x.ViewModel.GetType()); if (x.Contract != null) { message += String.Format(" and contract \"{0}\"", x.Contract.GetType()); } message += "."; throw new Exception(message); } // set the VM on the controller and stash a copy of the added view viewController.ViewModel = x.ViewModel; viewLastAdded = ((NSViewController)viewController).View; // sanity check, view controllers are expect to have a view if (viewLastAdded == null) { var message = string.Format("No view associated with view controller {0}.", viewController.GetType()); throw new Exception(message); } if (AddAutoLayoutConstraintsToSubView) { // see https://developer.apple.com/library/ios/documentation/userexperience/conceptual/AutolayoutPG/AdoptingAutoLayout/AdoptingAutoLayout.html viewLastAdded.TranslatesAutoresizingMaskIntoConstraints = false; } targetView.AddSubview(viewLastAdded); if (AddAutoLayoutConstraintsToSubView) { // Add edge constraints so that subview trails changes in parent addEdgeConstraint(NSLayoutAttribute.Left, targetView, viewLastAdded); addEdgeConstraint(NSLayoutAttribute.Right, targetView, viewLastAdded); addEdgeConstraint(NSLayoutAttribute.Top, targetView, viewLastAdded); addEdgeConstraint(NSLayoutAttribute.Bottom, targetView, viewLastAdded); } }); }
void ReleaseDesignerOutlets () { if (backgroundImage != null) { backgroundImage.Dispose (); backgroundImage = null; } if (btnMore != null) { btnMore.Dispose (); btnMore = null; } if (btnSettings != null) { btnSettings.Dispose (); btnSettings = null; } if (followingLabel != null) { followingLabel.Dispose (); followingLabel = null; } if (follwersLabel != null) { follwersLabel.Dispose (); follwersLabel = null; } if (locationLabel != null) { locationLabel.Dispose (); locationLabel = null; } if (nameLabel != null) { nameLabel.Dispose (); nameLabel = null; } if (profileImage != null) { profileImage.Dispose (); profileImage = null; } if (whiteView != null) { whiteView.Dispose (); whiteView = null; } }
public TableLayoutHandler() { #if OSX Control = new MacEventView { Handler = this }; #elif IOS Control = new NSView(); #endif }
public static nfloat StackSubViews(this _View thisView, float topPadding, float spaceBetweenElements) { return(ViewHelper.StackSubViews(thisView, topPadding, spaceBetweenElements)); }
public static nfloat StackSubViews(this _View thisView) { return(ViewHelper.StackSubViews(thisView.Subviews)); }
public virtual SizeRequest GetDesiredSize(double widthConstraint, double heightConstraint) { return(NativeView.GetSizeRequest(widthConstraint, heightConstraint)); }
public static bool HasParent(this _View view) { return(view.Superview != null); }
void ReleaseDesignerOutlets() { if (_birthdateValueBnWidthConstraint != null) { _birthdateValueBnWidthConstraint.Dispose(); _birthdateValueBnWidthConstraint = null; } if (_birthdayValueBnLeadingConstraint != null) { _birthdayValueBnLeadingConstraint.Dispose(); _birthdayValueBnLeadingConstraint = null; } if (_headerConstraintHeight != null) { _headerConstraintHeight.Dispose(); _headerConstraintHeight = null; } if (_headerConstraintTop != null) { _headerConstraintTop.Dispose(); _headerConstraintTop = null; } if (_imageScrollConstraintHeight != null) { _imageScrollConstraintHeight.Dispose(); _imageScrollConstraintHeight = null; } if (_personalSiteView != null) { _personalSiteView.Dispose(); _personalSiteView = null; } if (activityIndicator != null) { activityIndicator.Dispose(); activityIndicator = null; } if (address_forwBn != null) { address_forwBn.Dispose(); address_forwBn = null; } if (address_imageBn != null) { address_imageBn.Dispose(); address_imageBn = null; } if (address_mainBn != null) { address_mainBn.Dispose(); address_mainBn = null; } if (backBn != null) { backBn.Dispose(); backBn = null; } if (birthday_forwBn != null) { birthday_forwBn.Dispose(); birthday_forwBn = null; } if (birthday_mainBn != null) { birthday_mainBn.Dispose(); birthday_mainBn = null; } if (birthday_valueBn != null) { birthday_valueBn.Dispose(); birthday_valueBn = null; } if (CardNameTextField != null) { CardNameTextField.Dispose(); CardNameTextField = null; } if (confirm_pickerBn != null) { confirm_pickerBn.Dispose(); confirm_pickerBn = null; } if (continueBn != null) { continueBn.Dispose(); continueBn = null; } if (date_picker != null) { date_picker.Dispose(); date_picker = null; } if (DegreeTextField != null) { DegreeTextField.Dispose(); DegreeTextField = null; } if (EmailTextField != null) { EmailTextField.Dispose(); EmailTextField = null; } if (headerLabel != null) { headerLabel.Dispose(); headerLabel = null; } if (headerView != null) { headerView.Dispose(); headerView = null; } if (HomePhoneTextField != null) { HomePhoneTextField.Dispose(); HomePhoneTextField = null; } if (imageScroll != null) { imageScroll.Dispose(); imageScroll = null; } if (NameMiddleNameTextField != null) { NameMiddleNameTextField.Dispose(); NameMiddleNameTextField = null; } if (PhoneTextField != null) { PhoneTextField.Dispose(); PhoneTextField = null; } if (pickPhotoBn != null) { pickPhotoBn.Dispose(); pickPhotoBn = null; } if (reset_pickerBn != null) { reset_pickerBn.Dispose(); reset_pickerBn = null; } if (resetBn != null) { resetBn.Dispose(); resetBn = null; } if (scrollView != null) { scrollView.Dispose(); scrollView = null; } if (SiteTextField != null) { SiteTextField.Dispose(); SiteTextField = null; } if (social_netw_forwBn != null) { social_netw_forwBn.Dispose(); social_netw_forwBn = null; } if (social_netw_imageBn != null) { social_netw_imageBn.Dispose(); social_netw_imageBn = null; } if (social_netw_mainBn != null) { social_netw_mainBn.Dispose(); social_netw_mainBn = null; } if (SurnameTextField != null) { SurnameTextField.Dispose(); SurnameTextField = null; } if (view_for_picker != null) { view_for_picker.Dispose(); view_for_picker = null; } }
void ReleaseDesignerOutlets() { if (btnA != null) { btnA.Dispose (); btnA = null; } if (btnB != null) { btnB.Dispose (); btnB = null; } if (btnBack != null) { btnBack.Dispose (); btnBack = null; } if (btnC != null) { btnC.Dispose (); btnC = null; } if (btnNext != null) { btnNext.Dispose (); btnNext = null; } if (btnPreview != null) { btnPreview.Dispose (); btnPreview = null; } if (imageViewQues != null) { imageViewQues.Dispose (); imageViewQues = null; } if (labelTitle != null) { labelTitle.Dispose (); labelTitle = null; } if (lableQues != null) { lableQues.Dispose (); lableQues = null; } if (topView != null) { topView.Dispose (); topView = null; } }
/// <summary> /// Provides the desired size of the element, from the last measure phase. /// </summary> /// <param name="view">The element to get the measured with</param> /// <returns>The measured size</returns> Size ILayouter.GetDesiredSize(View view) { return(DesiredChildSize(view)); }
void ReleaseDesignerOutlets() { if (btnBackhome != null) { btnBackhome.Dispose (); btnBackhome = null; } if (btnRestart != null) { btnRestart.Dispose (); btnRestart = null; } if (btnReview != null) { btnReview.Dispose (); btnReview = null; } if (lableCorrect != null) { lableCorrect.Dispose (); lableCorrect = null; } if (lableIncorrect != null) { lableIncorrect.Dispose (); lableIncorrect = null; } if (lableResult != null) { lableResult.Dispose (); lableResult = null; } if (TopView != null) { TopView.Dispose (); TopView = null; } }
/// <summary> /// Finds first responder in view /// </summary> /// <param name="view">View</param> /// <returns>First responder view</returns> public static _View FindFirstResponder(this _View view) => Uno.Extensions.UIViewExtensions.FindFirstResponder(view);