[ 3 posts ]

Charles Walker

  • Username: cw6834
  • Joined: Thu Mar 18, 2010 12:29 pm
  • Posts: 3
  • IRC: chaz
  • Offline
  • Profile

Cannot Display YUI widgets in TabViews

Post Posted: Thu Oct 21, 2010 9:55 am
+0-
Hi all,

I am developing an application to let user manage records. I want to do this using YUI and this is what I have so far.

When you go to the site it will load the page and the page is using the YAHOO.widget.Layout with the layout looking like this

• Top: YAHOO.widget.MenuBar()
• Center: this is were everything will load from the menu selection
• Left: the login component
• Footer: informational

Now I have everything working at this point
Now I load my ‘User Access Page’ after clicking on the link. The page is displaying YAHOO.widget.TabView(), this display fine.
My problem is I cannot use any YUI widgets in the tab views, it does not format correctly can not see the style of the widgets.
Can anyone help me with this or point me in the right direction, so I can continue developing this app.

Thanks
Charles

Matt Parker

YUI Contributor

  • Username: mattatlamplight
  • Joined: Mon Apr 20, 2009 12:03 pm
  • Posts: 465
  • Location: London UK
  • GitHub: mattparker
  • Gists: mattparker
  • Offline
  • Profile

Re: Cannot Display YUI widgets in TabViews

Post Posted: Fri Oct 22, 2010 2:32 am
+0-
Hi,

Here's a starting point: http://developer.yahoo.com/yui/examples ... bview.html The key line is
Code:
 myTabView.getTab(1).addListener("click", function() {myDataTable.onShow()}); 


As I understand it, the issue is that some widgets use computed styles when they're rendered, but if the tab (and thus widget) is hidden, there won't be any, so it doesn't display properly. The line of code above tells the datatable that the tab's just been made visible, and to do it's thing so it'll display properly.

Matt

Charles Walker

  • Username: cw6834
  • Joined: Thu Mar 18, 2010 12:29 pm
  • Posts: 3
  • IRC: chaz
  • Offline
  • Profile

Re: Cannot Display YUI widgets in TabViews

Post Posted: Fri Oct 22, 2010 11:30 am
+0-
Hi Matt,

thanks alot for your help...
I have some before and after images to show you more details on what i am getting. I tried your line of code but it still did not work.

Thanks again...

thanks
  [ 3 posts ]
Display posts from previous:  Sort by  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum