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 137319 - palette: imports are not automatically added
Summary: palette: imports are not automatically added
Status: VERIFIED FIXED
Alias: None
Product: javafx
Classification: Unclassified
Component: Editor (show other bugs)
Version: 6.x
Hardware: All Linux
: P3 blocker (vote)
Assignee: Michal Skvor
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-06-16 14:55 UTC by Alexandr Scherbatiy
Modified: 2008-06-20 19:24 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alexandr Scherbatiy 2008-06-16 14:55:55 UTC
See http://forums.java.net/jive/thread.jspa?messageID=279771

Steps to reproduce:

- Drag the Frame element from the Palette to the editor
- Build th project
  The project is not compiled because necessary imports has not
  been automatically added
Comment 1 Alexandr Scherbatiy 2008-06-16 14:56:37 UTC
JavaFXApplication2\src\javafxapplication2\Main.fx:9: cannot find symbol
symbol  : class Frame
location: class javafxapplication2.Main
Frame {
JavaFXApplication2\src\javafxapplication2\Main.fx:18: cannot find symbol
symbol  : class Canvas
location: class javafxapplication2.Main
    content: Canvas {
2 errors
BUILD FAILED (total time: 1 second)
Comment 2 Martin Ryzl 2008-06-17 17:54:14 UTC
adding David to cc and my question is - can this be fixed any time soon? If I correctly remember fix import in general
is not easy but in this case, we know in advance what import we know for the snippets, for instance when adding Label:

Label {
    text: "Label"
}

we know that javafx.gui.Label or javafx.gui.* is required.
Comment 3 Michal Skvor 2008-06-17 18:44:50 UTC
I would like to implement it till the end of this week.
Comment 4 Michal Skvor 2008-06-20 09:23:52 UTC
Implemented. Automatic addition of imports should be working now.
Comment 5 Lark Fitzgerald 2008-06-20 19:24:06 UTC
Verified using:
Product Version: NetBeans IDE 6.1 (Build 200804211638)
Java: 1.6.0_10-beta; Java HotSpot(TM) Client VM 11.0-b11
System: Windows Vista version 6.0 running on x86; Cp1252; en_US (nb)
fx NB61 nighly plugin: 271

But there is also a new issue:
http://www.netbeans.org/issues/show_bug.cgi?id=137841