diff --git a/java/compiler/impl/src/com/intellij/compiler/options/CompilerConfigurable.java b/java/compiler/impl/src/com/intellij/compiler/options/CompilerConfigurable.java
index f48a81ed0589..7614ebcdeed0 100644
--- a/java/compiler/impl/src/com/intellij/compiler/options/CompilerConfigurable.java
+++ b/java/compiler/impl/src/com/intellij/compiler/options/CompilerConfigurable.java
@@ -41,7 +41,7 @@ import java.util.Collections;
import java.util.Comparator;
import java.util.List;
-public class CompilerConfigurable implements SearchableConfigurable.Parent {
+public class CompilerConfigurable implements SearchableConfigurable.Parent, Configurable.NoScroll {
private static final Logger LOG = Logger.getInstance("#com.intellij.compiler.options.CompilerConfigurable");
private final Project myProject;
diff --git a/java/compiler/impl/src/com/intellij/compiler/options/CompilerOptionsPanel.form b/java/compiler/impl/src/com/intellij/compiler/options/CompilerOptionsPanel.form
index 5294042ebf11..3438552c1290 100644
--- a/java/compiler/impl/src/com/intellij/compiler/options/CompilerOptionsPanel.form
+++ b/java/compiler/impl/src/com/intellij/compiler/options/CompilerOptionsPanel.form
@@ -1,6 +1,6 @@
diff --git a/java/compiler/impl/src/com/intellij/compiler/options/CompilerUIConfigurable.java b/java/compiler/impl/src/com/intellij/compiler/options/CompilerUIConfigurable.java
index 61e32f8aa50b..1fa9511d4b14 100644
--- a/java/compiler/impl/src/com/intellij/compiler/options/CompilerUIConfigurable.java
+++ b/java/compiler/impl/src/com/intellij/compiler/options/CompilerUIConfigurable.java
@@ -49,10 +49,10 @@ public class CompilerUIConfigurable implements SearchableConfigurable, Configura
myProject = project;
myCbUseCompileServer.setVisible(ApplicationManager.getApplication().isInternal());
myPatternLegendLabel.setText("" +
- "Use ; to separate patterns and ! to negate a pattern.
" +
- "Accepted wildcards: ? — exactly one symbol; * — zero or more symbols;
" +
- " / — path separator; /**/ — any number of directories;
" +
- " <dir_name>:<pattern> — restrict to source roots with the specified name" +
+ "Use ; to separate patterns and ! to negate a pattern. " +
+ "Accepted wildcards: ? — exactly one symbol; * — zero or more symbols; " +
+ "/ — path separator; /**/ — any number of directories; " +
+ "<dir_name>:<pattern> — restrict to source roots with the specified name" +
"");
}
diff --git a/java/debugger/impl/src/com/intellij/debugger/ui/ExpressionEvaluationDialog.java b/java/debugger/impl/src/com/intellij/debugger/ui/ExpressionEvaluationDialog.java
index c61d1301b83e..eab6dd027d74 100644
--- a/java/debugger/impl/src/com/intellij/debugger/ui/ExpressionEvaluationDialog.java
+++ b/java/debugger/impl/src/com/intellij/debugger/ui/ExpressionEvaluationDialog.java
@@ -80,8 +80,8 @@ public class ExpressionEvaluationDialog extends EvaluationDialog {
final JPanel panel = new JPanel(new GridBagLayout());
final JLabel expressionLabel = new JLabel(DebuggerBundle.message("label.evaluate.dialog.expression"));
- panel.add(expressionLabel, new GridBagConstraints(0, GridBagConstraints.RELATIVE, 1, 1, 0.0, 0.0, GridBagConstraints.WEST, GridBagConstraints.NONE, new Insets(5, 0, 0, 0), 0, 0));
- panel.add(getExpressionCombo(), new GridBagConstraints(1, GridBagConstraints.RELATIVE, 1, 1, 1.0, 0.0, GridBagConstraints.NORTHWEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 0, 0), 0, 0));
+ panel.add(expressionLabel, new GridBagConstraints(0, GridBagConstraints.RELATIVE, 1, 1, 0.0, 0.0, GridBagConstraints.BASELINE_LEADING, GridBagConstraints.NONE, new Insets(0, 0, 0, 0), 0, 0));
+ panel.add(getExpressionCombo(), new GridBagConstraints(1, GridBagConstraints.RELATIVE, 1, 1, 1.0, 0.0, GridBagConstraints.BASELINE_LEADING, GridBagConstraints.HORIZONTAL, new Insets(0, 10, 0, 0), 0, 0));
final JLabel resultLabel = new JLabel(DebuggerBundle.message("label.evaluate.dialog.result"));
panel.add(resultLabel, new GridBagConstraints(0, GridBagConstraints.RELATIVE, 2, 1, 1.0, 0.0, GridBagConstraints.NORTHWEST, GridBagConstraints.NONE, new Insets(5, 0, 0, 0), 0, 0));
diff --git a/java/idea-ui/src/com/intellij/facet/impl/ui/FacetEditorImpl.java b/java/idea-ui/src/com/intellij/facet/impl/ui/FacetEditorImpl.java
index 78af4b89e87b..de8bbb9f157a 100644
--- a/java/idea-ui/src/com/intellij/facet/impl/ui/FacetEditorImpl.java
+++ b/java/idea-ui/src/com/intellij/facet/impl/ui/FacetEditorImpl.java
@@ -28,6 +28,7 @@ import com.intellij.openapi.options.UnnamedConfigurable;
import com.intellij.openapi.options.UnnamedConfigurableGroup;
import com.intellij.openapi.util.Disposer;
import com.intellij.ui.TabbedPaneWrapper;
+import com.intellij.util.ui.UIUtil;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
@@ -77,7 +78,11 @@ public class FacetEditorImpl extends UnnamedConfigurableGroup implements Unnamed
if (myEditorTabs.length > 1) {
final TabbedPaneWrapper tabbedPane = new TabbedPaneWrapper(myDisposable);
for (FacetEditorTab editorTab : myEditorTabs) {
- tabbedPane.addTab(editorTab.getDisplayName(), editorTab.getIcon(), editorTab.createComponent(), null);
+ JComponent c = editorTab.createComponent();
+ if (c != null) {
+ UIUtil.addInsets(c, UIUtil.PANEL_SMALL_INSETS);
+ }
+ tabbedPane.addTab(editorTab.getDisplayName(), editorTab.getIcon(), c, null);
}
tabbedPane.addChangeListener(new ChangeListener() {
public void stateChanged(ChangeEvent e) {
diff --git a/java/idea-ui/src/com/intellij/openapi/roots/ui/configuration/AnnotationsEditor.java b/java/idea-ui/src/com/intellij/openapi/roots/ui/configuration/AnnotationsEditor.java
index 9b4f8c0f7016..082ecbaef263 100644
--- a/java/idea-ui/src/com/intellij/openapi/roots/ui/configuration/AnnotationsEditor.java
+++ b/java/idea-ui/src/com/intellij/openapi/roots/ui/configuration/AnnotationsEditor.java
@@ -20,15 +20,16 @@ import com.intellij.openapi.fileChooser.FileChooserDescriptor;
import com.intellij.openapi.fileChooser.FileChooserDescriptorFactory;
import com.intellij.openapi.project.ProjectBundle;
import com.intellij.openapi.roots.AnnotationOrderRootType;
-import com.intellij.openapi.ui.PanelWithText;
import com.intellij.openapi.util.IconLoader;
import com.intellij.openapi.vfs.VirtualFile;
import com.intellij.ui.ColoredTableCellRenderer;
import com.intellij.ui.ScrollPaneFactory;
import com.intellij.ui.TableUtil;
+import com.intellij.ui.components.JBLabel;
import com.intellij.util.ArrayUtil;
import com.intellij.util.ui.ItemRemovable;
import com.intellij.util.ui.Table;
+import com.intellij.util.ui.UIUtil;
import javax.swing.*;
import javax.swing.border.Border;
@@ -81,8 +82,7 @@ public class AnnotationsEditor extends ModuleElementsEditor {
}
public JComponent createComponentImpl() {
- final JPanel mainPanel = new JPanel(new BorderLayout());
- mainPanel.setBorder(BorderFactory.createEmptyBorder(6, 6, 6, 6));
+ final JPanel mainPanel = new JPanel(new BorderLayout(5, 10));
mainPanel.setPreferredSize(new Dimension(-1, 200));
final DefaultTableModel tableModel = createModel();
myTable = new Table(tableModel);
@@ -109,14 +109,12 @@ public class AnnotationsEditor extends ModuleElementsEditor {
});
final JPanel panel = new JPanel(new GridBagLayout());
- panel.add(myAddPathButton, new GridBagConstraints(0, GridBagConstraints.RELATIVE, 1, 1, 1.0, 0.0, GridBagConstraints.NORTH, GridBagConstraints.HORIZONTAL, new Insets(0, 6, 0, 0), 0, 0));
- panel.add(myRemoveButton, new GridBagConstraints(0, GridBagConstraints.RELATIVE, 1, 1, 1.0, 1.0, GridBagConstraints.NORTH, GridBagConstraints.HORIZONTAL, new Insets(6, 6, 0, 0), 0, 0));
+ panel.add(myAddPathButton, new GridBagConstraints(0, GridBagConstraints.RELATIVE, 1, 1, 1.0, 0.0, GridBagConstraints.NORTH, GridBagConstraints.HORIZONTAL, new Insets(0, 0, 0, 0), 0, 0));
+ panel.add(myRemoveButton, new GridBagConstraints(0, GridBagConstraints.RELATIVE, 1, 1, 1.0, 1.0, GridBagConstraints.NORTH, GridBagConstraints.HORIZONTAL, new Insets(4, 0, 0, 0), 0, 0));
mainPanel.add(ScrollPaneFactory.createScrollPane(myTable), BorderLayout.CENTER);
mainPanel.add(panel, BorderLayout.EAST);
- final PanelWithText panelWithText = new PanelWithText(ProjectBundle.message("project.roots.external.annotations.description"));
- panelWithText.setBorder(null);
- mainPanel.add(panelWithText, BorderLayout.NORTH);
+ mainPanel.add(new JBLabel(ProjectBundle.message("project.roots.external.annotations.description"), UIUtil.ComponentStyle.SMALL, UIUtil.FontColor.BRIGHTER), BorderLayout.NORTH);
myTable.getSelectionModel().addListSelectionListener(new ListSelectionListener() {
public void valueChanged(ListSelectionEvent e) {
diff --git a/java/idea-ui/src/com/intellij/openapi/roots/ui/configuration/ConfigurationErrorsComponent.java b/java/idea-ui/src/com/intellij/openapi/roots/ui/configuration/ConfigurationErrorsComponent.java
index 72e35ed64766..9233ad1d8c88 100644
--- a/java/idea-ui/src/com/intellij/openapi/roots/ui/configuration/ConfigurationErrorsComponent.java
+++ b/java/idea-ui/src/com/intellij/openapi/roots/ui/configuration/ConfigurationErrorsComponent.java
@@ -135,6 +135,7 @@ public class ConfigurationErrorsComponent extends JPanel implements Disposable,
add(myCurrentView.self(), BorderLayout.CENTER);
myCurrentView.updateView();
+ UIUtil.adjustWindowToMinimumSize(SwingUtilities.getWindowAncestor(this));
revalidate();
repaint();
}
@@ -282,8 +283,8 @@ public class ConfigurationErrorsComponent extends JPanel implements Disposable,
if (window != null) {
final Dimension d = window.getSize();
final Dimension preferredSize = getPreferredSize();
- setPreferredSize(new Dimension(preferredSize.width, d.height / 4));
- setMinimumSize(new Dimension(preferredSize.width, 100));
+ setPreferredSize(new Dimension(preferredSize.width, 200));
+ setMinimumSize(getPreferredSize());
}
}
diff --git a/java/idea-ui/src/com/intellij/openapi/roots/ui/configuration/JavadocEditor.java b/java/idea-ui/src/com/intellij/openapi/roots/ui/configuration/JavadocEditor.java
index 2ae3030d7d00..4cbb4489199b 100644
--- a/java/idea-ui/src/com/intellij/openapi/roots/ui/configuration/JavadocEditor.java
+++ b/java/idea-ui/src/com/intellij/openapi/roots/ui/configuration/JavadocEditor.java
@@ -21,15 +21,16 @@ import com.intellij.openapi.fileChooser.FileChooserDescriptorFactory;
import com.intellij.openapi.project.ProjectBundle;
import com.intellij.openapi.projectRoots.ui.Util;
import com.intellij.openapi.roots.JavadocOrderRootType;
-import com.intellij.openapi.ui.PanelWithText;
import com.intellij.openapi.util.IconLoader;
import com.intellij.openapi.vfs.VirtualFile;
import com.intellij.ui.ColoredTableCellRenderer;
import com.intellij.ui.ScrollPaneFactory;
import com.intellij.ui.TableUtil;
+import com.intellij.ui.components.JBLabel;
import com.intellij.util.ArrayUtil;
import com.intellij.util.ui.ItemRemovable;
import com.intellij.util.ui.Table;
+import com.intellij.util.ui.UIUtil;
import javax.swing.*;
import javax.swing.border.Border;
@@ -83,9 +84,7 @@ public class JavadocEditor extends ModuleElementsEditor {
}
public JComponent createComponentImpl() {
- final JPanel mainPanel = new JPanel(new BorderLayout());
- mainPanel.setBorder(BorderFactory.createEmptyBorder(6, 6, 6, 6));
- mainPanel.setPreferredSize(new Dimension(-1, 200));
+ final JPanel mainPanel = new JPanel(new BorderLayout(5, 10));
final DefaultTableModel tableModel = createModel();
myTable = new Table(tableModel);
myTable.setIntercellSpacing(new Dimension(0, 0));
@@ -113,15 +112,13 @@ public class JavadocEditor extends ModuleElementsEditor {
});
final JPanel panel = new JPanel(new GridBagLayout());
- panel.add(myAddPathButton, new GridBagConstraints(0, GridBagConstraints.RELATIVE, 1, 1, 1.0, 0.0, GridBagConstraints.NORTH, GridBagConstraints.HORIZONTAL, new Insets(0, 6, 0, 0), 0, 0));
- panel.add(myAddUrlButton, new GridBagConstraints(0, GridBagConstraints.RELATIVE, 1, 1, 1.0, 0.0, GridBagConstraints.NORTH, GridBagConstraints.HORIZONTAL, new Insets(6, 6, 0, 0), 0, 0));
- panel.add(myRemoveButton, new GridBagConstraints(0, GridBagConstraints.RELATIVE, 1, 1, 1.0, 1.0, GridBagConstraints.NORTH, GridBagConstraints.HORIZONTAL, new Insets(6, 6, 0, 0), 0, 0));
+ panel.add(myAddPathButton, new GridBagConstraints(0, GridBagConstraints.RELATIVE, 1, 1, 1.0, 0.0, GridBagConstraints.NORTH, GridBagConstraints.HORIZONTAL, new Insets(0, 0, 0, 0), 0, 0));
+ panel.add(myAddUrlButton, new GridBagConstraints(0, GridBagConstraints.RELATIVE, 1, 1, 1.0, 0.0, GridBagConstraints.NORTH, GridBagConstraints.HORIZONTAL, new Insets(4, 0, 0, 0), 0, 0));
+ panel.add(myRemoveButton, new GridBagConstraints(0, GridBagConstraints.RELATIVE, 1, 1, 1.0, 1.0, GridBagConstraints.NORTH, GridBagConstraints.HORIZONTAL, new Insets(4, 0, 0, 0), 0, 0));
mainPanel.add(ScrollPaneFactory.createScrollPane(myTable), BorderLayout.CENTER);
mainPanel.add(panel, BorderLayout.EAST);
- final PanelWithText panelWithText = new PanelWithText(ProjectBundle.message("project.roots.javadoc.tab.description"));
- panelWithText.setBorder(null);
- mainPanel.add(panelWithText, BorderLayout.NORTH);
+ mainPanel.add(new JBLabel(ProjectBundle.message("project.roots.javadoc.tab.description"), UIUtil.ComponentStyle.SMALL, UIUtil.FontColor.BRIGHTER), BorderLayout.NORTH);
myTable.getSelectionModel().addListSelectionListener(new ListSelectionListener() {
public void valueChanged(ListSelectionEvent e) {
diff --git a/java/idea-ui/src/com/intellij/openapi/roots/ui/configuration/OutputEditor.java b/java/idea-ui/src/com/intellij/openapi/roots/ui/configuration/OutputEditor.java
index 9b9cecbce37d..1f6c7e98882a 100644
--- a/java/idea-ui/src/com/intellij/openapi/roots/ui/configuration/OutputEditor.java
+++ b/java/idea-ui/src/com/intellij/openapi/roots/ui/configuration/OutputEditor.java
@@ -24,10 +24,12 @@ package com.intellij.openapi.roots.ui.configuration;
import com.intellij.openapi.project.ProjectBundle;
import com.intellij.ui.IdeBorderFactory;
+import com.intellij.util.ui.UIUtil;
import org.jetbrains.annotations.NonNls;
import org.jetbrains.annotations.Nullable;
import javax.swing.*;
+import javax.swing.border.EmptyBorder;
import java.awt.*;
public class OutputEditor extends ModuleElementsEditor {
@@ -44,18 +46,17 @@ public class OutputEditor extends ModuleElementsEditor {
protected JComponent createComponentImpl() {
final JPanel panel = new JPanel(new GridBagLayout());
+ panel.setBorder(new EmptyBorder(UIUtil.PANEL_SMALL_INSETS));
final GridBagConstraints gc =
- new GridBagConstraints(0, GridBagConstraints.RELATIVE, 1, 1, 1, 0, GridBagConstraints.NORTHWEST, GridBagConstraints.HORIZONTAL, new Insets(0, 0, 0, 0), 0, 0);
+ new GridBagConstraints(0, GridBagConstraints.RELATIVE, 1, 1, 1, 0, GridBagConstraints.NORTHWEST, GridBagConstraints.BOTH, new Insets(0, 0, 0, 0), 0, 0);
panel.add(myCompilerOutputEditor.createComponentImpl(), gc);
final JPanel javadocPanel = (JPanel)myJavadocEditor.createComponentImpl();
javadocPanel.setBorder(IdeBorderFactory.createTitledBorder(myJavadocEditor.getDisplayName(), false, false, true));
+ gc.weighty = 1;
panel.add(javadocPanel, gc);
final JPanel annotationsPanel = (JPanel)myAnnotationsEditor.createComponentImpl();
annotationsPanel.setBorder(IdeBorderFactory.createTitledBorder(myAnnotationsEditor.getDisplayName(), false, false, true));
panel.add(annotationsPanel, gc);
- panel.add(Box.createVerticalBox(), new GridBagConstraints(0, GridBagConstraints.RELATIVE, 1, 1, 1, 1, GridBagConstraints.CENTER,
- GridBagConstraints.BOTH, new Insets(0,0,0,0), 0, 0));
- panel.setBorder(BorderFactory.createEmptyBorder(4, 4, 4, 4));
return panel;
}
diff --git a/java/idea-ui/src/com/intellij/openapi/roots/ui/configuration/artifacts/ArtifactEditorImpl.java b/java/idea-ui/src/com/intellij/openapi/roots/ui/configuration/artifacts/ArtifactEditorImpl.java
index f3959c21ff8a..c69cd57bc5af 100644
--- a/java/idea-ui/src/com/intellij/openapi/roots/ui/configuration/artifacts/ArtifactEditorImpl.java
+++ b/java/idea-ui/src/com/intellij/openapi/roots/ui/configuration/artifacts/ArtifactEditorImpl.java
@@ -61,7 +61,6 @@ import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
import javax.swing.*;
-import javax.swing.border.Border;
import javax.swing.event.HyperlinkEvent;
import javax.swing.event.HyperlinkListener;
import java.awt.*;
@@ -198,8 +197,7 @@ public class ArtifactEditorImpl implements ArtifactEditorEx {
Splitter splitter = new Splitter(false);
final JPanel leftPanel = new JPanel(new BorderLayout());
leftPanel.add(myLayoutTreeComponent.getTreePanel(), BorderLayout.CENTER);
- final Border border = BorderFactory.createEmptyBorder(3, 3, 3, 3);
- leftPanel.setBorder(border);
+ leftPanel.setBorder(BorderFactory.createEmptyBorder(3, 3, 3, 0));
splitter.setFirstComponent(leftPanel);
final JPanel rightPanel = new JPanel(new BorderLayout());
@@ -224,7 +222,7 @@ public class ArtifactEditorImpl implements ArtifactEditorEx {
rightTopPanel.add(labelPanel, BorderLayout.SOUTH);
rightPanel.add(rightTopPanel, BorderLayout.NORTH);
rightPanel.add(ScrollPaneFactory.createScrollPane(mySourceItemsTree), BorderLayout.CENTER);
- rightPanel.setBorder(border);
+ rightPanel.setBorder(BorderFactory.createEmptyBorder(3, 0, 3, 3));
splitter.setSecondComponent(rightPanel);
diff --git a/platform/lang-impl/src/com/intellij/execution/actions/RunConfigurationAction.java b/platform/lang-impl/src/com/intellij/execution/actions/RunConfigurationAction.java
index 61d6b12fa1b0..862790d02294 100644
--- a/platform/lang-impl/src/com/intellij/execution/actions/RunConfigurationAction.java
+++ b/platform/lang-impl/src/com/intellij/execution/actions/RunConfigurationAction.java
@@ -120,6 +120,14 @@ public class RunConfigurationAction extends ComboBoxAction implements DumbAware
LOG.assertTrue(frame != null);
frame.getComponent().getRootPane().putClientProperty(BUTTON_KEY, this);
}
+
+ @Override
+ public void removeNotify() {
+ final IdeFrame frame = findFrame(this);
+ LOG.assertTrue(frame != null);
+ frame.getComponent().getRootPane().putClientProperty(BUTTON_KEY, null);
+ super.removeNotify();
+ }
};
final JPanel panel = new JPanel(new BorderLayout());
diff --git a/platform/lang-impl/src/com/intellij/find/impl/FindDialog.java b/platform/lang-impl/src/com/intellij/find/impl/FindDialog.java
index 98e8b48a1af8..01c6bb74aee3 100644
--- a/platform/lang-impl/src/com/intellij/find/impl/FindDialog.java
+++ b/platform/lang-impl/src/com/intellij/find/impl/FindDialog.java
@@ -806,7 +806,12 @@ public class FindDialog extends DialogWrapper {
gbConstraints.gridx++;
gbConstraints.weightx = 1;
gbConstraints.gridwidth = 2;
- myScopeCombo = new ScopeChooserCombo(myProject, true, true, FindSettings.getInstance().getDefaultScopeName());
+ myScopeCombo = new ScopeChooserCombo(myProject, true, true, FindSettings.getInstance().getDefaultScopeName()) {
+ @Override
+ public Dimension getMinimumSize() {
+ return new Dimension(200, super.getMinimumSize().height);
+ }
+ };
Disposer.register(myDisposable, myScopeCombo);
scopePanel.add(myScopeCombo, gbConstraints);
diff --git a/platform/lang-impl/src/com/intellij/profile/codeInspection/ui/SingleInspectionProfilePanel.java b/platform/lang-impl/src/com/intellij/profile/codeInspection/ui/SingleInspectionProfilePanel.java
index 45cb44146e42..909fa7e4e1c0 100644
--- a/platform/lang-impl/src/com/intellij/profile/codeInspection/ui/SingleInspectionProfilePanel.java
+++ b/platform/lang-impl/src/com/intellij/profile/codeInspection/ui/SingleInspectionProfilePanel.java
@@ -534,9 +534,6 @@ public class SingleInspectionProfilePanel extends JPanel {
final JScrollPane scrollPane = ScrollPaneFactory.createScrollPane(myTree);
scrollPane.setHorizontalScrollBarPolicy(ScrollPaneConstants.HORIZONTAL_SCROLLBAR_AS_NEEDED);
TreeUtil.collapseAll(myTree, 1);
- final Dimension preferredSize = new Dimension(myTree.getPreferredSize().width + 20, scrollPane.getPreferredSize().height);
- //scrollPane.setPreferredSize(preferredSize);
- //scrollPane.setMinimumSize(preferredSize);
myTree.addTreeExpansionListener(new TreeExpansionListener() {
@@ -566,7 +563,6 @@ public class SingleInspectionProfilePanel extends JPanel {
myTreeExpander = new DefaultTreeExpander(myTree);
myProfileFilter = new MyFilterComponent();
- myProfileFilter.setPreferredSize(new Dimension(100, -1));
return scrollPane;
}
@@ -905,10 +901,10 @@ public class SingleInspectionProfilePanel extends JPanel {
final JScrollPane tree = initTreeScrollPane();
treePanel.add(tree, BorderLayout.CENTER);
- final JPanel northPanel = new JPanel(new BorderLayout());
+ final JPanel northPanel = new JPanel(new GridBagLayout());
northPanel.setBorder(IdeBorderFactory.createEmptyBorder(2, 0, 2, 0));
- northPanel.add(createTreeToolbarPanel().getComponent(), BorderLayout.CENTER);
- northPanel.add(myProfileFilter, BorderLayout.EAST);
+ northPanel.add(createTreeToolbarPanel().getComponent(), new GridBagConstraints(0, 0, 1, 1, 0.5, 1, GridBagConstraints.BASELINE_LEADING, GridBagConstraints.HORIZONTAL, new Insets(0, 0, 0, 0), 0, 0));
+ northPanel.add(myProfileFilter, new GridBagConstraints(1, 0, 1, 1, 1, 1, GridBagConstraints.BASELINE_TRAILING, GridBagConstraints.HORIZONTAL, new Insets(0, 0, 0, 0), 0, 0));
treePanel.add(northPanel, BorderLayout.NORTH);
myMainSplitter = new Splitter(false);
@@ -919,7 +915,6 @@ public class SingleInspectionProfilePanel extends JPanel {
final JPanel panel = new JPanel(new BorderLayout());
panel.add(myMainSplitter, BorderLayout.CENTER);
- panel.setBorder(IdeBorderFactory.createEmptyBorder(2, 2, 0, 2));
return panel;
}
diff --git a/platform/lang-impl/src/com/intellij/tools/ToolEditorDialog.java b/platform/lang-impl/src/com/intellij/tools/ToolEditorDialog.java
index 2bc95674938a..5a8333de970b 100644
--- a/platform/lang-impl/src/com/intellij/tools/ToolEditorDialog.java
+++ b/platform/lang-impl/src/com/intellij/tools/ToolEditorDialog.java
@@ -180,12 +180,7 @@ public class ToolEditorDialog extends DialogWrapper {
private JPanel createCommandPane() {
JPanel pane = new JPanel(new GridBagLayout());
- //pane.setBorder(
- // BorderFactory.createCompoundBorder(
- // BorderFactory.createEtchedBorder(),
- // BorderFactory.createEmptyBorder(5, 5, 5, 5)
- // )
- //);
+ pane.setBorder(IdeBorderFactory.createTitledBorder(ToolsBundle.message("tools.tool.group"), false, true, true));
GridBagConstraints constr;
// program
@@ -193,8 +188,8 @@ public class ToolEditorDialog extends DialogWrapper {
constr = new GridBagConstraints();
constr.gridx = 0;
constr.gridy = 0;
- constr.insets = new Insets(5, 0, 0, 10);
- constr.anchor = GridBagConstraints.WEST;
+ constr.insets = new Insets(0, 0, 0, 10);
+ constr.anchor = GridBagConstraints.BASELINE_LEADING;
pane.add(new JLabel(ToolsBundle.message("tools.program.label")), constr);
FixedSizeButton browseCommandButton = new FixedSizeButton(myTfCommand);
@@ -224,18 +219,18 @@ public class ToolEditorDialog extends DialogWrapper {
constr = new GridBagConstraints();
constr.gridx = 1;
constr.gridy = 0;
- constr.insets = new Insets(5, 10, 0, 0);
+ constr.insets = new Insets(0, 0, 0, 10);
constr.fill = GridBagConstraints.HORIZONTAL;
- constr.anchor = GridBagConstraints.WEST;
+ constr.anchor = GridBagConstraints.BASELINE_LEADING;
constr.weightx = 1.0;
pane.add(_pane0, constr);
constr = new GridBagConstraints();
constr.gridx = 2;
constr.gridy = 0;
- constr.insets = new Insets(5, 10, 0, 0);
+ constr.insets = new Insets(0, 0, 0, 0);
constr.fill = GridBagConstraints.HORIZONTAL;
- constr.anchor = GridBagConstraints.WEST;
+ constr.anchor = GridBagConstraints.BASELINE_LEADING;
myInsertCommandMacroButton = new JButton(ToolsBundle.message("tools.insert.macro.button"));
pane.add(myInsertCommandMacroButton, constr);
@@ -244,25 +239,25 @@ public class ToolEditorDialog extends DialogWrapper {
constr = new GridBagConstraints();
constr.gridx = 0;
constr.gridy = 1;
- constr.insets = new Insets(5, 0, 0, 0);
- constr.anchor = GridBagConstraints.WEST;
+ constr.insets = new Insets(5, 0, 0, 10);
+ constr.anchor = GridBagConstraints.BASELINE_LEADING;
pane.add(new JLabel(ToolsBundle.message("tools.parameters.label")), constr);
constr = new GridBagConstraints();
constr.gridx = 1;
constr.gridy = 1;
- constr.insets = new Insets(5, 10, 0, 0);
+ constr.insets = new Insets(5, 0, 0, 10);
constr.fill = GridBagConstraints.HORIZONTAL;
- constr.anchor = GridBagConstraints.WEST;
+ constr.anchor = GridBagConstraints.BASELINE_LEADING;
constr.weightx = 1.0;
pane.add(myParametersField, constr);
constr = new GridBagConstraints();
constr.gridx = 2;
constr.gridy = 1;
- constr.insets = new Insets(5, 10, 0, 0);
+ constr.insets = new Insets(5, 0, 0, 0);
constr.fill = GridBagConstraints.HORIZONTAL;
- constr.anchor = GridBagConstraints.WEST;
+ constr.anchor = GridBagConstraints.BASELINE_LEADING;
myInsertParametersMacroButton = new JButton(ToolsBundle.message("tools.insert.macro.button.a"));
pane.add(myInsertParametersMacroButton, constr);
@@ -271,8 +266,8 @@ public class ToolEditorDialog extends DialogWrapper {
constr = new GridBagConstraints();
constr.gridx = 0;
constr.gridy = 2;
- constr.insets = new Insets(5, 0, 5, 10);
- constr.anchor = GridBagConstraints.WEST;
+ constr.insets = new Insets(5, 0, 0, 10);
+ constr.anchor = GridBagConstraints.BASELINE_LEADING;
pane.add(new JLabel(ToolsBundle.message("tools.working.directory.label")), constr);
FixedSizeButton browseDirectoryButton = new FixedSizeButton(myTfCommandWorkingDirectory);
@@ -296,7 +291,7 @@ public class ToolEditorDialog extends DialogWrapper {
constr.gridx = 1;
constr.gridy = 2;
constr.gridwidth = 1;
- constr.insets = new Insets(5, 10, 5, 0);
+ constr.insets = new Insets(5, 0, 0, 10);
constr.fill = GridBagConstraints.HORIZONTAL;
constr.anchor = GridBagConstraints.WEST;
constr.weightx = 1.0;
@@ -305,7 +300,7 @@ public class ToolEditorDialog extends DialogWrapper {
constr = new GridBagConstraints();
constr.gridx = 2;
constr.gridy = 2;
- constr.insets = new Insets(5, 10, 0, 0);
+ constr.insets = new Insets(5, 0, 0, 0);
constr.fill = GridBagConstraints.HORIZONTAL;
constr.anchor = GridBagConstraints.WEST;
myInsertWorkingDirectoryMacroButton = new JButton(ToolsBundle.message("tools.insert.macro.button.c"));
@@ -318,8 +313,6 @@ public class ToolEditorDialog extends DialogWrapper {
constr.weighty = 1.0;
pane.add(new JLabel(), constr);
- pane.setPreferredSize(new Dimension(600, 100));
-
return pane;
}
@@ -434,7 +427,7 @@ public class ToolEditorDialog extends DialogWrapper {
}
private JPanel getShowInPanel() {
- JPanel panel = new JPanel(new GridLayout(1, 4, 10, 0));
+ JPanel panel = new JPanel(new FlowLayout(FlowLayout.LEFT, 10, 0));
panel.setBorder(IdeBorderFactory.createTitledBorder(ToolsBundle.message("tools.menu.group"), false, true, true));
panel.add(myShowInMainMenuCheckbox);
panel.add(myShowInEditorCheckbox);
@@ -444,7 +437,8 @@ public class ToolEditorDialog extends DialogWrapper {
}
private JPanel getOptionsPanel() {
- JPanel panel = new JPanel(new FlowLayout(FlowLayout.LEFT));
+ JPanel panel = new JPanel(new FlowLayout(FlowLayout.LEFT, 10, 0));
+ panel.setBorder(IdeBorderFactory.createTitledBorder(ToolsBundle.message("tools.options.group"), false, true, true));
panel.add(mySynchronizedAfterRunCheckbox);
panel.add(myUseConsoleCheckbox);
panel.add(myOutputFiltersButton);
diff --git a/platform/platform-api/src/com/intellij/ide/util/treeView/AbstractTreeUpdater.java b/platform/platform-api/src/com/intellij/ide/util/treeView/AbstractTreeUpdater.java
index aad7cfc0de51..f40f9cf1ff5b 100644
--- a/platform/platform-api/src/com/intellij/ide/util/treeView/AbstractTreeUpdater.java
+++ b/platform/platform-api/src/com/intellij/ide/util/treeView/AbstractTreeUpdater.java
@@ -167,9 +167,6 @@ public class AbstractTreeUpdater implements Disposable, Activatable {
if (eachNode.isNodeAncestor(toAdd.getNode())) {
eachYielding.setUpdateStamp(newUpdateCount);
}
- else {
- toAdd.expire();
- }
}
}
}
diff --git a/platform/platform-api/src/com/intellij/openapi/fileEditor/OpenFileDescriptor.java b/platform/platform-api/src/com/intellij/openapi/fileEditor/OpenFileDescriptor.java
index 241ce3840a4b..09020968f919 100644
--- a/platform/platform-api/src/com/intellij/openapi/fileEditor/OpenFileDescriptor.java
+++ b/platform/platform-api/src/com/intellij/openapi/fileEditor/OpenFileDescriptor.java
@@ -26,6 +26,7 @@ import com.intellij.openapi.fileTypes.INativeFileType;
import com.intellij.openapi.project.Project;
import com.intellij.openapi.util.TextRange;
import com.intellij.openapi.vfs.VirtualFile;
+import com.intellij.openapi.wm.IdeFocusManager;
import com.intellij.pom.Navigatable;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
@@ -146,6 +147,9 @@ public class OpenFileDescriptor implements Navigatable {
if (editor instanceof TextEditor) {
Editor e = ((TextEditor)editor).getEditor();
unfoldCurrentLine(e);
+ if (focusEditor) {
+ IdeFocusManager.getInstance(myProject).requestFocus(e.getContentComponent(), true);
+ }
}
}
return !editors.isEmpty();
@@ -205,7 +209,7 @@ public class OpenFileDescriptor implements Navigatable {
}
}
- private static void unfoldCurrentLine(@NotNull final Editor editor) {
+ private void unfoldCurrentLine(@NotNull final Editor editor) {
final FoldRegion[] allRegions = editor.getFoldingModel().getAllFoldRegions();
final int offset = editor.getCaretModel().getOffset();
int line = editor.getDocument().getLineNumber(offset);
diff --git a/platform/platform-api/src/com/intellij/ui/components/JBCheckBox.java b/platform/platform-api/src/com/intellij/ui/components/JBCheckBox.java
index 839146897853..d64551ddf6ef 100644
--- a/platform/platform-api/src/com/intellij/ui/components/JBCheckBox.java
+++ b/platform/platform-api/src/com/intellij/ui/components/JBCheckBox.java
@@ -9,7 +9,7 @@ import java.awt.*;
* @author evgeny.zakrevsky
*/
public class JBCheckBox extends JCheckBox implements AnchorableComponent {
- private JComponent anchor;
+ private JComponent myAnchor;
public JBCheckBox() {
super();
@@ -46,18 +46,23 @@ public class JBCheckBox extends JCheckBox implements AnchorableComponent {
@Override
public JComponent getAnchor() {
- return anchor;
+ return myAnchor;
}
@Override
public void setAnchor(JComponent anchor) {
if (this != anchor) {
- this.anchor = anchor;
+ this.myAnchor = anchor;
}
}
@Override
public Dimension getPreferredSize() {
- return anchor == null ? super.getPreferredSize() : anchor.getPreferredSize();
+ return myAnchor == null ? super.getPreferredSize() : myAnchor.getPreferredSize();
+ }
+
+ @Override
+ public Dimension getMinimumSize() {
+ return myAnchor == null ? super.getMinimumSize() : myAnchor.getMinimumSize();
}
}
diff --git a/platform/platform-api/src/com/intellij/ui/components/JBLabel.java b/platform/platform-api/src/com/intellij/ui/components/JBLabel.java
index e19c7d0fcfa7..4ced2491f3af 100644
--- a/platform/platform-api/src/com/intellij/ui/components/JBLabel.java
+++ b/platform/platform-api/src/com/intellij/ui/components/JBLabel.java
@@ -30,9 +30,11 @@ public class JBLabel extends JLabel implements AnchorableComponent {
private JComponent myAnchor = null;
public JBLabel() {
+ super();
}
public JBLabel(@NotNull UIUtil.ComponentStyle componentStyle) {
+ super();
setComponentStyle(componentStyle);
}
@@ -49,6 +51,12 @@ public class JBLabel extends JLabel implements AnchorableComponent {
setComponentStyle(componentStyle);
}
+ public JBLabel(@NotNull String text, @NotNull UIUtil.ComponentStyle componentStyle, @NotNull UIUtil.FontColor fontColor) {
+ super(text);
+ setComponentStyle(componentStyle);
+ setFontColor(fontColor);
+ }
+
public JBLabel(@NotNull String text, int horizontalAlignment) {
super(text, horizontalAlignment);
}
@@ -101,4 +109,9 @@ public class JBLabel extends JLabel implements AnchorableComponent {
public Dimension getPreferredSize() {
return myAnchor == null ? super.getPreferredSize() : myAnchor.getPreferredSize();
}
+
+ @Override
+ public Dimension getMinimumSize() {
+ return myAnchor == null ? super.getMinimumSize() : myAnchor.getMinimumSize();
+ }
}
diff --git a/platform/platform-api/src/com/intellij/ui/components/JBRadioButton.java b/platform/platform-api/src/com/intellij/ui/components/JBRadioButton.java
index 4d1f7432e944..a075495edf5e 100644
--- a/platform/platform-api/src/com/intellij/ui/components/JBRadioButton.java
+++ b/platform/platform-api/src/com/intellij/ui/components/JBRadioButton.java
@@ -10,7 +10,7 @@ import java.awt.*;
* @author evgeny.zakrevsky
*/
public class JBRadioButton extends JRadioButton implements AnchorableComponent {
- private JComponent anchor;
+ private JComponent myAnchor;
public JBRadioButton() {
}
@@ -45,18 +45,23 @@ public class JBRadioButton extends JRadioButton implements AnchorableComponent {
@Override
public JComponent getAnchor() {
- return anchor;
+ return myAnchor;
}
@Override
public void setAnchor(@Nullable JComponent anchor) {
if (anchor != this) {
- this.anchor = anchor;
+ this.myAnchor = anchor;
}
}
@Override
public Dimension getPreferredSize() {
- return anchor == null ? super.getPreferredSize() : anchor.getPreferredSize();
+ return myAnchor == null ? super.getPreferredSize() : myAnchor.getPreferredSize();
+ }
+
+ @Override
+ public Dimension getMinimumSize() {
+ return myAnchor == null ? super.getMinimumSize() : myAnchor.getMinimumSize();
}
}
diff --git a/platform/platform-impl/src/com/intellij/ide/plugins/PluginManagerMain.java b/platform/platform-impl/src/com/intellij/ide/plugins/PluginManagerMain.java
index d3a34ea078bc..3a51ce366750 100644
--- a/platform/platform-impl/src/com/intellij/ide/plugins/PluginManagerMain.java
+++ b/platform/platform-impl/src/com/intellij/ide/plugins/PluginManagerMain.java
@@ -27,7 +27,6 @@ import com.intellij.openapi.actionSystem.ActionToolbar;
import com.intellij.openapi.actionSystem.AnActionEvent;
import com.intellij.openapi.application.PathManager;
import com.intellij.openapi.diagnostic.Logger;
-import com.intellij.openapi.options.Configurable;
import com.intellij.openapi.progress.ProgressManager;
import com.intellij.openapi.project.DumbAwareAction;
import com.intellij.openapi.ui.Messages;
diff --git a/platform/platform-impl/src/com/intellij/openapi/diff/impl/DiffSplitter.java b/platform/platform-impl/src/com/intellij/openapi/diff/impl/DiffSplitter.java
index 6da18259ece1..5f4507dcfad3 100644
--- a/platform/platform-impl/src/com/intellij/openapi/diff/impl/DiffSplitter.java
+++ b/platform/platform-impl/src/com/intellij/openapi/diff/impl/DiffSplitter.java
@@ -40,6 +40,7 @@ class DiffSplitter extends Splitter implements DiffSplitterI {
setDividerWidth(30);
setFirstComponent(component1);
setSecondComponent(component2);
+ setHonorComponentsMinimumSize(false);
}
protected Splitter.Divider createDivider() {
diff --git a/platform/platform-impl/src/com/intellij/openapi/options/newEditor/OptionsEditor.java b/platform/platform-impl/src/com/intellij/openapi/options/newEditor/OptionsEditor.java
index cff762ce268a..e72b7a38cbff 100644
--- a/platform/platform-impl/src/com/intellij/openapi/options/newEditor/OptionsEditor.java
+++ b/platform/platform-impl/src/com/intellij/openapi/options/newEditor/OptionsEditor.java
@@ -207,12 +207,12 @@ public class OptionsEditor extends JPanel implements DataProvider, Place.Navigat
myLeftSide.add(mySearchWrapper, BorderLayout.NORTH);
myLeftSide.add(myTree, BorderLayout.CENTER);
- myLeftSide.setMinimumSize(new Dimension(150, -1));
setLayout(new BorderLayout());
myMainSplitter = new Splitter(false);
myMainSplitter.setFirstComponent(myLeftSide);
+ myMainSplitter.setHonorComponentsMinimumSize(false);
myLoadingDecorator = new LoadingDecorator(myOwnDetails.getComponent(), this, 150);
myMainSplitter.setSecondComponent(myLoadingDecorator.getComponent());
diff --git a/platform/platform-impl/src/com/intellij/openapi/ui/impl/DialogWrapperPeerImpl.java b/platform/platform-impl/src/com/intellij/openapi/ui/impl/DialogWrapperPeerImpl.java
index 5e09f19f128f..2e2edd048091 100644
--- a/platform/platform-impl/src/com/intellij/openapi/ui/impl/DialogWrapperPeerImpl.java
+++ b/platform/platform-impl/src/com/intellij/openapi/ui/impl/DialogWrapperPeerImpl.java
@@ -937,27 +937,7 @@ public class DialogWrapperPeerImpl extends DialogWrapperPeer implements FocusTra
private class MyComponentListener extends ComponentAdapter {
@SuppressWarnings({"RefusedBequest"})
public void componentResized(ComponentEvent e) {
- final JRootPane pane = getRootPane();
- if (pane == null) return;
- final Dimension minSize = pane.getMinimumSize();
- final Dimension size = pane.getSize();
- final Dimension winSize = getSize();
- if (minSize.width > size.width) {
- winSize.width += minSize.width - size.width;
- }
- if (minSize.height > size.height) {
- winSize.height += minSize.height - size.height;
- }
-
- if (!winSize.equals(getSize())) {
- SwingUtilities.invokeLater(new Runnable() {
- public void run() {
- if (isShowing()) {
- setSize(winSize);
- }
- }
- });
- }
+ UIUtil.adjustWindowToMinimumSize(getWindow());
}
}
diff --git a/platform/platform-impl/src/com/intellij/openapi/wm/impl/content/ToolWindowContentUi.java b/platform/platform-impl/src/com/intellij/openapi/wm/impl/content/ToolWindowContentUi.java
index e6e2a8771718..423f8eda7369 100644
--- a/platform/platform-impl/src/com/intellij/openapi/wm/impl/content/ToolWindowContentUi.java
+++ b/platform/platform-impl/src/com/intellij/openapi/wm/impl/content/ToolWindowContentUi.java
@@ -70,7 +70,7 @@ public class ToolWindowContentUi extends JPanel implements ContentUI, PropertyCh
ContentLayout myComboLayout = new ComboContentLayout(this);
private ToolWindowContentUiType myType = ToolWindowContentUiType.TABBED;
- private static DefaultActionGroup myGroup;
+ private DefaultActionGroup myGroup;
public ToolWindowContentUi(ToolWindowImpl window) {
myWindow = window;
@@ -252,7 +252,7 @@ public class ToolWindowContentUi extends JPanel implements ContentUI, PropertyCh
return true;
}
- static void initMouseListeners(final JComponent c, final ToolWindowContentUi ui) {
+ void initMouseListeners(final JComponent c, final ToolWindowContentUi ui) {
if (c.getClientProperty(ui) != null) return;
diff --git a/platform/platform-impl/src/com/intellij/openapi/wm/impl/status/IdeStatusBarImpl.java b/platform/platform-impl/src/com/intellij/openapi/wm/impl/status/IdeStatusBarImpl.java
index 019b59619859..c5ae1e9efeb6 100644
--- a/platform/platform-impl/src/com/intellij/openapi/wm/impl/status/IdeStatusBarImpl.java
+++ b/platform/platform-impl/src/com/intellij/openapi/wm/impl/status/IdeStatusBarImpl.java
@@ -257,6 +257,11 @@ public class IdeStatusBarImpl extends JComponent implements StatusBarEx {
public void dispose() {
myWidgetMap.clear();
+ myChildren.clear();
+
+ myLeftPanel.removeAll();
+ myRightPanel.removeAll();
+ myCenterPanel.removeAll();
}
private void addWidget(@NotNull final StatusBarWidget widget, @NotNull final Position pos, @NotNull final String anchor) {
diff --git a/platform/platform-impl/testSrc/com/intellij/ide/util/treeView/TreeUiTest.java b/platform/platform-impl/testSrc/com/intellij/ide/util/treeView/TreeUiTest.java
index bd3685d61f5b..24810565cf08 100644
--- a/platform/platform-impl/testSrc/com/intellij/ide/util/treeView/TreeUiTest.java
+++ b/platform/platform-impl/testSrc/com/intellij/ide/util/treeView/TreeUiTest.java
@@ -201,7 +201,43 @@ public class TreeUiTest extends AbstractTreeBuilderTest {
" +org\n" +
" +xunit\n");
}
-
+
+
+ public void testMoveElementToAdjacentEmptyParentWithSmartExpandAndSerialUpdateSubtrees() throws Exception {
+ Node com = myRoot.addChild("com");
+ Node folder1 = com.addChild("folder1");
+ Node folder2 = com.addChild("folder2");
+
+ Node file21 = folder2.addChild("file21");
+ folder2.addChild("file22");
+
+ mySmartExpand = true;
+ activate();
+
+ buildNode(file21, true);
+
+ assertTree("-/\n" +
+ " -com\n" +
+ " folder1\n" +
+ " -folder2\n" +
+ " [file21]\n" +
+ " file22\n");
+
+ folder2.myChildElements.remove(file21);
+ folder1.addChild(file21);
+
+ getBuilder().queueUpdateFrom(folder2.getElement(), false);
+ getBuilder().queueUpdateFrom(folder1.getElement(), false);
+
+ assertTree("-/\n" +
+ " -com\n" +
+ " -folder1\n" +
+ " [file21]\n" +
+ " -folder2\n" +
+ " file22\n");
+
+ }
+
public void testReadyCallbackWhenReleased() throws Exception {
buildStructure(myRoot);
@@ -2568,6 +2604,10 @@ public class TreeUiTest extends AbstractTreeBuilderTest {
//todo
}
+ @Override
+ public void testMoveElementToAdjacentEmptyParentWithSmartExpandAndSerialUpdateSubtrees() throws Exception {
+ // doesn't make sense since passthrough mode is always serial, it doesn't queue for updates
+ }
@Override
public void testElementMove1() throws Exception {
diff --git a/platform/platform-resources-en/src/messages/ProjectBundle.properties b/platform/platform-resources-en/src/messages/ProjectBundle.properties
index 2133db0e581e..ab1c4ae0ee85 100644
--- a/platform/platform-resources-en/src/messages/ProjectBundle.properties
+++ b/platform/platform-resources-en/src/messages/ProjectBundle.properties
@@ -316,7 +316,7 @@ project.roots.tooltip.library.has.broken.paths=Library ''{0}'' has broken {1, ch
project.roots.error.message.invalid.roots=invalid {0} {1, choice, 1#root|2#roots}
choose.modules.dialog.title=Choose Modules
choose.modules.dialog.description=Library ''{0}'' will be added to the selected modules.
-project.roots.javadoc.tab.description=Manage external JavaDocs attached to this module. External JavaDoc override JavaDoc annotations you might have in your module.
+project.roots.javadoc.tab.description=Manage external JavaDocs attached to this module. External JavaDoc override JavaDoc annotations you might have in your module.
project.roots.output.compiler.title=Compiler output
project.roots.module.jdk.problem.message=Module SDK is not defined.
project.roots.module.duplicate.name.message=duplicate module name
@@ -338,7 +338,7 @@ external.annotations.suggestion.message=If you do not want annotatio
sdk.configure.annotations.tab=Annotations
project.roots.path.tab.title=Paths
project.roots.external.annotations.tab.title=External Annotations
-project.roots.external.annotations.description=Manage external annotations attached to this module.
+project.roots.external.annotations.description=Manage external annotations attached to this module.
add.external.annotations.path.title=Add path to external annotations
add.external.annotations.path.description=Select path in which external annotations for module sources is located
diff --git a/platform/platform-resources-en/src/messages/ToolsBundle.properties b/platform/platform-resources-en/src/messages/ToolsBundle.properties
index 521a15bf7319..712bd71e7f40 100644
--- a/platform/platform-resources-en/src/messages/ToolsBundle.properties
+++ b/platform/platform-resources-en/src/messages/ToolsBundle.properties
@@ -35,6 +35,8 @@ tools.insert.macro.button.a=Insert m&acro...
tools.working.directory.label=Working directory:
tools.insert.macro.button.c=Insert ma&cro...
tools.menu.group=Menu
+tools.options.group=Options
+tools.tool.group=Tool Options
tools.settings=Tools
tools.completed.message=External tool ''{0}'' completed with exit code {1}
tools.add.button=&Add...
diff --git a/platform/util/src/com/intellij/util/ui/UIUtil.java b/platform/util/src/com/intellij/util/ui/UIUtil.java
index 2d9f73b9fcf9..d24d45272415 100644
--- a/platform/util/src/com/intellij/util/ui/UIUtil.java
+++ b/platform/util/src/com/intellij/util/ui/UIUtil.java
@@ -2555,5 +2555,22 @@ public class UIUtil {
return ans;
}
+
+ public static void adjustWindowToMinimumSize(final Window window) {
+ if (window == null) return;
+ final Dimension minSize = window.getMinimumSize();
+ final Dimension size = window.getSize();
+ final Dimension newSize = new Dimension(Math.max(size.width, minSize.width), Math.max(size.height, minSize.height));
+
+ if (!newSize.equals(size)) {
+ SwingUtilities.invokeLater(new Runnable() {
+ public void run() {
+ if (window.isShowing()) {
+ window.setSize(newSize);
+ }
+ }
+ });
+ }
+ }
}
diff --git a/platform/vcs-impl/src/com/intellij/openapi/vcs/changes/ChangesViewManager.java b/platform/vcs-impl/src/com/intellij/openapi/vcs/changes/ChangesViewManager.java
index c27716f62009..6b82dc03f532 100644
--- a/platform/vcs-impl/src/com/intellij/openapi/vcs/changes/ChangesViewManager.java
+++ b/platform/vcs-impl/src/com/intellij/openapi/vcs/changes/ChangesViewManager.java
@@ -313,7 +313,6 @@ public class ChangesViewManager implements ChangesViewI, JDOMExternalizable, Pro
final JScrollPane scrollPane = ScrollPaneFactory.createScrollPane(myView);
final JPanel wrapper = new JPanel(new BorderLayout());
wrapper.add(scrollPane, BorderLayout.CENTER);
- mySplitter.setShowDividerControls(true);
mySplitter.setFirstComponent(wrapper);
content.add(mySplitter, BorderLayout.CENTER);
content.add(myProgressLabel, BorderLayout.SOUTH);
diff --git a/platform/vcs-impl/src/com/intellij/openapi/vcs/changes/ui/ChangeListViewerDialog.java b/platform/vcs-impl/src/com/intellij/openapi/vcs/changes/ui/ChangeListViewerDialog.java
index 57515ce1d6b7..dfd29fc13cd6 100644
--- a/platform/vcs-impl/src/com/intellij/openapi/vcs/changes/ui/ChangeListViewerDialog.java
+++ b/platform/vcs-impl/src/com/intellij/openapi/vcs/changes/ui/ChangeListViewerDialog.java
@@ -165,7 +165,6 @@ public class ChangeListViewerDialog extends DialogWrapper implements DataProvide
commitPanel.add(commitMessageScroll, BorderLayout.CENTER);
splitter.setSecondComponent(commitPanel);
- splitter.setShowDividerControls(true);
}
mainPanel.add(splitter, BorderLayout.CENTER);
diff --git a/plugins/android/resources/messages/AndroidBundle.properties b/plugins/android/resources/messages/AndroidBundle.properties
index 61c9e09482f2..5e2930c3a5a2 100644
--- a/plugins/android/resources/messages/AndroidBundle.properties
+++ b/plugins/android/resources/messages/AndroidBundle.properties
@@ -149,9 +149,9 @@ android.manifest.not.found.error=AndroidManifest.xml doesn't exist or has incorr
android.apt.settings.title=AAPT Compiler
android.aidl.settings.title=AIDL Compiler
android.generate.r.java.checkbox=Re&generate R.java file when resources are changed
-android.dest.directory.title=De&stination directory
+android.dest.directory.title=De&stination directory\:
android.generate.r.java.by.res.dir=Use res&ource directory specified at "Structure" section
-android.use.custom.r.java.source.dir=Use custo&m resource directory
+android.use.custom.r.java.source.dir=Use custo&m resource directory\:
android.regenerate.idl.when.changed.checkbox=Regenerate &Java files when AIDL files are changed
android.wizard.application.project.button=&Application
android.wizard.lib.project.button=&Library
diff --git a/plugins/android/src/org/jetbrains/android/AndroidProjectComponent.java b/plugins/android/src/org/jetbrains/android/AndroidProjectComponent.java
index e047daf6bb8b..65bff27a39de 100644
--- a/plugins/android/src/org/jetbrains/android/AndroidProjectComponent.java
+++ b/plugins/android/src/org/jetbrains/android/AndroidProjectComponent.java
@@ -19,11 +19,15 @@ import com.intellij.openapi.compiler.CompilerManager;
import com.intellij.openapi.components.AbstractProjectComponent;
import com.intellij.openapi.project.Project;
import org.jetbrains.android.compiler.AndroidPrecompileTask;
+import org.jetbrains.annotations.NotNull;
/**
* @author Eugene.Kudelevsky
*/
public class AndroidProjectComponent extends AbstractProjectComponent {
+ private volatile boolean myCompilationRunning = false;
+ private final Object COMPILATION_FLAG_LOCK = new Object();
+
protected AndroidProjectComponent(Project project) {
super(project);
}
@@ -31,6 +35,26 @@ public class AndroidProjectComponent extends AbstractProjectComponent {
@Override
public void projectOpened() {
final CompilerManager manager = CompilerManager.getInstance(myProject);
- manager.addBeforeTask(new AndroidPrecompileTask());
+ manager.addBeforeTask(new AndroidPrecompileTask(this));
+ }
+
+ public void setCompilationStarted() {
+ synchronized (COMPILATION_FLAG_LOCK) {
+ myCompilationRunning = true;
+ }
+ }
+
+ public void setCompilationFinished() {
+ synchronized (COMPILATION_FLAG_LOCK) {
+ myCompilationRunning = false;
+ }
+ }
+
+ public void runIfNotInCompilation(@NotNull Runnable r) {
+ synchronized (COMPILATION_FLAG_LOCK) {
+ if (!myCompilationRunning) {
+ r.run();
+ }
+ }
}
}
diff --git a/plugins/android/src/org/jetbrains/android/compiler/AndroidCompileUtil.java b/plugins/android/src/org/jetbrains/android/compiler/AndroidCompileUtil.java
index e3edf4f77940..a5222ce3f74a 100644
--- a/plugins/android/src/org/jetbrains/android/compiler/AndroidCompileUtil.java
+++ b/plugins/android/src/org/jetbrains/android/compiler/AndroidCompileUtil.java
@@ -44,6 +44,7 @@ import com.intellij.psi.PsiFile;
import com.intellij.psi.search.GlobalSearchScope;
import com.intellij.util.ArrayUtil;
import com.intellij.util.containers.HashSet;
+import org.jetbrains.android.AndroidProjectComponent;
import org.jetbrains.android.dom.resources.Attr;
import org.jetbrains.android.dom.resources.DeclareStyleable;
import org.jetbrains.android.dom.resources.ResourceElement;
@@ -340,19 +341,24 @@ public class AndroidCompileUtil {
}
}
- public static void generate(final Module module, GeneratingCompiler compiler) {
- assert !ApplicationManager.getApplication().isDispatchThread();
- final CompileContext[] contextWrapper = new CompileContext[1];
- ApplicationManager.getApplication().runReadAction(new Runnable() {
+ public static void generate(final Module module, final GeneratingCompiler compiler) {
+ module.getProject().getComponent(AndroidProjectComponent.class).runIfNotInCompilation(new Runnable() {
+ @Override
public void run() {
- Project project = module.getProject();
- if (project.isDisposed()) return;
- CompilerTask task = new CompilerTask(project, true, "Android auto-generation", true);
- CompileScope scope = new ModuleCompileScope(module, false);
- contextWrapper[0] = new CompileContextImpl(project, task, scope, null, false, false);
+ assert !ApplicationManager.getApplication().isDispatchThread();
+ final CompileContext[] contextWrapper = new CompileContext[1];
+ ApplicationManager.getApplication().runReadAction(new Runnable() {
+ public void run() {
+ Project project = module.getProject();
+ if (project.isDisposed()) return;
+ CompilerTask task = new CompilerTask(project, true, "Android auto-generation", true);
+ CompileScope scope = new ModuleCompileScope(module, false);
+ contextWrapper[0] = new CompileContextImpl(project, task, scope, null, false, false);
+ }
+ });
+ generate(compiler, contextWrapper[0]);
}
});
- generate(compiler, contextWrapper[0]);
}
public static boolean isModuleAffected(CompileContext context, Module module) {
diff --git a/plugins/android/src/org/jetbrains/android/compiler/AndroidPrecompileTask.java b/plugins/android/src/org/jetbrains/android/compiler/AndroidPrecompileTask.java
index 1835433415db..a12daa8df257 100644
--- a/plugins/android/src/org/jetbrains/android/compiler/AndroidPrecompileTask.java
+++ b/plugins/android/src/org/jetbrains/android/compiler/AndroidPrecompileTask.java
@@ -34,6 +34,7 @@ import com.intellij.openapi.util.text.StringUtil;
import com.intellij.openapi.vfs.LocalFileSystem;
import com.intellij.openapi.vfs.VirtualFile;
import com.intellij.util.containers.hash.HashSet;
+import org.jetbrains.android.AndroidProjectComponent;
import org.jetbrains.android.facet.AndroidFacet;
import org.jetbrains.android.facet.AndroidRootUtil;
import org.jetbrains.android.sdk.AndroidPlatform;
@@ -48,11 +49,19 @@ import java.util.Set;
* @author Eugene.Kudelevsky
*/
public class AndroidPrecompileTask implements CompileTask {
- private static final Logger LOG = Logger.getInstance("#org.jetbrains.android.compiler.AndroidPrecompileTask");
+ private final AndroidProjectComponent myOwner;
+ private static final Logger LOG = Logger.getInstance("#org.jetbrains.android.compiler.AndroidPrecompileTask");
+
+ public AndroidPrecompileTask(@NotNull AndroidProjectComponent owner) {
+ myOwner = owner;
+ }
+
@Override
public boolean execute(CompileContext context) {
final Project project = context.getProject();
+
+ myOwner.setCompilationStarted();
ExcludedEntriesConfiguration configuration =
((CompilerConfigurationImpl)CompilerConfiguration.getInstance(project)).getExcludedEntriesConfiguration();
@@ -96,6 +105,18 @@ public class AndroidPrecompileTask implements CompileTask {
CompilerManager.getInstance(project).addCompilationStatusListener(new MyCompilationStatusListener(project, addedEntries), project);
}
+ CompilerManager.getInstance(project).addCompilationStatusListener(new CompilationStatusListener() {
+ @Override
+ public void compilationFinished(boolean aborted, int errors, int warnings, final CompileContext compileContext) {
+ ApplicationManager.getApplication().executeOnPooledThread(new Runnable() {
+ @Override
+ public void run() {
+ myOwner.setCompilationFinished();
+ }
+ });
+ }
+ }, project);
+
return true;
}
diff --git a/plugins/copyright/src/com/maddyhome/idea/copyright/ui/TemplateCommentPanel.form b/plugins/copyright/src/com/maddyhome/idea/copyright/ui/TemplateCommentPanel.form
index 2316c1cb25ab..c4fe5a943446 100644
--- a/plugins/copyright/src/com/maddyhome/idea/copyright/ui/TemplateCommentPanel.form
+++ b/plugins/copyright/src/com/maddyhome/idea/copyright/ui/TemplateCommentPanel.form
@@ -64,7 +64,7 @@
-
+
@@ -84,7 +84,7 @@
-
+
@@ -121,7 +121,7 @@
-
+
@@ -219,7 +219,7 @@
-
+
diff --git a/plugins/git4idea/src/git4idea/update/GitUpdateOptionsPanel.form b/plugins/git4idea/src/git4idea/update/GitUpdateOptionsPanel.form
index ec4d512199fb..db27637ca0c1 100644
--- a/plugins/git4idea/src/git4idea/update/GitUpdateOptionsPanel.form
+++ b/plugins/git4idea/src/git4idea/update/GitUpdateOptionsPanel.form
@@ -15,7 +15,7 @@
-
+
@@ -56,7 +56,7 @@
-
+
diff --git a/resources-en/src/messages/CompilerBundle.properties b/resources-en/src/messages/CompilerBundle.properties
index 2a8cebb6cceb..6d67ba3e3db7 100644
--- a/resources-en/src/messages/CompilerBundle.properties
+++ b/resources-en/src/messages/CompilerBundle.properties
@@ -110,7 +110,7 @@ label.option.deploy.never=Never
label.option.deploy.always=Always
label.option.deploy.text=Deploy web applications to server after compilation:
label.option.clear.output.directory.on.rebuild=C&lear output directory on rebuild
-label.option.resource.patterns.text=Resource Patterns
+label.option.resource.patterns.text=Resource patterns\:
error.compiler.configurable.malformed.patterns=The following resource patterns are malformed:\n{0}
exclude.from.compile.table.path.column.name=Path
exclude.from.compile.table.recursively.column.name=Recursively