Ext


Go Back   Ext JS Forums > Ext JS Community Forums (2.0) > Ext 2.x: User Extensions and Plugins

Reply
 
Thread Tools
  #1  
Old 03-01-2008, 03:15 PM
Condor's Avatar
Condor Condor is offline
Ext JS - Community Support Team
 
Join Date: Mar 2007
Location: The Netherlands
Posts: 14,249
Condor is on a distinguished road
Default [2.x] Tri-state checkbox and themed checkbox and radio

I know several of you have been waiting for this extension:

Tri-state checkbox and themed checkbox and radio components:



The attachment contains all needed files and an example.

Know issues:
Ext.ux.form.Radio currently ONLY works with the ext-base.js adapter.

Remarks:
- TriCheckbox is actually a multi-state checkbox. You can supply values and checkedCls arrays in the config with values and CSS classes for every state.
- Does somebody have better looking grayed checkbox images?
Attached Files
File Type: zip Ext.ux.form.Checkbox.zip (7.4 KB, 671 views)

Last edited by Condor; 03-08-2008 at 10:36 AM.. Reason: Added TriCheckbox
Reply With Quote
  #2  
Old 03-03-2008, 05:05 PM
dantheman's Avatar
dantheman dantheman is offline
Ext User
 
Join Date: Mar 2007
Posts: 249
dantheman is on a distinguished road
Default Very cool!

How will this play under a non-Ext theme (eg Slate)?

--dan
Reply With Quote
  #3  
Old 03-04-2008, 12:26 AM
Condor's Avatar
Condor Condor is offline
Ext JS - Community Support Team
 
Join Date: Mar 2007
Location: The Netherlands
Posts: 14,249
Condor is on a distinguished road
Default

The checkbox images are blue'ish. You might want to change them to gray.

The CSS also assumes a line-height of 13. For a smaller line-height you will have to adjust the CSS and the images, for a bigger line-height you can just add margins in the CSS.
Reply With Quote
  #4  
Old 03-08-2008, 10:16 AM
Condor's Avatar
Condor Condor is offline
Ext JS - Community Support Team
 
Join Date: Mar 2007
Location: The Netherlands
Posts: 14,249
Condor is on a distinguished road
Default

I was reading the Ext roadmap thread and noticed the request for tri-state checkboxes.

Since I already made the themed checkbox adding tri-state support wasn't that hard.

(I updated my original post with the new code)
Reply With Quote
  #5  
Old 03-08-2008, 11:13 AM
jgarcia@tdg-i.com's Avatar
jgarcia@tdg-i.com jgarcia@tdg-i.com is offline
Ext User
 
Join Date: Mar 2007
Location: Frederick MD, NYC, DC
Posts: 11,448
jgarcia@tdg-i.com is on a distinguished road
Send a message via AIM to jgarcia@tdg-i.com Send a message via Skype™ to jgarcia@tdg-i.com
Default

Excellent work Condor
__________________
Get 42% off by using coupon code n2442 valid until (11/24/09) -> [Book] - Ext JS In Action

My Blog || Ext JS screencasts || ext-doc || twitter

My free extensions/plugins:
Progressbar inside paging toolbar || Tab panel scroller menu || Window drawers || Icon Manager
Grid view custom 'view' filter || PanelHeaderToolbar

JavaScript Magazine August article now available.
Reply With Quote
  #6  
Old 03-10-2008, 07:40 PM
SeaSharp2 SeaSharp2 is offline
Ext User
 
Join Date: Dec 2007
Posts: 141
SeaSharp2 is on a distinguished road
Default

Looking at the screen shots I do not understand how the tri-state will behave. Going by another Winform library I reckon the most intuitive behavior is:

Classic unchecked.
Classic checked.
Uniform mid-dark grey block.

Three clicks should cycle through those 3 states. Is this how the new Ext implementation works.
Reply With Quote
  #7  
Old 03-11-2008, 03:04 AM
Condor's Avatar
Condor Condor is offline
Ext JS - Community Support Team
 
Join Date: Mar 2007
Location: The Netherlands
Posts: 14,249
Condor is on a distinguished road
Default

Quote:
Originally Posted by SeaSharp2 View Post
Three clicks should cycle through those 3 states. Is this how the new Ext implementation works.
Yes.

The only problem is that I don't have good images of a grayed checkbox.
If somebody could provide those I would gladly replace my images (I need normal, focussed, down and disabled state images).
Reply With Quote
  #8  
Old 03-13-2008, 07:58 PM
SeaSharp2 SeaSharp2 is offline
Ext User
 
Join Date: Dec 2007
Posts: 141
SeaSharp2 is on a distinguished road
Default

Quote:
Originally Posted by Condor View Post
I would gladly replace my images (I need normal, focussed, down and disabled state images).
Just wanted to clarify my view on what a tri-state checkbox is about. The 3rd state is "not declared" which is different to a state of disabled.
Reply With Quote
  #9  
Old 01-08-2009, 04:42 PM
gjain gjain is offline
Ext User
 
Join Date: May 2008
Posts: 14
gjain is on a distinguished road
Default

There seems to be a bug in this extension. The check event is getting blocked. So if I add a listener for the check event, it never gets called. Has someone else experienced this?

Tx
Reply With Quote
  #10  
Old 01-08-2009, 05:54 PM
Condor's Avatar
Condor Condor is offline
Ext JS - Community Support Team
 
Join Date: Mar 2007
Location: The Netherlands
Posts: 14,249
Condor is on a distinguished road
Default

I abandoned this project when Ext 2.2 came out. Which version of Ext JS are you using?
Reply With Quote
Reply

Thread Tools

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

All times are GMT -5. The time now is 05:06 AM.

© 2006-2009 Ext, LLC
Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.