[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Newsgroup Home]
|
[news.eclipse.platform.rcp] Eclispe NewBie question - Preferences and WorkbenchPlugin
|
Hello,
I 've added preference page in my application using plugin.xml extensions
template.
Then, in a new package, Eclipse created 3 classes (Template preferences page
extending
FieldEditorPreferencePage, a preference constants class and a preference
initializer class).
The template preferences page uses a PreferenceClass which doesn't already
exists...
I suppose this class has to initialize the preference store, in the
preference template class
constructor, unsing the plugin instance of the product :
"setPreferenceStore(PreferenceClass.getDefault().getPreferenceStore());"
I've tried to extend the AbstractUIPlugin (I've read in differents articles
from eclipse.org) to catch the
plugin instance when it is created, but without succes (when to catch this
single instance during startup of eclispe
core runtime ?). Then I've found the existance of the WorkBenchPlugin class
which holds this static instance,
I used it, discarding PreferenceClass , but Eclispe tells me that the use of
this class is discouraged.
Why ? How is it possible to store the plugin instance at startup ?
Thanks a lot for your help,
frank