decouple JBUIScale and UI initialization logic

GitOrigin-RevId: 72cd2f178a2b25d80ffee5bc172e7ac54ada8f9a
This commit is contained in:
Vladimir Krivosheev
2019-06-04 21:11:37 +03:00
committed by intellij-monorepo-bot
parent d25e658b5c
commit b429440a58
439 changed files with 3808 additions and 4430 deletions
@@ -1,4 +1,4 @@
// Copyright 2000-2018 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
// Copyright 2000-2019 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
package com.intellij.compiler.impl.javaCompiler;
import com.intellij.compiler.options.ModuleOptionsTableModel;
@@ -9,6 +9,7 @@ import com.intellij.ui.TableSpeedSearch;
import com.intellij.ui.TableUtil;
import com.intellij.ui.ToolbarDecorator;
import com.intellij.ui.components.fields.ExpandableTextField;
import com.intellij.ui.scale.JBUIScale;
import com.intellij.ui.table.JBTable;
import com.intellij.util.ui.JBUI;
import org.jetbrains.annotations.NotNull;
@@ -30,7 +31,7 @@ public class CompilerModuleOptionsComponent extends JPanel {
myProject = project;
myTable = new JBTable(new ModuleOptionsTableModel());
myTable.setRowHeight(JBUI.scale(22));
myTable.setRowHeight(JBUIScale.scale(22));
myTable.getEmptyText().setText("Additional compilation options will be the same for all modules");
TableColumn moduleColumn = myTable.getColumnModel().getColumn(0);
@@ -22,10 +22,10 @@ import com.intellij.ui.Gray;
import com.intellij.ui.JBColor;
import com.intellij.ui.RawCommandLineEditor;
import com.intellij.ui.components.JBLabel;
import com.intellij.ui.scale.JBUIScale;
import com.intellij.util.containers.ContainerUtil;
import com.intellij.util.containers.ContainerUtilRt;
import com.intellij.util.execution.ParametersListUtil;
import com.intellij.util.ui.JBUI;
import com.intellij.xml.util.XmlStringUtil;
import org.jetbrains.annotations.NotNull;
@@ -331,6 +331,6 @@ public class CompilerUIConfigurable implements SearchableConfigurable, Configura
myResourcePatternsField = new RawCommandLineEditor(ParametersListUtil.COLON_LINE_PARSER, ParametersListUtil.COLON_LINE_JOINER);
myResourcePatternsField.setDialogCaption("Resource patterns");
myHeapSizeField = new JTextField();
myHeapSizeField.setPreferredSize(new Dimension(JBUI.scale(50), myHeapSizeField.getPreferredSize().height));
myHeapSizeField.setPreferredSize(new Dimension(JBUIScale.scale(50), myHeapSizeField.getPreferredSize().height));
}
}
@@ -9,6 +9,7 @@ import com.intellij.ui.TableSpeedSearch;
import com.intellij.ui.TableUtil;
import com.intellij.ui.ToolbarDecorator;
import com.intellij.ui.components.JBTextField;
import com.intellij.ui.scale.JBUIScale;
import com.intellij.ui.table.JBTable;
import com.intellij.util.ArrayUtilRt;
import com.intellij.util.ObjectUtils;
@@ -57,7 +58,7 @@ public class TargetOptionsComponent extends JPanel {
myCbProjectTargetLevel = createTargetOptionsCombo();
myTable = new JBTable(new ModuleOptionsTableModel());
myTable.setRowHeight(JBUI.scale(22));
myTable.setRowHeight(JBUIScale.scale(22));
myTable.getEmptyText().setText("All modules will be compiled with project bytecode version");
TableColumn moduleColumn = myTable.getColumnModel().getColumn(0);