1. #1
    Sencha User
    Join Date
    Jul 2012
    Posts
    2
    Vote Rating
    0
    vanilson is on a distinguished road

      0  

    Default Unanswered: Using vbox layout

    Unanswered: Using vbox layout


    Hi, I´m new in sencha touch 2.2.1 and I´m trying to use vbox layout. Here is the code:

    App.js
    Code:
    Ext.Loader.setPath({
        'Ext': 'touch/src'
    });
    //</debug>
    
    
    Ext.application({
        name: 'TP',
    
    
        views: [
            'Main'
        ],
    
    
        launch: function() {
            // Destroy the #appLoadingIndicator element
            Ext.fly('appLoadingIndicator').destroy();
    
    
            // Initialize the main view
            Ext.Viewport.add(Ext.create('TP.view.Main'));
        }
    
    
    });
    Main.js
    Code:
    Ext.define('TP.view.Main', {
        extend: 'Ext.Panel',
        xtype: 'main',
        requires: [
            'Ext.TitleBar'
        ],
    
    
        config: {
            layout: 'vbox',
            items:[
                {
                    style: 'background-color:#999999;',
                    flex: 1
                },
                {
                    style: 'background-color:#666666;',
                    flex: 3,
                }
            ]
    
    
        }
    });
    The problem is that I can´t see the division that I made using vbox layout, I only see a white background...

  2. #2
    jay@moduscreate.com's Avatar
    Join Date
    Mar 2007
    Location
    Frederick MD, NYC, DC
    Posts
    16,360
    Answers
    102
    Vote Rating
    81
    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


    add "fullscreen : true" to your TP.view.Main's config block.

  3. #3
    Sencha User
    Join Date
    Jul 2012
    Posts
    2
    Vote Rating
    0
    vanilson is on a distinguished road

      0  

    Default


    jay I add the fullscreen property and it didn´t work, but I test the same code in safari and it works just fine, but I can´t understand why isn´t working in chrome...

Thread Participants: 1

Tags for this Thread