diff options
author | Mike Gabriel <mike.gabriel@das-netzwerkteam.de> | 2023-02-12 21:16:56 +0100 |
---|---|---|
committer | Mike Gabriel <mike.gabriel@das-netzwerkteam.de> | 2023-02-12 21:16:56 +0100 |
commit | a19e4d91444b607e92aaea305df724a43afa958c (patch) | |
tree | 3380b3ce1f1d76d255f54f5123688aea60f96738 /src/flashlight.c | |
parent | 5ff62e2035c58ef583825240479f2522dcc8e82e (diff) | |
parent | d2569c71afb8651db6199c73369b9d8ef771aab0 (diff) | |
download | ayatana-indicator-power-a19e4d91444b607e92aaea305df724a43afa958c.tar.gz ayatana-indicator-power-a19e4d91444b607e92aaea305df724a43afa958c.tar.bz2 ayatana-indicator-power-a19e4d91444b607e92aaea305df724a43afa958c.zip |
Merge branch 'tari01-pr/flashlight-change-state'
Attributes GH PR #73: https://github.com/AyatanaIndicators/ayatana-indicator-power/pull/73
Diffstat (limited to 'src/flashlight.c')
-rw-r--r-- | src/flashlight.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/flashlight.c b/src/flashlight.c index 064bd31..0a68af2 100644 --- a/src/flashlight.c +++ b/src/flashlight.c @@ -1,5 +1,6 @@ /* * Copyright 2017 The UBports project + * Copyright 2023 Robert Tari * * This program is free software: you can redistribute it and/or modify it * under the terms of the GNU General Public License version 3, as published @@ -15,6 +16,7 @@ * * Authors: * Marius Gripsgard <marius@ubports.com> + * Robert Tari <robert@tari.in> */ #include "flashlight.h" @@ -145,7 +147,7 @@ toggle_flashlight_action(GAction *action, toggled = toggle_flashlight_action_simple(); if (toggled) - g_action_change_state(action, g_variant_new_boolean(!activated)); + g_simple_action_set_state (G_SIMPLE_ACTION (action), g_variant_new_boolean(!activated)); } int |