Changeset View
Changeset View
Standalone View
Standalone View
applets/devicenotifier/package/contents/ui/configGeneral.qml
Show All 11 Lines | |||||
12 | * GNU General Public License for more details. | 12 | * GNU General Public License for more details. | ||
13 | * | 13 | * | ||
14 | * You should have received a copy of the GNU General Public License | 14 | * You should have received a copy of the GNU General Public License | ||
15 | * along with this program; if not, write to the Free Software | 15 | * along with this program; if not, write to the Free Software | ||
16 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 2.010-1301, USA. | 16 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 2.010-1301, USA. | ||
17 | */ | 17 | */ | ||
18 | 18 | | |||
19 | import QtQuick 2.0 | 19 | import QtQuick 2.0 | ||
20 | import QtQuick.Controls 1.1 as Controls | 20 | import QtQuick.Controls 2.5 | ||
21 | import QtQuick.Layouts 1.1 as Layouts | 21 | import org.kde.kirigami 2.4 as Kirigami | ||
22 | 22 | | |||
23 | import org.kde.plasma.core 2.0 as PlasmaCore | 23 | import org.kde.plasma.core 2.0 as PlasmaCore | ||
filipf: Is PlasmaCore also needed here? | |||||
ngraham: Looks like it's not used anywhere, so I'd say no. | |||||
24 | 24 | | |||
25 | | ||||
26 | Item { | 25 | Item { | ||
27 | id: iconsPage | | |||
28 | width: childrenRect.width | 26 | width: childrenRect.width | ||
29 | height: childrenRect.height | 27 | height: childrenRect.height | ||
30 | implicitWidth: mainColumn.implicitWidth | | |||
31 | implicitHeight: mainColumn.implicitHeight | | |||
32 | 28 | | |||
33 | property alias cfg_removableDevices: removableOnly.checked | 29 | property alias cfg_removableDevices: removableOnly.checked | ||
34 | property alias cfg_nonRemovableDevices: nonRemovableOnly.checked | 30 | property alias cfg_nonRemovableDevices: nonRemovableOnly.checked | ||
35 | property alias cfg_allDevices: allDevices.checked | 31 | property alias cfg_allDevices: allDevices.checked | ||
36 | property alias cfg_popupOnNewDevice: autoPopup.checked | 32 | property alias cfg_popupOnNewDevice: autoPopup.checked | ||
37 | 33 | | |||
38 | Layouts.ColumnLayout { | 34 | Kirigami.FormLayout { | ||
39 | id: mainColumn | | |||
40 | anchors.left: parent.left | 35 | anchors.left: parent.left | ||
41 | Controls.ExclusiveGroup{ | 36 | anchors.right: parent.right | ||
42 | id: deviceFilter | 37 | | ||
43 | } | 38 | RadioButton { | ||
44 | Controls.RadioButton { | | |||
45 | id: removableOnly | 39 | id: removableOnly | ||
40 | Kirigami.FormData.label: i18n("Show:") | ||||
46 | text: i18n("Removable devices only") | 41 | text: i18n("Removable devices only") | ||
47 | exclusiveGroup: deviceFilter | | |||
48 | } | 42 | } | ||
49 | Controls.RadioButton { | 43 | | ||
44 | RadioButton { | ||||
50 | id: nonRemovableOnly | 45 | id: nonRemovableOnly | ||
51 | text: i18n("Non-removable devices only") | 46 | text: i18n("Non-removable devices only") | ||
52 | exclusiveGroup: deviceFilter | | |||
53 | } | 47 | } | ||
54 | Controls.RadioButton { | 48 | | ||
49 | RadioButton { | ||||
55 | id: allDevices | 50 | id: allDevices | ||
56 | text: i18n("All devices") | 51 | text: i18n("All devices") | ||
57 | exclusiveGroup: deviceFilter | | |||
58 | } | 52 | } | ||
59 | 53 | | |||
60 | Controls.CheckBox { | 54 | CheckBox { | ||
61 | id: autoPopup | 55 | id: autoPopup | ||
62 | Layouts.Layout.fillWidth: true | | |||
63 | text: i18n("Open popup when new device is plugged in") | 56 | text: i18n("Open popup when new device is plugged in") | ||
64 | } | 57 | } | ||
65 | } | 58 | } | ||
66 | } | 59 | } |
Is PlasmaCore also needed here?