public void apply()

in src/main/java/org/apache/log4j/chainsaw/ApplicationPreferenceModel.java [192:237]


    public void apply(ApplicationPreferenceModel model) {
        setIdentifierExpression(model.getIdentifierExpression());
        setShowNoReceiverWarning(model.isShowNoReceiverWarning() || (model.getConfigurationURL() == null || model.getConfigurationURL().trim().equals("")));
        setResponsiveness(model.getResponsiveness());
        setTabPlacement(model.getTabPlacement());
        setStatusBar(model.isStatusBar());
        setToolbar(model.isToolbar());
        setReceivers(model.isReceivers());
        if (model.getLookAndFeelClassName() != null && !model.getLookAndFeelClassName().trim().equals("")) {
            setLookAndFeelClassName(model.getLookAndFeelClassName());
        } else {
            //ensure current look and feel is selected
            setLookAndFeelClassName(UIManager.getLookAndFeel().getClass().getName());
        }
        setConfirmExit(model.isConfirmExit());
        setShowSplash(model.isShowSplash());
        setToolTipDisplayMillis(model.getToolTipDisplayMillis());
        setCyclicBufferSize(model.getCyclicBufferSize());
        Vector<String> configurationURLs = model.getConfigurationURLs();
        if (configurationURLs != null) {
            setConfigurationURLs(configurationURLs);
        }
        //only set current config URL if bypass is null
        if (model.getBypassConfigurationURL() == null) {
            setConfigurationURL(model.getConfigurationURL());
        }
        setLastUsedVersion(model.getLastUsedVersion());
        setOkToRemoveSecurityManager(model.isOkToRemoveSecurityManager());
        Color searchForeground = model.getSearchForegroundColor();
        Color searchBackground = model.getSearchBackgroundColor();
        if (searchForeground != null && searchBackground != null) {
            setSearchBackgroundColor(searchBackground);
            setSearchForegroundColor(searchForeground);
        }

        Color alternatingForeground = model.getAlternatingColorForegroundColor();
        Color alternatingBackground = model.getAlternatingColorBackgroundColor();
        if (alternatingForeground != null && alternatingBackground != null) {
            setAlternatingBackgroundColor(alternatingBackground);
            setAlternatingForegroundColor(alternatingForeground);
        }
        if (model.isDefaultColumnsSet()) {
            setDefaultColumnNames(model.getDefaultColumnNames());
        }
        setBypassSearchColors(model.isBypassSearchColors());
    }