Thursday, April 21, 2011

Taming the Beast - AdvancedDataGrid Code

I refactored and cleaned up my code from my 360Flex unconference presentation. I've posted an example and the code with unit tests at:

the swf has view source enabled, so you can download it that way.

  • External focus control. None, First, Next, Previous or any data item
  • Skipping data via a given condition ( in this case it is when the product.inStock == false)
  • Using arrow keys and page up and page down to move focus
  • Using tab in a normal mouse-less workflow
  • Clicking anywhere in a row causes focus to cell
Goals (as a note to those that didn't attend my session)
  • Very easy to read (Compose, delegate, and very small functions)
  • Swappable functionality on a an instance level
  • Unit Testable
  • 100% decoupled from Data, Models, and Frameworks
  • Still  *is* an AdvancedDataGrid to the developers

No comments:

Post a Comment