Page 1 of 2 12 LastLast
Results 1 to 10 of 18

Thread: Deferred rendering change in 3.x

  1. #1
    Sencha User mschwartz's Avatar
    Join Date
    Nov 2008
    Location
    San Diego, Peoples' Republic of California
    Posts
    2,061

    Default Deferred rendering change in 3.x

    I'm seeing a few landmine type bugs appearing in my application that are related to how deferred rendering is done in 3.x vs. how it was done in 2.x.

    Specifically, a form that is spread across multiple tabs in a dialog or panel is breaking my submit logic. Why? Fields not rendered on the hidden tabs aren't getting their onRender() called unless the tabs are activated, and thus the Field inheritors aren't adding their fields (hidden or otherwise) to the DOM.

    What's the workaround? Is there a way to get 3.x to render those hidden Fields? And can I do it without editing all 200 of my forms?

  2. #2
    Sencha User jay@moduscreate.com's Avatar
    Join Date
    Mar 2007
    Location
    DC Area =)
    Posts
    16,364

    Default

    Are you explicitly setting deferredRender : false in the tab panels?

  3. #3
    Sencha User mschwartz's Avatar
    Join Date
    Nov 2008
    Location
    San Diego, Peoples' Republic of California
    Posts
    2,061

    Default

    No.

    For the one dialog I found, I had to set it false and it worked, albeit slower (it had to render the hidden tabs).

  4. #4

    Default

    Makes sense.

    What you describe has been the behavior since 2.x

  5. #5
    Sencha User mschwartz's Avatar
    Join Date
    Nov 2008
    Location
    San Diego, Peoples' Republic of California
    Posts
    2,061

    Default

    Quote Originally Posted by [email protected] View Post
    Makes sense.

    What you describe has been the behavior since 2.x
    I wrote that dialog under 2.x and never had this problem. That's why I think there are timebombs in my code - I have to check all 200 dialogs now and set deferredRender to false in the ones that don't work.

  6. #6
    Sencha User Animal's Avatar
    Join Date
    Mar 2007
    Location
    Bédoin/Nottingham
    Posts
    30,890

    Default

    Or you could change the default in the TabPanel's prorotype.

    'sup to you.

  7. #7
    Sencha User mschwartz's Avatar
    Join Date
    Nov 2008
    Location
    San Diego, Peoples' Republic of California
    Posts
    2,061

    Default

    This is at least a gotcha for those migrating to 3.x from 2.x.

  8. #8
    Sencha User jay@moduscreate.com's Avatar
    Join Date
    Mar 2007
    Location
    DC Area =)
    Posts
    16,364

    Default

    Quote Originally Posted by mschwartz View Post
    This is at least a gotcha for those migrating to 3.x from 2.x.
    negative. 2.x behaves the same way.

  9. #9
    Sencha User Animal's Avatar
    Join Date
    Mar 2007
    Location
    Bédoin/Nottingham
    Posts
    30,890

    Default

    deferredRender also defaulted to true in 2.0

    So unvisited tabs would not be rendered, and therefore Fields in there would not be rendered, therefore not submitted.

    People have been posting questions caused by that ever since 2.0 was released.

  10. #10
    Sencha User jay@moduscreate.com's Avatar
    Join Date
    Mar 2007
    Location
    DC Area =)
    Posts
    16,364

    Default

    i remember being one of'em in the 2.x alpha days

Page 1 of 2 12 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •