Bug 66418 Code formatter not obeying prefs
build i0609-1200 I have my code formatter settings set to put 0 lines before field declarations. I set this up a while ago (months). Template is available from the Core team web page. - When I upgraded to today's build and formatted code, it put spaces between field declarations. - I checked the prefs and it was still set to 0 spaces. - I changed it to be 1 space, hit OK then Apply then back to 0 spaces, and OK and Apply. -> formatting from this point worked ok Note that there were other things that didn't take effect until after the 2nd Apply including: - spaces in array element initializers - tabbing for switch/case statements
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/preferences/formatter/CodingStyleConfigurationBlock.java
private final List fSortedProfiles;
		
		public ProfileComboController() {
			fSortedProfiles= fProfileManager.getSortedProfiles();
			fProfileCombo.addSelectionListener(this);
			fProfileManager.addObserver(this);
			updateProfiles();
			updateSelection();
		}
		
		public void widgetSelected(SelectionEvent e) {
			final int index= fProfileCombo.getSelectionIndex();
			fProfileManager.setSelected((Profile)fSortedProfiles.get(index));
		}
		public void widgetDefaultSelected(SelectionEvent e) {}
		public void update(Observable o, Object arg) {
			if (arg == null) return;
			final int value= ((Integer)arg).intValue();
			switch (value) {
				case ProfileManager.PROFILE_CREATED_EVENT:
				case ProfileManager.PROFILE_DELETED_EVENT:
				case ProfileManager.PROFILE_RENAMED_EVENT:
					updateProfiles();
				case ProfileManager.SELECTION_CHANGED_EVENT:
					updateSelection();
			}
		}