Warning, /pim/merkuro/src/contacts/qml/private/ContactGroupPage.qml is written in an unsupported language. File is not indexed.
0001 // SPDX-FileCopyrightText: 2022 Carl Schwan <carl@carlschwan.eu> 0002 // SPDX-License-Identifier: LGPL-3.0-or-later 0003 0004 import QtQuick 0005 import QtQuick.Controls as Controls 0006 import QtQuick.Layouts 0007 import org.kde.kirigami as Kirigami 0008 import org.kde.kirigamiaddons.delegates as Delegates 0009 import org.kde.merkuro.contact 0010 0011 Kirigami.ScrollablePage { 0012 id: page 0013 0014 property int itemId 0015 property ContactGroupWrapper contactGroup: ContactGroupWrapper { 0016 id: contactGroup 0017 item: ContactManager.getItem(page.itemId) 0018 } 0019 0020 title: contactGroup.name 0021 0022 leftPadding: 0 0023 rightPadding: 0 0024 topPadding: 0 0025 0026 function openEditor() { 0027 const editor = pageStack.pushDialogLayer(Qt.resolvedUrl("contact_editor/ContactGroupEditorPage.qml"), { 0028 mode: ContactGroupEditor.EditMode, 0029 }); 0030 editor.item = page.contactGroup.item; 0031 } 0032 0033 actions: Kirigami.Action { 0034 icon.name: "document-edit" 0035 text: i18nc("@action:button", "Edit") 0036 onTriggered: openEditor() 0037 } 0038 0039 ListView { 0040 model: contactGroup.model 0041 delegate: Delegates.RoundedItemDelegate { 0042 id: contact 0043 0044 required property int index 0045 required property string iconName 0046 required property string email 0047 required property string displayName 0048 0049 icon.name: iconName 0050 text: displayName 0051 0052 contentItem: Delegates.SubtitleContentItem { 0053 itemDelegate: contact 0054 subtitle: contact.email 0055 } 0056 } 0057 } 0058 }