> so it would seem like something evil is happening when some UserData  
> is deleted. Thing is i'm not aware of attaching any user data to any  
> qtjambi object. Any help is appreciated.


I think we might have had a similar problem some time ago.
At first we prevented these JVM crashes by calling "System.exit(0);" 
after "QApplication.exec();" but that solution ceased to work after a 
jambi update.
After quite some long hours pinpointing that needle in the haystack we 
found out that the following lines were the culprit:

*************************************

for (int i =0;i < points_.size();i++) {
                        MPoint point = points_.get(i);
                        QGraphicsPathItem item;
                        QPainterPath path = new QPainterPath();
                        
path.addEllipse(point.x - a, point.y - b, 2 * a,2 * b);

// Some more stuff with the path

                        
if (point.valid == null || point.valid == true){
   item = scene().addPath(path,new QPen(QColor.black),new 
QBrush(QColor.black));
}else{
   item = scene().addPath(path, new QPen(QColor.lightGray));
}

// Some more stuff with the item

item.setData(32, point.widget); // CRASHES THE VM AT THE END
item.setData(33, point.x);
point.widget.setData(0, 32, item);


*****************

The original idea was that each point knows of its corresponding list 
element (the point.widget is a QTreeWidgetItem) and vice versa. It 
worked quite well but the circle of putting the widget into the item and 
the item back into the widget apparently caused alot of troubles when 
the JVM tries to clean everything up.

Not sure if that is of any help but who knows...

best regards
Florian
                
_______________________________________________
Qt-jambi-interest mailing list
[email protected]
http://lists.trolltech.com/mailman/listinfo/qt-jambi-interest

Reply via email to