1. #1
    Sencha User
    Join Date
    Nov 2011
    Posts
    5
    Vote Rating
    0
    Jurian Baas is on a distinguished road

      0  

    Default Unanswered: Docking multiple toolbars in a view

    Unanswered: Docking multiple toolbars in a view


    I don't seem to be able to dock a toolbar to the top and bottom of a panel. The bottom toolbar does not show up. Are there any specific requirements for this configuration?

    I'm using a Container with a card layout that contains all my views. This container is added to the viewport and has fullscreen to true. My subviews have no layout specified.

    Like this:
    -viewport
    ---Main (extends Ext.Container, cardlayout, fullscreen = true)
    -----List (extends Ext.List)
    -----Detail (extends Ext.Panel)
    -----Add (extends Ext.form.Panel)

    I am currently using 'docked' instead of 'dock'. I tried both but I'm unsure which one is correct. Using PR2.

  2. #2
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    St. Louis, MO
    Posts
    33,624
    Vote Rating
    434
    Answers
    3104
    mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of

      0  

    Default


    Using PR2, this worked for me:

    Code:
    Ext.create('Ext.Panel', {
        fullscreen : true,
        layout     : 'card',
        items      : [
            {
                xtype  : 'toolbar',
                docked : 'top',
                items  : [
                    {
                        text : 'Back',
                        ui   : 'back'
                    }
                ]
            },
            {
                xtype  : 'toolbar',
                docked : 'bottom',
                items  : [
                    {
                        text : 'Hello',
                        ui   : 'confirm'
                    }
                ]
            },
            {
                xtype : 'container',
                html  : 'One'
            },
            {
                xtype : 'container',
                html  : 'two'
            }
        ]
    });
    About the use of dock vs docked, I believe this will be made to dock at some point but currently is docked.
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    http://www.JSONPLint.com - Source to lint your JSONP!

    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 almost in print!

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

  3. #3
    Sencha - Community Support Team jay@moduscreate.com's Avatar
    Join Date
    Mar 2007
    Location
    Frederick MD, NYC, DC
    Posts
    16,167
    Vote Rating
    28
    Answers
    83
    jay@moduscreate.com is a jewel in the rough jay@moduscreate.com is a jewel in the rough jay@moduscreate.com is a jewel in the rough jay@moduscreate.com is a jewel in the rough

      0  

    Default


    Could you post your code in code blocks (like mitch did)? Perhaps we can help spot the problem.

    Jay Garcia @ModusJesus || Modus Create co-founder
    Ext JS in Action author
    Sencha Touch in Action author

    Get in touch for Ext JS & Sencha Touch Touch Training

    We are also working on Video-based Sencha Touch training: Check it out here.

Tags for this Thread