facebook

issue with scroller or reloading a screen: CLOSED

  1. MobiOne Archive
  2.  > 
  3. Getting Help – General
Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #333792 Reply

    dabbelju
    Member

    Hi all and a happy new year!

    I have an native app with two screens.

    Background is, that due to missing iAD support, I want to realize my own AD stuff.

    In my first page i have the following widgets:

    – navigation
    – panel 1 (list with several list items)
    – panel 2 (just a blank one, here I want to put my AD)
    – panel 3 (button to navigate to screen 2)

    I have two buttons, which show or hide panel 2 and adjust the height of panel 1 in order to be displayed either over the whole available space or being reduced by the height of panel 1.

    This works fine so far.

    Not to my problem:

    When I start the app, panel 2 is show, everything is fine and scroller in panel 1 is scrolling correctly. When I do the hide function, panel 2 is hidden, height of panel 1 is adjusted correctly, but the scroller is doing correctly. It scrolls as panle 2 would still be displayed. I thought it might be a godd idea to reload the page automatically, because when I navigate to the second screen and come back, it is ok.

    So I use “phoneui.preprocessDOM(‘m1-adtest’);” as I found in this article (http://www.genuitec.com/support-genuitec/viewtopic.php?f=8&t=2527&hilit=reload), but that does not work.

    Is there anyone who can help me?

    Please find my adtest porject attached.

    Thanks and best regards.
    Christian

    Attachments:
    You must be logged in to view attached files.
    #333824 Reply

    Hi dabbelju,

    Are you using $.hide() and $.show() functions?? If yes please set the css directly on the top level <div> of the panel widget. Next snippets should works:

    $(‘#m1-test-panel’).css(‘visibility’, ‘visible’);
    $(‘#m1-test-panel’).css(‘visibility’, ‘hidden’);

    #333985 Reply

    dabbelju
    Member

    Hi Octavio,

    I changed what you suggested, but does not make any difference.

    So I still need help.

    Thanks
    Dabbelju

    #334273 Reply

    dabbelju
    Member

    Any new ideas?

    #334300 Reply

    Hi dabbelju,

    I have talked with dev team and the thing is that there is no straightforward way, only hacky one.
    See next _custom.js file with modification provided by team.

    There is a single line was added:

    $('#m1-adtest-panel2 .m1-iscroll-scroller')[0].myScroll.refresh();
    Attachments:
    You must be logged in to view attached files.
    #334447 Reply

    dabbelju
    Member

    Hi Octavio,

    thanks a lot. It works.

    best regards
    Dabbelju

    #334480 Reply

    Hi dabbelju,

    Thanks for sharing your success with us. Closing thread.

Viewing 7 posts - 1 through 7 (of 7 total)
Reply To: issue with scroller or reloading a screen: CLOSED

You must be logged in to post in the forum log in