mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
HiDPI default component/dialog sizes
This commit is contained in:
+3
-4
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2000-2014 JetBrains s.r.o.
|
||||
* Copyright 2000-2015 JetBrains s.r.o.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -21,6 +21,7 @@ import com.intellij.openapi.ui.DialogWrapper;
|
||||
import com.intellij.openapi.util.Pair;
|
||||
import com.intellij.openapi.util.text.StringUtil;
|
||||
import com.intellij.ui.TabbedPaneWrapper;
|
||||
import com.intellij.util.ui.JBUI;
|
||||
import gnu.trove.THashMap;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.idea.maven.dom.model.MavenDomDependency;
|
||||
@@ -29,9 +30,7 @@ import org.jetbrains.idea.maven.model.MavenId;
|
||||
import javax.swing.*;
|
||||
import javax.swing.event.ChangeEvent;
|
||||
import javax.swing.event.ChangeListener;
|
||||
import java.awt.*;
|
||||
import java.util.*;
|
||||
import java.util.List;
|
||||
|
||||
public class MavenArtifactSearchDialog extends DialogWrapper {
|
||||
private List<MavenId> myResult = Collections.emptyList();
|
||||
@@ -132,7 +131,7 @@ public class MavenArtifactSearchDialog extends DialogWrapper {
|
||||
myTabbedPane.addTab("Search for class", myClassesPanel);
|
||||
myTabbedPane.setSelectedIndex(classMode ? 1 : 0);
|
||||
|
||||
myTabbedPane.getComponent().setPreferredSize(new Dimension(900, 600));
|
||||
myTabbedPane.getComponent().setPreferredSize(JBUI.size(900, 600));
|
||||
|
||||
myTabbedPane.addChangeListener(new ChangeListener() {
|
||||
public void stateChanged(ChangeEvent e) {
|
||||
|
||||
+3
-3
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2000-2009 JetBrains s.r.o.
|
||||
* Copyright 2000-2015 JetBrains s.r.o.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -21,6 +21,7 @@ import com.intellij.ui.ScrollPaneFactory;
|
||||
import com.intellij.ui.treeStructure.SimpleNode;
|
||||
import com.intellij.ui.treeStructure.SimpleNodeVisitor;
|
||||
import com.intellij.ui.treeStructure.SimpleTree;
|
||||
import com.intellij.util.ui.JBUI;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
import org.jetbrains.idea.maven.project.MavenProjectsManager;
|
||||
import org.jetbrains.idea.maven.tasks.MavenShortcutsManager;
|
||||
@@ -28,7 +29,6 @@ import org.jetbrains.idea.maven.tasks.MavenTasksManager;
|
||||
|
||||
import javax.swing.*;
|
||||
import javax.swing.tree.TreeSelectionModel;
|
||||
import java.awt.*;
|
||||
|
||||
public class SelectFromMavenProjectsDialog extends DialogWrapper {
|
||||
private final Project myProject;
|
||||
@@ -92,7 +92,7 @@ public class SelectFromMavenProjectsDialog extends DialogWrapper {
|
||||
@Nullable
|
||||
protected JComponent createCenterPanel() {
|
||||
final JScrollPane pane = ScrollPaneFactory.createScrollPane(myTree);
|
||||
pane.setPreferredSize(new Dimension(320, 400));
|
||||
pane.setPreferredSize(JBUI.size(320, 400));
|
||||
return pane;
|
||||
}
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2000-2009 JetBrains s.r.o.
|
||||
* Copyright 2000-2015 JetBrains s.r.o.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -19,6 +19,7 @@ import com.intellij.ide.util.ElementsChooser;
|
||||
import com.intellij.openapi.project.Project;
|
||||
import com.intellij.openapi.ui.DialogWrapper;
|
||||
import com.intellij.ui.ScrollPaneFactory;
|
||||
import com.intellij.util.ui.JBUI;
|
||||
import com.intellij.util.ui.UIUtil;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
|
||||
@@ -35,7 +36,7 @@ public class ChooserDialog<T> extends DialogWrapper {
|
||||
public ChooserDialog(final Project project, ElementsChooser<T> chooser, final String title, final String description) {
|
||||
super(project, true);
|
||||
myChooser = chooser;
|
||||
myChooser.setPreferredSize(new Dimension(300, 150));
|
||||
myChooser.setPreferredSize(JBUI.size(300, 150));
|
||||
setTitle(title);
|
||||
myDescription = description;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user