Mercurial > minori
comparison dep/animia/src/animia.cc @ 198:bc1ae1810855
dep/animia: switch from using classes to global functions
the old idea was ok, but sort of hackish; this method doesn't use classes
at all, and this way (especially important!) we can do wayland stuff AND x11
at the same time, which wasn't really possible without stupid workarounds in
the other method
author | Paper <mrpapersonic@gmail.com> |
---|---|
date | Sun, 24 Dec 2023 02:59:42 -0500 |
parents | 0fc126d52de4 |
children | 031a257ee019 |
comparison
equal
deleted
inserted
replaced
197:c4ca035c565d | 198:bc1ae1810855 |
---|---|
59 break; | 59 break; |
60 } | 60 } |
61 return true; | 61 return true; |
62 }; | 62 }; |
63 | 63 |
64 if (!internal::fd.EnumerateOpenProcesses(process_proc)) | 64 if (!internal::EnumerateOpenProcesses(process_proc)) |
65 return false; | 65 return false; |
66 | 66 |
67 /* Then add our cool windows. | 67 /* Then add our cool windows. |
68 Note: X11 is stupid and there's no reliable way to get a PID from a given window. | 68 Note: X11 is stupid and there's no reliable way to get a PID from a given window. |
69 This is because some windows might not even have a process attached to them. | 69 This is because some windows might not even have a process attached to them. |
81 break; | 81 break; |
82 } | 82 } |
83 return true; | 83 return true; |
84 }; | 84 }; |
85 | 85 |
86 if (!internal::win.EnumerateWindows(window_proc)) | 86 if (!internal::EnumerateWindows(window_proc)) |
87 return false; | 87 return false; |
88 | 88 |
89 return internal::ApplyStrategies(results); | 89 return internal::ApplyStrategies(results); |
90 } | 90 } |
91 | 91 |