ks32 / CrosswalkNative

Embedded Crosswalk 77 webview based sample project.
95 stars 42 forks source link

Errors encountered in xwalk_core_library-77 #23

Closed SithisDev closed 3 years ago

SithisDev commented 4 years ago

1) When playing any WebGL content, when using the android emulator (Android studio) API 28-29 (x86). The application does not give any errors, however, the rendering of the image stops and stops responding to any actions. D/cr_iotto: [XWalkWebContentsDelegateAdapter.java:97] rendererUnresponsive In unofficial emulators and on real devices (which I had), this problem was not noticed.

2) Some methods don't work and won't run, for example: shouldOverrideUrlLoading and onLoadStarted

        xWalkView.setResourceClient(new XWalkResourceClient() {

            @Override
            public void onLoadStarted(XWalkView view, String url) {
                Log.d("INFOURL", "onLoadStarted:" + url);
            }

            @Override
            public boolean shouldOverrideUrlLoading(XWalkView view, String url) {
                Log.d("INFOURL", "shouldOverrideUrlLoading:" + url);
                view.loadUrl(url);
                return false;
            }
        }

_3) These are trifles, but there is a mistake in the name of the xwalk_corelirary-77.aar (lirary -> library)

ks32 commented 4 years ago
  1. No idea about this error. But if it is working on a device then good.
  2. shouldOverrideUrlLoading and onLoadStarted are working fine.
  3. Yes it's a typo, macbook pro keyboard issue.

Quran Majeed for iOS and Android https://quranmajeed.page.link/RGhFYwtYUVwBbTnB9

Pakistan Data Management Services p: +92 21 3455 9003 w: www.pakdata.com https://facebook.com/pakdata https://twitter.com/hashtag/Pakdata https://www.instagram.com/pakdataapps/

On Thu, Sep 10, 2020 at 7:27 PM Nikita notifications@github.com wrote:

1.

When playing any WebGL content, when using the android emulator (Android studio) API 28-29 (x86). The application does not give any errors, however, the rendering of the image stops and stops responding to any actions. D/cr_iotto: [XWalkWebContentsDelegateAdapter.java:97] rendererUnresponsive In unofficial emulators and on real devices (which I had), this problem was not noticed. 2.

Some methods don't work and won't run, for example: shouldOverrideUrlLoading and onLoadStarted

    xWalkView.setResourceClient(new XWalkResourceClient() {

        @Override
        public void onLoadStarted(XWalkView view, String url) {
            Log.d("INFOURL", "onLoadStarted:" + url);
        }

        @Override
        public boolean shouldOverrideUrlLoading(XWalkView view, String url) {
            Log.d("INFOURL", "shouldOverrideUrlLoading:" + url);
            view.loadUrl(url);
            return false;
        }
    }

3) These are trifles, but there is a mistake in the name of the xwalk_core_lirary-77.aar (lirary -> library)

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/ks32/CrosswalkNative/issues/23, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAHILZ3R54WFOVKRNVCJPBDSFDO6BANCNFSM4RFFBUWA .

SithisDev commented 4 years ago

The first mistake was the wrong choice of the automatic rendering option for the emulator; you had to manually select the parameters.

You are wrong about "shouldOverrideUrlLoading". Yes, it may work, but it cannot be overridden. It must be called before every attempt to open the page. However, he doesn't even call Log.

ks32 commented 4 years ago

try onPageLoadStarted in XWalkUIClient

for shouldOverrideUrlLoading do not use it. Instead use XWalkWebResourceResponse shouldInterceptLoadRequest(XWalkView view, XWalkWebResourceRequest request)