mirror of
https://github.com/Swordfish90/cool-retro-term.git
synced 2026-02-08 00:32:27 +00:00
Fix focus issue with multiple windows. Fix build issues with previous Qt versions.
This commit is contained in:
@@ -24,7 +24,7 @@ import "utils.js" as Utils
|
||||
Loader {
|
||||
id: burnInEffect
|
||||
|
||||
property ShaderEffectSource source: item ? item.source : null
|
||||
property ShaderEffectSource effectSource: item ? item.source : null
|
||||
|
||||
property real lastUpdate: 0
|
||||
property real prevLastUpdate: 0
|
||||
|
||||
@@ -83,13 +83,6 @@ Item{
|
||||
terminalContainer.updateSources()
|
||||
}
|
||||
}
|
||||
Connections {
|
||||
target: terminalWindow
|
||||
|
||||
onActiveChanged: {
|
||||
kterminal.forceActiveFocus()
|
||||
}
|
||||
}
|
||||
|
||||
function updateSources() {
|
||||
kterminal.update()
|
||||
|
||||
@@ -73,7 +73,7 @@ Item {
|
||||
id: dynamicShader
|
||||
|
||||
property ShaderEffectSource screenBuffer: frameBuffer
|
||||
property ShaderEffectSource burnInSource: burnInEffect.source
|
||||
property ShaderEffectSource burnInSource: burnInEffect.effectSource
|
||||
property ShaderEffectSource frameSource: terminalFrameLoader.item
|
||||
|
||||
property color fontColor: parent.fontColor
|
||||
|
||||
@@ -130,9 +130,9 @@ Item {
|
||||
Repeater {
|
||||
model: tabsModel
|
||||
TerminalContainer {
|
||||
property bool isCurrentItem: StackLayout.isCurrentItem
|
||||
onIsCurrentItemChanged: {
|
||||
if (isCurrentItem) {
|
||||
property bool shouldHaveFocus: terminalWindow.active && StackLayout.isCurrentItem
|
||||
onShouldHaveFocusChanged: {
|
||||
if (shouldHaveFocus) {
|
||||
activate()
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user