Changeset View
Changeset View
Standalone View
Standalone View
kcmcontrols/GridViewKCM.qml
- This file was added.
1 | /* | ||||
---|---|---|---|---|---|
2 | Copyright (c) 2017 Marco Martin <mart@kde.org> | ||||
3 | | ||||
4 | This library is free software; you can redistribute it and/or | ||||
5 | modify it under the terms of the GNU Library General Public | ||||
6 | License version 2 as published by the Free Software Foundation. | ||||
7 | | ||||
8 | This library is distributed in the hope that it will be useful, | ||||
9 | but WITHOUT ANY WARRANTY; without even the implied warranty of | ||||
10 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||||
11 | Library General Public License for more details. | ||||
12 | | ||||
13 | You should have received a copy of the GNU Library General Public License | ||||
14 | along with this library; see the file COPYING.LIB. If not, write to | ||||
15 | the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, | ||||
16 | Boston, MA 02110-1301, USA. | ||||
17 | */ | ||||
18 | | ||||
19 | import QtQuick 2.7 | ||||
20 | import QtQuick.Layouts 1.1 | ||||
21 | import QtQuick.Controls 2.2 as QtControls | ||||
22 | import org.kde.kirigami 2.2 as Kirigami | ||||
23 | import org.kde.kcmcontrols 1.0 as KCMControls | ||||
24 | import org.kde.kcm 1.0 | ||||
25 | | ||||
26 | Kirigami.Page { | ||||
27 | id: root | ||||
28 | | ||||
29 | title: kcm.name | ||||
30 | implicitWidth: Kirigami.Units.gridUnit * 20 | ||||
31 | implicitHeight: Kirigami.Units.gridUnit * 20 | ||||
32 | | ||||
33 | property alias view: scroll.view | ||||
34 | | ||||
35 | topPadding: 0 | ||||
36 | leftPadding: 0 | ||||
37 | rightPadding: 0 | ||||
38 | bottomPadding: footer ? Kirigami.Units.smallSpacing : 0 | ||||
39 | | ||||
40 | KCMControls.GridView { | ||||
41 | id: scroll | ||||
42 | anchors { | ||||
43 | top: parent.top | ||||
44 | bottom: parent.bottom | ||||
45 | horizontalCenter: parent.horizontalCenter | ||||
46 | } | ||||
47 | } | ||||
48 | } |