Thank you for reporting this bug. We will make it our priority to review this report.
  1. #1
    Sencha User
    Join Date
    Aug 2007
    Posts
    23
    Vote Rating
    2
    jbondc is on a distinguished road

      0  

    Default Too many events, avoid 'painted' at all costs

    Too many events, avoid 'painted' at all costs


    I found that most 'performance problems' are related to the 'painted' event:
    ComponentPaint.js
    Dispatcher.js

    Much better performance by using making components listen to 'show' or creating custom events. This seems to be related to the isPainted() --> dom.offsetParent calculation.

    Just add a couple of console.debug() statements to Dispatcher.js or Controller.js and you'll start to see where things go wrong!

    Too many events firing that do nothing and delay a simple dom.style.display = ''.

    http://dev.sencha.com/deploy/sencha-...ase-notes.html

    I have several patches / hacks to improve performance but oddly enough I have to pay to get access to the GIT or SVN repo? How does that work?

    I've also created a lightweight Ext.DomContainer with xtype: 'dom' that triggers less events and more lightweight to use in the view / template.

  2. #2
    Sencha Premium Member intellix's Avatar
    Join Date
    Mar 2012
    Location
    UK + Malta
    Posts
    263
    Vote Rating
    18
    intellix will become famous soon enough

      0  

    Default


    I'm going from poor to unusable performance in chrome and now you've mentioned paint event I'm thinking maybe I added something like this recently. If I tap and drag to move a view down but it changes thebackground of one of my list items then it jerks and lags as though it's the event that killed it. Will take a deeper look tomorrow into what's being fired. What sort of stuff did you uncover yourself?

  3. #3
    Sencha Premium Member intellix's Avatar
    Join Date
    Mar 2012
    Location
    UK + Malta
    Posts
    263
    Vote Rating
    18
    intellix will become famous soon enough

      0  

    Default


    mmm I don't have any painted events for any of the components on my homepage. Removed shadows in 2.1b3 and it sped things up quite considerably.

    I just changed 2.1b3 to 2.0.1.1 again and it's absolutely lightning fast in comparison.

    What happened in 2.1b3 that made it run like crap on both iOS and Android/Android Chrome? Looking at the list of things it talks about improving performance for odd events but other bits have killed my app making it unusable.

  4. #4
    Touch Premium Member suzuki1100nz's Avatar
    Join Date
    Apr 2011
    Location
    New Zealand
    Posts
    447
    Vote Rating
    62
    suzuki1100nz is a jewel in the rough suzuki1100nz is a jewel in the rough suzuki1100nz is a jewel in the rough suzuki1100nz is a jewel in the rough

      0  

    Default


    Hi,

    I ended up using painted as I could get the show listener to fire with a extension (i.e. not adding a listener to a created object but defining a listener an extension ) see bug - http://www.sencha.com/forum/showthread.php?220301


    What do you mean to many events? surely there is one painted event fired for the component the listener is registered on.

    Can anyone else confirm this issue

  5. #5
    Sencha User
    Join Date
    Aug 2007
    Posts
    23
    Vote Rating
    2
    jbondc is on a distinguished road

      0  

    Default


    .

  6. #6
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    37,338
    Vote Rating
    847
    mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute

      0  

    Default


    This is a reason why painted is not listenable within the controller... performance.
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
    https://github.com/mitchellsimoens

    Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/

    Need more help with your app? Hire Sencha Services services@sencha.com

    Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is in print!

    When posting code, please use BBCode's CODE tags.

  7. #7
    Sencha User
    Join Date
    Aug 2007
    Posts
    23
    Vote Rating
    2
    jbondc is on a distinguished road

      0  

    Default


    .