protected void setProgressText(final ToolWindow toolWindow, final String progressTextKey) {
final Content content = toolWindow.getContentManager().getContent(0);
// the content instance will be a JLabel while the component initialises
if (content != null && content.getComponent() instanceof CheckStyleToolWindowPanel) {
final ResourceBundle resources = ResourceBundle.getBundle(CheckStyleConstants.RESOURCE_BUNDLE);
final CheckStyleToolWindowPanel panel = (CheckStyleToolWindowPanel) content.getComponent();
panel.setProgressText(resources.getString(progressTextKey));
}
}