Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Web and WebWorks Development

Reply
Developer
squished18
Posts: 289
Registered: ‎10-17-2008
My Device: Torch 9800
Accepted Solution

button click event not firing - position:fixed - Playbook 2.0

I have a fixed-position "back" button in my app that is not firing when the screen is scrolled down.

 

Here's the button code:

<button id='buttonBack' style='position:fixed; right:5px'>Back</button><br>

 

When I scroll the screen back to the top, the button fires without a problem. However, if the screen is scrolled down at all, the button click event does not fire.

 

I traced events in Web Inspector and an click event does fire when I click on the button. However, it doesn't actually fire the method I have bound to the button's click event. Again, if I scroll the screen back to the top, the button click fires fine.

 

I should note that the button is displayed correctly at all times. It stays in a fixed position 5px from the right side of the screen, even when the window is scrolled down. So the button is visible at all times. It's just that when I scroll down nothing happens if I click the button.

 

It seems like a bug with WebWorks. Can anybody confirm?

 

Thanks,

 

 

feel free to press the like button on the right side to thank the user that helped you.
please mark posts as solved if you found a solution.
Developer
ignites
Posts: 466
Registered: ‎04-11-2012
My Device: Bold 9900

Re: button click event not firing - position:fixed - Playbook 2.0

have you tried this on chrome? (minimize the window to a smaller size so it scrolls and then try


Developer for easyDial for BlackBerry Bold & inLink for BlackBerry PlayBook
Find me online via twitter, or on the techfruits.com webpage. Please hit the like button below if what I said helped!
Developer
squished18
Posts: 289
Registered: ‎10-17-2008
My Device: Torch 9800

Re: button click event not firing - position:fixed - Playbook 2.0

Thanks for the suggestion ignites.

 

I found that this was caused by my own bug. It was a z-index problem. I increased the z-index of the button and it solved the problem. The button must have been conflicting with elements further down the page, but was fine at the top of the page.

 

Thanks,

feel free to press the like button on the right side to thank the user that helped you.
please mark posts as solved if you found a solution.