예제 #1
0
 public Styles()
 {
     this.SfGrid = new SfDataGrid();
     viewmodel   = new GridGettingStartedViewModel();
     this.SfGrid.AutoGeneratingColumn += GridAutoGenerateColumns;
     this.SfGrid.ItemsSource           = viewmodel.OrdersInfo;
     this.SfGrid.ShowRowHeader         = false;
     this.SfGrid.HeaderRowHeight       = 45;
     this.SfGrid.RowHeight             = 45;
     this.SfGrid.SelectionMode         = SelectionMode.Multiple;
     this.SfGrid.GridViewCreated      += SfGrid_GridViewCreated;
     this.SfGrid.GroupColumnDescriptions.Add(new GroupColumnDescription()
     {
         ColumnName = "CustomerID"
     });
     this.SfGrid.AlternatingRowColor = UIColor.FromRGB(25, 25, 25);
     segmentControl = new UISegmentedControl();
     segmentControl.ControlStyle = UISegmentedControlStyle.Bezeled;
     segmentControl.InsertSegment("Dark", 0, true);
     segmentControl.InsertSegment("Blue", 1, true);
     segmentControl.InsertSegment("Red", 2, true);
     segmentControl.InsertSegment("Green", 3, true);
     segmentControl.SelectedSegment = 0;
     segmentControl.ValueChanged   += SegmentControl_ValueChanged;
     this.control = this;
     this.AddSubview(segmentControl);
     this.AddSubview(SfGrid);
 }
예제 #2
0
		public Styles()
		{
			this.SfGrid = new SfDataGrid ();
			viewmodel = new GridGettingStartedViewModel ();
			this.SfGrid.AutoGeneratingColumn += GridAutoGenerateColumns;
			this.SfGrid.ItemsSource = viewmodel.OrdersInfo;
			this.SfGrid.ShowRowHeader = false;
			this.SfGrid.HeaderRowHeight = 45;
			this.SfGrid.RowHeight = 45;
			this.SfGrid.SelectionMode = SelectionMode.Multiple;
			this.SfGrid.GridViewCreated += SfGrid_GridViewCreated;
			this.SfGrid.GroupColumnDescriptions.Add (new GroupColumnDescription(){ColumnName ="CustomerID"});
			this.SfGrid.AlternatingRowColor = UIColor.FromRGB (25, 25, 25);
			segmentControl = new UISegmentedControl();
			segmentControl.ControlStyle = UISegmentedControlStyle.Bezeled;
			segmentControl.InsertSegment("Dark", 0,true);
			segmentControl.InsertSegment("Blue", 1, true);
			segmentControl.InsertSegment("Red", 2, true);
			segmentControl.InsertSegment("Green", 3, true);
			segmentControl.SelectedSegment = 0;
			segmentControl.ValueChanged += SegmentControl_ValueChanged;
			this.control = this;
			this.AddSubview (segmentControl);
			this.AddSubview (SfGrid);
		}
예제 #3
0
 protected override void Dispose(bool disposing)
 {
     if (disposing)
     {
         if (segmentControl != null)
         {
             segmentControl.ValueChanged -= SegmentControl_ValueChanged;
         }
         if (SfGrid != null)
         {
             SfGrid.GridViewCreated      -= SfGrid_GridViewCreated;
             SfGrid.AutoGeneratingColumn -= GridAutoGenerateColumns;
             SfGrid.Dispose();
         }
         segmentControl = null;
         viewmodel      = null;
         SfGrid         = null;
     }
     base.Dispose(disposing);
 }
 public SfDataGridInPullToRefresh()
 {
     this.pullToRefresh = new SfPullToRefresh();
     this.pullToRefresh.RefreshContentThreshold = 45;
     this.SfGrid = new SfDataGrid();
     this.SfGrid.SelectionMode         = SelectionMode.Single;
     this.SfGrid.AutoGeneratingColumn += GridAutoGenerateColumns;
     viewModel = new GridGettingStartedViewModel();
     this.SfGrid.ItemsSource     = viewModel.OrdersInfo;
     this.SfGrid.ShowRowHeader   = false;
     this.SfGrid.HeaderRowHeight = 45;
     this.SfGrid.RowHeight       = 45;
     this.SfGrid.GridStyle.AlternatingRowColor = UIColor.FromRGB(219, 219, 219);
     this.SfGrid.AllowResizingColumn           = true;
     this.SfGrid.GridStyle = new CustomGridStyle();
     this.pullToRefresh.PullableContent = SfGrid;
     this.pullToRefresh.Refreshing     += PullToRefresh_Refreshing;
     this.AddSubview(this.pullToRefresh);
     this.OptionView = new Options(pullToRefresh);
 }
예제 #5
0
 public Styles()
 {
     this.SfGrid = new SfDataGrid();
     viewmodel   = new GridGettingStartedViewModel();
     this.SfGrid.AutoGeneratingColumn += GridAutoGenerateColumns;
     this.SfGrid.ItemsSource           = viewmodel.OrdersInfo;
     this.SfGrid.ShowRowHeader         = false;
     this.SfGrid.HeaderRowHeight       = 45;
     this.SfGrid.RowHeight             = 45;
     this.SfGrid.SelectionMode         = SelectionMode.Multiple;
     this.SfGrid.GridViewCreated      += SfGrid_GridViewCreated;
     segmentControl = new UISegmentedControl();
     segmentControl.ControlStyle = UISegmentedControlStyle.Bezeled;
     segmentControl.InsertSegment("Dark", 0, true);
     segmentControl.InsertSegment("Blue", 1, true);
     segmentControl.InsertSegment("Red", 2, true);
     segmentControl.InsertSegment("Green", 3, true);
     segmentControl.InsertSegment("Purple", 4, true);
     segmentControl.SelectedSegment = 4;
     segmentControl.ValueChanged   += SegmentControl_ValueChanged;
     this.AddSubview(segmentControl);
     this.AddSubview(SfGrid);
 }