Re: [Xsltforms-support] set focus to item in a list constructed by repeat
Brought to you by:
alain-couthures
From: Alain C. <ala...@ag...> - 2013-08-10 13:29:02
|
Hi Alex, Could you please try this patch in the xsltforms.js file? In the XsltForms_dispatch.prototype.run function: target = typeof target === "string"? *_XsltForms_idManager.find_*(target) : target; instead of target = typeof target === "string"? *_document.getElementById_*(target) : target; If it does not work as expected, it would be easier for me to use a minimal test case. Thank you for your feedbacks! -Alain Le 09/08/2013 14:02, Alexander Holupirek a écrit : > Hi all, > > let's say I have a long list of items constructed by a repeat. > Now I compute the position of an item I want to be highlighted by setting the index via, for example: > > <xf:setindex repeat="repeat-foo" index="count(instance('inst-foo')/foo[./@id = instance('inst-bar')//id]/preceding-sibling::*)+1"/> > > So far, so good. > > Is there a way to additionally set the focus to this item? > > <xf:setfocus control="repeat-foo"/> does not seem to be intended for such purposes. > > The current state is that in that long list the correct item is highlighted, but the user has to scroll to actually find it. > > Any thoughts? Thanks for your time! > Alex > > ------------------------------------------------------------------------------ > Get 100% visibility into Java/.NET code with AppDynamics Lite! > It's a free troubleshooting tool designed for production. > Get down to code-level detail for bottlenecks, with <2% overhead. > Download for free and get started troubleshooting in minutes. > http://pubads.g.doubleclick.net/gampad/clk?id=48897031&iu=/4140/ostg.clktrk > _______________________________________________ > Xsltforms-support mailing list > Xsl...@li... > https://lists.sourceforge.net/lists/listinfo/xsltforms-support > |