Results 1 to 2 of 2

Thread: Inconsistency on closing tabpanel items

    Success! Looks like we've fixed this one. According to our records the fix was applied for EXTJS-5351 in a recent build.
  1. #1
    Sencha User
    Join Date
    Apr 2007
    Posts
    3

    Default Inconsistency on closing tabpanel items

    REQUIRED INFORMATION

    Ext version tested:
    • Ext 4.0.7 rev ???


    Browser versions tested against:
    • Chrome, Firefox


    DOCTYPE tested against:
    • HTML5


    Description:
    • Closing a tabpanels item behaves different when clicking the close button than to using the API (remove()-Method).
    • Closing a tab item via the close button activates the item to its left. Using the remove()-Method the item to its right is selected afterwards. So when assigning a keyboard shortcut to close tabs they behave different than using the mouse.


    Steps to reproduce the problem:
    • use a tabpanel
    • open at least 4 (closable) tabs
    • select a middle tab
    • close one by clicking the close item, another by calling the remove-Method on its container


    The result that was expected:
    • In both cases the same item should be focussed afterwards


    The result that occurs instead:
    • A different tab is focussed depending on the procedure taken


    HELPFUL INFORMATION

    Debugging already done:
    • none


    Possible fix:
    • not provided



    Operating System:
    • Mac OSX

  2. #2
    Sencha Premium User mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    40,450

    Default

    Either way it really should remember the last tab that was selected and that should be the one it make active.

    To test this, I added this button to the tabs-adv.html example:

    Code:
        Ext.createWidget('button', {
            renderTo: 'addButtonCt',
            text: 'Remove Active Tab',
            handler: function () {
                var active = tabs.activeTab;
    
                tabs.remove(active);
            },
            iconCls:'new-tab',
            style: 'margin-left: 8px;'
        });
    Mitchell Simoens @LikelyMitch
    Modus Create, Senior Fullstack Engineer
    ________________
    Modus Create is based on the model of an open source team. We’re a remote, global team of experts in our field. To find out more about the work we do, head over to our website.

    Check out my GitHub:
    https://github.com/mitchellsimoens

Posting Permissions

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