diff --git a/platform/platform-api/src/com/intellij/ui/tabs/impl/JBTabsImpl.java b/platform/platform-api/src/com/intellij/ui/tabs/impl/JBTabsImpl.java index 67ad7b6694ec..f651f7fabcb0 100644 --- a/platform/platform-api/src/com/intellij/ui/tabs/impl/JBTabsImpl.java +++ b/platform/platform-api/src/com/intellij/ui/tabs/impl/JBTabsImpl.java @@ -147,7 +147,7 @@ public class JBTabsImpl extends JComponent private TimedDeadzone.Length myTabActionsMouseDeadzone = TimedDeadzone.DEFAULT; - private long myRemoveDefferredRequest; + private long myRemoveDeferredRequest; private boolean myTestMode; private JBTabsPosition myPosition = JBTabsPosition.top; @@ -156,8 +156,6 @@ public class JBTabsImpl extends JComponent private BaseNavigationAction myNextAction; private BaseNavigationAction myPrevAction; - private boolean myWasEverShown; - private boolean myTabDraggingEnabled; private DragHelper myDragHelper; private boolean myNavigationActionsEnabled = true; @@ -884,11 +882,11 @@ public class JBTabsImpl extends JComponent private ActionCallback removeDeferred() { final ActionCallback callback = new ActionCallback(); - final long executionRequest = ++myRemoveDefferredRequest; + final long executionRequest = ++myRemoveDeferredRequest; final Runnable onDone = new Runnable() { public void run() { - if (myRemoveDefferredRequest == executionRequest) { + if (myRemoveDeferredRequest == executionRequest) { removeDeferredNow(); } @@ -1468,11 +1466,6 @@ public class JBTabsImpl extends JComponent return insets; } - private int fixInset(int inset, int addin) { - return inset + addin; - } - - public int getToolbarInset() { return getArcSize() + 1; } @@ -2903,7 +2896,7 @@ public class JBTabsImpl extends JComponent return mySingleRowLayout; } - public JBTabsPresentation setUiDecorator(UiDecorator decorator) { + public JBTabsPresentation setUiDecorator(@Nullable UiDecorator decorator) { myUiDecorator = decorator == null ? ourDefaultDecorator : decorator; applyDecoration(); return this; @@ -2989,9 +2982,7 @@ public class JBTabsImpl extends JComponent ActionGroup group = selection.getGroup(); if (group != null) { AnAction[] children = group.getChildren(null); - for (int i = 0; i < children.length; i++) { - result.add(children[i]); - } + Collections.addAll(result, children); } } diff --git a/platform/platform-api/src/com/intellij/ui/tabs/impl/TabLabel.java b/platform/platform-api/src/com/intellij/ui/tabs/impl/TabLabel.java index 63237e5e51b8..a462865b3b2f 100644 --- a/platform/platform-api/src/com/intellij/ui/tabs/impl/TabLabel.java +++ b/platform/platform-api/src/com/intellij/ui/tabs/impl/TabLabel.java @@ -34,6 +34,7 @@ import com.intellij.ui.tabs.UiDecorator; import com.intellij.ui.tabs.impl.table.TableLayout; import com.intellij.util.PairConsumer; import com.intellij.util.ui.Centerizer; +import org.jetbrains.annotations.Nullable; import javax.swing.*; import javax.swing.border.EmptyBorder; @@ -385,8 +386,8 @@ public class TabLabel extends JPanel { } } - private static int getValue(int curentValue, int newValue) { - return newValue != -1 ? newValue : curentValue; + private static int getValue(int currentValue, int newValue) { + return newValue != -1 ? newValue : currentValue; } public void setTabActions(ActionGroup group) { @@ -530,6 +531,7 @@ public class TabLabel extends JPanel { } + @Nullable public BufferedImage getInactiveStateImage(Rectangle effectiveBounds) { BufferedImage img = null; if (myLastPaintedInactiveImageBounds != null && myLastPaintedInactiveImageBounds.getSize().equals(effectiveBounds.getSize())) { @@ -541,7 +543,7 @@ public class TabLabel extends JPanel { return img; } - public void setInactiveStateImage(BufferedImage img) { + public void setInactiveStateImage(@Nullable BufferedImage img) { if (myInactiveStateImage != null && img != myInactiveStateImage) { myInactiveStateImage.flush(); } diff --git a/platform/platform-resources-en/src/misc/registry.properties b/platform/platform-resources-en/src/misc/registry.properties index 20657e9847e7..25819ceda9e5 100644 --- a/platform/platform-resources-en/src/misc/registry.properties +++ b/platform/platform-resources-en/src/misc/registry.properties @@ -116,7 +116,7 @@ debugger.valueTooltipAutoShow=true debugger.valueTooltipAutoShow.description=Auto show tooltip on mouse over debugger.mayBringFrameToFrontOnBreakpoint=true debugger.breakpoint.message.full.trace=false -debugger.breakpoint.message.full.trace.description='Log message to console' breakpoint action will out full stacktrace for the trhread that hit the breakpoint +debugger.breakpoint.message.full.trace.description='Log message to console' breakpoint action will out full stacktrace for the thread that hit the breakpoint filesystem.useNative=true