Beispiel #1
0
 public static PendingResult <Status> signOut(GoogleApiClient arg_GoogleApiClient_1)
 {
     return(JavaObjWrapper.StaticInvokeCall <PendingResult <Status> >("com/google/android/gms/games/Games", "signOut", "(Lcom/google/android/gms/common/api/GoogleApiClient;)Lcom/google/android/gms/common/api/PendingResult;", new object[1]
     {
         arg_GoogleApiClient_1
     }));
 }
Beispiel #2
0
 public static object getSettingsIntent(GoogleApiClient arg_GoogleApiClient_1)
 {
     return(JavaObjWrapper.StaticInvokeCall <object>("com/google/android/gms/games/Games", "getSettingsIntent", "(Lcom/google/android/gms/common/api/GoogleApiClient;)Landroid/content/Intent;", new object[1]
     {
         arg_GoogleApiClient_1
     }));
 }
Beispiel #3
0
 public static int getSdkVariant(GoogleApiClient arg_GoogleApiClient_1)
 {
     return(JavaObjWrapper.StaticInvokeCall <int>("com/google/android/gms/games/Games", "getSdkVariant", "(Lcom/google/android/gms/common/api/GoogleApiClient;)I", new object[1]
     {
         arg_GoogleApiClient_1
     }));
 }
Beispiel #4
0
 public static string getCurrentAccountName(GoogleApiClient arg_GoogleApiClient_1)
 {
     return(JavaObjWrapper.StaticInvokeCall <string>("com/google/android/gms/games/Games", "getCurrentAccountName", "(Lcom/google/android/gms/common/api/GoogleApiClient;)Ljava/lang/String;", new object[1]
     {
         arg_GoogleApiClient_1
     }));
 }
 public static PendingResult <Status> signOut(GoogleApiClient arg_GoogleApiClient_1)
 {
     return(JavaObjWrapper.StaticInvokeCall <PendingResult <Status> >(CLASS_NAME, "signOut", "(Lcom/google/android/gms/common/api/GoogleApiClient;)Lcom/google/android/gms/common/api/PendingResult;", arg_GoogleApiClient_1));
 }
 public static void setViewForPopups(GoogleApiClient arg_GoogleApiClient_1, object arg_object_2)
 {
     JavaObjWrapper.StaticInvokeCallVoid(CLASS_NAME, "setViewForPopups", "(Lcom/google/android/gms/common/api/GoogleApiClient;Landroid/view/View;)V", arg_GoogleApiClient_1, arg_object_2);
 }
 public static void setGravityForPopups(GoogleApiClient arg_GoogleApiClient_1, int arg_int_2)
 {
     JavaObjWrapper.StaticInvokeCallVoid(CLASS_NAME, "setGravityForPopups", "(Lcom/google/android/gms/common/api/GoogleApiClient;I)V", arg_GoogleApiClient_1, arg_int_2);
 }
 public static object getSettingsIntent(GoogleApiClient arg_GoogleApiClient_1)
 {
     return(JavaObjWrapper.StaticInvokeCall <object>(CLASS_NAME, "getSettingsIntent", "(Lcom/google/android/gms/common/api/GoogleApiClient;)Landroid/content/Intent;", arg_GoogleApiClient_1));
 }
 public static int getSdkVariant(GoogleApiClient arg_GoogleApiClient_1)
 {
     return(JavaObjWrapper.StaticInvokeCall <int>(CLASS_NAME, "getSdkVariant", "(Lcom/google/android/gms/common/api/GoogleApiClient;)I", arg_GoogleApiClient_1));
 }
 public static string getCurrentAccountName(GoogleApiClient arg_GoogleApiClient_1)
 {
     return(JavaObjWrapper.StaticInvokeCall <string>(CLASS_NAME, "getCurrentAccountName", "(Lcom/google/android/gms/common/api/GoogleApiClient;)Ljava/lang/String;", arg_GoogleApiClient_1));
 }
Beispiel #11
0
        public void OpenContentPage()
        {
            if (IsHidden)
            {
                // This fragment is hidden, need not open page
                return;
            }

            if (wvContent == null ||            // WebView does not requested
                DataCache.INSTATNCE.Toc == null // Toc has not been retrieved
                )
            {
                return;
            }



            var pub = ((ContentActivity)Activity).Publication;

            if (!DataCache.INSTATNCE.Toc.IsCurrentPublication(pub.Value.BookId))
            {
                // The toc is not belong to current publication
                return;
            }

            var tocNode = DataCache.INSTATNCE.Toc.ShowingLeafNode;
            var tag     = wvContent.Tag as JavaObjWrapper <WebViewTag>;

            if (tag != null && tag.Value.IsCurrentTOC(pub.Value.BookId, tocNode.ID))
            {
                /*
                 *              wvContent.Tag = new JavaObjWrapper<WebViewTag>(
                 *                      WebViewTag.CreateWebViewTagByTOC(
                 *                              pub.Value.BookId,
                 *                              tocNode.ID));
                 */

                ((ContentActivity)Activity).ClosePleaseWaitPageLoadDialog();
                UpdateNavigationIcon();

                if (!tag.Value.IsCurrentNavigationItem())
                {
                    wvContent.LoadUrl("javascript:android.red.applyHighLight();android.red.scrollByNavigation();");
                    tag.Value.BindNavigationItem();

                    if (((ContentActivity)Activity).IsPbo())
                    {
                        var pboPageItem = AsyncHelpers.RunSync <PageItem>(
                            () => PageSearchUtil.Instance.GetFirstPageItem(pub.Value.BookId, tocNode.ID));
                        currentPboPage = pboPageItem != null?pboPageItem.Identifier.ToString() : null;
                    }

                    //UpdatePboPage();
                }

                return;
            }

            var result = AsyncHelpers.RunSync <string>(
                () => PublicationContentUtil.Instance.GetContentFromTOC(pub.Value.BookId, tocNode, true, false));

            //result = SlideToc(result);

            // Only large content need show wait dialog
            if (result.Length > WebViewManager.ShowWaitContentMinLength ||
                WebViewManager.CountATag(result) > WebViewManager.ShowWaitMinATagCount)
            {
                ((ContentActivity)Activity).ShowPleaseWaitDialog();
                Task.Run(() =>
                {
                    Thread.Sleep(100);

                    result = PublicationContentUtil.Instance.RenderHyperLink(result, pub.Value.BookId);
                    result = "<div id='toc_" + tocNode.ID + "' class='tocpagediv' >" + result + "</div>";

                    Application.SynchronizationContext.Post(_ =>
                    {
                        tag = new JavaObjWrapper <WebViewTag>(
                            WebViewTag.CreateWebViewTagByTOC(
                                pub.Value.BookId,
                                tocNode.ID));
                        tag.Value.BindNavigationItem();
                        wvContent.Tag = tag;

                        wvContent.LoadDataWithBaseURL(
                            "file:///android_asset/html/",
                            WebViewManager.Instance.ApplyTemplate(WebViewManager.WebViewType.Content, result),
                            "text/html",
                            "utf-8",
                            null);

                        if (((ContentActivity)Activity).IsPbo())
                        {
                            var pboPageItem = AsyncHelpers.RunSync <PageItem>(
                                () => PageSearchUtil.Instance.GetFirstPageItem(pub.Value.BookId, tocNode.ID));
                            currentPboPage = pboPageItem != null ? pboPageItem.Identifier.ToString() : null;
                        }

                        UpdatePboPage();
                        UpdateNavigationIcon();
                    }, null);
                });

                return;
            }

            //result = PublicationContentUtil.Instance.RenderHyperLink(result, pub.Value.BookId);
            //result = "<div id='toc_" + tocNode.ID + "' class='tocpagediv' >" + result + "</div>";



            //DumpToc(pub.Value.BookId, tocNode.ID, WebViewManager.Instance.ApplyTemplate(WebViewManager.WebViewType.Content, result));

            //tag = new JavaObjWrapper<WebViewTag>(
            //    WebViewTag.CreateWebViewTagByTOC(
            //        pub.Value.BookId,
            //        tocNode.ID));
            //tag.Value.BindNavigationItem();
            //wvContent.Tag = tag;

            //wvContent.LoadDataWithBaseURL(
            //    "file:///android_asset/html/",
            //    WebViewManager.Instance.ApplyTemplate(WebViewManager.WebViewType.Content, result),
            //    "text/html",
            //    "utf-8",
            //    null);

            //if (((ContentActivity)Activity).IsPbo())
            //{
            //    var pboPageItem = AsyncHelpers.RunSync<PageItem>(
            //        () => PageSearchUtil.Instance.GetFirstPageItem(pub.Value.BookId, tocNode.ID));
            //    currentPboPage = pboPageItem != null ? pboPageItem.Identifier.ToString() : null;
            //}

            //UpdatePboPage();
            //UpdateNavigationIcon();
        }
Beispiel #12
0
 public static void setViewForPopups(GoogleApiClient arg_GoogleApiClient_1, object arg_object_2)
 {
     object[] args = new object[] { arg_GoogleApiClient_1, arg_object_2 };
     JavaObjWrapper.StaticInvokeCallVoid("com/google/android/gms/games/Games", "setViewForPopups", "(Lcom/google/android/gms/common/api/GoogleApiClient;Landroid/view/View;)V", args);
 }
Beispiel #13
0
 public static string getAppId(GoogleApiClient arg_GoogleApiClient_1)
 {
     object[] args = new object[] { arg_GoogleApiClient_1 };
     return(JavaObjWrapper.StaticInvokeCall <string>("com/google/android/gms/games/Games", "getAppId", "(Lcom/google/android/gms/common/api/GoogleApiClient;)Ljava/lang/String;", args));
 }
Beispiel #14
0
 public static void setViewForPopups(GoogleApiClient arg_GoogleApiClient_1, object arg_object_2)
 {
     JavaObjWrapper.StaticInvokeCallVoid("com/google/android/gms/games/Games", nameof(setViewForPopups), "(Lcom/google/android/gms/common/api/GoogleApiClient;Landroid/view/View;)V", (object)arg_GoogleApiClient_1, arg_object_2);
 }
Beispiel #15
0
 public static void setGravityForPopups(GoogleApiClient arg_GoogleApiClient_1, int arg_int_2)
 {
     JavaObjWrapper.StaticInvokeCallVoid("com/google/android/gms/games/Games", nameof(setGravityForPopups), "(Lcom/google/android/gms/common/api/GoogleApiClient;I)V", (object)arg_GoogleApiClient_1, (object)arg_int_2);
 }
Beispiel #16
0
 public static string getAppId(GoogleApiClient arg_GoogleApiClient_1)
 {
     return(JavaObjWrapper.StaticInvokeCall <string>("com/google/android/gms/games/Games", nameof(getAppId), "(Lcom/google/android/gms/common/api/GoogleApiClient;)Ljava/lang/String;", (object)arg_GoogleApiClient_1));
 }