Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
X
ximper-shell-notification-center
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Ximper Linux
ximper-shell-notification-center
Commits
d909c2d2
Verified
Commit
d909c2d2
authored
Mar 31, 2026
by
Kirill Unitsaev
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
night-light: check running process instead of installed binary
parent
81efb6ef
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
6 deletions
+20
-6
nightLightTile.vala
...rolCenter/widgets/quickSettings/tiles/nightLightTile.vala
+20
-6
No files found.
src/controlCenter/widgets/quickSettings/tiles/nightLightTile.vala
View file @
d909c2d2
...
...
@@ -15,10 +15,6 @@ namespace XimperShellNotificationCenter.Widgets {
temperature
=
temp
;
}
}
_is_available
=
Environment
.
find_program_in_path
(
"hyprsunset"
)
!=
null
;
}
public
override
bool
is_available
()
{
...
...
@@ -27,8 +23,26 @@ namespace XimperShellNotificationCenter.Widgets {
public
override
void
on_cc_visibility_change
(
bool
visible
)
{
if
(
visible
&&
_is_available
)
{
sync_state
.
begin
();
if
(
visible
)
{
check_and_sync
.
begin
();
}
}
private
async
void
check_and_sync
()
{
string
msg
;
bool
ok
=
yield
Functions
.
execute_command
(
"pgrep -x hyprsunset"
,
{},
out
msg
);
bool
was_available
=
_is_available
;
_is_available
=
ok
&&
msg
.
strip
().
length
>
0
;
if
(
_is_available
)
{
yield
sync_state
();
}
if
(
was_available
!=
_is_available
)
{
// Trigger grid rebuild
set_visible
(
_is_available
);
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment