Dec 11, 2013, 12:19 PM
[CLOSED] TabCloseMenu Plugin.
Guys
Anyway I have a series of tabs which have the property "CloseAction=Hide" however if I close them using the TabCloseMenu plugin they seem to get destroyed as opposed to hidden.
Is there a way to tell the TabCloseMenu plugin to respect that property or to override the default handler of the TabCloseMenu.
Example of code that fails.
Anyway I have a series of tabs which have the property "CloseAction=Hide" however if I close them using the TabCloseMenu plugin they seem to get destroyed as opposed to hidden.
Is there a way to tell the TabCloseMenu plugin to respect that property or to override the default handler of the TabCloseMenu.
Example of code that fails.
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Debug.aspx.cs" Inherits="Measures.Debug" %>
<%@ Register Assembly="Ext.Net" Namespace="Ext.Net" TagPrefix="ext" %>
<script runat="server">
[DirectMethod]
public void OpenTab(bool Tab1Open, bool Tab2Open)
{
if (Tab1Open == false)
{
this.TabPanel1.ShowTab(this.Tab1, true);
this.Tab1.SetTitle("Tab 1");
}
else if (Tab2Open == false)
{
this.TabPanel1.ShowTab(this.Tab2, true);
this.Tab2.SetTitle("Tab 2");
}
}
</script>
<!DOCTYPE html>
<html>
<head id="Head1" runat="server">
<title>Ext.NET v2 Example</title>
</head>
<body>
<form id="Form2" runat="server">
<ext:ResourceManager ID="ResourceManager2" runat="server" />
<ext:Button ID="Button2"
runat="server"
Text="OpenTab"
OnClientClick="App.direct.OpenTab(App.TabPanel1.contains(App.Tab1), App.TabPanel1.contains(App.Tab2));" />
<ext:TabPanel ID="TabPanel1" runat="server">
<Plugins>
<ext:TabCloseMenu ID="TabCloseMenu1" runat="server" />
</Plugins>
<Bin>
<ext:Panel
ID="Tab1"
runat="server"
Closable="true"
CloseAction="Hide"
Hidden="true" />
<ext:Panel
ID="Tab2"
runat="server"
Closable="true"
CloseAction="Hide"
Hidden="true" />
</Bin>
</ext:TabPanel>
</form>
</body>
</html>
Last edited by Daniil; Dec 12, 2013 at 6:20 AM.
Reason: [CLOSED]