Originally Posted by
geoffrey.mcgill
Hi Marcelo,
You can set Animate="true" on the <ext:AccordionLayout> control, or set within the <LayoutConfig>. Default value is false.
Hi Geoffrey,
I just got latest 1.0 code from SVN today (August 23, 2010) and begun upgrading my 0.8.2 project to 1.0.
On the whole very smooth upgrade (well done). Had a couple of issues with AccordionLayout:
1) Setting Animate="true" on <ext:AccordionLayout> does NOT work, but setting within the <LayoutConfig> of a Panel with Layout="Accordion" does work.
2) When inside a border layout's region, the accordion layout ends up getting a blank title at the top of the region which did not happen before in 0.8.2.
Code example using Accordion element with Animate="true":
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Accordion.aspx.cs" Inherits="Ext.Net.Tests.Layout.Accordion" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title>Accordion example</title>
</head>
<body>
<ext:ResourceManager ID="ResourceManager1" runat="server" />
<form id="form1" runat="server">
<div>
<ext:Viewport runat="server">
<Content>
<ext:BorderLayout runat="server">
<North>
<ext:Panel Title="Header" runat="server" Height="70" Split="false">
<Content>
<p>{Branding header area}</p>
</Content>
</ext:Panel>
</North>
<Center>
<ext:Panel Title="Main Content" runat="server">
<Content>
<p>{Main content area}</p>
<p>Problems:</p>
<ul>
<li>Blank title now appears (didn't appear in 0.8.2)</li>
<li>Even though Animate="true" is set on AccordionLayout, it doesn't animate</li>
</ul>
</Content>
</ext:Panel>
</Center>
<West MinWidth="155" MaxWidth="400" Split="true" Collapsible="true" Floatable="false">
<ext:Panel ID="WestPanel" runat="server" Width="225" TitleCollapse="true">
<Content>
<ext:AccordionLayout ID="Accordion1" runat="server" Animate="true">
<Items>
<ext:Panel ID="Panel1" runat="server" Title="Panel 1" Icon="Table" Border="false" Cls="content-panel" AutoScroll="True">
<Content>
{Panel 1}
</Content>
</ext:Panel>
<ext:Panel ID="Panel2" runat="server" Title="Panel 2" Icon="FolderGo" Border="false" Cls="content-panel" AutoScroll="True">
<Content>
{Panel 2}
</Content>
</ext:Panel>
<ext:Panel ID="Panel3" runat="server" Title="Panel 3" Icon="Magnifier" Border="false" Cls="content-panel" AutoScroll="True">
<Content>
{Panel 3}
</Content>
</ext:Panel>
<ext:Panel ID="Panel4" runat="server" Title="Panel 4" Icon="Cog" Border="false" Cls="content-panel filters" AutoScroll="True">
<Content>
{Panel 4}
</Content>
</ext:Panel>
<ext:Panel ID="Panel5" runat="server" Title="Panel 5" Border="false" Cls="content-panel" Icon="PageWhiteWrench" AutoScroll="True">
<Content>
{Panel 5}
</Content>
</ext:Panel>
</Items>
</ext:AccordionLayout>
</Content>
</ext:Panel>
</West>
</ext:BorderLayout>
</Content>
</ext:Viewport>
</div>
</form>
</body>
</html>
Here's the example where animate works, using Panel's layout attribute instead, but the blank title still appears:
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Accordion.aspx.cs" Inherits="Ext.Net.Tests.Layout.Accordion" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
<title>Accordion example</title>
</head>
<body>
<ext:ResourceManager ID="ResourceManager1" runat="server" />
<form id="form1" runat="server">
<div>
<ext:Viewport ID="Viewport1" runat="server">
<Content>
<ext:BorderLayout ID="BorderLayout1" runat="server">
<North>
<ext:Panel ID="Panel1" Title="Header" runat="server" Height="70" Split="false">
<Content>
<p>{Branding header area}</p>
</Content>
</ext:Panel>
</North>
<Center>
<ext:Panel ID="Panel2" Title="Main Content" runat="server">
<Content>
<p>{Main content area}</p>
<p>Problems:</p>
<ul>
<li>Switching to Panel with Layout="config" works but blank title still appears (not there in 0.8.2)</li>
<li>When Collapsible = "true" the panel's header appears</li>
</ul>
</Content>
</ext:Panel>
</Center>
<West MinWidth="155" MaxWidth="400" Split="true" Collapsible="true" Floatable="false">
<ext:Panel ID="WestPanel" Layout="Accordion" runat="server" Width="225" TitleCollapse="true">
<Items>
<ext:Panel ID="Panel3" runat="server" Title="Panel 1" Icon="Table" Border="false" Cls="content-panel" AutoScroll="True">
<Content>
{Panel 1}
</Content>
</ext:Panel>
<ext:Panel ID="Panel4" runat="server" Title="Panel 2" Icon="FolderGo" Border="false" Cls="content-panel" AutoScroll="True">
<Content>
{Panel 2}
</Content>
</ext:Panel>
<ext:Panel ID="Panel5" runat="server" Title="Panel 3" Icon="Magnifier" Border="false" Cls="content-panel" AutoScroll="True">
<Content>
{Panel 3}
</Content>
</ext:Panel>
<ext:Panel ID="Panel6" runat="server" Title="Panel 4" Icon="Cog" Border="false" Cls="content-panel filters" AutoScroll="True">
<Content>
{Panel 4}
</Content>
</ext:Panel>
<ext:Panel ID="Panel7" runat="server" Title="Panel 5" Border="false" Cls="content-panel" Icon="PageWhiteWrench" AutoScroll="True">
<Content>
{Panel 5}
</Content>
</ext:Panel>
</Items>
<LayoutConfig>
<ext:AccordionLayoutConfig Animate="true" />
</LayoutConfig>
</ext:Panel>
</West>
</ext:BorderLayout>
</Content>
</ext:Viewport>
</div>
</form>
</body>
</html>
Any suggestions?