mirror of
https://github.com/AvengeMedia/DankMaterialShell.git
synced 2025-12-10 07:25:37 -05:00
Fix warnings
This commit is contained in:
@@ -28,7 +28,9 @@ Rectangle {
|
|||||||
|
|
||||||
onActivePlayerChanged: {
|
onActivePlayerChanged: {
|
||||||
if (activePlayer && activePlayer.positionSupported) {
|
if (activePlayer && activePlayer.positionSupported) {
|
||||||
currentPosition = Qt.binding(() => activePlayer?.position)
|
currentPosition = Qt.binding(() => activePlayer?.position || 0)
|
||||||
|
} else {
|
||||||
|
currentPosition = 0
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -146,7 +146,6 @@ PanelWindow {
|
|||||||
|
|
||||||
TextArea {
|
TextArea {
|
||||||
id: textArea
|
id: textArea
|
||||||
text: SessionData.notepadContent
|
|
||||||
placeholderText: qsTr("Start typing your notes here...")
|
placeholderText: qsTr("Start typing your notes here...")
|
||||||
font.family: SettingsData.monoFontFamily
|
font.family: SettingsData.monoFontFamily
|
||||||
font.pixelSize: Theme.fontSizeMedium
|
font.pixelSize: Theme.fontSizeMedium
|
||||||
@@ -164,6 +163,19 @@ PanelWindow {
|
|||||||
rightPadding: Theme.spacingM
|
rightPadding: Theme.spacingM
|
||||||
bottomPadding: Theme.spacingM
|
bottomPadding: Theme.spacingM
|
||||||
|
|
||||||
|
Component.onCompleted: {
|
||||||
|
text = SessionData.notepadContent
|
||||||
|
}
|
||||||
|
|
||||||
|
Connections {
|
||||||
|
target: SessionData
|
||||||
|
function onNotepadContentChanged() {
|
||||||
|
if (textArea.text !== SessionData.notepadContent) {
|
||||||
|
textArea.text = SessionData.notepadContent
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
onTextChanged: {
|
onTextChanged: {
|
||||||
if (text !== SessionData.notepadContent) {
|
if (text !== SessionData.notepadContent) {
|
||||||
SessionData.notepadContent = text
|
SessionData.notepadContent = text
|
||||||
|
|||||||
Reference in New Issue
Block a user