diff --git a/CMakeLists.txt b/CMakeLists.txt index 46f7ebd..e6d5b23 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,15 +1,16 @@ +project(plasma-redshift-control) cmake_minimum_required(VERSION 2.8.12 FATAL_ERROR) set(QT_MIN_VERSION "5.4.0") set(KF5_MIN_VERSION "5.0.0") find_package(ECM 0.0.11 REQUIRED NO_MODULE) set(CMAKE_MODULE_PATH ${ECM_MODULE_PATH} ${ECM_KDE_MODULE_DIR}) include(KDEInstallDirs) include(KDECMakeSettings) include(KDECompilerSettings) find_package(KF5Plasma) plasma_install_package(package org.kde.redshiftControl) diff --git a/package/contents/ui/config/ConfigGeneral.qml b/package/contents/ui/config/ConfigGeneral.qml index e57dfba..347991d 100644 --- a/package/contents/ui/config/ConfigGeneral.qml +++ b/package/contents/ui/config/ConfigGeneral.qml @@ -1,119 +1,122 @@ /* * Copyright 2015 Martin Kotelnik * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as * published by the Free Software Foundation; either version 2 of * the License, or (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ import QtQuick 2.2 import QtQuick.Controls 1.3 import QtQuick.Layouts 1.1 Item { property alias cfg_autostart: autostart.checked property alias cfg_smoothTransitions: smoothTransitions.checked property alias cfg_manualTemperatureStep: manualTemperatureStep.value property alias cfg_manualBrightnessStep: manualBrightnessStep.value property alias cfg_useDefaultIcons: useDefaultIcons.checked property string cfg_iconActive: plasmoid.configuration.iconActive property string cfg_iconInactive: plasmoid.configuration.iconInactive Label { text: i18n('Plasmoid version') + ': 1.0.18' anchors.right: parent.right } GridLayout { Layout.fillWidth: true columns: 2 CheckBox { id: autostart text: i18n('Autostart') Layout.columnSpan: 2 } CheckBox { id: smoothTransitions text: i18n('Smooth transitions') Layout.columnSpan: 2 } Item { width: 2 height: 10 Layout.columnSpan: 2 } Label { text: i18n("Manual temperature step:") Layout.alignment: Qt.AlignRight } SpinBox { id: manualTemperatureStep + Layout.minimumWidth: iconActivePicker.width decimals: 0 stepSize: 125 minimumValue: 25 maximumValue: 5000 } Label { text: i18n("Manual brightness step:") Layout.alignment: Qt.AlignRight } SpinBox { id: manualBrightnessStep + Layout.minimumWidth: iconActivePicker.width decimals: 2 stepSize: 0.01 minimumValue: 0.01 maximumValue: 0.2 } Item { width: 2 height: 10 Layout.columnSpan: 2 } CheckBox { id: useDefaultIcons text: i18n('Use default icons') Layout.columnSpan: 2 } Label { text: i18n("Active:") Layout.alignment: Qt.AlignRight } IconPicker { + id: iconActivePicker currentIcon: cfg_iconActive defaultIcon: 'redshift-status-on' onIconChanged: cfg_iconActive = iconName enabled: !useDefaultIcons.checked } Label { text: i18n("Inactive:") Layout.alignment: Qt.AlignRight } IconPicker { currentIcon: cfg_iconInactive defaultIcon: 'redshift-status-off' onIconChanged: cfg_iconInactive = iconName enabled: !useDefaultIcons.checked } } }