Exemplo n.º 1
0
        public App()
        {
            GmsPlace.Init("AIzaSyAPG4sE6X99SivTUHCz7FnIi2gzfh1C_U8");
            GmsDirection.Init("AIzaSyCJN3Cd-Sp1a5V5OnkvTR-Gqhx7A3S-b6M");

            MainPage = new Master();
        }
Exemplo n.º 2
0
        public App()
        {
            GmsPlace.Init("AIzaSyDx0rnc6jDr5VtGYgqhDQ3VvanZ1ko4S9M");
            GmsDirection.Init("AIzaSyDx0rnc6jDr5VtGYgqhDQ3VvanZ1ko4S9M");
            // The root page of your application
            var content = new ContentPage
            {
                Title   = "Ezi.CustomMap",
                Content = new StackLayout
                {
                    VerticalOptions = LayoutOptions.Center,
                    Children        =
                    {
                        new Label {
                            HorizontalTextAlignment = TextAlignment.Center,
                            Text = "Welcome to Xamarin Forms!"
                        }
                    }
                }
            };

            MainPage = new NavigationPage(content);
            var mainPage = new NavigationPage(new SamplePage());

            if (Device.OS == TargetPlatform.iOS)
            {
                mainPage.BarBackgroundColor = Color.FromHex("#f1f1f1");
            }
            MainPage = mainPage;
        }
Exemplo n.º 3
0
 public App()
 {
     LiveReload.Init();
     InitializeComponent();
     GmsDirection.Init("AIzaSyDW67S9GCGz-Ys9cahFsQm6VsQfDxNNIkE");
     //MainPage = new Views.MDPage();
     NavigationService.Current.SetarMainPage <SplashViewModel>();
 }
Exemplo n.º 4
0
 public App()
 {
     InitializeComponent();
     ChangeHandler = new SemesterChangeHandler();
     GmsPlace.Init("AIzaSyCjMY_194mgeHLsyhlPre7kZ-UVXHCCt0o");
     GmsDirection.Init("AIzaSyCJN3Cd-Sp1a5V5OnkvTR-Gqhx7A3S-b6M");
     MainPage = new MainPageCS();
 }
Exemplo n.º 5
0
 public OrdersPage()
 {
     InitializeComponent();
     Settings.LastNotify = null;
     GmsDirection.Init("AIzaSyB7rB6s8fc317zCPz8HS_yqwi7HjMsAqks");
     SetMyLocation();
     OrderMap.RouteCalculationFinished += OrderMap_RouteCalculationFinished;
     OrderMap.RouteCalculationFailed   += OrderMap_RouteCalculationFailed;
 }
Exemplo n.º 6
0
        public App()
        {
            Register();
            GmsDirection.Init("AIzaSyASYVBniofTez5ZkWBEc1-3EEby_bZeRJk");
            var page     = FreshPageModelResolver.ResolvePageModel <LoginPageModel>(this);
            var mainPage = new FreshNavigationContainer(page);

            MainPage = mainPage;
        }
Exemplo n.º 7
0
        public App()
        {
            InitializeComponent();

            GmsPlace.Init("AIzaSyCr2z_PnUvCFuKNnt_UAGed0jaMWWhDpz0");
            GmsDirection.Init("AIzaSyCr2z_PnUvCFuKNnt_UAGed0jaMWWhDpz0");

            MainPage = new MasterAppointment();
        }
Exemplo n.º 8
0
        public App()
        {
            InitializeComponent();
            GmsPlace.Init("AIzaSyADpUdHb2a44fRcsxtIrKl5JvWzosq3Ihs");
            GmsDirection.Init("AIzaSyBmEqmCV4WQG5NwY0_JRqTxB_1eFTLd-ok");

            MainPage = new NavigationPage();
            MainPage.Navigation.PushAsync(new StartPage());
        }
Exemplo n.º 9
0
        public App()
        {
            InitializeComponent();

            GmsPlace.Init("AIzaSyDIgc3KeHRMQko6Uviq-8ImCdRclzG2v0I");
            GmsDirection.Init("AIzaSyDIgc3KeHRMQko6Uviq-8ImCdRclzG2v0I");

            MainPage = new NavigationPage(new MainView(null));
        }
Exemplo n.º 10
0
        public App(GeoJSONData dat, List <VenueLocation> venues)
        {
            InitializeComponent();
            ChangeHandler = new SemesterChangeHandler();
            GmsPlace.Init("AIzaSyCjMY_194mgeHLsyhlPre7kZ-UVXHCCt0o");
            GmsDirection.Init("AIzaSyCJN3Cd-Sp1a5V5OnkvTR-Gqhx7A3S-b6M");
            var temp = new GEOJSONTOJSONParser(dat, venues);//the Dat file sent by each platform to the parent App

            temp.Process();
            MainPage = new MainPageCS();
        }
Exemplo n.º 11
0
 public OrderPushPage()
 {
     InitializeComponent();
     FlowDirection = (Settings.LastUserGravity == "Arabic") ? FlowDirection.RightToLeft
           : FlowDirection.LeftToRight;
     AppResources.Culture = CrossMultilingual.Current.CurrentCultureInfo;
     ChechNotification();
     GmsDirection.Init("AIzaSyB7rB6s8fc317zCPz8HS_yqwi7HjMsAqks");
     SetMyLocation();
     OrderMap.RouteCalculationFinished += OrderMap_RouteCalculationFinished;
     OrderMap.RouteCalculationFailed   += OrderMap_RouteCalculationFailed;
 }
Exemplo n.º 12
0
        //Page MenuPage = new MenuPage();


        public App()
        {
            InitializeComponent();

            GmsPlace.Init("AIzaSyDAmhu79jCKlkE6KIVSqgxlIl83gJj_rkk");
            GmsDirection.Init("AIzaSyDAmhu79jCKlkE6KIVSqgxlIl83gJj_rkk");

            Syncfusion.Licensing.SyncfusionLicenseProvider.RegisterLicense("MjQzMkAzMTM2MmUzMjJlMzBiRXp6WjNDdFdzZTRjcmc4YWxJdXU2eVZ2OHhWOWJ0dHhQakVvZ0YvZmNZPQ==");
            //MainPage = new NavigationPage( new LoginPage());
            NavigationService navigationService = new NavigationService();

            navigationService.SetMainPage();
        }
Exemplo n.º 13
0
        public App()
        {
            GmsPlace.Init("AIzaSyCwxK-1FnusRJOx1ZpcTS5dpIoJZH9h0Eg");
            GmsDirection.Init("AIzaSyCwxK-1FnusRJOx1ZpcTS5dpIoJZH9h0Eg");
            // The root page of your application
            var mainPage = new NavigationPage(new SamplePage());

            if (Device.OS == TargetPlatform.iOS)
            {
                mainPage.BarBackgroundColor = Color.FromHex("#f1f1f1");
            }
            MainPage = mainPage;
        }
Exemplo n.º 14
0
        public App()
        {
            InitializeComponent();

            GmsPlace.Init("AIzaSyDAmhu79jCKlkE6KIVSqgxlIl83gJj_rkk");
            GmsDirection.Init("AIzaSyDAmhu79jCKlkE6KIVSqgxlIl83gJj_rkk");

            NavigationService navigationService = new NavigationService();

            navigationService.SetMainPage();

            //MainPage = new MainPage();
        }
Exemplo n.º 15
0
        public App()
        {
            GmsPlace.Init("YOUR API KEY");
            GmsDirection.Init("AIzaSyCJN3Cd-Sp1a5V5OnkvTR-Gqhx7A3S-b6M");
            // The root page of your application
            var mainPage = new NavigationPage(new SamplePage());

            if (Device.OS == TargetPlatform.iOS)
            {
                mainPage.BarBackgroundColor = Color.FromHex("#f1f1f1");
            }
            MainPage = mainPage;
        }
Exemplo n.º 16
0
 public OrderSuccessPage()
 {
     InitializeComponent();
     FlowDirection = (Settings.LastUserGravity == "Arabic") ? FlowDirection.RightToLeft
          : FlowDirection.LeftToRight;
     AppResources.Culture = CrossMultilingual.Current.CurrentCultureInfo;
     //  OneSignal.Current.StartInit("f5f4f650-3453-456c-8024-010ea68e738b")
     //.InFocusDisplaying(OSInFocusDisplayOption.None)
     //.HandleNotificationReceived(OnNotificationRecevied)
     //.HandleNotificationOpened(OnNotificationOpened)
     //.EndInit();
     GmsDirection.Init("AIzaSyB7rB6s8fc317zCPz8HS_yqwi7HjMsAqks");
     SetMyLocation();
 }
Exemplo n.º 17
0
        public App()
        {
            try
            {
                GmsPlace.Init(ApplicationSettings.MapsApiKey);
                GmsDirection.Init(ApplicationSettings.MapsApiKey);
                Current.Resources = new ResourceDictionary();
                ApplicationSettings.Notificator         = DependencyService.Get <IToastNotificator>();
                ApplicationSettings.Service.ErrorEvent += Service_ErrorEvent;
                ApplicationSettings.MainApp             = this;
                ApplicationSettings.DataBase            = new MapBulDataBaseRepository("MapBulDb.db");
                Plugin.Connectivity.CrossConnectivity.Current.ConnectivityChanged += Current_ConnectivityChanged;
                DateTime lastLogin;
                ApplicationSettings.LoadCategories();
                lastLogin = ApplicationSettings.DataBase.Users.Any()
                    ? ApplicationSettings.DataBase.Users.Max(item => item.LastLogin)
                    : DateTime.MinValue;
                var currentUser = ApplicationSettings.DataBase.Users.FirstOrDefault(item => item.LastLogin == lastLogin);
                if (currentUser != null)
                {
                    currentUser.LastLogin = DateTime.UtcNow;
                    ApplicationSettings.DataBase.SaveUser(currentUser);
                }
                ApplicationSettings.SetCurrentSession();
                ApplicationSettings.CurrentUser.SetUser(currentUser);
                NavigationPage.SetHasNavigationBar(this, false);//скрыть ActionBar
                MainPage = new MyMasterDetailPage();

                if (ApplicationSettings.CurrentUser.IsLogined || ApplicationSettings.CurrentUser.UserType == UserTypesMobile.Guest)
                {
                    ApplicationSettings.LoadFavorites();
                    ApplicationSettings.MainPage.Navigation.PushAsync(new TKMapView());
                }
                else
                {
                    ApplicationSettings.MainPage.Navigation.PushAsync(new LoginView());
                }
            }
            catch (Exception e)
            {
                throw;
            }
        }
Exemplo n.º 18
0
 public void SetMapKey(string key)
 {
     GmsPlace.Init(key);
     GmsDirection.Init(key);
 }
Exemplo n.º 19
0
        /// <summary>
        /// Inflates the views.
        /// N.B. The MapsMainPage will be added as soon as Xamarin fixes issue where
        /// GooglePlay services v42 works with the latest version of xamarin forms
        /// </summary>
        public void InflateViews()
        {
            GmsDirection.Init("AIzaSyCjMY_194mgeHLsyhlPre7kZ-UVXHCCt0o");
            SfTabItem mnday = new SfTabItem();

            mnday.Content                 = new Monday();
            mnday.Title                   = "Monday";
            mnday.TitleFontColor          = Color.Black;
            mnday.Content.BackgroundColor = Color.WhiteSmoke;
            SfTabItem tues = new SfTabItem();

            tues.Title                   = "Tuesday";
            tues.TitleFontColor          = Color.Black;
            tues.Content                 = new Tuesday();
            tues.Content.BackgroundColor = Color.WhiteSmoke;
            SfTabItem wed = new SfTabItem();

            wed.Title                   = "Wednesday";
            wed.TitleFontColor          = Color.Black;
            wed.Content                 = new Wednesday();
            wed.Content.BackgroundColor = Color.WhiteSmoke;
            SfTabItem thurs = new SfTabItem();

            thurs.Title                   = "Thursday";
            thurs.TitleFontColor          = Color.Black;
            thurs.Content                 = new Thursday();
            thurs.Content.BackgroundColor = Color.WhiteSmoke;
            SfTabItem fri = new SfTabItem();

            fri.Title                   = "Friday";
            fri.TitleFontColor          = Color.Black;
            fri.Content                 = new Friday();
            fri.Content.BackgroundColor = Color.WhiteSmoke;
            SfTabItem daySummary = new SfTabItem();

            daySummary.Title          = "Day Summary";
            daySummary.TitleFontColor = Color.Black;
            daySummary.Content        = new DaySummary();
            SfTabItem addTimetable = new SfTabItem();

            addTimetable.Title          = "Add Timetable";
            addTimetable.TitleFontColor = Color.Black;
            addTimetable.Content        = new AddTimetable();
            SfTabItem Main = new SfTabItem();

            Main.Title          = "Menu";
            Main.TitleFontColor = Color.Black;
            Main.Content        = new SfTabView {
                DisplayMode        = TabDisplayMode.ImageWithText,
                VisibleHeaderCount = 2,
                BackgroundColor    = Color.White,
                EnableSwiping      = true,
                Items = new TabItemCollection {
                    daySummary, addTimetable
                },
            };
            Grid main = new Grid {
                BackgroundColor = Color.White
            };

            main.Children.Add(new SfTabView()
            {
                DisplayMode = TabDisplayMode.ImageWithText, EnableSwiping = true, BackgroundColor = Color.WhiteSmoke, Items = new TabItemCollection {
                    Main, mnday, tues, wed, thurs, fri
                }
            });
            Content = main;
        }
Exemplo n.º 20
0
        public App()
        {
            InitializeComponent();
            TK.CustomMap.Api.Google.GmsPlace.Init(Constant.APIKey);
            GmsDirection.Init(Constant.APIKey);
            //MainPage = new MapView();
            // The root page of your application
            MyCustomMap map = new MyCustomMap();

            map.MapType = MapType.Street;
            map.MoveToRegion(MapSpan.FromCenterAndRadius(new Position(17.4474, 78.3762), Distance.FromKilometers(8)));
            map.CustomPins = new List <TKCustomMapPin>(new[]
            {
                new TKCustomMapPin
                {
                    Title       = "Custom Callout Sample",
                    Position    = new Position(17.4474, 78.3762),
                    ShowCallout = true,
                    IsDraggable = true
                }
            });



            Entry searchPosition = new Entry()
            {
                Placeholder   = "Search Places",
                WidthRequest  = 250,
                HeightRequest = 35,
                TextColor     = Color.Red
            };
            Button btnSearch = new Button()
            {
                Text            = "Search Now",
                TextColor       = Color.White,
                BackgroundColor = Color.Black,
                FontSize        = 12
            };
            StackLayout stkSearch = new StackLayout()
            {
                Orientation = StackOrientation.Horizontal,
                Margin      = new Thickness(5, 10, 5, 5)
            };

            stkSearch.Children.Add(searchPosition);
            stkSearch.Children.Add(btnSearch);
            //MainPage = new ContentPage
            //{
            //    Content = new StackLayout
            //    {
            //        Children =
            //        {
            //            stkSearch,
            //            map
            //        }
            //    }
            //};


            MainPage = new NavigationPage(new SamplePage()); //new SamplePage()
        }