PDA

View Full Version : menucheckitem's checkBox missing in column layout



SurenderBhyan1
27 Aug 2015, 4:21 AM
Hi ,

I am not sure this is a bug or I am missing something here.

Plateform: Chrome 44.0, IE11

Tested ExtJS Ver: 4.2.1 , 5.0.1.1255, 6.0.0.640

Description: menucheckitem's checkBox is missing in column layout but visible in other layout.

How to reproduce: Just run the below fiddle

https://fiddle.sencha.com/#fiddle/su8

Snapshot:
53106
su8

Requirement : All check box should be visible with column layout too.

Any help will be appreciated =D>

Gary Schlosberg
27 Aug 2015, 2:56 PM
Thanks for the report. Looking at the docs, the layout (http://docs.sencha.com/extjs/4.2.1/#!/api/Ext.menu.Menu-cfg-layout) config is private, and it's the same for 5.x and 6.x. Unfortunately, I don't believe you can configure the a menu in the column layout.

SurenderBhyan1
27 Aug 2015, 9:45 PM
Thanks Gary,


After changing the config as hbox/vbox and able to see the change as hbox layout with check box with each item, then why column layout is not working.

Output:
53115

svs

Can anyone have some workaround for just two column ?
Thank you

jhrinoa
29 Aug 2015, 11:23 AM
Column layout uses "float" property. So making your items's position relative might work for you.

So try the following.



defaults: {
columnWidth: 0.5,
style: {
position: 'relative'
}
}


But then again, like Gary said, it's not really recommended to use private config.
I mean there's no "layout" config publicly available when you look at Ext.menu.Menu class.

SurenderBhyan1
31 Aug 2015, 12:49 AM
Thanks Jhrinoa,
Your workaround worked like a charm and thanks for clearing my confusion with menu layout config.
=D>

https://fiddle.sencha.com/#fiddle/su8