NetBeans Forums
| View previous topic :: View next topic |
| Author |
Message |
mostlair
Joined: 26 Jun 2010 Posts: 71 Location: Argentina
|
Posted: Mon Jun 28, 2010 1:42 pm Post subject: Problem with SAF, maven and Matisse |
|
|
Hi: I'm working in a desktop project with swing application framework, and designing the UI using Matisse, but I found a problem when refactoring to separete in several independent JPanels.
It seems that, when maven support and the SAF-Archetype are used, I can't add the jpanel (my subclass) to a jframe or jinternalframe. It works perfectly in a desktop app project, without maven, and it should not be a problem AFAIK.
I proved 2 strategies that I know without lucky: just drag from project explorer and drop in the form, and add the elements to the palette.
The jpanels ARE compiled, I know that it's impossible to use the jpanels subclasses before compilation, that is the same with or without maven...
I reproduced this in 3 computers with NB 6.8 and 6.9, and windows XP and 7. Is it a bug? Can anyone else reproduce it? Did I make a mistake maybe? Some workarround if I didn't?
Best regards.- |
|
| Back to top |
|
 |
mostlair
Joined: 26 Jun 2010 Posts: 71 Location: Argentina
|
Posted: Mon Jun 28, 2010 2:25 pm Post subject: |
|
|
I'm still on it, and I got an important message when trying to drag and drop my jpanel: "Cannot blablabla... The class must be compiled and must be on the classpath of the project to wich this form belongs".
NB doesn't show it always, and I cannot discover when it does or not, it's some kind of combination of clean&compile of this and other opened projects... but it is not resolved by just recompiling the project. Is there some compile-related option/preferency that could cause trouble? I'm pretty sure it's all by default in this project anyway...
I'll post if I have some news,
best regards.- |
|
| Back to top |
|
 |
mostlair
Joined: 26 Jun 2010 Posts: 71 Location: Argentina
|
Posted: Tue Jun 29, 2010 3:41 pm Post subject: |
|
|
Ok, I could reproduce the same problem in 4 computers now:
2 with win XP and both NB 6.8 and 6.9. I checked it with the same project and independent ones
1 win vista with NB 6.8
1 win 7 with NB 6.8
I've never reported a bug but I'm reading thte guidelines to do it, but one of the requeriments is that the problem should be reproducible and, as I've already posted it here:
Can anyone try the following with a NB 6.8 and/or NB 6.9?
1 - Create a new project, select maven in categories and "Maven Project" as project type
2 - Select "Maven Quick Startarchetype", it should be the first one, outside any repository
3 - Give the project a name and location
4 - Creat a package "newpackage"
5 - Create a new JPanel in that package an drop some swing elements
6 - Create a JFrame in the package and save it
7 - Right click the project and select clean and build
test 1 - open the JFrame and select the design mode, go to the project explorer and try to drag the created JPanel and drop it in the JFrame in the explorer
Expected: the JPanel is displayed in the JFrame (as a JPanel but using the subclass)
test 2 - right click in the palette and open the palette manager, select "Add from project", locate the project and click next
Expected: the window shows the created JPanel and JFrame as components to add to the palette.
An my questions would be: can anyone reproduce it? Is it well explained to present it as a bug? |
|
| Back to top |
|
 |
Tomas Pavek Posted via mailing list.
|
Posted: Fri Jul 02, 2010 1:18 pm Post subject: Problem with SAF, maven and Matisse |
|
|
In 6.9 this should be working better than in 6.8. But maybe you face bug
http://netbeans.org/bugzilla/show_bug.cgi?id=186493
mostlair wrote:
| Quote: | I'm still on it, and I got an important message when trying to drag and drop my jpanel: "Cannot blablabla... The class must be compiled and must be on the classpath of the project to wich this form belongs".
NB doesn't show it always, and I cannot discover when it does or not, it's some kind of combination of clean&compile of this and other opened projects... but it is not resolved by just recompiling the project. Is there some compile-related option/preferency that could cause trouble? I'm pretty sure it's all by default in this project anyway...
I'll post if I have some news,
best regards.-
|
|
|
| Back to top |
|
 |
mostlair
Joined: 26 Jun 2010 Posts: 71 Location: Argentina
|
Posted: Tue Jul 06, 2010 12:42 pm Post subject: |
|
|
Thanks for your interest Tomas! Yes, the maven support should be better in 6.9 but I can't really compare them, the only feature I did want in 6.8 seem to be missing in 6.9 (if it's not a bug) The bug you pointed is related but not what I meant, thanks anyway.
I found a "workaround" (maybe is just the way to do it with maven, I'm not sure) The way to do it seems to be add the beans to the palette from the jar file in target folder... you can use the one in the repository, but I prefer not to do it -> right click the palette > palette manager > add from jar > go to the projects folder, target subfolder and choose the jar. That's all. You should recompile and reopen the class using a bean to see the changes in it.
I wanted to DnD beans directly from the projects panel, as with any ant project, or add the beans to the palette from the projects, but NB just doesn't find the classes in classpath, so they doesn't exist.
An option is to change the project and use ant+ivy. If you just use maven becouse of the dependency management it can be an option. I don't know the differencies in the advanced features, in the basics both are the same.
Hope that helps someone... |
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You can attach files in this forum You can download files in this forum
|
|