|
From: Raymond I. <xw...@ya...> - 2003-08-25 19:30:10
|
Hi Stephen,
I've seen your post sometime and I believe the way you
did it was to use a Java Applet to capture the keys?
I believe Kevin is the best person to port such
function in DynKeyEvent since he had done an excellent
job with DynKey and TabManager.
PS. I think such extended keybard fnuctions should not
be enabled by default.
--
Raymond Irving
--- Stephen Carroll <sca...@vi...> wrote:
> I while back I also wrote a library that corrects
> for keyboard events by
> returning a remapped ascii set. If you notice,
> keyboard events on IE and
> Netcape return different keycodes. I've made one mod
> to remap them and get
> the case right. May I suggest that be corrected as
> well. Also, there was an
> example I sent out that showed how to retrieve tab,
> shift+alt+del, enter,
> and even arrow keys regardless of platform or
> browser but it was in DynAPI
> 2.5. I haven't had the time to port it to 3.0 but I
> believe the code should
> be implemented, as keyboard support is rather poor
> to date.
>
> ----- Original Message -----
> From: "Raymond Irving" <xw...@ya...>
> To: <dyn...@li...>
> Sent: Friday, August 22, 2003 9:11 AM
> Subject: Re: [Dynapi-Dev] Keyboard events in
> HTMLTextBox
>
>
> >
> > Point well taken. I'll see to it that your changes
> be
> > implemented inside the HTML form based components.
> >
> > --
> > Raymond Irving
> >
> > --- Andrew Gillett <an...@zo...> wrote:
> > > Hello,
> > >
> > > I have had a problem with capturing keyboard
> events
> > > in HTMLTextBox. I
> > > want to execute some code when the Enter key is
> > > pressed in a textbox,
> > > but while the keyboard event handling in
> HTMLTextBox
> > > works quite well it
> > > doesn't allow me to find out which key was
> pressed.
> > >
> > > The getInnerHTML function in htmltextbox.js
> > > contains:
> > > this._inlineEvents+=' onkeypress="return
> > > htc._e(\'keypress\',this);" '
> > > +' onkeyup="return htc._e(\'keyup\',this);"
> '
> > > +' onkeydown="return
> htc._e(\'keyup\',this);" '
> > >
> > > The event handlers are invoked with two
> arguments: a
> > > String that give
> > > the kind of event and a reference to the TextBox
> > > object. The event
> > > handler in my own code gets the reference to the
> > > object but this doesn't
> > > let me find out which key was pressed.
> > >
> > > I have worked around this problem in my own copy
> of
> > > DynAPI by adding the
> > > "event" object to the arguments passed to the
> event
> > > handler:
> > > this._inlineEvents+=' onkeypress="return
> > > htc._e(\'keypress\',this,event);" '
> > > +' onkeyup="return
> > > htc._e(\'keyup\',this,event);" '
> > > +' onkeydown="return
> > > htc._e(\'keyup\',this,event);" '
> > > ...
> > >
> > > The _e function also needs to change from:
> > > p._e = function(evt,elm){
> > > var rt = this._oldHCTBEvt(evt,elm);
> > > to
> > > p._e = function(evt,elm,arg){
> > > var rt = this._oldHCTBEvt(evt,elm,arg);
> > >
> > >
> > > This allows my own event handler two receive two
> > > parameters: the object
> > > that raised the event and the event itself.
> > >
> > > May I suggest this change be made to the
> library?
> > > I'm hoping it won't
> > > cause any cross-browser portability problems.
> > >
> > >
> > >
> > > On a slightly different matter, while I was
> poking
> > > about in
> > > htmltextbox.js, I noticed that line 72
> contained:
> > > if(this.getElm()) this.elm.readonly=(b)?
> > > 'readyonly':'';
> > >
> > > The 'readyonly' looks like a typo which should
> > > probably be fixed.
> > >
> > >
> > >
> > > regards
> > > Andrew Gillett
> > >
> > > ps. I'm using the latest version for DynAPI3
> from
> > > CVS.
> > >
> > >
> > >
> > >
> > >
> > >
> >
>
-------------------------------------------------------
> > > This SF.net email is sponsored by: VM Ware
> > > With VMware you can run multiple operating
> systems
> > > on a single machine.
> > > WITHOUT REBOOTING! Mix Linux / Windows / Novell
> > > virtual machines
> > > at the same time. Free trial click
> > > here:http://www.vmware.com/wl/offer/358/0
> > > _______________________________________________
> > > Dynapi-Dev mailing list
> > > Dyn...@li...
> > >
> >
>
http://www.mail-archive.com/dyn...@li.../
> >
> >
> > __________________________________
> > Do you Yahoo!?
> > Yahoo! SiteBuilder - Free, easy-to-use web site
> design software
> > http://sitebuilder.yahoo.com
> >
> >
>
>
>
>
>
-------------------------------------------------------
> This SF.net email is sponsored by: VM Ware
> With VMware you can run multiple operating systems
> on a single machine.
> WITHOUT REBOOTING! Mix Linux / Windows / Novell
> virtual machines
> at the same time. Free trial click
> here:http://www.vmware.com/wl/offer/358/0
> _______________________________________________
> Dynapi-Dev mailing list
> Dyn...@li...
>
http://www.mail-archive.com/dyn...@li.../
__________________________________
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com
|