1. #1
    Sencha - Community Support Team jay@moduscreate.com's Avatar
    Join Date
    Mar 2007
    Location
    Frederick MD, NYC, DC
    Posts
    16,337
    Answers
    101
    Vote Rating
    75
    jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all

      0  

    Default Answered: Why don't components scroll?

    Answered: Why don't components scroll?


    Looks like Container only observes scrollable. What if you wanted a component with hundreds of lines of HTML?

  2. Components no longer have scrollable behavior to keep their DOM structure fast and minimal. Use Containers instead.

  3. #2
    Sencha - Sencha Touch Dev Team Jacky Nguyen's Avatar
    Join Date
    Jul 2009
    Location
    Palo Alto, California
    Posts
    469
    Answers
    24
    Vote Rating
    13
    Jacky Nguyen has a spectacular aura about Jacky Nguyen has a spectacular aura about

      0  

    Default


    Components no longer have scrollable behavior to keep their DOM structure fast and minimal. Use Containers instead.
    Sencha Touch Lead Architect

  4. #3
    Sencha - Sencha Touch Dev Team Jamie Avins's Avatar
    Join Date
    Mar 2007
    Location
    Redwood City, California
    Posts
    3,661
    Answers
    17
    Vote Rating
    19
    Jamie Avins is a jewel in the rough Jamie Avins is a jewel in the rough Jamie Avins is a jewel in the rough

      0  

    Default


    Quote Originally Posted by Jacky Nguyen View Post
    Components no longer have scrollable behavior to keep their DOM structure fast and minimal. Use Containers instead.
    In fact, DataView does this!

  5. #4
    Sencha User
    Join Date
    Mar 2011
    Posts
    72
    Vote Rating
    -1
    phil.fuse is an unknown quantity at this point

      0  

    Default


    i'm in the process of slowly migrating my app to see what performance gains we're getting.
    my app had a vertical scrolling vbox and in that it had several rows of horizontal scrolling hbox's.
    i've just hacked an extremly quick version of this here...


    Code:
    createItems = function(number) {
                var items = [];
                for (var i = 0; i < number; i++) {
                    items.push(
                            {
                                html: '<div style="height:188px;width:100px;background-color: red; margin: 10px"></div>',
                            }
                    )
                }
                return items;
            };
    
    
            createTitle = function() {
                return Ext.create("Ext.Container", {
                    html : "sencha 2.0.0"
                });
            };
    
    
            createContainer = function() {
                return Ext.create("Ext.Container", {
                    layout: 'hbox',
                    scrollable : {
                        direction : 'horizontal',
                        useIndicators : true
                    },
                    width: window.innerWidth,
                    height: 198,
                    items :createItems(20)
                })
            };
    
    
            Ext.application({
                name: 'POC',
                launch: function() {
                    var main = Ext.create("Ext.Container", {
                        layout: 'vbox',
                        scrollable : {
                            direction : 'vertical',
                            useIndicators : true
                        },
                        items : [
                            createTitle(),
                            createContainer(),
                            createContainer(),
                            createContainer(),
                            createContainer(),
                        ]
                    }).show();
                }});
    you'll notice that you can scroll horizontally and vertically at the same time - the same code written for sencha1 will only scroll in one direction at a time.
    i'm assuming this was intention - but is it configurable at all?
    i don't see anything in the docs quite yet about the 'scrollable' property and it doesn't seem to be taking into account fps, acceleration, friction etc...

    so i'm wondering if the design of my app will even work if i migrate it to v2.

  6. #5
    Sencha User
    Join Date
    Mar 2007
    Location
    Haarlem, Netherlands
    Posts
    1,243
    Answers
    28
    Vote Rating
    8
    TommyMaintz will become famous soon enough

      0  

    Default


    Hi Phil,

    Having a horizontal scrollable inside of a vertical currently doesn't work quite right. Before, as soon as you started scrolling in one direction, it would cancel the scroll of the scroller with the other direction. This is the expected behavior. Unfortunately we haven't implemented this particular feature in the new scroller yet. This is one of our higher priorities, so expect this to be fixed very soon.

    We do suggest keeping the fps option to 'auto', as it makes sure the performance is the best possible across all the devices. You can still configure the acceleration and friction. They are now more organized in a momentumEasing config as you can actually control these variables for different parts of the scrolling experience. The following shows a highly customized (and probably completely unpractical/non-functional) scroller

    PHP Code:
        scrollable: {
            
    direction 'vertical',
            
    indicatorsfalse,
            
    momentumEasing: {
                
    momentum: {
                    
    acceleration60,
                    
    friction0.8
                
    },

                
    bounce: {
                    
    acceleration10,
                    
    springTension0.1
                
    }
            },

            
    // This is used when snapping is turned on, like in a Picker
            
    snapEasing: {
                
    duration400,
                
    exponent4
            
    },

            
    // This is used when dragging the list out of bounds. E.g. 0.5 causes
            // the scroller to move half a pixel for every pixel you drag it as
            // soon as you are out of bounds.
            
    outOfBoundRestrictFactor0.5
        


  7. #6
    Sencha User
    Join Date
    Mar 2011
    Posts
    72
    Vote Rating
    -1
    phil.fuse is an unknown quantity at this point

      0  

    Default


    configuration options look great - i'll have a play...
    really looking forward to the next release - great work..!!
    ...
    yeah the fps i didn't really like playing with to be honest...
    it was something i was playing (read hacking) with as we're having to support the HTC Desire which is proving to be an absolute nightmare.
    - just posted something about it here http://www.sencha.com/forum/showthre...Android-issues

    v2 is MUCH better but unfortunately it's looking a little like we'll have to redesign / drop support for this device which i know our client will not like at all...
    ...

  8. #7
    Sencha User
    Join Date
    Mar 2007
    Location
    Haarlem, Netherlands
    Posts
    1,243
    Answers
    28
    Vote Rating
    8
    TommyMaintz will become famous soon enough

      0  

    Default


    What specifically doesn't work on the HTC Desire in Touch 2.0? I am quite sure we tested for this device and are not aware of any serious performance issues.

  9. #8
    Sencha User
    Join Date
    Mar 2011
    Posts
    72
    Vote Rating
    -1
    phil.fuse is an unknown quantity at this point

      0  

    Default


    thanks tommy - you answered it in another thread http://www.sencha.com/forum/showthre...ssues&p=660252

film izle

hd film izle

film sitesi

takipci kazanma sitesi

takipci kazanma sitesi

güzel olan herşey

takipci alma sitesi

komik eğlenceli videolar