roojs-ui.js
[roojs1] / Roo / TabPanel.js
index 8992c75..8bb7aee 100644 (file)
@@ -70,11 +70,11 @@ Roo.TabPanel = function(container, config){
         Roo.fly(this.stripWrap.dom.firstChild).setStyle("overflow-x", "hidden");
     }
     if(this.tabPosition != "bottom"){
-    /** The body element that contains {@link Roo.TabPanelItem} bodies. +
-     * @type Roo.Element
-     */
-      this.bodyEl = Roo.get(this.createBody(this.el.dom));
-      this.el.addClass("x-tabs-top");
+        /** The body element that contains {@link Roo.TabPanelItem} bodies. +
+         * @type Roo.Element
+         */
+        this.bodyEl = Roo.get(this.createBody(this.el.dom));
+        this.el.addClass("x-tabs-top");
     }
     this.items = [];
 
@@ -107,12 +107,15 @@ Roo.TabPanel = function(container, config){
 
 
     // toolbar on the tabbar support...
-    if (this.toolbar) { 
-        var se = this.stripEl;
-        var tbh = se.child('td.x-tab-strip-toolbar'); //createChild(  { tag: 'td', style: 'width:100%;'  });
-    
-    
-        var lotb = new Roo.Toolbar(tbh);
+    if (this.toolbar) {
+        var tcfg = this.toolbar;
+        tcfg.container = this.stripEl.child('td.x-tab-strip-toolbar');  
+        this.toolbar = new Roo.Toolbar(tcfg);
+        if (Roo.isSafari) {
+            var tbl = tcfg.container.child('table', true);
+            tbl.setAttribute('width', '100%');
+        }
+        
     }