Exemplo n.º 1
0
        private async void ListView_ItemClick(object sender, ItemTappedEventArgs e)
        {
            ToolbarItemModel item = (ToolbarItemModel)SecondaryToolbarListView.SelectedItem;
            string           url  = "https://iroai.app/";

            if (item.Name == "USER")
            {
                url = "https://iroai.app/users/";
            }
            else if (item.Name == "HELP")
            {
                url = "https://iroai.app/manual/";
            }
            else if (item.Name == "AUTHOR")
            {
                url = "https://iroai.app/copyright/";
            }
            if (isConnected == 2 || isConnected == 0 && CrossConnectivity.IsSupported && CrossConnectivity.Current.IsConnected)
            {
                bool checkalert;
                checkalert = await DisplayAlert("", "アプリから移動します\nよろしいですか?", "はい", "キャンセル");

                if (checkalert)
                {
                    await Navigation.PushModalAsync(new InAppBrowserXaml(url));
                }
            }
            else
            {
                await DisplayAlert("", "オフラインのためサイトが表示されません。", "はい");
            }
            CloseAllPopup();
        }
Exemplo n.º 2
0
        private async void ListView_ItemClick(object sender, ItemTappedEventArgs e)
        {
            ToolbarItemModel item = (ToolbarItemModel)SecondaryToolbarListView.SelectedItem;

            if (item.Name == "Camera")
            {
                await TakePhoto();
            }
            else if (item.Name == "Library")
            {
                await PickPhoto();
            }
            else if (item.Name == "Export")
            {
                await Navigation.PushModalAsync(new Export());
            }
            else if (item.Name == "Import")
            {
                await importPhoto();
            }
            CloseAllPopup();
        }