Esempio n. 1
0
        public override bool FinishedLaunching(UIApplication app, NSDictionary options)
        {
            FirebasePushNotificationManager.Initialize(options, true);

            global::Xamarin.Forms.Forms.Init();
            KeyboardOverlap.Forms.Plugin.iOSUnified.KeyboardOverlapRenderer.Init();

            global::Xamarin.Auth.Presenters.XamarinIOS.AuthenticationConfiguration.Init();

            FormsMaps.Init();

            FFImageLoading.Forms.Touch.CachedImageRenderer.Init();
            var dummy  = new FFImageLoading.Forms.Touch.CachedImageRenderer();
            var ignore = new FFImageLoading.Transformations.CircleTransformation();

            App.ScreenHeight = (int)UIScreen.MainScreen.Bounds.Height;
            App.ScreenWidht  = (int)UIScreen.MainScreen.Bounds.Width;

            //  KeyboardOverlapRenderer.Init();
            LoadApplication(new App());

            var manager = BITHockeyManager.SharedHockeyManager;

            manager.Configure("440c8d3c2763449c86a17a06d73c26e6"); //TODO: CAMBIAR
            manager.StartManager();

            InitNotifiactions(app, options);

            return(base.FinishedLaunching(app, options));
        }
 void AssemblyInit()
 {
     DuGu.XFLib.iOS.ControlSet.Init();
     CarouselView.FormsPlugin.iOS.CarouselViewRenderer.Init();
     FFImageLoading.Forms.Touch.CachedImageRenderer.Init();
     var s = new FFImageLoading.Transformations.RoundedTransformation();
     var a = new FFImageLoading.Transformations.CircleTransformation();
 }
Esempio n. 3
0
        public App()
        {
            InitializeComponent();

            var ignore = new FFImageLoading.Transformations.CircleTransformation();

            MainPage = new Pages.Core.MainPage();
        }
Esempio n. 4
0
        public override bool FinishedLaunching(UIApplication app, NSDictionary options)
        {
            global::Xamarin.Forms.Forms.Init();
            Xamarin.FormsMaps.Init();
            TKCustomMapRenderer.InitMapRenderer();
            LoadApplication(new App());

            FFImageLoading.Forms.Touch.CachedImageRenderer.Init();
            var dummy  = new FFImageLoading.Forms.Touch.CachedImageRenderer();
            var ignore = new FFImageLoading.Transformations.CircleTransformation();

            return(base.FinishedLaunching(app, options));
        }
        //Constructor that sets up the item template for the EventEntry list
        public SchedListView(List <EventEntry> _events, MyEventEntries myEvents = null, EventEntriesMain _mainEvents = null) : base(ListViewCachingStrategy.RecycleElement)
        {
            this.IsPullToRefreshEnabled = false;
            mainEvents = _mainEvents;
            events     = _events;

            Task.Factory.StartNew(() => {
                refresh();
                ItemTemplate = new DataTemplate(() =>
                {
                    RowHeight            = 95;
                    Label Title          = new Label();
                    Title.FontAttributes = FontAttributes.Bold;
                    Title.SetBinding(Label.TextProperty, "Title");
                    Title.MinimumHeightRequest = 50;
                    Title.FontSize             = Xamarin.Forms.AbsoluteLayout.AutoSize;

                    Label date          = new Label();
                    date.FontAttributes = FontAttributes.Italic;
                    date.SetBinding(Label.TextProperty, "StartTime", BindingMode.Default, null, ("{0:MMMM dd}"));
                    date.MinimumHeightRequest = 50;
                    date.FontSize             = Xamarin.Forms.AbsoluteLayout.AutoSize;

                    Label speaker          = new Label();
                    speaker.FontAttributes = FontAttributes.Italic;
                    speaker.SetBinding(Label.TextProperty, "speaker1");
                    speaker.MinimumHeightRequest = 50;
                    speaker.FontSize             = Xamarin.Forms.AbsoluteLayout.AutoSize;

                    Label startEndTime          = new Label();
                    startEndTime.FontAttributes = FontAttributes.Italic;
                    startEndTime.SetBinding(Label.TextProperty, "StartEndTime");
                    startEndTime.MinimumHeightRequest = 50;
                    startEndTime.FontSize             = Xamarin.Forms.AbsoluteLayout.AutoSize;

                    Label location = new Label();
                    location.SetBinding(Label.TextProperty, "Location");
                    location.MinimumHeightRequest = 50;
                    location.FontSize             = Xamarin.Forms.AbsoluteLayout.AutoSize;

                    FFImageLoading.Forms.CachedImage im = new FFImageLoading.Forms.CachedImage()
                    {
                        RetryCount    = 3,   //Number of trys until it gives up
                        RetryDelay    = 200, //Delay between tries (in ms)
                        HeightRequest = 50,
                        WidthRequest  = 50,
                        // DownsampleWidth = 100, //Down sample to predetermined width (maintains aspect ratio)
                        Aspect = Xamarin.Forms.Aspect.AspectFit, //Sets aspect ratio
                        DownsampleToViewSize = true,
                        CacheType            = FFImageLoading.Cache.CacheType.All,
                        IsOpaque             = true,
                        LoadingPriority      = FFImageLoading.Work.LoadingPriority.High,
                        LoadingPlaceholder   = AppResources.defaultPicture
                    };

                    var transform = new FFImageLoading.Transformations.CircleTransformation(10, "#000000");
                    im.Transformations.Add(transform);
                    im.SetBinding(CachedImage.SourceProperty, "ThumbnailStr");
                    im.SetBinding(CachedImage.BackgroundColorProperty, "Color");

                    FFImageLoading.Forms.CachedImage calenderImage = new FFImageLoading.Forms.CachedImage()
                    {
                        IsVisible     = false,
                        HeightRequest = 50,
                        WidthRequest  = 50,
                        // DownsampleWidth = 100, //Down sample to predetermined width (maintains aspect ratio)
                        Aspect = Xamarin.Forms.Aspect.AspectFit, //Sets aspect ratio
                        DownsampleToViewSize = true,
                        CacheType            = FFImageLoading.Cache.CacheType.Memory,
                        IsOpaque             = true,
                        LoadingPriority      = FFImageLoading.Work.LoadingPriority.High,
                        Source = "checklist.png"
                    };
                    calenderImage.SetBinding(CachedImage.IsVisibleProperty, "inMySched");



                    Button addRemove;
                    addRemove = new Button
                    {
                        Text = "Add/Remove",
                    };

                    BoxView boxView = new BoxView
                    {
                        Color             = Color.Gray,
                        HeightRequest     = 1,
                        HorizontalOptions = LayoutOptions.Fill
                    };


                    var tempGrid           = new Grid();
                    tempGrid.RowSpacing    = 2;
                    tempGrid.ColumnSpacing = 5;

                    tempGrid.RowDefinitions.Add(new RowDefinition {
                        Height = new GridLength(1, GridUnitType.Star)
                    });
                    tempGrid.RowDefinitions.Add(new RowDefinition {
                        Height = new GridLength(50, GridUnitType.Star)
                    });
                    tempGrid.RowDefinitions.Add(new RowDefinition {
                        Height = new GridLength(50, GridUnitType.Auto)
                    });
                    tempGrid.RowDefinitions.Add(new RowDefinition {
                        Height = new GridLength(25, GridUnitType.Star)
                    });
                    tempGrid.RowDefinitions.Add(new RowDefinition {
                        Height = new GridLength(25, GridUnitType.Star)
                    });
                    tempGrid.RowDefinitions.Add(new RowDefinition {
                        Height = new GridLength(5, GridUnitType.Star)
                    });

                    tempGrid.ColumnDefinitions.Add(new ColumnDefinition {
                        Width = new GridLength(30, GridUnitType.Star)
                    });
                    tempGrid.ColumnDefinitions.Add(new ColumnDefinition {
                        Width = new GridLength(50, GridUnitType.Star)
                    });
                    tempGrid.ColumnDefinitions.Add(new ColumnDefinition {
                        Width = new GridLength(10, GridUnitType.Star)
                    });
                    tempGrid.ColumnDefinitions.Add(new ColumnDefinition {
                        Width = new GridLength(50, GridUnitType.Star)
                    });
                    tempGrid.ColumnDefinitions.Add(new ColumnDefinition {
                        Width = new GridLength(10, GridUnitType.Star)
                    });
                    //  tempGrid.ColumnDefinitions.Add(new ColumnDefinition { Width = new GridLength(50, GridUnitType.Star) });
                    tempGrid.Children.Add(Title, 1, 4, 1, 3);
                    tempGrid.Children.Add(date, 1, 3);
                    tempGrid.Children.Add(startEndTime, 3, 3);
                    tempGrid.Children.Add(location, 1, 3, 4, 5);
                    tempGrid.Children.Add(speaker, 3, 4);
                    tempGrid.Children.Add(im, 0, 1, 1, 5);
                    tempGrid.Children.Add(calenderImage, 4, 5, 1, 5);
                    //tempGrid.Children.Add(addRemove, 2, 3, 1, 4);
                    tempGrid.Children.Add(boxView, 0, 5, 5, 6);
                    tempGrid.SetBinding(Grid.BackgroundColorProperty, "Color");

                    return(new ViewCell
                    {
                        View = tempGrid
                    });
                });
            }).ContinueWith(task =>
            {
                // scrollToCurrent();
            }, TaskScheduler.FromCurrentSynchronizationContext());
        }