else if (fUseTransformerCheck.getSelection() != fPrefUseLinkTransformer)
otherDisplayChanges = true;
else {
IStructuredSelection selection = (IStructuredSelection) fLinkTransformerViewer.getSelection();
if (!selection.isEmpty()) {
LinkTransformer transformer = (LinkTransformer) selection.getFirstElement();
if (!transformer.getId().equals(fPrefLinkTransformerId))
otherDisplayChanges = true;
}
}
/*
* We can not simply store the one display property that has changed if any
* of the properties changed because as soon as the global scope changes in
* any way, these changes here would be overridden otherwise. The fix is to
* store all display properties into the news mark in case any has changed.
*/
if (otherDisplayChanges) {
changed = true;
scope.putBoolean(DefaultPreferences.BM_OPEN_SITE_FOR_NEWS, fOpenLinkOfNewsRadio.getSelection());
scope.putBoolean(DefaultPreferences.BM_OPEN_SITE_FOR_EMPTY_NEWS, fOpenSiteForEmptyNewsCheck.getSelection());
scope.putBoolean(DefaultPreferences.ENABLE_IMAGES, fLoadImagesForNewsCheck.getSelection());
scope.putBoolean(DefaultPreferences.ENABLE_MEDIA, fLoadMediaForNewsCheck.getSelection());
scope.putBoolean(DefaultPreferences.BM_USE_TRANSFORMER, fUseTransformerCheck.getSelection());
IStructuredSelection selection = (IStructuredSelection) fLinkTransformerViewer.getSelection();
if (!selection.isEmpty()) {
LinkTransformer transformer = (LinkTransformer) selection.getFirstElement();
scope.putString(DefaultPreferences.BM_TRANSFORMER_ID, transformer.getId());
}
}
return changed;
}