Giter Site home page Giter Site logo

Comments (14)

asiayeah avatar asiayeah commented on May 27, 2024

I've found where the problem lies:

Previoiusly the codes were:

            innerChildNode.setAttribute('onmouseover', "this.setAttribute('class','bb-text-arrow-list-item-hover')");
            innerChildNode.setAttribute('onmouseout', "this.setAttribute('class','bb-text-arrow-list-item')");

In this setup, at most only 1 will be hilighted. It seems the onmouseout will be triggered on the previous element if a new one got hilighted.

In the new codes, we have:

            innerChildNode.setAttribute(inEvent, "this.setAttribute('class','bb-text-arrow-list-item-hover');");
            innerChildNode.setAttribute(outEvent, "this.setAttribute('class','bb-text-arrow-list-item')");

For PlayBook, inEvent = "ontouchstart", outEvent="ontouchend".

With this change, multiple entries will be hilighted if you drag your fingers across entries. It looks like the ontouchend never got triggered.

from bbui.js.

tneil avatar tneil commented on May 27, 2024

That's what puzzles me.. its the same way I've done it for all the other lists which don't have this happening. You're using PlayBook 2.0 correct?

With iScroll, I had to change these to touch events because mouse events don't fire when using it.

from bbui.js.

asiayeah avatar asiayeah commented on May 27, 2024

Yes, I am using PlayBook 2.0.0.7971.

May I ask if you are able to reproduce the same?

I can give other list types a try.

from bbui.js.

tneil avatar tneil commented on May 27, 2024

I'll give a try on Monday. My test device is at the office.

from bbui.js.

tneil avatar tneil commented on May 27, 2024

I can't seem to reproduce it.. does it happen when you use the sample code?

from bbui.js.

asiayeah avatar asiayeah commented on May 27, 2024

I pretty much use the sample code but in my app. Do you see the blue highlight bar when you touch the arrow-text-list? And when you drag your touch across the entries, the blue light remains.

from bbui.js.

tneil avatar tneil commented on May 27, 2024

That's the problem.. it doesn't do that for me..I can't seem to reproduce it.. I'm looking into the touch handling to see if there's anything that could be improved.

from bbui.js.

asiayeah avatar asiayeah commented on May 27, 2024

Do you see any blue hilighting when you touch the entry?

from bbui.js.

tneil avatar tneil commented on May 27, 2024

Yes it does do the blue highlight.. it just will only highlight the one I'm currently touching.. It doesn't highlight multiple like you are seeing

from bbui.js.

asiayeah avatar asiayeah commented on May 27, 2024

Sorry for the back and forth. Let me elaborate in details and see if it helps.

  1. With the 1st version (i.e. onmouseover/onmouseout)

When I touch 1 entry, that entry becomes blue highlighted. While still touching the screen, I drag my finger to the next entry or other areas and then lift up. The blue hilight remains on the original entry. This looks funny as the hilighting doesn't mean anything on the PlayBook. Now if I touch a new entry, the original blue highlight will be gone and the new entry becomes blue hilighted.

  1. With the new version (i.e. ontouchstart/ontouchend)

With the original entry hilighted, when a new entry is touched, 2 entries got hilighted.

Is this reproducible?

from bbui.js.

tneil avatar tneil commented on May 27, 2024

I currently cannot reproduce this behavior

from bbui.js.

asiayeah avatar asiayeah commented on May 27, 2024

I was able to reproduce it when I use the download, blackberry-bbUI.js-30d614d.zip.

Today, I've tried to download version 20e0455 of bbUI.js (dated Mar 26), and the highlighting issue was gone and the inertia scrolling is working fine there, too.

Pardon me, as I am not familar with the github.com. Is the zip download not updated correctly for blackberry-bbUI.js-30d614d.zip? But I'm fine with using version 20e0455 of bbUI.js.

from bbui.js.

tneil avatar tneil commented on May 27, 2024

That's a good question.. I'm actually not sure how the downloads get updated.. I typically clone the repo using git. I'll take a look into it. For now I'll close this issue

from bbui.js.

asiayeah avatar asiayeah commented on May 27, 2024

Ok...this is embarrasing...eventually I found out my problem was due to the missing of the following in my config.xml:

<feature id="blackberry.system.event" />

(just FYI, so that others won't run into the same, thanks!)

from bbui.js.

Related Issues (20)

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.