Giter Club home page Giter Club logo

Comments (4)

lupidan avatar lupidan commented on August 24, 2024

Ok, let me go trough it, and see what it is.

from popoverview.

coder4567 avatar coder4567 commented on August 24, 2024

thank u, I truly appreciate it, I've been debugging and noticed that the problem occurs when it reaches: group.addView(this, insertParams); in showPopoverFromRectInViewGroup function.
thought this would help to find the bug

from popoverview.

coder4567 avatar coder4567 commented on August 24, 2024

By the way I'm calling this function from inside the class of the webview that I created. cause if I wanted to call it from the activity, I have to make the function static which would add so many restrictions to my code, and I can't use "this", nor "getContext()" ...
In popoverView.showPopoverFromRectInViewGroup(this, viewRect, PopoverView.PopoverArrowDirectionAny, true);
"this" might be referring to the webview class, could it be the problem cause? and if it is how can I handle it and what should I put instead of "this"

from popoverview.

lupidan avatar lupidan commented on August 24, 2024

Ok, I made a test, and I can load a Webview with an HTML string inside the popover just fine, from the main Activity

From what I can read, you are calling the showPopoverFromRectInViewGroup in a different thread than the main thread (in this case in the WebViewCoreThread).

As far as I know, the main rule for Android development is to call all the view methods (adding views, removing views, showPopoverFromRectInViewGroup) in the main thread, while processing, data downloading, etc... is done in background threads (like user-created Threads, or WebViewCoreThread in this case).

I don't know what your WebView class does, or when does it call showPopoverFromRectInViewGroup, but you should call this method in the main thread, since it's updating the views and the interface.

from popoverview.

Related Issues (12)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.