mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
Borderless UI: Missing file title in compare view (#RIDER-28210)
GitOrigin-RevId: cde935ff13c33413cca6db20d2f1e84e984e7d24
This commit is contained in:
committed by
intellij-monorepo-bot
parent
231f2818c4
commit
fb949f20f7
+14
@@ -5,11 +5,15 @@ import com.intellij.openapi.wm.impl.customFrameDecorations.CustomFrameTitleButto
|
||||
import com.intellij.ui.awt.RelativeRectangle
|
||||
import net.miginfocom.swing.MigLayout
|
||||
import java.awt.*
|
||||
import java.beans.PropertyChangeListener
|
||||
import java.util.ArrayList
|
||||
import javax.swing.*
|
||||
|
||||
class DialogHeader(val window: Window) : CustomHeader(window) {
|
||||
private val titleLabel = JLabel()
|
||||
private val titleChangeListener = PropertyChangeListener{
|
||||
titleLabel.text = getTitle()
|
||||
}
|
||||
|
||||
init {
|
||||
layout = MigLayout("novisualpadding, ins 0, fillx, gap 0", "$H_GAP[min!]$H_GAP[][pref!]", "")
|
||||
@@ -20,6 +24,16 @@ class DialogHeader(val window: Window) : CustomHeader(window) {
|
||||
add(buttonPanes.getView(), "top, wmin pref")
|
||||
}
|
||||
|
||||
override fun installListeners() {
|
||||
super.installListeners()
|
||||
window.addPropertyChangeListener("title", titleChangeListener)
|
||||
}
|
||||
|
||||
override fun uninstallListeners() {
|
||||
super.uninstallListeners()
|
||||
window.removePropertyChangeListener(titleChangeListener)
|
||||
}
|
||||
|
||||
override fun createButtonsPane(): CustomFrameTitleButtons = CustomFrameTitleButtons.create(myCloseAction)
|
||||
|
||||
override fun updateActive() {
|
||||
|
||||
Reference in New Issue
Block a user