Bug 17598 Source->Generate Getter and Setter enabled for read only file
F1 This action is enabled for read-only files. Executing it shows a dialog saying that the file is read-only. The action should be disabled since all other source actions are disabled as well.
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/actions/AddGetterSetterAction.java
run(type, new IField[0]);	
						return;
					} 
				}
			} 
			MessageDialog.openInformation(getShell(), dialogTitle, 
				ActionMessages.getString("AddGetterSetterAction.not_applicable")); 
		} catch (CoreException e) {
			JavaPlugin.log(e.getStatus());
			showError(ActionMessages.getString("AddGetterSetterAction.error.actionfailed")); 
		}
	}
	
	private boolean checkCu(IMember member) throws JavaModelException{
		if (JavaModelUtil.isEditable(member.getCompilationUnit())) 
			return true;
		MessageDialog.openInformation(getShell(), dialogTitle, 
			ActionMessages.getFormattedString("AddGetterSetterAction.read_only", member.getElementName())); 
		return false;
	}
	
	
	
	private void run(IField[] getterFields, IField[] setterFields, IEditorPart editor) {
		try{
			AddGetterSetterOperation op= createAddGetterSetterOperation(getterFields, setterFields);
			new ProgressMonitorDialog(getShell()).run(false, true, new WorkbenchRunnableAdapter(op));
		
			IMethod[] createdMethods= op.getCreatedAccessors();
			if (createdMethods.length > 0) {