This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 122255 - Add Widget-picking methods
Summary: Add Widget-picking methods
Status: NEW
Alias: None
Product: platform
Classification: Unclassified
Component: Graph (show other bugs)
Version: 6.x
Hardware: All All
: P3 blocker (vote)
Assignee: issues@platform
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-11-19 09:26 UTC by David Kaspar
Modified: 2007-11-22 07:47 UTC (History)
1 user (show)

See Also:
Issue Type: ENHANCEMENT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description David Kaspar 2007-11-19 09:26:45 UTC
It would be good to have
Scene.pick(Point sceneLocation):List<Widget>
method which returns a list of widget that lays at specified scene location.
The method above is inspecting all Widgets on scene based on their boundaries.

There may be a faster implemetation with method:
Scene.pick(Point sceneLocation,ScenePickTask task):boolean
method which returns a boolean state. ScenePickTask interface is having a method which is invoked for each picked widget:
widgetPicked(Widget widget, Point localLocation):ConnectorState
The method should return ConnectorState.ACCEPT, ConnectorState.REJECT or ConnectorState.REJECT_AND_STOP which similar
meaning as it is used in ConnectProvider interface.
Comment 1 Trey Spiva 2007-11-21 20:46:38 UTC
I was thinking why limit this method to the scene.  Why not add the method to the Widget class.  That way you can start the search from any widget.
Comment 2 David Kaspar 2007-11-22 07:47:33 UTC
I totally agree. There is not be any obstacle for having it on Widget.