Ticket #5821 (closed defect: fixed)

Opened 10 months ago

Last modified 3 months ago

TabContainer - Visual problem when creating tab programmatically (both FF and IE)

Reported by: guest Owned by: bill
Priority: normal Milestone: 1.2
Component: Dijit Version: 1.0
Severity: normal Keywords: TabContainer
Cc:

Description (last modified by peller) (diff)

I'm having a problem with TabContainer? when I add a new "tabs" created programmatically. I attach my test HTML page (derived from official Dojo test_TabContainer.html file). It creates an empty TabContainer? declaratively and then in dojo.addOnLoad() I create one tab programmatically.

Everything works fine except that initially when TabContainer? is displayed, the tab created programmatically is not properly resized - see attached tab-FF-1.png (FireFox?) and tab-IE-1.png (MSIE). When I slightly resize the browser's window, the tab is properly resized and fitted into TabContainer? - see attached screenshot tab-FF-2.png and tab-IE-2.png. It works almost identically in both FF 2.0.0.11 and IE 6 (both tested on Win XP).

I tested this with Dojo 1.0.2.

Attachments

tab-FF-1.png (9.1 kB) - added by guest 10 months ago.
tab-FF-2.png (9.4 kB) - added by guest 10 months ago.
tab-IE-1.png (10.5 kB) - added by guest 10 months ago.
tab-IE-2.png (10.7 kB) - added by guest 10 months ago.
test_TabContainer_test.html (1.4 kB) - added by guest 10 months ago.
Test HTML page

Change History

Changed 10 months ago by guest

Changed 10 months ago by guest

Changed 10 months ago by guest

Changed 10 months ago by guest

Changed 10 months ago by guest

Test HTML page

Changed 9 months ago by dante

  • status changed from new to closed
  • resolution set to worksforme

i've just tested this in trunk, and it works for me? adding tc.layout() in the addOnLoad after addChild(cp) fixes.

Changed 9 months ago by bill

  • status changed from closed to reopened
  • resolution deleted
  • milestone set to 1.2

OK, but shouldn't need to call layout() after addChild(). startup() on child widget should happen automatically if the parent is already started. Problem in StackContainer??

Changed 8 months ago by peller

  • owner set to peller
  • status changed from reopened to new
  • description modified (diff)

Changed 3 months ago by peller

  • milestone changed from 1.2 to 1.3

Changed 3 months ago by bill

  • owner changed from peller to bill
  • status changed from new to assigned
  • milestone changed from 1.3 to 1.2

Changed 3 months ago by bill

  • status changed from assigned to closed
  • resolution set to fixed

(In [15137]) Fixes #5821, fixes #7594: programatically adding tab to empty TabContainer? fails. Problem was that we were querying size of tab strip before any tabs had been created, thus it was coming out as 0.

May also help fix part of #4502 (refs #4502).

!strict

Changed 3 months ago by peller

(In [15138]) remove console.log from [15137] Refs #5821 !strict

Note: See TracTickets for help on using tickets.