So, one of our requirements is to make the up/down arrow keys work in
a DataGrid that is being edited. In Beta 2, I was able to subclass
certain functions (keyDownHandler, findNextEnterItemRenderer) of the
DataGrid which were marked public at the time. Now it seems these
functions are marked private so I am unable to subclass them. Does
anyone have any ideas as to how I can achieve functionality similar to
the code below?

Thanks,
Jim

--------------------------------------

package com.wgint.wglib {
      import mx.controls.DataGrid;
      import flash.ui.Keyboard;
      import flash.events.KeyboardEvent;

      public class WGDataGrid extends DataGrid {
           
            public function WGDataGrid() {
                  super();
            }
           
            override public function keyDownHandler(event:KeyboardEvent):void {
                  if(event.keyCode == Keyboard.DOWN) {
                        event.shiftKey = false;
                                findNextEnterItemRenderer(event);
                     }
                     if(event.keyCode == Keyboard.UP) {
                           event.shiftKey = true;     
                           findNextEnterItemRenderer(event);
                     }
                     super.keyDownHandler(event);
            }     
      }
}


--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com




SPONSORED LINKS
Web site design development Computer software development Software design and development
Macromedia flex Software development best practice


YAHOO! GROUPS LINKS




Reply via email to