private void Init() { ListView = new ExtendedListView { ItemsSource = Folders, ItemTemplate = new DataTemplate(() => new SettingsFolderListViewCell(this)) }; if (Device.RuntimePlatform == Device.iOS || Device.RuntimePlatform == Device.UWP) { ToolbarItems.Add(new DismissModalToolBarItem(this, AppResources.Close)); } var fabLayout = new FabLayout(ListView); if (Device.RuntimePlatform == Device.Android) { Fab = new Fab(fabLayout, "plus.png", async(sender, args) => { await Navigation.PushForDeviceAsync(new SettingsAddFolderPage()); }); ListView.BottomPadding = 50; } else { AddItem = new AddFolderToolBarItem(this); ToolbarItems.Add(AddItem); } Title = AppResources.Folders; Content = fabLayout; }
private void Init() { SearchItem = new SearchToolBarItem(this); AddCipherItem = new AddCipherToolBarItem(this, null); ToolbarItems.Add(SearchItem); ToolbarItems.Add(AddCipherItem); ListView = new ExtendedListView(ListViewCachingStrategy.RecycleElement) { IsGroupingEnabled = true, ItemsSource = PresentationSections, HasUnevenRows = true, GroupHeaderTemplate = new DataTemplate(() => new SectionHeaderViewCell( nameof(Section<Grouping>.Name), nameof(Section<Grouping>.Count), new Thickness(16, 12))), ItemTemplate = new GroupingOrCipherDataTemplateSelector(this) }; if(Device.RuntimePlatform == Device.iOS) { ListView.RowHeight = -1; } var noDataLabel = new Label { Text = AppResources.NoItems, HorizontalTextAlignment = TextAlignment.Center, FontSize = Device.GetNamedSize(NamedSize.Small, typeof(Label)), Style = (Style)Application.Current.Resources["text-muted"] }; var addCipherButton = new ExtendedButton { Text = AppResources.AddAnItem, Command = new Command(() => Helpers.AddCipher(this, null)), Style = (Style)Application.Current.Resources["btn-primaryAccent"] }; NoDataStackLayout = new StackLayout { Children = { noDataLabel, addCipherButton }, VerticalOptions = LayoutOptions.CenterAndExpand, Padding = new Thickness(20, 0), Spacing = 20 }; LoadingIndicator = new ActivityIndicator { IsRunning = true }; if(Device.RuntimePlatform != Device.UWP) { LoadingIndicator.VerticalOptions = LayoutOptions.CenterAndExpand; LoadingIndicator.HorizontalOptions = LayoutOptions.Center; } Content = LoadingIndicator; Title = AppResources.MyVault; }
/// <summary> /// Initializes a new instance of the <see cref="SelectionModel"/> class. /// </summary> /// <param name="pParent">The model parent.</param> public SelectionModel(ExtendedListView pParent) { this.mParent = pParent; this.mCanSelect = true; this.mSelectedViewModels = new ObservableCollection <IHierarchicalItemViewModel>(); this.Anchor = null; }
public MainPage() { InitializeComponent(); this.BindingContext = new MainPageViewModel(); var list = ExtendedListView.ItemsSource as ObservableCollection <int>; ExtendedListView.ScrollTo(list.Last(), ScrollToPosition.MakeVisible, false); }
/// <summary> /// Initializes a new instance of the <see cref="ColumnResizeBehavior"/> class. /// </summary> /// <param name="pListView">The managed list view.</param> public ColumnResizeBehavior(ExtendedListView pListView) { if (pListView == null) { throw new ArgumentNullException("pListView"); } this.mVerticalScrollBarVisibility = ScrollBarVisibility.Auto; this.mListView = pListView; }
private void Init() { var noDataLabel = new Label { Text = string.Format(AppResources.NoItemsForUri, _name ?? "--"), HorizontalTextAlignment = TextAlignment.Center, FontSize = Device.GetNamedSize(NamedSize.Small, typeof(Label)), Style = (Style)Application.Current.Resources["text-muted"] }; var addCipherButton = new ExtendedButton { Text = AppResources.AddAnItem, Command = new Command(() => AddCipherAsync()), Style = (Style)Application.Current.Resources["btn-primaryAccent"] }; NoDataStackLayout = new StackLayout { Children = { noDataLabel, addCipherButton }, VerticalOptions = LayoutOptions.CenterAndExpand, Padding = new Thickness(20, 0), Spacing = 20 }; SearchItem = new SearchToolBarItem(this); ToolbarItems.Add(SearchItem); ListView = new ExtendedListView(ListViewCachingStrategy.RecycleElement) { IsGroupingEnabled = true, ItemsSource = PresentationCiphersGroup, HasUnevenRows = true, GroupHeaderTemplate = new DataTemplate(() => new SectionHeaderViewCell( nameof(Section <AutofillCipher> .Name))), ItemTemplate = new DataTemplate(() => new VaultListViewCell( (VaultListPageModel.Cipher c) => Helpers.CipherMoreClickedAsync(this, c, true))) }; if (Device.RuntimePlatform == Device.iOS) { ListView.RowHeight = -1; } Title = string.Format(AppResources.ItemsForUri, _name ?? "--"); LoadingIndicator = new ActivityIndicator { IsRunning = true, VerticalOptions = LayoutOptions.CenterAndExpand, HorizontalOptions = LayoutOptions.Center }; Content = LoadingIndicator; }
public AccionesDTViewModel() { ExtendedListView ContenidoAcciones = new ExtendedListView { Margin = 0, IsPullToRefreshEnabled = false, BackgroundColor = Color.Transparent, ItemTemplate = new DataTemplate(typeof(AppsActionsDTViewModel)), HasUnevenRows = false, RowHeight = 90, SeparatorColor = Color.FromHex("E5E5E5"), ItemsSource = actions }; Content = ContenidoAcciones; }
private void Init() { AddItem = new AddFolderToolBarItem(this); ToolbarItems.Add(AddItem); ListView = new ExtendedListView { ItemsSource = Folders, ItemTemplate = new DataTemplate(() => new SettingsFolderListViewCell(this)) }; if (Device.RuntimePlatform == Device.iOS || Device.RuntimePlatform == Device.UWP) { ToolbarItems.Add(new DismissModalToolBarItem(this, AppResources.Close)); } Title = AppResources.Folders; Content = ListView; }
protected override void OnElementChanged(ElementChangedEventArgs <Xamarin.Forms.ListView> e) { base.OnElementChanged(e); if (e.OldElement == _myListView) { _myListView = null; } if (e.NewElement is ExtendedListView) { _myListView = Element as ExtendedListView; _myListView.LastScrollDirection = ExtendedListView.NoPreviousScroll; _myListView.AtStartOfList = true; _attached = true; Control.Scroll += Control_Scroll; } }
public async void displayAsync() { var nativeListView2 = new ExtendedListView() { BackgroundColor = Color.White }; var MainView = new StackLayout() { BackgroundColor = LibInfo.Backgroundcolor }; CalenderEvents = await dataStore.GetCalendarAsync(); Enity2 = new List <EntityClass>(); DateTime before = DateTime.MinValue; listday = new List <SpecialDate>(); foreach (var Event in CalenderEvents) { DateTime result; if (DateTime.TryParse(Event.start, out result)) { if (!before.Date.Equals(result.Date)) { before = result.Date; listday.Add(new SpecialDate(result.Date) { FontSize = 30, TextColor = Color.Blue, Selectable = true }); } } var Children = new List <EntityClass>(); Children.Add(new EntityClass { Title = Event.description }); Enity2.Add(new EntityClass { Title = String.Format("{0}: {1}", result.ToString("t"), Event.summary), Description = result.Date.ToString(), ChildItems = Children }); } calendar = new Calendar { MinDate = DateTime.Now, DisableAllDates = false, MultiSelectDates = false, SelectedTextColor = Color.Fuchsia, StartDate = DateTime.Today, SpecialDates = listday, BackgroundColor = Color.White }; MainView.Padding = new Thickness(5, Device.OS == TargetPlatform.iOS ? 25 : 5, 5, 5); MainView.Children.Add(calendar); calendar.DateClicked += (sender, e) => { System.Diagnostics.Debug.WriteLine(calendar.SelectedDates); //REQUIRED: To share a scrollable view with other views in a StackLayout, it should have a VerticalOptions of FillAndExpand. if (MainView.Children.Contains(nativeListView2)) { MainView.Children.Remove(nativeListView2); nativeListView2 = new ExtendedListView() { BackgroundColor = Color.White }; } nativeListView2.VerticalOptions = LayoutOptions.FillAndExpand; var select = new List <EntityClass>(); select = Enity2.FindAll(r => r.Description.Contains(e.DateTime.Date.ToString())); nativeListView2.Items = select; MainView.Children.Add(nativeListView2); }; if (Device.OS == TargetPlatform.iOS) { MainView.BackgroundColor = Color.White; ScrollView scrollView = new ScrollView() { Content = MainView, Padding = new Thickness(5, 0, 5, 0) }; Content = scrollView; } else { Content = MainView; } }
private void Init() { _canUseAttachments = _cryptoService.EncKey != null; SubscribeFileResult(true); var selectButton = new ExtendedButton { Text = AppResources.ChooseFile, Command = new Command(async() => await _deviceActionService.SelectFileAsync()), Style = (Style)Application.Current.Resources["btn-primaryAccent"], FontSize = Device.GetNamedSize(NamedSize.Medium, typeof(Button)) }; FileLabel = new Label { Text = AppResources.NoFileChosen, Style = (Style)Application.Current.Resources["text-muted"], FontSize = Device.GetNamedSize(NamedSize.Small, typeof(Label)), HorizontalTextAlignment = TextAlignment.Center }; AddNewStackLayout = new StackLayout { Children = { selectButton, FileLabel }, Orientation = StackOrientation.Vertical, Padding = new Thickness(20, Helpers.OnPlatform(iOS: 10, Android: 20), 20, 20), VerticalOptions = LayoutOptions.Start }; NewTable = new ExtendedTableView { Intent = TableIntent.Settings, HasUnevenRows = true, NoFooter = true, EnableScrolling = false, EnableSelection = false, VerticalOptions = LayoutOptions.Start, Margin = new Thickness(0, Helpers.OnPlatform(iOS: 10, Android: 30), 0, 0), WrappingStackLayout = () => NoDataStackLayout, Root = new TableRoot { new TableSection(AppResources.AddNewAttachment) { new ExtendedViewCell { View = AddNewStackLayout, BackgroundColor = Color.White } } } }; ListView = new ExtendedListView(ListViewCachingStrategy.RecycleElement) { ItemsSource = PresentationAttchments, HasUnevenRows = true, ItemTemplate = new DataTemplate(() => new VaultAttachmentsViewCell()), VerticalOptions = LayoutOptions.FillAndExpand }; NoDataLabel = new Label { Text = AppResources.NoAttachments, HorizontalTextAlignment = TextAlignment.Center, FontSize = Device.GetNamedSize(NamedSize.Small, typeof(Label)), Style = (Style)Application.Current.Resources["text-muted"] }; NoDataStackLayout = new RedrawableStackLayout { VerticalOptions = LayoutOptions.Start, Spacing = 0, Margin = new Thickness(0, 40, 0, 0) }; SaveToolbarItem = new ToolbarItem(AppResources.Save, Helpers.ToolbarImage("envelope.png"), async() => { if (_lastAction.LastActionWasRecent() || _cipher == null) { return; } _lastAction = DateTime.UtcNow; if (!_canUseAttachments) { await ShowUpdateKeyAsync(); return; } if (!_connectivity.IsConnected) { AlertNoConnection(); return; } if (_fileBytes == null) { await DisplayAlert(AppResources.AnErrorHasOccurred, string.Format(AppResources.ValidationFieldRequired, AppResources.File), AppResources.Ok); return; } await _deviceActionService.ShowLoadingAsync(AppResources.Saving); var saveTask = await _cipherService.EncryptAndSaveAttachmentAsync(_cipher, _fileBytes, FileLabel.Text); await _deviceActionService.HideLoadingAsync(); if (saveTask.Succeeded) { _fileBytes = null; FileLabel.Text = AppResources.NoFileChosen; _deviceActionService.Toast(AppResources.AttachementAdded); _googleAnalyticsService.TrackAppEvent("AddedAttachment"); await LoadAttachmentsAsync(); } else if (saveTask.Errors.Count() > 0) { await DisplayAlert(AppResources.AnErrorHasOccurred, saveTask.Errors.First().Message, AppResources.Ok); } else { await DisplayAlert(null, AppResources.AnErrorHasOccurred, AppResources.Ok); } }, ToolbarItemOrder.Default, 0); Title = AppResources.Attachments; Content = ListView; if (Device.RuntimePlatform == Device.iOS) { ListView.RowHeight = -1; NewTable.RowHeight = -1; NewTable.EstimatedRowHeight = 44; NewTable.HeightRequest = 180; ListView.BackgroundColor = Color.Transparent; ToolbarItems.Add(new DismissModalToolBarItem(this, AppResources.Close)); } else if (Device.RuntimePlatform == Device.Android) { ListView.BottomPadding = 50; } }
public ServicioSasociadoDetalle(servicios Servicio) { NavigationPage.SetBackButtonTitle(this, Servicio.alias.ToUpper()); MessagingCenter.Subscribe <FacturasDTModeloVista>(this, "PDF", async(sender) => { await Navigation.PushAsync(new FacturaVista()); }); Label Bienvenida = new Label { BackgroundColor = Color.Transparent, Margin = new Thickness((App.DisplayScreenWidth / 12.533333333333333), 0, 0, 0), HorizontalTextAlignment = TextAlignment.Start, HorizontalOptions = LayoutOptions.FillAndExpand, FontFamily = Device.OnPlatform("Montserrat-Bold", "Montserrat-Bold", null), TextColor = Color.White, FontSize = (App.DisplayScreenWidth / 15.04) }; Bienvenida.Text = Servicio.alias; continuar = new CircleImage { BackgroundColor = Color.Transparent, BorderColor = Color.FromHex("f6f6f6"), BorderThickness = Convert.ToInt32(App.DisplayScreenWidth / 107.428571428571429), Aspect = Aspect.AspectFill, Source = "iContinuarA" }; TapGestureRecognizer continuarTAP = new TapGestureRecognizer { NumberOfTapsRequired = 1 }; continuarTAP.Tapped += ContinuarTAP_Tapped; continuar.GestureRecognizers.Add(continuarTAP); RelativeLayout CC = new RelativeLayout() { Padding = 0, WidthRequest = App.DisplayScreenWidth, HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.Start, BackgroundColor = Color.Transparent, }; CC.Children.Add(new Image { Aspect = Aspect.Fill, Source = "header", HeightRequest = App.DisplayScreenHeight / 2.889679715302491 }, Constraint.Constant(0), Constraint.Constant(-60), Constraint.Constant(App.DisplayScreenWidth), Constraint.Constant(App.DisplayScreenHeight / 2.889679715302491) ); CC.Children.Add(Bienvenida, Constraint.Constant(0), Constraint.Constant(App.DisplayScreenHeight / 10.15), Constraint.Constant(App.DisplayScreenWidth) ); CC.Children.Add(continuar, Constraint.Constant((App.DisplayScreenWidth / 1.540983606557377)), Constraint.Constant(App.DisplayScreenHeight / 4.69364161849711), Constraint.Constant(App.DisplayScreenHeight / 12.492307692307692), Constraint.Constant(App.DisplayScreenHeight / 12.492307692307692) ); facturas = new List <facturas> { new facturas { alias = "FACTURA MARZO 2018", proveedor = "EEGSA", categoria = string.Empty, saldo = !Servicio.alias.Equals("CASA PROPIA")?"TOTAL: Q.2,150.00":"TOTAL: Q.852.00", aviso = string.Empty, vencimiento = "Ven: 01 - 03 - 2018", background = "iFacturaBackground", iconEstado = "iNoSeleccionado", backgroundColor = Color.FromHex("BFBFBF") }, }; if (!Servicio.alias.Equals("CASA PROPIA")) { facturas.Add(new facturas { alias = "FACTURA ABRIL 2018", proveedor = "EEGSA", categoria = string.Empty, saldo = "TOTAL: Q.2,150.00", aviso = string.Empty, vencimiento = "Ven: 13 - 07 - 1991", background = "iFacturaBackground", iconEstado = "iNoSeleccionado", backgroundColor = Color.FromHex("BFBFBF") }); facturas.Add(new facturas { alias = "FACTURA MAYO 2018", proveedor = "EEGSA", categoria = string.Empty, saldo = "TOTAL: Q.2,150.00", aviso = string.Empty, vencimiento = "Ven: 13 - 07 - 1991", background = "iFacturaBackground", iconEstado = "iNoSeleccionado", backgroundColor = Color.FromHex("BFBFBF") }); } Facturas = new ExtendedListView { ItemTemplate = new DataTemplate(typeof(FacturasDTModeloVista)), Margin = 0, HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand, ItemsSource = facturas, RowHeight = Convert.ToInt32((App.DisplayScreenWidth / 1.978947368421053)), IsScrollEnable = true, IsPullToRefreshEnabled = false, SeparatorVisibility = SeparatorVisibility.None, SeparatorColor = Color.White, BackgroundColor = Color.Transparent, HasUnevenRows = false }; Facturas.ItemSelected += Facturas_ItemSelected; Grid Contenido = new Grid { Padding = 0, BackgroundColor = Color.White, RowSpacing = 0, VerticalOptions = LayoutOptions.FillAndExpand, HorizontalOptions = LayoutOptions.FillAndExpand, RowDefinitions = { new RowDefinition { Height = new GridLength(1, GridUnitType.Auto) }, new RowDefinition { Height = new GridLength(1, GridUnitType.Star) } }, ColumnDefinitions = { new ColumnDefinition { Width = new GridLength(1, GridUnitType.Star) } } }; Contenido.Children.Add(CC, 0, 0); Contenido.Children.Add(Facturas, 0, 1); Padding = 0; Content = Contenido; }
public GeneralesVista() { NavigationPage.SetBackButtonTitle(this, "GENERALES"); Label Bienvenida = new Label { BackgroundColor = Color.Transparent, Margin = new Thickness((App.DisplayScreenWidth / 12.533333333333333), 0, 0, 0), HorizontalTextAlignment = TextAlignment.Start, HorizontalOptions = LayoutOptions.FillAndExpand, Text = "PAMPSIP", FontFamily = Device.OnPlatform("Montserrat-Bold", "Montserrat-Bold", null), TextColor = Color.White, FontSize = (App.DisplayScreenWidth / 15.04) }; CircleImage avatar = new CircleImage { BackgroundColor = Color.Transparent, BorderColor = Color.FromHex("f6f6f6"), BorderThickness = Convert.ToInt32(App.DisplayScreenWidth / 107.428571428571429), Aspect = Aspect.AspectFill, Source = "avatar" }; AnimationView avatarDefault = new AnimationView { AutoPlay = true, Animation = "outline_user.json", Loop = true, WidthRequest = App.DisplayScreenHeight / 10.15, HeightRequest = App.DisplayScreenHeight / 10.15, VerticalOptions = LayoutOptions.Center, HorizontalOptions = LayoutOptions.Center, }; Grid Avatar = new Grid { Children = { avatar, avatarDefault } }; CircleImage config = new CircleImage { BackgroundColor = Color.Transparent, BorderColor = Color.FromHex("f6f6f6"), BorderThickness = Convert.ToInt32(App.DisplayScreenWidth / 107.428571428571429), Aspect = Aspect.AspectFill, Source = "iConfig" }; TapGestureRecognizer configTAP = new TapGestureRecognizer { NumberOfTapsRequired = 1 }; configTAP.Tapped += (sender, e) => { MessagingCenter.Send <RootPagina>((RootPagina)Application.Current.MainPage, "Categorias"); }; config.GestureRecognizers.Add(configTAP); RelativeLayout CC = new RelativeLayout() { Padding = 0, WidthRequest = App.DisplayScreenWidth, HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.Start, BackgroundColor = Color.Transparent }; CC.Children.Add(new Image { BackgroundColor = Color.Transparent, Aspect = Aspect.Fill, Source = "header", HeightRequest = App.DisplayScreenHeight / 2.889679715302491 }, Constraint.Constant(0), Constraint.Constant(-20), Constraint.Constant(App.DisplayScreenWidth), Constraint.Constant(App.DisplayScreenHeight / 2.889679715302491) ); CC.Children.Add(Bienvenida, Constraint.Constant(0), Constraint.Constant(App.DisplayScreenHeight / 8.12), Constraint.Constant(App.DisplayScreenWidth) ); CC.Children.Add(Avatar, Constraint.Constant((App.DisplayScreenWidth / 9.4)), Constraint.Constant(App.DisplayScreenHeight / 5.205128205128205), Constraint.Constant(App.DisplayScreenHeight / 8.12), Constraint.Constant(App.DisplayScreenHeight / 8.12) ); CC.Children.Add(config, Constraint.Constant((App.DisplayScreenWidth / 1.540983606557377)), Constraint.Constant(App.DisplayScreenHeight / 3.625), Constraint.Constant(App.DisplayScreenHeight / 12.492307692307692), Constraint.Constant(App.DisplayScreenHeight / 12.492307692307692) ); servicios = new List <servicios> { new servicios { alias = "CONTADOR MARÍA", proveedor = "EEGSA", categoria = "Categoría: Hogar 1", saldo = "SALDO: Q.2,150.00", aviso = "3 Facturas pendiente de pago", vencimiento = "Ven: 13 - 07 - 1991" }, new servicios { alias = "CONTADOR PEDRO", proveedor = "EEGSA", categoria = "Categoría: Hogar 1", saldo = "SALDO: Q.100.00", aviso = "3 Facturas pendiente de pago", vencimiento = "Ven: 13 - 07 - 1991" }, new servicios { alias = "CASA PROPIA", proveedor = "EEGSA", categoria = "Categoría: Hogar 2", saldo = "SALDO: Q.852.00", aviso = "1 Facturas pendiente de pago", vencimiento = "Ven: 01 - 03 - 2018" } }; ServiciosAsociados = new ExtendedListView { ItemTemplate = new DataTemplate(typeof(ServiciosAsociadosDTModeloVista)), Margin = 0, HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand, ItemsSource = servicios, RowHeight = Convert.ToInt32((App.DisplayScreenWidth / 1.978947368421053)), IsScrollEnable = true, IsPullToRefreshEnabled = false, SeparatorVisibility = SeparatorVisibility.None, SeparatorColor = Color.White, BackgroundColor = Color.Transparent, HasUnevenRows = false }; ServiciosAsociados.ItemSelected += ServiciosAsociados_ItemSelected; Grid Contenido = new Grid { Padding = 0, BackgroundColor = Color.White, RowSpacing = 0, VerticalOptions = LayoutOptions.FillAndExpand, HorizontalOptions = LayoutOptions.FillAndExpand, RowDefinitions = { new RowDefinition { Height = new GridLength(1, GridUnitType.Auto) }, new RowDefinition { Height = new GridLength(1, GridUnitType.Star) } }, ColumnDefinitions = { new ColumnDefinition { Width = new GridLength(1, GridUnitType.Star) } } }; Contenido.Children.Add(CC, 0, 0); Contenido.Children.Add(ServiciosAsociados, 0, 1); Padding = 0; Content = Contenido; }
public Menu() { Icon = ImageResources.MenuIcon; Title = StringResources.MenuTitle; BindingContext = modeloVista = new MenuVistaModelo(); BackgroundColor = ColorResources.MenuBackground; Menus = new ExtendedListView { IsScrollEnable = false, Margin = 0, ItemsSource = modeloVista.Menus, RowHeight = Convert.ToInt32((App.DisplayScreenHeight / 13.533333333333333)), IsPullToRefreshEnabled = false, SeparatorVisibility = SeparatorVisibility.None, SeparatorColor = Color.White, HasUnevenRows = false }; menuAnterior = MenuTipo.Contactanos; Menus.ItemSelected += (sender, e) => { try { var elemento = e.SelectedItem as Menus; if (menuAnterior == elemento.MenuTipo) { return; } else { menuAnterior = elemento.MenuTipo; } foreach (var _menu in modeloVista.Menus) { if (_menu.MenuTipo == elemento.MenuTipo) { _menu.isSelected = true; } else { _menu.isSelected = false; } } Menus.ItemsSource = null; Menus.ItemsSource = modeloVista.Menus; } catch (Exception ex) { System.Diagnostics.Debug.WriteLine(ex.Message); } }; Label header = new Label { HorizontalTextAlignment = TextAlignment.Center, HorizontalOptions = LayoutOptions.CenterAndExpand, Text = "MENÚ", FontFamily = Device.OnPlatform("Montserrat-Bold", "Montserrat-Bold", null), TextColor = Color.FromHex("4D4D4D"), FontSize = (App.DisplayScreenWidth / 15.04) }; facebook = new Grid { Children = { new Image { HorizontalOptions = LayoutOptions.Start, VerticalOptions = LayoutOptions.Center, HeightRequest = (App.DisplayScreenHeight / 36.909090909090909), //WidthRequest = (App.DisplayScreenHeight / 13.853658536585366), Aspect = Aspect.AspectFit, Source = "iFacebook", } } }; twitter = new Grid { Children = { new Image { HorizontalOptions = LayoutOptions.Center, VerticalOptions = LayoutOptions.Center, HeightRequest = (App.DisplayScreenHeight / 36.909090909090909), //WidthRequest = (App.DisplayScreenHeight / 13.853658536585366), Aspect = Aspect.AspectFit, Source = "iTwitter", } } }; messenger = new Grid { Children = { new Image { HorizontalOptions = LayoutOptions.End, VerticalOptions = LayoutOptions.Center, HeightRequest = (App.DisplayScreenHeight / 36.909090909090909), //WidthRequest = (App.DisplayScreenHeight / 13.853658536585366), Aspect = Aspect.AspectFit, Source = "iMessenger", } } }; facebookIndicador = new ActivityIndicator { HeightRequest = (App.DisplayScreenHeight / 36.909090909090909), WidthRequest = (App.DisplayScreenHeight / 36.909090909090909), IsRunning = false, IsVisible = false }; twitterIndicador = new ActivityIndicator { HeightRequest = (App.DisplayScreenHeight / 36.909090909090909), WidthRequest = (App.DisplayScreenHeight / 36.909090909090909), IsRunning = false, IsVisible = false }; messengerIndicador = new ActivityIndicator { HeightRequest = (App.DisplayScreenHeight / 36.909090909090909), WidthRequest = (App.DisplayScreenHeight / 36.909090909090909), IsRunning = false, IsVisible = false }; TapGestureRecognizer facebookTAP = new TapGestureRecognizer(); TapGestureRecognizer twitterTAP = new TapGestureRecognizer(); TapGestureRecognizer messengerTAP = new TapGestureRecognizer(); facebookTAP.NumberOfTapsRequired = 1; twitterTAP.NumberOfTapsRequired = 1; messengerTAP.NumberOfTapsRequired = 1; facebookTAP.Tapped += async(object sender, EventArgs e) => { facebookIndicador.IsVisible = true; facebookIndicador.IsRunning = true; facebook.IsVisible = false; Device.OpenUri(new Uri("fb://profile/604146393288718")); await Task.Delay(2000); if (Constantes.RedSocialPresentada) { Constantes.RedSocialPresentada = false; } else { Device.OpenUri(new Uri("https://www.facebook.com/Pampsip/")); } facebookIndicador.IsVisible = false; facebookIndicador.IsRunning = false; facebook.IsVisible = true; }; twitterTAP.Tapped += async(object sender, EventArgs e) => { twitterIndicador.IsVisible = true; twitterIndicador.IsRunning = true; twitter.IsVisible = false; Device.OpenUri(new Uri("twitter://user?user_id=999476282705502208")); //Device.OpenUri(new Uri("twitter://userName?user_id=198829810")); await Task.Delay(2000); if (Constantes.RedSocialPresentada) { Constantes.RedSocialPresentada = false; } else { Device.OpenUri(new Uri("https://twitter.com/pamsip1")); } twitterIndicador.IsVisible = false; twitterIndicador.IsRunning = false; twitter.IsVisible = true; }; messengerTAP.Tapped += async(object sender, EventArgs e) => { messengerIndicador.IsVisible = true; messengerIndicador.IsRunning = true; messenger.IsVisible = false; Device.OpenUri(new Uri("https://www.messenger.com/t/604146393288718")); messengerIndicador.IsVisible = false; messengerIndicador.IsRunning = false; messenger.IsVisible = true; }; facebook.GestureRecognizers.Add(facebookTAP); twitter.GestureRecognizers.Add(twitterTAP); messenger.GestureRecognizers.Add(messengerTAP); Grid redesSociales = new Grid { WidthRequest = App.DisplayScreenHeight / 5.010180786080089, HeightRequest = App.DisplayScreenHeight / 36.909090909090909, Padding = 0, ColumnSpacing = 0, HorizontalOptions = LayoutOptions.Center, RowDefinitions = { new RowDefinition { Height = new GridLength((App.DisplayScreenHeight / 36.909090909090909), GridUnitType.Absolute) } }, ColumnDefinitions = { new ColumnDefinition { Width = new GridLength((App.DisplayScreenHeight / 15.030542358240267), GridUnitType.Absolute) }, new ColumnDefinition { Width = new GridLength((App.DisplayScreenHeight / 15.030542358240267), GridUnitType.Absolute) }, new ColumnDefinition { Width = new GridLength((App.DisplayScreenWidth / 15.030542358240267), GridUnitType.Star) } } }; redesSociales.Children.Add(new Grid { Children = { facebookIndicador, facebook } }, 0, 0); redesSociales.Children.Add(new Grid { Children = { twitterIndicador, twitter } }, 1, 0); redesSociales.Children.Add(new Grid { Children = { messengerIndicador, messenger } }, 2, 0); Grid RedesSociales = new Grid { Padding = 0, HeightRequest = App.DisplayScreenHeight / 36.909090909090909, HorizontalOptions = LayoutOptions.FillAndExpand, Children = { redesSociales } }; Button cerrarSesion = new Button { Margin = 0, HorizontalOptions = LayoutOptions.CenterAndExpand, Text = "cerrar sesión", TextColor = Color.FromHex("BFBFBF"), FontFamily = FontResources.ButtonFont, FontSize = ((App.DisplayScreenHeight / 54.133333333333333)), WidthRequest = App.DisplayScreenHeight / 5.678321678321678, HeightRequest = App.DisplayScreenHeight / 40.6 }; Grid CerrarSesion = new Grid { Children = { new StackLayout { HeightRequest = App.DisplayScreenHeight / 32.48, WidthRequest = App.DisplayScreenHeight / 5.678321678321678, Spacing = App.DisplayScreenHeight / 162.4, HorizontalOptions = LayoutOptions.Center, Children = { cerrarSesion, new BoxView { HorizontalOptions = LayoutOptions.FillAndExpand, BackgroundColor = Color.FromHex("BFBFBF"), HeightRequest = (App.DisplayScreenWidth / 341.818181818181818), Opacity = 0.25 } } } } }; cerrarSesion.Clicked += CerrarSesion_Clicked; Menus.ItemTemplate = new DataTemplate(typeof(MenuDTModeloVista)); RelativeLayout Contenido = new RelativeLayout() { HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand, }; Contenido.Children.Add(header, Constraint.Constant(0), Constraint.Constant(Device.RuntimePlatform == Device.iOS ? (App.DisplayScreenHeight / 8.923076923076923) : (App.DisplayScreenHeight / 10.278481012658228)), Constraint.RelativeToParent((arg) => { return(arg.Width); }) ); Contenido.Children.Add(Menus, Constraint.Constant(0), Constraint.Constant(Device.RuntimePlatform == Device.iOS ? (App.DisplayScreenHeight / 3.029850746268657) : (App.DisplayScreenHeight / 3.171875)), Constraint.RelativeToParent((arg) => { return(arg.Width); }), Constraint.Constant(App.DisplayScreenHeight / 2.942028985507246) ); Contenido.Children.Add(new Label { HorizontalTextAlignment = TextAlignment.Center, HorizontalOptions = LayoutOptions.FillAndExpand, Margin = 0, TextColor = Color.FromHex("BFBFBF"), FontSize = (App.DisplayScreenWidth / 25.066666666666667), VerticalTextAlignment = TextAlignment.Center, Text = "Contáctanos", FontFamily = Device.OnPlatform("Montserrat-Regular", "Montserrat-Regular", null), }, Constraint.Constant(0), Constraint.Constant(Device.RuntimePlatform == Device.iOS ? (App.DisplayScreenHeight / 1.407279029462738) : (App.DisplayScreenHeight / 1.43716814159292)), Constraint.RelativeToParent((arg) => { return(arg.Width); }) ); Contenido.Children.Add(RedesSociales, Constraint.Constant(0), Constraint.Constant(Device.RuntimePlatform == Device.iOS ? (App.DisplayScreenHeight / 1.280757097791798) : (App.DisplayScreenHeight / 1.305466237942122)), Constraint.RelativeToParent((arg) => { return(arg.Width); }), Constraint.Constant(App.DisplayScreenHeight / 36.909090909090909) ); Contenido.Children.Add(CerrarSesion, Constraint.Constant(0), Constraint.Constant(Device.RuntimePlatform == Device.iOS ? (App.DisplayScreenHeight / 1.087014725568942) : (App.DisplayScreenHeight / 1.104761904761905)), Constraint.RelativeToParent((arg) => { return(arg.Width); }), Constraint.Constant(App.DisplayScreenHeight / 32.48) ); Contenido.Children.Add(new BoxView { BackgroundColor = Color.FromHex("BFBFBF"), Opacity = 0.08 }, Constraint.RelativeToParent((arg) => { return(arg.Width - (App.DisplayScreenHeight / 203)); }), Constraint.Constant(20), Constraint.Constant(App.DisplayScreenWidth / 203), Constraint.Constant(App.DisplayScreenHeight) ); Content = Contenido; }
/// <summary> /// Initializes a new instance of the <see cref="ExpandBehavior"/> class. /// </summary> /// <param name="pParent">The behavior's parent.</param> public ExpandBehavior(ExtendedListView pParent) { this.mParent = pParent; }
private void UpdateUi(ExtendedListView element) { Control.ScrollEnabled = element.IsScrollEnable; }
private void SubBtn_Clicked(object sender, EventArgs e) { ExtendedListView.Subtract(); }
public BaskasininProfili(NoteWork.Modals.Profile baskaProfil, NetWork nts, bool bool1) { this.Icon = "profil.png"; Grid a = new Grid(); Grid b = new Grid(); Grid d = new Grid(); for (var i = 0; i < 57; i++) { a.ColumnDefinitions.Add(new ColumnDefinition { Width = new GridLength(1, GridUnitType.Star) }); } for (var i = 0; i < 113; i++) { a.RowDefinitions.Add(new RowDefinition { Height = new GridLength(1, GridUnitType.Star) }); } a.RowDefinitions.Add(new RowDefinition { Height = new GridLength(6, GridUnitType.Absolute) }); var gayagay = new Image() { Source = "gaydirganlik.png", VerticalOptions = LayoutOptions.FillAndExpand, HorizontalOptions = LayoutOptions.FillAndExpand }; var gayagay1 = new Image() { Source = "gaydirganlik2.png", VerticalOptions = LayoutOptions.Center, HorizontalOptions = LayoutOptions.FillAndExpand }; var gayagay2 = new Image() { Source = "gaydirganlik2.png", VerticalOptions = LayoutOptions.Center, HorizontalOptions = LayoutOptions.FillAndExpand }; var gayagay3 = new Image() { Source = "gaydirganlik2.png", VerticalOptions = LayoutOptions.Center, HorizontalOptions = LayoutOptions.FillAndExpand }; var gayagay4 = new Image() { Source = "gaydirganlik2.png", VerticalOptions = LayoutOptions.Center, HorizontalOptions = LayoutOptions.FillAndExpand }; gayagay1.IsVisible = true; gayagay2.IsVisible = false; gayagay3.IsVisible = false; gayagay4.IsVisible = false; b.Children.Add(gayagay, 0, 0); Grid.SetColumnSpan(gayagay, 4); b.Children.Add(gayagay1, 0, 0); b.Children.Add(gayagay2, 1, 0); b.Children.Add(gayagay3, 2, 0); b.Children.Add(gayagay4, 3, 0); var AdSoyad = new Button() { HeightRequest = 50, WidthRequest = 50, BackgroundColor = Color.FromHex("#1a94d2"), VerticalOptions = LayoutOptions.Center, HorizontalOptions = LayoutOptions.Center }; var adsoyad = new ExtendedListView() { HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.Start, HeightRequest = Device.OnPlatform(410, 350, 350) }; adsoyad.Focus(); adsoyad.Items = new List <EntityClass>() { new EntityClass() { Id = 1, Title = "Ad Soyad: " + baskaProfil.FirstName + " " + baskaProfil.LastName, }, new EntityClass() { Id = 1, Title = "Şirket: " + baskaProfil.Company, }, new EntityClass() { Id = 1, Title = "Ünvan: " + baskaProfil.JobTitle, }, new EntityClass() { Id = 1, Title = "Şehir: " + baskaProfil.City, }, new EntityClass() { Id = 1, Title = "Telefon: " + baskaProfil.TelNo, }, new EntityClass() { Id = 1, Title = "e-mail: " + baskaProfil.EMail, }, new EntityClass() { Id = 1, Title = "Ben ve O", ChildItems = new List <EntityClass>() { new EntityClass() { Id = 1, Title = "Nerede tanıştınız: " + nts.MeetWhere, }, new EntityClass() { Id = 2, Title = "Ne Zaman Tanıştınız: " + nts.MeetWhen, }, new EntityClass() { Id = 3, Title = "İlk izlenim: " + nts.FirstImpression, }, new EntityClass() { Id = 3, Title = "Ayırt Edici Özellik: " + nts.Distinctive, }, new EntityClass() { Id = 4, Title = "Tanışıklık: " + nts.MeetState }, new EntityClass() { Id = 5, Title = "Çevre: " + nts.NetWorks } } } }; var SosyalAg = new Button() { HeightRequest = 50, WidthRequest = 50, BackgroundColor = Color.FromHex("#00aeb3"), VerticalOptions = LayoutOptions.Center, HorizontalOptions = LayoutOptions.Center }; var sosyalAg = new ExtendedListView() { HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.Start, HeightRequest = Device.OnPlatform(410, 350, 350) }; sosyalAg.Items = new List <EntityClass>() { new EntityClass() { Id = 0, Title = "Facebook: " + baskaProfil.FaceAccount, }, new EntityClass() { Id = 1, Title = "LinkedIn: " + baskaProfil.LinkedAccount, }, new EntityClass() { Id = 1, Title = "Twitter: " + baskaProfil.TwitterAccount, }, new EntityClass() { Id = 1, Title = "Instagram: " + baskaProfil.InstaAccount, } }; var TBilgi = new Button() { HeightRequest = 50, WidthRequest = 50, BackgroundColor = Color.FromHex("#9e9fa2"), VerticalOptions = LayoutOptions.Center, HorizontalOptions = LayoutOptions.Start }; var Temel = new ExtendedListView() { HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.Start, HeightRequest = Device.OnPlatform(410, 350, 350) }; Temel.Items = new List <EntityClass>() { new EntityClass() { Id = 0, Title = AppResource.profilentitychildclassname10, ChildItems = new List <EntityClass>() { new EntityClass() { Id = 1, Title = "Ad Soyad: " + baskaProfil.FirstName + " " + baskaProfil.LastName, }, new EntityClass() { Id = 2, Title = "Şehir: " + baskaProfil.City }, new EntityClass() { Id = 3, Title = "Memleket: " + baskaProfil.Hometown }, new EntityClass() { Id = 4, Title = "Doğum Günü: " + baskaProfil.BirthDate.ToString() } } }, new EntityClass() { Id = 5, Title = AppResource.profilentitychildclassname11, ChildItems = new List <EntityClass>() { new EntityClass() { Id = 6, Title = "Telefon: " + baskaProfil.TelNo }, new EntityClass() { Id = 7, Title = "e-mail: " + baskaProfil.EMail }, new EntityClass() { Id = 8, Title = "Ofis Adresi: " + baskaProfil.OfficeAddress }, new EntityClass() { Id = 9, Title = "Asistan İsmi: " + baskaProfil.AssistantName } } }, new EntityClass() { Id = 10, Title = AppResource.profilentitychildclassname12, ChildItems = new List <EntityClass>() { new EntityClass() { Id = 11, Title = "Şirket: " + baskaProfil.Company, }, new EntityClass() { Id = 12, Title = "Ünvan: " + baskaProfil.JobTitle }, new EntityClass() { Id = 13, Title = "Önceki Şirketler: " + baskaProfil.PreviousCompanies }, new EntityClass() { Id = 14, Title = "Uzmanlıklar: " + baskaProfil.Profficiencies }, new EntityClass() { Id = 15, Title = "Projeler: " + baskaProfil.Projects }, new EntityClass() { Id = 16, Title = "Sertifikalar: " + baskaProfil.Sertificates }, } }, new EntityClass() { Id = 17, Title = AppResource.profilentitychildclassname13, ChildItems = new List <EntityClass>() { new EntityClass() { Id = 18, Title = "Üniversite: " + baskaProfil.Universities, }, new EntityClass() { Id = 19, Title = "Lise: " + baskaProfil.HighSchool } } } }; var KisiselBil = new Button() { HeightRequest = 50, WidthRequest = 50, BackgroundColor = Device.OnPlatform(Color.FromHex("#c5c2c2"), Color.FromHex("#fff"), Color.FromHex("#fff")), VerticalOptions = LayoutOptions.Center, HorizontalOptions = LayoutOptions.End, }; var KisiselBilgi = new ExtendedListView() { HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.Start, HeightRequest = Device.OnPlatform(410, 350, 350) }; KisiselBilgi.Items = new List <EntityClass>() { new EntityClass() { Id = 0, Title = "Eş ve Çocuklar: " + baskaProfil.FamilyMembers, }, new EntityClass() { Id = 1, Title = "Ev Adresi: " + baskaProfil.HomeAddress, }, new EntityClass() { Id = 1, Title = "Vakıf ve Dernekler: " + baskaProfil.FoundAssociates, }, new EntityClass() { Id = 1, Title = "İlgilenilen Sporlar:" + baskaProfil.Sports, }, new EntityClass() { Id = 1, Title = "Hobiler: " + baskaProfil.Hobbies, }, new EntityClass() { Id = 1, Title = "Facori takım: " + baskaProfil.Team, }, new EntityClass() { Id = 1, Title = "Seyehatler: " + baskaProfil.Travels, } }; var img = new Image() { Source = "doldurbar.png", HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand }; var img1 = new Image() { Source = "kendiprofil.png", HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand }; var img2 = new Image() { Source = "profilduzenle.png", HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand, HeightRequest = 30, WidthRequest = 30 }; var img9 = new Image() { Source = "Ekle.png", HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand, HeightRequest = 30, WidthRequest = 30 }; var img3 = new Image() { Source = "Sil.png", // HorizontalOptions = LayoutOptions.StartAndExpand, HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand, }; var img4 = new Image() { Source = "ortakbaglanti.png", // HorizontalOptions = LayoutOptions.StartAndExpand, HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand, }; var img5 = new Image() { Source = "telarama.png", // HorizontalOptions = LayoutOptions.StartAndExpand, HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand, }; var img6 = new Image() { Source = "mesajlasma.png", // HorizontalOptions = LayoutOptions.StartAndExpand, HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand, }; var img7 = new Image() { Source = "geributonu2.png", // HorizontalOptions = LayoutOptions.StartAndExpand, HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand, }; var img8 = new Image() { Source = "ortakbaglanti.png", // HorizontalOptions = LayoutOptions.StartAndExpand, HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand, }; var bt3 = new StackLayout() { HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand, BackgroundColor = Color.FromHex("#eee") }; var lockKey = new Image() { Source = "lock.png", HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand, HeightRequest = 30, WidthRequest = 30, }; var light = new Image() { Source = "light.png", HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand, HeightRequest = 30, WidthRequest = 30 }; var book = new Image() { Source = "book.png", HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand, HeightRequest = 30, WidthRequest = 30 }; var sosyalag = new Image() { Source = "sosyalag.png", HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand, HeightRequest = 30, WidthRequest = 30 }; d.Children.Add(adsoyad, 0, 0); var tapGestureRecognizer = new TapGestureRecognizer(); tapGestureRecognizer.Tapped += (s, e) => { var phoneCallTask = MessagingPlugin.PhoneDialer; if (phoneCallTask.CanMakePhoneCall && baskaProfil.TelNo != null) { phoneCallTask.MakePhoneCall(baskaProfil.TelNo); } }; img5.GestureRecognizers.Add(tapGestureRecognizer); var tapGestureRecognizer1 = new TapGestureRecognizer(); tapGestureRecognizer1.Tapped += (s, e) => { var smsMessenger = MessagingPlugin.SmsMessenger; if (smsMessenger.CanSendSms && baskaProfil.TelNo != null) { smsMessenger.SendSms(baskaProfil.TelNo, "Say 'Hello' to your friends from NoteWork!"); } }; img6.GestureRecognizers.Add(tapGestureRecognizer1); var tapGestureRecognizer2 = new TapGestureRecognizer(); tapGestureRecognizer2.Tapped += (s, e) => { GirisSayfasi.manager.DeleteNetWorkAsync(baskaProfil); Navigation.PopModalAsync(); }; img3.GestureRecognizers.Add(tapGestureRecognizer2); var tapGestureRecognizer3 = new TapGestureRecognizer(); tapGestureRecognizer3.Tapped += (s, e) => { Navigation.PushModalAsync(new Agim2(baskaProfil)); }; img8.GestureRecognizers.Add(tapGestureRecognizer3); var tapGestureRecognizerss3 = new TapGestureRecognizer(); tapGestureRecognizerss3.Tapped += async(s, e) => { Navigation.PushModalAsync(new Notlar(baskaProfil, nts)); }; img4.GestureRecognizers.Add(tapGestureRecognizerss3); var tapGestureRecognizer4 = new TapGestureRecognizer(); tapGestureRecognizer4.Tapped += (s, e) => { img7.RotationX = 180; Navigation.PopModalAsync(); }; img7.GestureRecognizers.Add(tapGestureRecognizer4); a.Children.Add(d, 0, 51); Grid.SetColumnSpan(d, 57); Grid.SetRowSpan(d, 42); a.Children.Add(AdSoyad, 3, 41); Grid.SetColumnSpan(AdSoyad, 8); Grid.SetRowSpan(AdSoyad, 8); a.Children.Add(book, 3, 41); Grid.SetColumnSpan(book, 8); Grid.SetRowSpan(book, 8); a.Children.Add(SosyalAg, 17, 41); Grid.SetColumnSpan(SosyalAg, 8); Grid.SetRowSpan(SosyalAg, 8); a.Children.Add(sosyalag, 17, 41); Grid.SetColumnSpan(sosyalag, 8); Grid.SetRowSpan(sosyalag, 8); a.Children.Add(TBilgi, 32, 41); Grid.SetColumnSpan(TBilgi, 8); Grid.SetRowSpan(TBilgi, 8); a.Children.Add(light, 32, 41); Grid.SetColumnSpan(light, 8); Grid.SetRowSpan(light, 8); a.Children.Add(KisiselBil, 46, 41); Grid.SetColumnSpan(KisiselBil, 8); Grid.SetRowSpan(KisiselBil, 8); a.Children.Add(lockKey, 46, 41); Grid.SetColumnSpan(lockKey, 8); Grid.SetRowSpan(lockKey, 8); a.Children.Add(img, 19, 7); Grid.SetColumnSpan(img, 20); Grid.SetRowSpan(img, 22); a.Children.Add(img1, 22, 10); Grid.SetColumnSpan(img1, 14); Grid.SetRowSpan(img1, 16); a.Children.Add(img2, 47, 3); Grid.SetColumnSpan(img2, 7); Grid.SetRowSpan(img2, 8); a.Children.Add(img3, 47, 25); Grid.SetColumnSpan(img3, 7); Grid.SetRowSpan(img3, 8); a.Children.Add(img4, 3, 25); Grid.SetColumnSpan(img4, 7); Grid.SetRowSpan(img4, 8); a.Children.Add(img5, 19, 33); Grid.SetColumnSpan(img5, 7); Grid.SetRowSpan(img5, 8); a.Children.Add(img6, 32, 33); Grid.SetColumnSpan(img6, 7); Grid.SetRowSpan(img6, 8); a.Children.Add(img7, 3, 3); Grid.SetColumnSpan(img7, 7); Grid.SetRowSpan(img7, 8); a.Children.Add(img8, 3, 14); Grid.SetColumnSpan(img8, 7); Grid.SetRowSpan(img8, 8); a.Children.Add(img9, 47, 3); Grid.SetColumnSpan(img9, 7); Grid.SetRowSpan(img9, 8); a.Children.Add(b, 0, 50); Grid.SetColumnSpan(b, 57); Grid.SetRowSpan(b, 2); a.Children.Add(bt3, 0, 113); Grid.SetColumnSpan(bt3, 57); var tapGestureRecognizers = new TapGestureRecognizer(); tapGestureRecognizers.Tapped += (s, e) => { if (thebool == false) { if (thebool2 == true) { d.Children.Remove(sosyalAg); } if (thebool3 == true) { d.Children.Remove(Temel); } if (thebool4 == true) { d.Children.Remove(KisiselBilgi); } d.Children.Add(adsoyad, 0, 0); thebool = true; thebool2 = false; thebool3 = false; thebool4 = false; gayagay1.IsVisible = true; gayagay2.IsVisible = false; gayagay3.IsVisible = false; gayagay4.IsVisible = false; } }; book.GestureRecognizers.Add(tapGestureRecognizers); var tapGestureRecognizers1 = new TapGestureRecognizer(); tapGestureRecognizers1.Tapped += (s, e) => { if (thebool2 == false) { if (thebool == true) { d.Children.Remove(adsoyad); } if (thebool3 == true) { d.Children.Remove(Temel); } if (thebool4 == true) { d.Children.Remove(KisiselBilgi); } d.Children.Add(sosyalAg, 0, 0); thebool = false; thebool2 = true; thebool3 = false; thebool4 = false; gayagay1.IsVisible = false; gayagay2.IsVisible = true; gayagay3.IsVisible = false; gayagay4.IsVisible = false; } }; sosyalag.GestureRecognizers.Add(tapGestureRecognizers1); var tapGestureRecognizers2 = new TapGestureRecognizer(); tapGestureRecognizers2.Tapped += (s, e) => { if (thebool3 == false) { if (thebool == true) { d.Children.Remove(adsoyad); } if (thebool2 == true) { d.Children.Remove(sosyalAg); } if (thebool4 == true) { d.Children.Remove(KisiselBilgi); } d.Children.Add(Temel, 0, 0); thebool = false; thebool2 = false; thebool3 = true; thebool4 = false; gayagay1.IsVisible = false; gayagay2.IsVisible = false; gayagay3.IsVisible = true; gayagay4.IsVisible = false; } }; light.GestureRecognizers.Add(tapGestureRecognizers2); var tapGestureRecognizers3 = new TapGestureRecognizer(); tapGestureRecognizers3.Tapped += (s, e) => { if (thebool4 == false) { if (thebool == true) { d.Children.Remove(adsoyad); } if (thebool2 == true) { d.Children.Remove(sosyalAg); } if (thebool3 == true) { d.Children.Remove(Temel); } d.Children.Add(KisiselBilgi, 0, 0); thebool = false; thebool2 = false; thebool3 = false; thebool4 = true; gayagay1.IsVisible = false; gayagay2.IsVisible = false; gayagay3.IsVisible = false; gayagay4.IsVisible = true; } }; lockKey.GestureRecognizers.Add(tapGestureRecognizers3); if (bool1 == true) { img2.IsVisible = true; img9.IsVisible = false; } else if (GirisSayfasi.manager.prof.LID == baskaProfil.LID) { img2.IsVisible = false; img9.IsVisible = false; } else { img2.IsVisible = false; img9.IsVisible = true; } var tapGestureRecognizer5 = new TapGestureRecognizer(); tapGestureRecognizer5.Tapped += async(s, e) => { await Navigation.PushModalAsync(new ProfilDuzenle(baskaProfil)); }; img2.GestureRecognizers.Add(tapGestureRecognizer5); var tapGestureRecognizer6 = new TapGestureRecognizer(); tapGestureRecognizer6.Tapped += async(s, e) => { await GirisSayfasi.manager.SaveLoginAsync3(baskaProfil, new Modals.NetWork()); await Navigation.PopModalAsync(); }; img9.GestureRecognizers.Add(tapGestureRecognizer6); Content = a; }
public virtual int Add(ExtendedListView.Forms.ToggleColumnHeader colhead) { colhead.WidthResized += new EventHandler(OnWidthResized); return colhead.Index = List.Add(colhead); }
/// <summary> /// Initializes a new instance of the <see cref="SelectionBehavior"/> class. /// </summary> /// <param name="pParent">The behavior's parent.</param> public SelectionBehavior(ExtendedListView pParent) { this.mParent = pParent; }
public ResumenPago(List <facturas> facturas) { NavigationPage.SetBackButtonTitle(this, "RESUMEN"); this.facturas = facturas; Label Bienvenida = new Label { BackgroundColor = Color.Transparent, Margin = new Thickness((App.DisplayScreenWidth / 12.533333333333333), 0, 0, 0), HorizontalTextAlignment = TextAlignment.Start, HorizontalOptions = LayoutOptions.FillAndExpand, FontFamily = Device.OnPlatform("Montserrat-Bold", "Montserrat-Bold", null), TextColor = Color.White, FontSize = (App.DisplayScreenWidth / 15.04), Text = "¿ESTÁS SEGURO?" }; RelativeLayout CC = new RelativeLayout() { Padding = 0, WidthRequest = App.DisplayScreenWidth, HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.Start, BackgroundColor = Color.Transparent, }; CC.Children.Add(new Image { Aspect = Aspect.Fill, Source = "header", HeightRequest = App.DisplayScreenHeight / 2.889679715302491 }, Constraint.Constant(0), Constraint.Constant(-60), Constraint.Constant(App.DisplayScreenWidth), Constraint.Constant(App.DisplayScreenHeight / 2.889679715302491) ); CC.Children.Add(Bienvenida, Constraint.Constant(0), Constraint.Constant(App.DisplayScreenHeight / 10.15), Constraint.Constant(App.DisplayScreenWidth) ); Facturas = new ExtendedListView { Header = new StackLayout { Children = { new BoxView { HeightRequest = App.DisplayScreenWidth / 9.4, HorizontalOptions = LayoutOptions.FillAndExpand, BackgroundColor = Color.Transparent, }, new Label { BackgroundColor = Color.Transparent, HorizontalTextAlignment = TextAlignment.Center, HorizontalOptions = LayoutOptions.FillAndExpand, FontFamily = Device.OnPlatform("Montserrat-Regular", "Montserrat-Regular", null), TextColor = Color.FromHex("4D4D4D"), FontSize = (App.DisplayScreenWidth / 26.857142857142857), Text = "A continuación te mostramos \r\nun resumen de lo que nos has\r\nindicado que deseas pagar.\r\n\r\nAsegurate de revisar bien cada detalle :)" }, new BoxView { HeightRequest = App.DisplayScreenWidth / 9.894736842105263, HorizontalOptions = LayoutOptions.FillAndExpand, BackgroundColor = Color.Transparent, } } }, ItemTemplate = new DataTemplate(typeof(FacturasCarretillaDTModeloVista)), Margin = 0, HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand, ItemsSource = facturas, RowHeight = Convert.ToInt32((App.DisplayScreenWidth / 3.514018691588785)), IsScrollEnable = true, IsPullToRefreshEnabled = false, SeparatorVisibility = SeparatorVisibility.None, SeparatorColor = Color.White, BackgroundColor = Color.Transparent, HasUnevenRows = false }; Facturas.ItemSelected += Facturas_ItemSelected; Button continuar = new Button { Margin = 0, Text = "CONTINUAR", TextColor = Color.White, FontFamily = Device.OnPlatform("Montserrat-Bold", "Montserrat-Bold", null), FontSize = (App.DisplayScreenWidth / 25.066666666666667), HorizontalOptions = LayoutOptions.Center, VerticalOptions = LayoutOptions.Center, BackgroundColor = Color.Transparent, WidthRequest = (App.DisplayScreenHeight / 3.608888888888889), HeightRequest = (App.DisplayScreenHeight / 20.3), }; continuar.Clicked += Continuar_Clicked; continuarImage = new Image { Source = "loginButton", HorizontalOptions = LayoutOptions.Center, VerticalOptions = LayoutOptions.Center, WidthRequest = (App.DisplayScreenHeight / 3.608888888888889), HeightRequest = (App.DisplayScreenHeight / 20.3), }; Grid Continuar = new Grid { Padding = 0, Children = { continuarImage, continuar } }; Grid Contenido = new Grid { Padding = 0, BackgroundColor = Color.White, RowSpacing = 0, VerticalOptions = LayoutOptions.FillAndExpand, HorizontalOptions = LayoutOptions.FillAndExpand, RowDefinitions = { new RowDefinition { Height = new GridLength(1, GridUnitType.Auto) }, new RowDefinition { Height = new GridLength(1, GridUnitType.Star) }, new RowDefinition { Height = new GridLength(1, GridUnitType.Auto) } }, ColumnDefinitions = { new ColumnDefinition { Width = new GridLength(1, GridUnitType.Star) } } }; Contenido.Children.Add(CC, 0, 0); Contenido.Children.Add(Facturas, 0, 1); Contenido.Children.Add(new Grid { BackgroundColor = Color.Transparent, HorizontalOptions = LayoutOptions.FillAndExpand, Padding = new Thickness(0, (App.DisplayScreenHeight / 20.3)), Children = { Continuar } }, 0, 2); Padding = 0; Content = Contenido; }
public AccionesFiltradoPage() { Padding = new Thickness(0, 30, 0, 0); BackgroundColor = Colors.BarBackgroundColor; IconView cerrar = new IconView { WidthRequest = 20, HeightRequest = 20, Margin = new Thickness(0, 0, 10, 0), HorizontalOptions = LayoutOptions.End, Source = Images.Cancelar, Foreground = Color.FromHex("E9242A") }; TapGestureRecognizer cerrarTAP = new TapGestureRecognizer(); cerrarTAP.Tapped += CerrarTAP_Tapped; cerrar.GestureRecognizers.Add(cerrarTAP); Grid botonCerrar = new Grid { HeightRequest = 35, WidthRequest = 80, Children = { new RoundedBoxView.Forms.Plugin.Abstractions.RoundedBoxView { BackgroundColor = Color.White, CornerRadius = 6 }, cerrar } }; StackLayout Header = new StackLayout { Padding = new Thickness(10, 0, 10, 20), Children = { new Label { Text = "Selecciona para agregar", FontSize = 15, FontFamily = Device.OnPlatform("OpenSans-Bold", "OpenSans-Bold", null), HorizontalTextAlignment = TextAlignment.Center, TextColor = Color.White, HorizontalOptions = LayoutOptions.Center }, new BoxView { BackgroundColor = Color.Transparent, HeightRequest = 30 } } }; AccionesContenido = new ExtendedListView { Margin = 0, IsPullToRefreshEnabled = false, BackgroundColor = Color.Transparent, ItemTemplate = new DataTemplate(typeof(AppsActionsDTViewModel)), HasUnevenRows = false, RowHeight = 90, SeparatorColor = Color.FromHex("E5E5E5"), ItemsSource = actions }; AccionesContenido.ItemSelected += AccionesContenido_ItemSelected; Contenido = new RelativeLayout(); Contenido.Children.Add(Header, xConstraint: Constraint.Constant(0), yConstraint: Constraint.Constant(0), widthConstraint: Constraint.RelativeToParent(parent => parent.Width)); Contenido.Children.Add(new StackLayout { HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand, Spacing = 0, Children = { new Grid { BackgroundColor = Color.FromHex("E5E5E5"), HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand, Padding = new Thickness(20, 0), Children = { AccionesContenido } }, new BoxView { BackgroundColor = Color.FromHex("B3B3B3"), HeightRequest = 4 } } }, xConstraint: Constraint.Constant(0), yConstraint: Constraint.RelativeToView(Header, (parent, view) => { return(view.Height); }), widthConstraint: Constraint.RelativeToParent(parent => parent.Width), heightConstraint: Constraint.RelativeToView(Header, (parent, view) => { return(parent.Height - view.Height); }) ); Contenido.Children.Add(botonCerrar, xConstraint: Constraint.Constant(-20), yConstraint: Constraint.Constant(30) ); Content = Contenido; }
private void ScrollToBottom_Clicked(object sender, EventArgs e) { ExtendedListView.Scroll(); }
// public SettingsListSource (List<EntityClass> data) // { // Settings = data; // } public SettingsListSource(ExtendedListView data) { Settings = data.Items.ToList(); }
private void AddBtn_Clicked(object sender, EventArgs e) { ExtendedListView.Add(); }
/// <summary> /// Constructor. /// </summary> /// <param name="listView">ListView with which this ToolStrip will be associated.</param> public ExtendedToolStrip(ExtendedListView listView) : this() { this.ListView = listView; }
/// <summary> /// Initializes a new instance of the <see cref="ExpandModel"/> class. /// </summary> /// <param name="pParent">The model parent.</param> public ExpandModel(ExtendedListView pParent) { this.mParent = pParent; }
private void Init() { ListView = new ExtendedListView(ListViewCachingStrategy.RecycleElement) { IsGroupingEnabled = true, ItemsSource = PresentationSections, HasUnevenRows = true, GroupHeaderTemplate = new DataTemplate(() => new SectionHeaderViewCell( nameof(Section <Grouping> .Name), nameof(Section <Grouping> .Count))), GroupShortNameBinding = new Binding(nameof(Section <Grouping> .NameShort)), ItemTemplate = new GroupingOrCipherDataTemplateSelector(this) }; if (Device.RuntimePlatform == Device.iOS) { ListView.RowHeight = -1; } Search = new SearchBar { Placeholder = AppResources.Search, FontSize = Device.GetNamedSize(NamedSize.Small, typeof(Button)), CancelButtonColor = Color.FromHex("3c8dbc") }; // Bug with search bar on android 7, ref https://bugzilla.xamarin.com/show_bug.cgi?id=43975 if (Device.RuntimePlatform == Device.Android && _deviceInfoService.Version >= 24) { Search.HeightRequest = 50; } var noDataLabel = new Label { Text = _favorites ? AppResources.NoFavorites : AppResources.NoItems, HorizontalTextAlignment = TextAlignment.Center, FontSize = Device.GetNamedSize(NamedSize.Small, typeof(Label)), Style = (Style)Application.Current.Resources["text-muted"] }; if (_folder || !string.IsNullOrWhiteSpace(_folderId)) { noDataLabel.Text = AppResources.NoItemsFolder; } else if (!string.IsNullOrWhiteSpace(_collectionId)) { noDataLabel.Text = AppResources.NoItemsCollection; } NoDataStackLayout = new StackLayout { Children = { noDataLabel }, VerticalOptions = LayoutOptions.CenterAndExpand, Padding = new Thickness(20, 0), Spacing = 20 }; if (string.IsNullOrWhiteSpace(_collectionId) && !_favorites) { NoDataStackLayout.Children.Add(new ExtendedButton { Text = AppResources.AddAnItem, Command = new Command(() => Helpers.AddCipher(this, _folderId)), Style = (Style)Application.Current.Resources["btn-primaryAccent"] }); } ResultsStackLayout = new StackLayout { Children = { Search, ListView }, Spacing = 0 }; if (!string.IsNullOrWhiteSpace(_groupingName)) { Title = _groupingName; } else if (_favorites) { Title = AppResources.Favorites; } else { Title = AppResources.SearchVault; if (Device.RuntimePlatform == Device.iOS || Device.RuntimePlatform == Device.UWP) { ToolbarItems.Add(new DismissModalToolBarItem(this)); } } LoadingIndicator = new ActivityIndicator { IsRunning = true }; if (Device.RuntimePlatform != Device.UWP) { LoadingIndicator.VerticalOptions = LayoutOptions.CenterAndExpand; LoadingIndicator.HorizontalOptions = LayoutOptions.Center; } ContentView = new ContentView { Content = LoadingIndicator }; var fabLayout = new FabLayout(ContentView); if (!string.IsNullOrWhiteSpace(_uri) || _folder || !string.IsNullOrWhiteSpace(_folderId)) { if (Device.RuntimePlatform == Device.Android) { ListView.BottomPadding = 170; Fab = new Fab(fabLayout, "plus.png", (sender, args) => Helpers.AddCipher(this, _folderId)); } else { AddCipherItem = new AddCipherToolBarItem(this, _folderId); ToolbarItems.Add(AddCipherItem); } } else if (Device.RuntimePlatform == Device.Android) { ListView.BottomPadding = 50; } Content = fabLayout; }
public Profilim() { this.Icon = "profil.png"; Grid a = new Grid(); Grid b = new Grid(); Grid d = new Grid(); //ScrollView c = new ScrollView(); var gayagay = new Image() { Source = "gaydirganlik.png", VerticalOptions = LayoutOptions.FillAndExpand, HorizontalOptions = LayoutOptions.FillAndExpand }; var gayagay1 = new Image() { Source = "gaydirganlik2.png", VerticalOptions = LayoutOptions.Center, HorizontalOptions = LayoutOptions.FillAndExpand }; var gayagay2 = new Image() { Source = "gaydirganlik2.png", VerticalOptions = LayoutOptions.Center, HorizontalOptions = LayoutOptions.FillAndExpand }; var gayagay3 = new Image() { Source = "gaydirganlik2.png", VerticalOptions = LayoutOptions.Center, HorizontalOptions = LayoutOptions.FillAndExpand }; var gayagay4 = new Image() { Source = "gaydirganlik2.png", VerticalOptions = LayoutOptions.Center, HorizontalOptions = LayoutOptions.FillAndExpand }; gayagay1.IsVisible = true; gayagay2.IsVisible = false; gayagay3.IsVisible = false; gayagay4.IsVisible = false; b.Children.Add(gayagay, 0, 0); Grid.SetColumnSpan(gayagay, 4); b.Children.Add(gayagay1, 0, 0); b.Children.Add(gayagay2, 1, 0); b.Children.Add(gayagay3, 2, 0); b.Children.Add(gayagay4, 3, 0); var AdSoyad = new Button() { HeightRequest = 50, WidthRequest = 50, BackgroundColor = Color.FromHex("#1a94d2"), VerticalOptions = LayoutOptions.Center, HorizontalOptions = LayoutOptions.Center }; var adsoyad = new ExtendedListView() { HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.Start, HeightRequest = Device.OnPlatform(410, 350, 350) }; adsoyad.Items = new List <EntityClass>() { new EntityClass() { Id = 1, Title = "Ad Soyad: " + GirisSayfasi.manager.prof.FirstName + " " + GirisSayfasi.manager.prof.LastName, }, new EntityClass() { Id = 1, Title = "Şirket: " + GirisSayfasi.manager.prof.Company, }, new EntityClass() { Id = 1, Title = "Ünvan: " + GirisSayfasi.manager.prof.JobTitle, }, new EntityClass() { Id = 1, Title = "Şehir: " + GirisSayfasi.manager.prof.City, }, new EntityClass() { Id = 1, Title = "Telefon: " + GirisSayfasi.manager.prof.TelNo, }, new EntityClass() { Id = 1, Title = "e-mail: " + GirisSayfasi.manager.prof.EMail, } }; var SosyalAg = new Button() { HeightRequest = 50, WidthRequest = 50, BackgroundColor = Color.FromHex("#00aeb3"), VerticalOptions = LayoutOptions.Center, HorizontalOptions = LayoutOptions.Center }; var sosyalAg = new ExtendedListView() { HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.Start, HeightRequest = Device.OnPlatform(410, 350, 350) }; sosyalAg.Items = new List <EntityClass>() { new EntityClass() { Id = 0, Title = "Facebook: " + GirisSayfasi.manager.prof.FaceAccount, }, new EntityClass() { Id = 1, Title = "LinkedIn: " + GirisSayfasi.manager.prof.LinkedAccount, }, new EntityClass() { Id = 1, Title = "Twitter: " + GirisSayfasi.manager.prof.TwitterAccount, }, new EntityClass() { Id = 1, Title = "Instagram: " + GirisSayfasi.manager.prof.InstaAccount, } }; var TBilgi = new Button() { HeightRequest = 50, WidthRequest = 50, BackgroundColor = Color.FromHex("#9e9fa2"), VerticalOptions = LayoutOptions.Center, HorizontalOptions = LayoutOptions.Start }; var Temel = new ExtendedListView() { HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.Start, HeightRequest = Device.OnPlatform(410, 350, 350) }; Temel.Items = new List <EntityClass>() { new EntityClass() { Id = 0, Title = AppResource.profilentitychildclassname10, ChildItems = new List <EntityClass>() { new EntityClass() { Id = 1, Title = "Ad Soyad: " + GirisSayfasi.manager.prof.FirstName + " " + GirisSayfasi.manager.prof.LastName, }, new EntityClass() { Id = 2, Title = "Şehir: " + GirisSayfasi.manager.prof.City }, new EntityClass() { Id = 3, Title = "Memleket: " + GirisSayfasi.manager.prof.Hometown }, new EntityClass() { Id = 4, Title = "Doğum Günü: " + GirisSayfasi.manager.prof.BirthDate.ToString() } } }, new EntityClass() { Id = 5, Title = AppResource.profilentitychildclassname11, ChildItems = new List <EntityClass>() { new EntityClass() { Id = 6, Title = "Telefon: " + GirisSayfasi.manager.prof.TelNo }, new EntityClass() { Id = 7, Title = "e-mail: " + GirisSayfasi.manager.prof.EMail }, new EntityClass() { Id = 8, Title = "Ofis Adresi: " + GirisSayfasi.manager.prof.OfficeAddress }, new EntityClass() { Id = 9, Title = "Asistan İsmi: " + GirisSayfasi.manager.prof.AssistantName } } }, new EntityClass() { Id = 10, Title = AppResource.profilentitychildclassname12, ChildItems = new List <EntityClass>() { new EntityClass() { Id = 11, Title = "Şirket: " + GirisSayfasi.manager.prof.Company, }, new EntityClass() { Id = 12, Title = "Ünvan: " + GirisSayfasi.manager.prof.JobTitle }, new EntityClass() { Id = 13, Title = "Önceki Şirketler: " + GirisSayfasi.manager.prof.PreviousCompanies }, new EntityClass() { Id = 14, Title = "Uzmanlıklar: " + GirisSayfasi.manager.prof.Profficiencies }, new EntityClass() { Id = 15, Title = "Projeler: " + GirisSayfasi.manager.prof.Projects }, new EntityClass() { Id = 16, Title = "Sertifikalar: " + GirisSayfasi.manager.prof.Sertificates }, } }, new EntityClass() { Id = 17, Title = AppResource.profilentitychildclassname13, ChildItems = new List <EntityClass>() { new EntityClass() { Id = 18, Title = "Üniversite: " + GirisSayfasi.manager.prof.Universities, }, new EntityClass() { Id = 19, Title = "Lise: " + GirisSayfasi.manager.prof.HighSchool } } } }; var KisiselBil = new Button() { HeightRequest = 50, WidthRequest = 50, BackgroundColor = Device.OnPlatform(Color.FromHex("#c5c2c2"), Color.FromHex("#fff"), Color.FromHex("#fff")), VerticalOptions = LayoutOptions.Center, HorizontalOptions = LayoutOptions.End, }; var KisiselBilgi = new ExtendedListView() { HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.Start, HeightRequest = Device.OnPlatform(410, 350, 350) }; KisiselBilgi.Items = new List <EntityClass>() { new EntityClass() { Id = 0, Title = "Eş ve Çocuklar: " + GirisSayfasi.manager.prof.FamilyMembers, }, new EntityClass() { Id = 1, Title = "Ev Adresi: " + GirisSayfasi.manager.prof.HomeAddress, }, new EntityClass() { Id = 1, Title = "Vakıf ve Dernekler: " + GirisSayfasi.manager.prof.FoundAssociates, }, new EntityClass() { Id = 1, Title = "İlgilenilen Sporlar:" + GirisSayfasi.manager.prof.Sports, }, new EntityClass() { Id = 1, Title = "Hobiler: " + GirisSayfasi.manager.prof.Hobbies, }, new EntityClass() { Id = 1, Title = "Facori takım: " + GirisSayfasi.manager.prof.Team, }, new EntityClass() { Id = 1, Title = "Seyehatler: " + GirisSayfasi.manager.prof.Travels, } }; for (var i = 0; i < 57; i++) { a.ColumnDefinitions.Add(new ColumnDefinition { Width = new GridLength(1, GridUnitType.Star) }); } for (var i = 0; i < 114; i++) { a.RowDefinitions.Add(new RowDefinition { Height = new GridLength(1, GridUnitType.Star) }); } var img = new Image() { Source = "doldurbar.png", HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand }; var img1 = new Image() { Source = "kendiprofil.png", HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand }; var img2 = new Image() { Source = "profilduzenle.png", HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand, HeightRequest = 30, WidthRequest = 30 }; var lockKey = new Image() { Source = "lock.png", HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand, HeightRequest = 30, WidthRequest = 30 }; var light = new Image() { Source = "light.png", HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand, HeightRequest = 30, WidthRequest = 30 }; var book = new Image() { Source = "book.png", HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand, HeightRequest = 30, WidthRequest = 30 }; var sosyalag = new Image() { Source = "sosyalag.png", HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand, HeightRequest = 30, WidthRequest = 30 }; var bt3 = new StackLayout() { HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand, BackgroundColor = Color.FromHex("#eee") }; d.Children.Add(adsoyad, 0, 0); /*void OnButtonClicked(object sender, EventArgs e) * { * * if (thebool == false) * { * if (thebool2 == true) * d.Children.Remove(sosyalAg); * if (thebool3 == true) * d.Children.Remove(Temel); * if (thebool4 == true) * d.Children.Remove(KisiselBilgi); * d.Children.Add(adsoyad, 0, 0); * * * * * thebool = true; * thebool2 = false; * thebool3 = false; * thebool4 = false; * * gayagay1.IsVisible = true; * gayagay2.IsVisible = false; * gayagay3.IsVisible = false; * gayagay4.IsVisible = false; * } * * * }; * * * void OnButtonClicked2(object sender, EventArgs e) * { * * * if (thebool2 == false) * { * if (thebool == true) * d.Children.Remove(adsoyad); * if (thebool3 == true) * d.Children.Remove(Temel); * if (thebool4 == true) * d.Children.Remove(KisiselBilgi); * d.Children.Add(sosyalAg, 0, 0); * * * * thebool = false; * thebool2 = true; * thebool3 = false; * thebool4 = false; * * gayagay1.IsVisible = false; * gayagay2.IsVisible = true; * gayagay3.IsVisible = false; * gayagay4.IsVisible = false; * } * * * }; * * * void OnButtonClicked3(object sender, EventArgs e){ * * * if (thebool3 == false) * { * if (thebool == true) * d.Children.Remove(adsoyad); * if (thebool2 == true) * d.Children.Remove(sosyalAg); * if (thebool4==true) * d.Children.Remove(KisiselBilgi); * d.Children.Add(Temel, 0, 0); * * * * thebool = false; * thebool2 = false; * thebool3 = true; * thebool4 = false; * * gayagay1.IsVisible = false; * gayagay2.IsVisible = false; * gayagay3.IsVisible = true; * gayagay4.IsVisible = false; * } * * * }; * * * void OnButtonClicked4(object sender, EventArgs e) * { * * * if (thebool4 == false) * { * if (thebool == true) * d.Children.Remove(adsoyad); * if (thebool2 == true) * d.Children.Remove(sosyalAg); * if (thebool3 == true) * d.Children.Remove(Temel); * * d.Children.Add(KisiselBilgi, 0, 0); * * * * thebool = false; * thebool2 = false; * thebool3 = false; * thebool4 = true; * * gayagay1.IsVisible = false; * gayagay2.IsVisible = false; * gayagay3.IsVisible = false; * gayagay4.IsVisible = true; * } * * * };*/ a.Children.Add(d, 0, 45); Grid.SetColumnSpan(d, 57); Grid.SetRowSpan(d, 42); a.Children.Add(img, 19, 7); Grid.SetColumnSpan(img, 20); Grid.SetRowSpan(img, 22); a.Children.Add(img1, 22, 10); Grid.SetColumnSpan(img1, 14); Grid.SetRowSpan(img1, 16); a.Children.Add(img2, 47, 3); Grid.SetColumnSpan(img2, 8); Grid.SetRowSpan(img2, 9); a.Children.Add(AdSoyad, 3, 35); Grid.SetColumnSpan(AdSoyad, 8); Grid.SetRowSpan(AdSoyad, 8); a.Children.Add(book, 3, 35); Grid.SetColumnSpan(book, 8); Grid.SetRowSpan(book, 8); a.Children.Add(SosyalAg, 17, 35); Grid.SetColumnSpan(SosyalAg, 8); Grid.SetRowSpan(SosyalAg, 8); a.Children.Add(sosyalag, 17, 35); Grid.SetColumnSpan(sosyalag, 8); Grid.SetRowSpan(sosyalag, 8); a.Children.Add(TBilgi, 32, 35); Grid.SetColumnSpan(TBilgi, 8); Grid.SetRowSpan(TBilgi, 8); a.Children.Add(light, 32, 35); Grid.SetColumnSpan(light, 8); Grid.SetRowSpan(light, 8); a.Children.Add(KisiselBil, 46, 35); Grid.SetColumnSpan(KisiselBil, 8); Grid.SetRowSpan(KisiselBil, 8); a.Children.Add(lockKey, 46, 35); Grid.SetColumnSpan(lockKey, 8); Grid.SetRowSpan(lockKey, 8); a.Children.Add(b, 0, 44); Grid.SetColumnSpan(b, 57); Grid.SetRowSpan(b, 2); a.Children.Add(bt3, 0, 113); Grid.SetColumnSpan(bt3, 57); var tapGestureRecognizers = new TapGestureRecognizer(); tapGestureRecognizers.Tapped += (s, e) => { if (thebool == false) { if (thebool2 == true) { d.Children.Remove(sosyalAg); } if (thebool3 == true) { d.Children.Remove(Temel); } if (thebool4 == true) { d.Children.Remove(KisiselBilgi); } d.Children.Add(adsoyad, 0, 0); thebool = true; thebool2 = false; thebool3 = false; thebool4 = false; gayagay1.IsVisible = true; gayagay2.IsVisible = false; gayagay3.IsVisible = false; gayagay4.IsVisible = false; } }; book.GestureRecognizers.Add(tapGestureRecognizers); var tapGestureRecognizers1 = new TapGestureRecognizer(); tapGestureRecognizers1.Tapped += (s, e) => { if (thebool2 == false) { if (thebool == true) { d.Children.Remove(adsoyad); } if (thebool3 == true) { d.Children.Remove(Temel); } if (thebool4 == true) { d.Children.Remove(KisiselBilgi); } d.Children.Add(sosyalAg, 0, 0); thebool = false; thebool2 = true; thebool3 = false; thebool4 = false; gayagay1.IsVisible = false; gayagay2.IsVisible = true; gayagay3.IsVisible = false; gayagay4.IsVisible = false; } }; sosyalag.GestureRecognizers.Add(tapGestureRecognizers1); var tapGestureRecognizers2 = new TapGestureRecognizer(); tapGestureRecognizers2.Tapped += (s, e) => { if (thebool3 == false) { if (thebool == true) { d.Children.Remove(adsoyad); } if (thebool2 == true) { d.Children.Remove(sosyalAg); } if (thebool4 == true) { d.Children.Remove(KisiselBilgi); } d.Children.Add(Temel, 0, 0); thebool = false; thebool2 = false; thebool3 = true; thebool4 = false; gayagay1.IsVisible = false; gayagay2.IsVisible = false; gayagay3.IsVisible = true; gayagay4.IsVisible = false; } }; light.GestureRecognizers.Add(tapGestureRecognizers2); var tapGestureRecognizers3 = new TapGestureRecognizer(); tapGestureRecognizers3.Tapped += (s, e) => { if (thebool4 == false) { if (thebool == true) { d.Children.Remove(adsoyad); } if (thebool2 == true) { d.Children.Remove(sosyalAg); } if (thebool3 == true) { d.Children.Remove(Temel); } d.Children.Add(KisiselBilgi, 0, 0); thebool = false; thebool2 = false; thebool3 = false; thebool4 = true; gayagay1.IsVisible = false; gayagay2.IsVisible = false; gayagay3.IsVisible = false; gayagay4.IsVisible = true; } }; lockKey.GestureRecognizers.Add(tapGestureRecognizers3); var tapGestureRecognizer = new TapGestureRecognizer(); tapGestureRecognizer.Tapped += async(s, e) => { await Navigation.PushModalAsync(new ProfilDuzenle(GirisSayfasi.manager.prof)); }; img2.GestureRecognizers.Add(tapGestureRecognizer); Content = a; }
public virtual void AddRange(ExtendedListView.Forms.ToggleColumnHeader[] items) { lock(List.SyncRoot) { for (int i=0; i< items.Length; i++) { items[i].WidthResized += new EventHandler(OnWidthResized); List.Add(items[i]); } } }
public Sorter(ExtendedListView lstView) { this.listView = lstView; }