mirror of
https://github.com/zoriya/noctalia-shell.git
synced 2026-06-01 10:05:30 +00:00
autofmt
This commit is contained in:
@@ -167,11 +167,11 @@ ColumnLayout {
|
|||||||
to: 1
|
to: 1
|
||||||
value: brightnessMonitor ? brightnessMonitor.brightness : 0.5
|
value: brightnessMonitor ? brightnessMonitor.brightness : 0.5
|
||||||
stepSize: 0.01
|
stepSize: 0.01
|
||||||
onMoved: (value) => {
|
onMoved: value => {
|
||||||
if (brightnessMonitor.method === "internal") {
|
if (brightnessMonitor.method === "internal") {
|
||||||
brightnessMonitor.setBrightness(value)
|
brightnessMonitor.setBrightness(value)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
onPressedChanged: (pressed, value) => brightnessMonitor.setBrightness(value)
|
onPressedChanged: (pressed, value) => brightnessMonitor.setBrightness(value)
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
}
|
}
|
||||||
|
|||||||
+32
-32
@@ -168,43 +168,43 @@ Item {
|
|||||||
}
|
}
|
||||||
|
|
||||||
IpcHandler {
|
IpcHandler {
|
||||||
target: "media"
|
target: "media"
|
||||||
function playPause() {
|
function playPause() {
|
||||||
MediaService.playPause()
|
MediaService.playPause()
|
||||||
}
|
}
|
||||||
|
|
||||||
function play() {
|
function play() {
|
||||||
MediaService.play()
|
MediaService.play()
|
||||||
}
|
}
|
||||||
|
|
||||||
function pause() {
|
function pause() {
|
||||||
MediaService.pause()
|
MediaService.pause()
|
||||||
}
|
}
|
||||||
|
|
||||||
function next() {
|
|
||||||
MediaService.next()
|
|
||||||
}
|
|
||||||
|
|
||||||
function previous() {
|
function next() {
|
||||||
MediaService.previous()
|
MediaService.next()
|
||||||
}
|
}
|
||||||
|
|
||||||
function seekRelative(offset: string) {
|
function previous() {
|
||||||
var offsetVal = parseFloat(position)
|
MediaService.previous()
|
||||||
if (Number.isNaN(offsetVal)) {
|
}
|
||||||
Logger.warn("Media", "Argument to ipc call 'media seekRelative' must be a number")
|
|
||||||
return
|
|
||||||
}
|
|
||||||
MediaService.seekRelative(offsetVal)
|
|
||||||
}
|
|
||||||
|
|
||||||
function seekByRatio(position: string) {
|
function seekRelative(offset: string) {
|
||||||
var positionVal = parseFloat(position)
|
var offsetVal = parseFloat(position)
|
||||||
if (Number.isNaN(positionVal)) {
|
if (Number.isNaN(offsetVal)) {
|
||||||
Logger.warn("Media", "Argument to ipc call 'media seekByRatio' must be a number")
|
Logger.warn("Media", "Argument to ipc call 'media seekRelative' must be a number")
|
||||||
return
|
return
|
||||||
}
|
|
||||||
MediaService.seekByRatio(positionVal)
|
|
||||||
}
|
}
|
||||||
|
MediaService.seekRelative(offsetVal)
|
||||||
|
}
|
||||||
|
|
||||||
|
function seekByRatio(position: string) {
|
||||||
|
var positionVal = parseFloat(position)
|
||||||
|
if (Number.isNaN(positionVal)) {
|
||||||
|
Logger.warn("Media", "Argument to ipc call 'media seekByRatio' must be a number")
|
||||||
|
return
|
||||||
|
}
|
||||||
|
MediaService.seekByRatio(positionVal)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -153,9 +153,9 @@ Singleton {
|
|||||||
|
|
||||||
function seekRelative(offset) {
|
function seekRelative(offset) {
|
||||||
if (currentPlayer && currentPlayer.canSeek) {
|
if (currentPlayer && currentPlayer.canSeek) {
|
||||||
var newPosition = currentPlayer.position + offset;
|
var newPosition = currentPlayer.position + offset
|
||||||
currentPlayer.position = newPosition;
|
currentPlayer.position = newPosition
|
||||||
currentPosition = newPosition;
|
currentPosition = newPosition
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user