[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]
Subject: Re: The highlight() method
I haven't heard from anyone regarding this one either? Your comments
would be appreciated.
--
Benoit mailto:benoit@itedo.com
Friday, November 25, 2005, 10:54:57 AM, you wrote:
> Hi,
> Itedo noticed that the highlight() method on the Picture interface
> may be problematic.
> The prototype is:
> void highlight(in WebCGMNodeList nodes, in boolean state);
> The method works for the following script:
> var list = pic.getAppStructuresByName("listToHighlight");
> pic.highlight( list, true );
> however, the following code is invalid:
> var aps = pic.getAppStructureById("apsToHighlight");
> pic.highlight( aps, true );
> getAppStructureById returns a WebCGMNode, not a WebCGMNodeList, doh!
> Here are some options that we have:
> i) leave it like this, fix in a later version (2.1) but that means
> WebCGM 2.0 users will not be able to highlight a single Application
> Structures.
> ii) change getAppStructureById to return a WebCGMNodeList. This
> however will force script writers to write:
> var id = pic.getAppStructureById("myID");
> if( id.count > 0 )
> {
> id.item(0). etc...
> }
> every time they want to access and APS by Id.
> iii) have two highlight methods. One that is called highlight(
> takes a WebCGMNode ) and one called highlightMany( takes a
> WebCGMNodeList). It wouldn't look very good in the spec, but hey, it
> would work.
> iv) introduce some sort of WebCGMNode.makeList() method that
> would return a WebCGMNodeList from a WebCGMNode. This approach would
> need more thoughts, as it could complicate the 'live' node
> implementation of our DOM.
> Thoughts,
[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]