After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 325837 - Nullable parameters not handled correctly in TreeView and ListStore.
Nullable parameters not handled correctly in TreeView and ListStore.
Status: RESOLVED FIXED
Product: java-gnome
Classification: Bindings
Component: GTK
Not Applicable
Other All
: Normal normal
: ---
Assigned To: Ismael Juma
java-gnome bindings maintainers
Depends on:
Blocks:
 
 
Reported: 2006-01-05 08:50 UTC by Damian Minkov
Modified: 2006-01-09 02:43 UTC
See Also:
GNOME target: ---
GNOME version: 2.9/2.10



Description Damian Minkov 2006-01-05 08:50:50 UTC
Please describe the problem:
In the doc for this method (TreeView.setCursor) is said 
@param focusColumn A TreeViewColumn, or NULL

in order to not start editing the row you must supply the third param false and
you can pass for column null. But in the source I saw 
gtk_tree_view_set_cursor(getHandle(), path.getHandle(), focusColumn.getHandle(),
startEditing);

And if you pass NULL for focusColumn it will always throw NullPointerException

Steps to reproduce:
1. create TreeView
2. pass null to TreeView.setCursor as second param
3. 


Actual results:
NullPointerException

Expected results:
to be focused on the appropriate row.

Does this happen every time?
yes

Other information:
Comment 1 Remy Suen 2006-01-07 22:34:01 UTC
It seems that this problem is also prevalent in various other places within TreeView.java with moveColumn(TreeViewColumn, TreeViewColumn), setExpanderColumn(TreeViewColumn), scrollToCell(TreePath), setModel(TreeModel), and the other setCursor(TreePath, TreeViewColumn, CellRenderer, boolean) method. There are similar problems with ListStore's insertRowBefore(TreeIter) and insertRowAfter(TreeIter) methods.
Comment 2 Ismael Juma 2006-01-09 02:22:03 UTC
Updating summary to better reflect the problem, considering comment #1.
Comment 3 Ismael Juma 2006-01-09 02:43:43 UTC
Thanks for reporting this. A fix has been applied to CVS HEAD. I've also updated the summary once again to mention ListStore. :)