Differential D28487 Diff 81020 applets/systemmonitor/systemmonitor/package/contents/ui/FullRepresentation.qml
Changeset View
Changeset View
Standalone View
Standalone View
applets/systemmonitor/systemmonitor/package/contents/ui/FullRepresentation.qml
- This file was added.
1 | /* | ||||
---|---|---|---|---|---|
2 | * Copyright 2019 Marco Martin <mart@kde.org> | ||||
3 | * Copyright 2019 David Edmundson <davidedmundson@kde.org> | ||||
4 | * Copyright 2019 Arjen Hiemstra <ahiemstra@heimr.nl> | ||||
5 | * | ||||
6 | * This program is free software; you can redistribute it and/or modify | ||||
7 | * it under the terms of the GNU Library General Public License as | ||||
8 | * published by the Free Software Foundation; either version 2, or | ||||
9 | * (at your option) any later version. | ||||
10 | * | ||||
11 | * This program is distributed in the hope that it will be useful, | ||||
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||||
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||||
14 | * GNU General Public License for more details | ||||
15 | * | ||||
16 | * You should have received a copy of the GNU Library General Public | ||||
17 | * License along with this program; if not, write to the | ||||
18 | * Free Software Foundation, Inc., | ||||
19 | * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. | ||||
20 | */ | ||||
21 | | ||||
22 | import QtQuick 2.9 | ||||
23 | import QtQuick.Layouts 1.1 | ||||
24 | import QtQuick.Controls 2.2 | ||||
25 | import QtQuick.Window 2.12 | ||||
26 | import QtGraphicalEffects 1.0 | ||||
27 | | ||||
28 | import org.kde.kirigami 2.8 as Kirigami | ||||
29 | | ||||
30 | import org.kde.plasma.core 2.0 as PlasmaCore | ||||
31 | import org.kde.plasma.plasmoid 2.0 | ||||
32 | | ||||
33 | import org.kde.ksysguard.sensors 1.0 as Sensors | ||||
34 | import org.kde.ksysguard.faces 1.0 as Faces | ||||
35 | | ||||
36 | import org.kde.quickcharts 1.0 as Charts | ||||
37 | | ||||
38 | Control { | ||||
39 | id: chartFace | ||||
40 | | ||||
41 | anchors { | ||||
42 | fill: parent | ||||
43 | margins: Kirigami.Units.smallSpacing * (plasmoid.configuration.backgroundEnabled ? 1 : 2) | ||||
44 | } | ||||
45 | | ||||
46 | Layout.minimumWidth: contentItem ? contentItem.Layout.minimumWidth : 0 | ||||
47 | Layout.minimumHeight: contentItem ? contentItem.Layout.minimumHeight : 0 | ||||
48 | Layout.preferredWidth: contentItem | ||||
49 | ? (contentItem.Layout.preferredWidth > 0 ? contentItem.Layout.preferredWidth : contentItem.implicitWidth) | ||||
50 | : 0 | ||||
51 | Layout.preferredHeight: contentItem | ||||
52 | ? (contentItem.Layout.preferredHeight > 0 ? contentItem.Layout.preferredHeight: contentItem.implicitHeight) | ||||
53 | : 0 | ||||
54 | Layout.maximumWidth: contentItem ? contentItem.Layout.maximumWidth : 0 | ||||
55 | Layout.maximumHeight: contentItem ? contentItem.Layout.maximumHeight : 0 | ||||
56 | | ||||
57 | Kirigami.Theme.textColor: PlasmaCore.ColorScope.textColor | ||||
58 | | ||||
59 | contentItem: plasmoid.nativeInterface.faceController.fullRepresentation | ||||
60 | } | ||||
61 | |