fhem-tablet-ui icon indicating copy to clipboard operation
fhem-tablet-ui copied to clipboard

"startReturnTimer" not called in "widget_pagebutton.js"

Open juniormajor opened this issue 8 years ago • 4 comments

since last update the return function within the pagebutton isn't triggered anymore. last known working version 23b63a961a (pre "Improved pointer events handler")

juniormajor avatar Oct 23 '16 16:10 juniormajor

can't trace this. no issue found

knowthelist avatar Oct 24 '16 00:10 knowthelist

To clarifiy the issue: until the rework of the pointer events, pagebutton has the same capability as pagetab regarding the return to a specified page after x seconds () defined as attr return-time. Since the rework the return timer isn't started at all. So automatic return to a specific page isn't possible anymore.

Or do you mean you need logs?

Am 24.10.2016 2:12 vorm. schrieb "knowthelist" [email protected]:

can't trace this. no issue found

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/knowthelist/fhem-tablet-ui/issues/169#issuecomment-255624653, or mute the thread https://github.com/notifications/unsubscribe-auth/ABn4h_iXHL4CSyPW2GCA_IqGE93ZL6v6ks5q2_fpgaJpZM4KeLKl .

juniormajor avatar Oct 25 '16 18:10 juniormajor

The condition to trigger the return timer is: data-return-time of the first pagebutton >0 and at least tap/click of the screen after an activation of a new pagebutton.

       // start return timer after last activity
       if ( me.elements.eq(0).data('return-time') > 0 ){
           $('body').once('touchend mouseup', function(e) {
               startReturnTimer(me.elements.eq(0));
               e.preventDefault();
           });
       }

If you just change the view via pagebutton and don't click on the screen, the timer wont start. Maybe this is the problem, isn't it? Should be changed to: return in any case.

knowthelist avatar Oct 26 '16 04:10 knowthelist

indeed, absolutely correct! nevertheless old behaviour was that the timer was triggered without "additional click". just change the view via click onto the pagebutton and timer was triggered.

would it be hard to reimplement the old behaviour?

2016-10-26 6:32 GMT+02:00 knowthelist [email protected]:

The condition to trigger the return timer is: data-return-time of the first pagebutton >0 and at least tap/click of the screen after an activation of a new pagebutton.

   // start return timer after last activity
   if ( me.elements.eq(0).data('return-time') > 0 ){
       $('body').once('touchend mouseup', function(e) {
           startReturnTimer(me.elements.eq(0));
           e.preventDefault();
       });
   }

If you just change the view via pagebutton and don't click on the screen, the timer wont start. Maybe this is the problem, isn't it? Should be changed to: return in any case.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/knowthelist/fhem-tablet-ui/issues/169#issuecomment-256247046, or mute the thread https://github.com/notifications/unsubscribe-auth/ABn4h-lhsjmqnv8hf7siXhJJZFqBDLzCks5q3tfqgaJpZM4KeLKl .

juniormajor avatar Oct 26 '16 15:10 juniormajor