blob: decc20fc41364ac0c0f097d8a7ea03d5f7d007e4 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
|
/*****************************************************************************
* Copyright (c) 2016 CEA LIST, ALL4TEC and others.
*
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
* Mickael ADAM (ALL4TEC) mickael.adam@all4tec.net - Initial API and implementation
*****************************************************************************/
package org.eclipse.papyrus.views.modelexplorer.preferences;
import org.eclipse.core.runtime.preferences.AbstractPreferenceInitializer;
import org.eclipse.jface.preference.IPreferenceStore;
import org.eclipse.papyrus.views.modelexplorer.Activator;
/**
* This preference initializer for filter preferences.
*/
public class FilterPreferenceInitializer extends AbstractPreferenceInitializer {
/**
* Initialize default preferences specific filter field preferences.
*/
@Override
public void initializeDefaultPreferences() {
IPreferenceStore store = getPreferenceStore();
store.setDefault(IFilterPreferenceConstants.PREF_FILTER_LIVE_VALIDATION, IFilterPreferenceConstants.DEFAULT_FILTER_LIVE_VALIDATION_VALUE);
store.setDefault(IFilterPreferenceConstants.PREF_FILTER_VALIDATION_DELAY, IFilterPreferenceConstants.DEFAULT_VALIDATION_DELAY_VALUE);
store.setDefault(IFilterPreferenceConstants.PREF_FILTER_STEREOTYPE_REPLACED, IFilterPreferenceConstants.DEFAULT_FILTER_STEREOTYPE_REPLACED_VALUE);
}
/**
* Get the preference store.
*/
protected IPreferenceStore getPreferenceStore() {
return Activator.getDefault().getPreferenceStore();
}
}
|