Bug 274262 [History] Allow to never prune history
I20090429-0100. I never want to loose my history and I never want to waste time on shutdown (or start up) to do any history pruning. Please add a preference to disable pruning entirely.
bundles/org.eclipse.ui.ide/src/org/eclipse/ui/internal/ide/dialogs/FileStatesPage.java
protected void performDefaults() {
        super.performDefaults();
        Preferences prefs = ResourcesPlugin.getPlugin().getPluginPreferences();
        long days = prefs
                .getDefaultLong(ResourcesPlugin.PREF_FILE_STATE_LONGEVITY)
                / DAY_LENGTH;
        long megabytes = prefs
                .getDefaultLong(ResourcesPlugin.PREF_MAX_FILE_STATE_SIZE)
                / MEGABYTES;
        this.longevityText.setText(String.valueOf(days));
        this.maxStatesText.setText(prefs
                .getDefaultString(ResourcesPlugin.PREF_MAX_FILE_STATES));
        this.maxStateSizeText.setText(String.valueOf(megabytes));
        checkState();
    }
    /** 
     * Perform the result of the OK from the receiver.
     */
    public boolean performOk() {
        long longevityValue = validateLongTextEntry(longevityText);
        int maxFileStates = validateMaxFileStates();
        long maxStateSize = validateMaxFileStateSize();
        if (longevityValue == FAILED_VALUE || maxFileStates == FAILED_VALUE
                || maxStateSize == FAILED_VALUE) {
			return false;
		}
        IWorkspaceDescription description = getWorkspaceDescription();
        description.setFileStateLongevity(longevityValue * DAY_LENGTH);
        description.setMaxFileStates(maxFileStates);
        description.setMaxFileStateSize(maxStateSize * MEGABYTES);