Bug 76453 [Encodings] Open properties fills log with encoding messages
I20041013 Every time I open the properties for a file it writes the following entries to .log (and also messages to the console): !ENTRY org.eclipse.ui 4 4 Okt 18, 2004 10:21:41.328 !MESSAGE null is not a valid charset. !ENTRY org.eclipse.ui 4 4 Okt 18, 2004 10:21:41.328 !MESSAGE null is not a valid charset. !ENTRY org.eclipse.ui 4 4 Okt 18, 2004 10:21:41.338 !MESSAGE null is not a valid charset. !ENTRY org.eclipse.ui 4 4 Okt 18, 2004 10:21:41.338 !MESSAGE null is not a valid charset. !ENTRY org.eclipse.ui 4 4 Okt 18, 2004 10:21:41.338 !MESSAGE null is not a valid charset. !ENTRY org.eclipse.ui 4 4 Okt 18, 2004 10:21:41.348 !MESSAGE null is not a valid charset. !ENTRY org.eclipse.ui 4 4 Okt 18, 2004 10:21:41.348 !MESSAGE null is not a valid charset. !ENTRY org.eclipse.ui 4 4 Okt 18, 2004 10:21:41.358 !MESSAGE null is not a valid charset. !ENTRY org.eclipse.ui 4 4 Okt 18, 2004 10:21:41.358 !MESSAGE null is not a valid charset. !ENTRY org.eclipse.ui 4 4 Okt 18, 2004 10:21:41.358 !MESSAGE null is not a valid charset. !ENTRY org.eclipse.ui 4 4 Okt 18, 2004 10:21:41.368 !MESSAGE null is not a valid charset. !ENTRY org.eclipse.ui 4 4 Okt 18, 2004 10:21:41.368 !MESSAGE null is not a valid charset. !ENTRY org.eclipse.ui 4 4 Okt 18, 2004 10:21:41.378 !MESSAGE null is not a valid charset. !ENTRY org.eclipse.ui 4 4 Okt 18, 2004 10:21:41.378 !MESSAGE null is not a valid charset. !ENTRY org.eclipse.ui 4 4 Okt 18, 2004 10:21:41.388 !MESSAGE null is not a valid charset. !ENTRY org.eclipse.ui 4 4 Okt 18, 2004 10:21:41.388 !MESSAGE null is not a valid charset. !ENTRY org.eclipse.ui 4 4 Okt 18, 2004 10:21:41.388 !MESSAGE null is not a valid charset.
bundles/org.eclipse.ui.ide/src/org/eclipse/ui/ide/IDEEncoding.java
*            to the default.
	 * @deprecated Use IWorkspaceRoot#setDefaultCharset and 
	 * add the encoding using #addEncoding.
	 * This API will be deleted before 3.1 M3.
	 */
	public static void setResourceEncoding(String value) {
		if (value != null)
			addIDEEncoding(value);	
		
		final String finalValue = value;
		Job charsetJob = new Job(IDEWorkbenchMessages.getString("IDEEncoding.EncodingJob")){ 
			/* (non-Javadoc)
			 * @see org.eclipse.core.runtime.jobs.Job#run(org.eclipse.core.runtime.IProgressMonitor)
			 */
			protected IStatus run(IProgressMonitor monitor) {
				try {
					ResourcesPlugin.getWorkspace().getRoot().setDefaultCharset(finalValue, monitor);
				} catch (CoreException exception) {
					return exception.getStatus();
				}
				return Status.OK_STATUS;
				
			}
			
			/* (non-Javadoc)
			 * @see org.eclipse.core.runtime.jobs.Job#shouldRun()
			 */
			public boolean shouldRun() {
				
				return PlatformUI.isWorkbenchRunning();