GitOrigin-RevId: 71e3469247019a6662871e0244873f32ba69b959
This commit is contained in:
Vladimir Krivosheev
2023-06-18 22:04:24 +00:00
committed by intellij-monorepo-bot
parent 7e1b7fe8cf
commit a834a7647e
2 changed files with 6 additions and 9 deletions
@@ -12,6 +12,7 @@ import com.intellij.openapi.application.*
import com.intellij.openapi.application.impl.LaterInvocator
import com.intellij.openapi.components.serviceIfCreated
import com.intellij.openapi.diagnostic.Logger
import com.intellij.openapi.diagnostic.debug
import com.intellij.openapi.diagnostic.logger
import com.intellij.openapi.fileEditor.FileEditorManager
import com.intellij.openapi.fileEditor.ex.FileEditorManagerEx
@@ -321,16 +322,12 @@ open class ProjectFrameHelper internal constructor(
rootPane.putClientProperty(INIT_BOUNDS_KEY, null)
if (bounds is Rectangle) {
ProjectFrameBounds.getInstance(project!!).markDirty(bounds)
if (IDE_FRAME_EVENT_LOG.isDebugEnabled) { // avoid unnecessary concatenation
IDE_FRAME_EVENT_LOG.debug("Applied init bounds for full screen from client property: $bounds")
}
IDE_FRAME_EVENT_LOG.debug { "Applied init bounds for full screen from client property: $bounds" }
}
}
else {
ProjectFrameBounds.getInstance(project!!).markDirty(frame.bounds)
if (IDE_FRAME_EVENT_LOG.isDebugEnabled) { // avoid unnecessary concatenation
IDE_FRAME_EVENT_LOG.debug("Applied init bounds for non-fullscreen from the frame: ${frame.bounds}")
}
IDE_FRAME_EVENT_LOG.debug { "Applied init bounds for non-fullscreen from the frame: ${frame.bounds}" }
}
}
@@ -1,4 +1,4 @@
// Copyright 2000-2022 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
// Copyright 2000-2023 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
@file:Suppress("ReplaceGetOrSet", "ReplacePutWithAssignment")
package com.intellij.openapi.wm.impl
@@ -46,7 +46,7 @@ import javax.swing.JWindow
private val LOG = logger<WindowManagerImpl>()
@JvmField
internal val IDE_FRAME_EVENT_LOG = Logger.getInstance("ide.frame.events")
internal val IDE_FRAME_EVENT_LOG: Logger = Logger.getInstance("ide.frame.events")
@NonNls
private const val FOCUSED_WINDOW_PROPERTY_NAME = "focusedWindow"
@@ -506,7 +506,7 @@ internal class FrameStateListener(private val defaultFrameInfoHelper: FrameInfoH
// Component moved during project loading - update myDefaultFrameInfo directly.
// Cannot mark as dirty and compute later, because to convert user space info to device space,
// we need graphicsConfiguration, but we can get graphicsConfiguration only from frame,
// but later, when getStateModificationCount or getState is called, may be no frame at all.
// but later, when getStateModificationCount or getState is called, there may be no frame at all.
defaultFrameInfoHelper.updateFrameInfo(frameHelper, frame)
}
else if (!project.isDisposed) {