mirror of
https://github.com/noctalia-dev/noctalia-shell.git
synced 2026-05-11 17:08:27 +08:00
21 lines
608 B
QML
21 lines
608 B
QML
import QtQuick.Layouts
|
|
import Quickshell
|
|
import qs.Commons
|
|
import qs.Services
|
|
import qs.Widgets
|
|
|
|
NQuickSetting {
|
|
property ShellScreen screen
|
|
property real scaling: 1.0
|
|
|
|
text: I18n.tr("quickSettings.keepAwake.label.enabled")
|
|
fontSize: Style.fontSizeS * scaling
|
|
fontWeight: Style.fontWeightMedium
|
|
icon: IdleInhibitorService.isInhibited ? "keep-awake-on" : "keep-awake-off"
|
|
hot: IdleInhibitorService.isInhibited
|
|
tooltipText: I18n.tr("quickSettings.keepAwake.tooltip.action")
|
|
style: Settings.data.controlCenter.quickSettingsStyle || "modern"
|
|
|
|
onClicked: IdleInhibitorService.manualToggle()
|
|
}
|