Ahh ok, it would be very nice if there could be a patch somehow on this.. BTW the auto hook is extremely simple.. So it will only auto hook in the most simple cases, you can always override, and manually tell it what todo..
2009/1/29 dukejansen <[email protected]> > > The code I posted below actually doesn't even get called if the tag has an > onclick attribute... > > I'm working up a workaround now, I'll post it if it ends up working... > > -Jason > > > dukejansen wrote: > > > > Nino, > > > > Thanks for the quick reply... > > > > I dug a bit deeper and you are correct, it does have some hooks for > > handling Links, but it may only work for links which extend from the base > > Link class. > > > > // Try to bind to link so shortcut will work. > Should only be done if > > // no other handlers were found > > if (component instanceof Link && eventType == null) > { > > linkUnbound = true; > > return; > > } > > > > In my case, the link is an Ajax link which launches a Modal, and AjaxLink > > does not extend Link. Furthermore, the behavior of simply handling the > > link by calling location = href is not necessarily sufficient - I believe > > this would circumvent any onclick event handlers set on the tag, which > > would prevent the AjaxLink from working... > > > > I'm thinking the hook for ajax links probably needs to be something like > a > > combination of the two mechanisms - instead of trying to call click(), > > which doesn't exist, would need to call the onclick() directly, and then > > check it's result and if true follow the link, if false do not... that > way > > it could still handle the ajax fallback links as well, I believe. > > > > This is all theory, haven't actually verified any of this would work > > yet... > > > > On top of all this, I'm working with a 1.4 backport we made of the > > input-events code, so any fix I come up with will likely not make it back > > into the main trunk for the input-events module... > > > > -Jason > > > > > > Nino Martinez-2 wrote: > >> > >> I cant exactly remember what the scope where, just that it did support > >> links at some point, in safari and IE. Patches are always welcome.. > >> > >> But looking in the source there are some auto hooking for links > >> actually, which uses href instead of click AFAIR it should just pick it > >> up automaticly...: > >> > >> <script type="text/javascript"> > >> function init${wicketComponentId}() { > >> shortcut.add("${keys}",function() { > >> > >> > >> window.location=document.getElementById('${wicketComponentId}').href; > >> > >> },{ > >> 'disable_in_input':${disable_in_input}, > >> 'type':'${type}', > >> 'propagate':${propagate}, > >> 'target':${target} > >> > >> }); > >> } > >> init${wicketComponentId}(); > >> </script> > >> > >> Did you check the examples, and see if they still are working, they do > >> include a link aswell? > >> > >> > https://wicket-stuff.svn.sourceforge.net/svnroot/wicket-stuff/trunk/wicketstuff-core/input-events-parent/input-events-examples > >> > > > > > > -- > View this message in context: > http://www.nabble.com/Issues-with-wicket-contrib-input-events-in-Mozilla-tp21718528p21732636.html > Sent from the Wicket - User mailing list archive at Nabble.com. > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [email protected] > For additional commands, e-mail: [email protected] > >
