vcs: non-modal: Move "Amend" checkbox and commit toolbar actions above commit message...
[idea/community.git] / platform / vcs-impl / src / com / intellij / vcs / commit / ChangesViewCommitStatusPanel.kt
index feba126abe72d2799984bb572a279fbb39be2de2..b3b529078aa470d12eb83ca2c36017e6942dfd75 100644 (file)
@@ -12,10 +12,9 @@ import com.intellij.openapi.vcs.changes.ui.*
 import com.intellij.openapi.vcs.changes.ui.ChangesViewContentManager.Companion.LOCAL_CHANGES
 import com.intellij.ui.content.Content
 import com.intellij.util.ui.JBUI.Borders.empty
+import com.intellij.util.ui.JBUI.Borders.emptyRight
 import com.intellij.util.ui.JBUI.emptyInsets
-import com.intellij.util.ui.JBUI.emptySize
 import com.intellij.util.ui.components.BorderLayoutPanel
-import java.awt.Dimension
 
 private val isCompactCommitLegend get() = Registry.get("vcs.non.modal.commit.legend.compact")
 
@@ -39,7 +38,7 @@ internal class ChangesViewCommitStatusPanel(tree: ChangesTree, private val commi
     setupLegend()
 
     addToRight(commitLegend.component)
-    border = empty(6)
+    border = emptyRight(6)
     background = tree.background
 
     commitWorkflowUi.addInclusionListener(this, commitWorkflowUi)
@@ -69,8 +68,6 @@ internal class ChangesViewCommitStatusPanel(tree: ChangesTree, private val commi
     tab.description = branchComponent.toolTipText
   }
 
-  override fun getPreferredSize(): Dimension? = if (commitLegend.component.isVisible) super.getPreferredSize() else emptySize()
-
   override fun inclusionChanged() = updateLegend()
 
   private fun setupLegend() {