Dec 24, 2015, 10:43 PM
[OPEN] [#1207] [3.2.1] Menu Item Issue
See complete example. There are a few issues i see when the right click of the grid brings up the context menu.
Test case:
1. load page (no need for store to load)
2. right click on grid
3. mouse over the 'test' item and a submenu 'sdsdsd' will appear
4. click the 'test' menuitem.
issue #1
observed: when clicking, the submenu 'sdsdsd' disappear even though it is flagged HideOnClick false
expected: it shouldnt disappear (though i may not understand the functionality
issue #2
5. after you clicked 'test', it disappeared.
6. now click it again to make the submenu reappear.
observed: unable to make it reappear untill you mouse out and mouse back and then click again
expected: clicking should make 'sdsdsd' reappear
issue #3:
if i mouse over 'test' and it appears, then clicking on 'test' again should do nothing. it shouldnt make it disappear.
Thanks,
/Z
Test case:
1. load page (no need for store to load)
2. right click on grid
3. mouse over the 'test' item and a submenu 'sdsdsd' will appear
4. click the 'test' menuitem.
issue #1
observed: when clicking, the submenu 'sdsdsd' disappear even though it is flagged HideOnClick false
expected: it shouldnt disappear (though i may not understand the functionality
issue #2
5. after you clicked 'test', it disappeared.
6. now click it again to make the submenu reappear.
observed: unable to make it reappear untill you mouse out and mouse back and then click again
expected: clicking should make 'sdsdsd' reappear
issue #3:
if i mouse over 'test' and it appears, then clicking on 'test' again should do nothing. it shouldnt make it disappear.
Thanks,
/Z
<%@ Page Language="C#" %>
<%@ Import Namespace="System.Collections.Generic" %>
<!DOCTYPE html>
<html>
<head id="Head1" runat="server">
<title>Menu bug</title>
</head>
<body>
<form id="Form1" runat="server">
<ext:ResourceManager ID="ResourceManager1" runat="server">
</ext:ResourceManager>
<ext:Viewport ID="Viewport1" runat="server" Layout="FitLayout">
<Items>
<ext:GridPanel
ID="GridPanel1"
runat="server"
Title="Test"
EmptyText="test"
ColumnLines="true"
ContextMenuID="MenuRightClick"
Layout="FitLayout">
<Store>
<ext:Store ID="Store1" runat="server" AutoLoad="false">
<Proxy>
<ext:AjaxProxy Url="/ta/Support/test">
<ActionMethods READ="GET" />
<Reader>
<ext:JsonReader IDProperty="id" RootProperty="data" TotalProperty="total"/>
</Reader>
</ext:AjaxProxy>
</Proxy>
<Model>
<ext:Model ID="Model1" runat="server" IDProperty="TaskID">
<Fields>
<ext:ModelField Name="ProjectID" Type="Int" />
<ext:ModelField Name="Name" />
<ext:ModelField Name="TaskID" Type="Int" />
<ext:ModelField Name="Description" />
<ext:ModelField Name="Estimate" Type="Int" />
<ext:ModelField Name="Rate" Type="Float" />
<ext:ModelField Name="Cost" Type="Float" />
<ext:ModelField Name="Due" Type="Date" />
</Fields>
</ext:Model>
</Model>
<Listeners>
<Load Handler="Ext.net.Mask.show();" Delay="5000" />
</Listeners>
</ext:Store>
</Store>
<ColumnModel ID="ColumnModel1" runat="server">
<Columns>
<ext:Column ID="Column1"
runat="server"
TdCls="task"
Text="Task"
Sortable="true"
DataIndex="Description"
Hideable="false"
Width="300">
</ext:Column>
<ext:Column ID="Column2" runat="server" Text="Project" DataIndex="Name" Width="180" />
<ext:DateColumn ID="DateColumn1"
runat="server"
Width="130"
Text="Due Date"
Sortable="true"
DataIndex="Due"
Format="MM/dd/yyyy">
</ext:DateColumn>
<ext:Column ID="Column3"
runat="server"
Width="130"
Text="Estimate"
Sortable="true"
DataIndex="Estimate">
</ext:Column>
<ext:Column ID="Column4"
runat="server"
Width="130"
Text="Rate"
Sortable="true"
DataIndex="Rate">
</ext:Column>
<ext:Column
runat="server"
Width="130"
ID="Cost"
Text="Cost"
Sortable="false"
Groupable="false"
DataIndex="Cost">
</ext:Column>
</Columns>
</ColumnModel>
<View>
<ext:GridView ID="GridView7" runat="server" StripeRows="true" EmptyText="No Data"/>
</View>
<SelectionModel>
<ext:RowSelectionModel ID="RowSelectionModel1" runat="server" Mode="Single" />
</SelectionModel>
</ext:GridPanel>
</Items>
</ext:Viewport>
<ext:Menu ID="MenuRightClick" runat="server">
<Listeners>
<Show Handler="Ext.QuickTips.getQuickTip().hide();" />
</Listeners>
<Items>
<ext:MenuItem ID="test" Icon="Clock" runat="server" Text="test" HideOnClick="false">
<Menu>
<ext:Menu ID="test4" runat="server">
<Items>
<ext:Label ID="test44" runat="server" Html="<b class='menu-title'>Choose a Option</b>" />
<ext:CheckMenuItem ID="sdfdf" runat="server" Icon="CalendarStar" Text="sdfsdf" Group="theme">
<Listeners>
<Click Handler="alert('test');" />
</Listeners>
</ext:CheckMenuItem>
</Items>
</ext:Menu>
</Menu>
</ext:MenuItem>
</Items>
</ext:Menu>
</form>
</body>
</html>