Fix warnings

This commit is contained in:
Tobias Fella
2025-08-13 21:32:45 +02:00
parent 13deb2d928
commit 36fccaffe6
2 changed files with 5 additions and 4 deletions

View File

@@ -117,6 +117,7 @@ ecm_add_qml_module(neochat URI org.kde.neochat GENERATE_PLUGIN_SOURCE
org.kde.neochat.login org.kde.neochat.login
org.kde.neochat.chatbar org.kde.neochat.chatbar
org.kde.config org.kde.config
org.kde.purpose
) )
if(NOT ANDROID AND NOT WIN32) if(NOT ANDROID AND NOT WIN32)

View File

@@ -6,7 +6,6 @@
*/ */
import QtQuick import QtQuick
import QtQuick.Layouts
import QtQuick.Controls as QQC2 import QtQuick.Controls as QQC2
import org.kde.purpose as Purpose import org.kde.purpose as Purpose
@@ -24,7 +23,7 @@ Kirigami.Page {
bottomPadding: 0 bottomPadding: 0
property alias index: jobView.index property alias index: jobView.index
property alias model: jobView.model required property var model
QQC2.Action { QQC2.Action {
shortcut: 'Escape' shortcut: 'Escape'
@@ -34,7 +33,7 @@ Kirigami.Page {
Notification { Notification {
id: sharingFailed id: sharingFailed
eventId: "Share" eventId: "Share"
text: i18n("Sharing failed") text: i18nc("@info:status", "Sharing failed")
urgency: Notification.NormalUrgency urgency: Notification.NormalUrgency
} }
@@ -51,11 +50,12 @@ Kirigami.Page {
Purpose.JobView { Purpose.JobView {
id: jobView id: jobView
model: root.model
anchors.fill: parent anchors.fill: parent
onStateChanged: { onStateChanged: {
if (state === Purpose.PurposeJobController.Finished) { if (state === Purpose.PurposeJobController.Finished) {
if (jobView.job?.output?.url?.length > 0) { if (jobView.job?.output?.url?.length > 0) {
sharingSuccess.text = i18n("Shared url for image is <a href='%1'>%1</a>", jobView.job.output.url); sharingSuccess.text = i18nc("@info", "Shared url for image is <a href='%1'>%1</a>", jobView.job.output.url);
sharingSuccess.sendEvent(); sharingSuccess.sendEvent();
Clipboard.saveText(jobView.job.output.url); Clipboard.saveText(jobView.job.output.url);
} }