Problem with an eclipse tutorial [message #464026] |
Thu, 22 February 2007 09:55 |
Eclipse User |
|
|
|
Next problem...currently I am working with the Tutorial "How to use the
JFace TreeViewer" at
http://www.eclipse.org/articles/Article-TreeViewer/TreeViewe rArticle.htm#viewerFilters
and I have a problem with the actions used for the filters there.
protected void updateFilter(Action action) {
if(action == atLeatThreeItems) {
if(action.isChecked()) {
treeViewer.addFilter(atLeastThreeFilter);
} else {
treeViewer.removeFilter(atLeastThreeFilter);
}
} else if(action == onlyBoardGamesAction) {
if(action.isChecked()) {
treeViewer.addFilter(onlyBoardGamesFilter);
} else {
treeViewer.removeFilter(onlyBoardGamesFilter);
}
}
}
My problem is (by using the debugger) that action.isChecked() returns
always false even when I added setChecked(true) and the GUI shows me the
selected Action. According to the API the isChecked-method only works
with the style AS_CHECK_BOX and AS_RADIO_BUTTON???
I am trying to get this running now since some time but without success
and I hope someone here could help me
Thanks
--Marc
|
|
|
Powered by
FUDForum. Page generated in 0.05396 seconds