void (LogRecord event) { if (event.getLevel().intValue() < Level.SEVERE.intValue() || AppMode.isCommandLine()) { return; // the dialog appender doesn't deal with non-critical errors and is meaningless when there is no frame to show an error icon } IdeaLoggingEvent ideaEvent; Object[] parameters = event.getParameters(); if (parameters != null && parameters.length > 0 && parameters[0] instanceof IdeaLoggingEvent) { ideaEvent = (IdeaLoggingEvent)parameters[0]; } else { Throwable thrown = event.getThrown(); if (thrown == null) return; ideaEvent = extractLoggingEvent(event.getMessage(), thrown); } synchronized (this) { if (LoadingState.COMPONENTS_LOADED.isOccurred() && !ourDelay) { IdeaLoggingEvent queued; while ((queued = myEarlyEvents.poll()) != null) queueAppend(queued); queueAppend(ideaEvent); } else if (myEarlyEvents.size() < MAX_EARLY_LOGGING_EVENTS) { myEarlyEvents.add(ideaEvent); } } }