Warning, /pim/merkuro/src/mail/qml/app/main.qml is written in an unsupported language. File is not indexed.
0001 // SPDX-FileCopyrightText: 2023 Carl Schwan <carlschwan@kde.org> 0002 // SPDX-License-Identifier: LGPL-3.0-or-later 0003 0004 import QtQuick 2.15 0005 import QtQuick.Controls 2.15 as QQC2 0006 import org.kde.merkuro.components 1.0 0007 import org.kde.merkuro.mail 1.0 as Mail 0008 import org.kde.akonadi 1.0 as Akonadi 0009 import org.kde.kirigami 2.20 as Kirigami 0010 0011 BaseApplication { 0012 id: root 0013 0014 application: Mail.MailApplication 0015 0016 menuBar: Loader { 0017 active: !Kirigami.Settings.hasPlatformMenuBar && !Kirigami.Settings.isMobile && applicationWindow().pageStack.currentItem 0018 0019 height: visible ? implicitHeight : 0 0020 sourceComponent: MenuBar {} 0021 onItemChanged: if (item) { 0022 item.Kirigami.Theme.colorSet = Kirigami.Theme.Header; 0023 } 0024 } 0025 0026 pageStack.initialPage: Mail.FolderView {} 0027 0028 globalDrawer: Mail.MailSidebar { 0029 id: sidebar 0030 } 0031 0032 //Loader { 0033 // id: globalMenuLoader 0034 // active: !Kirigami.Settings.isMobile 0035 // sourceComponent: Contact.GlobalMenuBar {} 0036 //} 0037 0038 Connections { 0039 target: Mail.MailApplication 0040 0041 function onOpenSettings() { 0042 const openDialogWindow = pageStack.pushDialogLayer("qrc:/qml/settings/Settings.qml", { 0043 width: root.width 0044 }, { 0045 title: i18n("Configure"), 0046 width: Kirigami.Units.gridUnit * 40, 0047 height: Kirigami.Units.gridUnit * 30 0048 }); 0049 openDialogWindow.Keys.escapePressed.connect(function() { openDialogWindow.closeDialog() }); 0050 } 0051 } 0052 }