11; @Ahk2Exe-SetName FireFlyFy
22; @Ahk2Exe-SetDescription Changes monitor brightness based on active window.
33; @Ahk2Exe-SetVersion 1.0.0
4- ; @Ahk2Exe-SetCopyright Copyright (c) 2025`, elModo7 - VictorDevLog
4+ ; @Ahk2Exe-SetCopyright 2025 elModo7 - VictorDevLog
55; @Ahk2Exe-SetOrigFilename FireFlyFy.exe
6+ ; ~ ;@Ahk2Exe-ConsoleApp ; Only for CLI Mode (maybe for a future revision as I will already be releasing a standalone CLI binary)
67#NoEnv
78#SingleInstance Force
89#Persistent
910SetTitleMatchMode , 3
1011DetectHiddenWindows , On
1112SetBatchLines - 1
1213CoordMode , Mouse , Screen
13- global version := " 0.1.3"
14+ FileEncoding , UTF- 8
15+ global version := " 0.1.9"
1416global appName := " FireFlyFy"
1517
1618; Libs
1719#Include <Screen>
1820#Include <cJSON>
21+ #Include <i18n>
1922#Include <Utils>
2023#Include <AboutScreen>
2124#Include <WindowsNightLight>
2225
2326; Globals
2427global initialBrightness, appPrev, processPrev, globalConfig, appsConfig, isVisible := 1 , fireFlyFyEnabled := 1
28+ global curLang := {}, langC, languages
29+
30+ ; Languages
31+ getLanguages()
32+ i18n := new i18n("" , " en_US" , [" en_US" ])
33+ loadTranslations()
2534
2635; Init
36+ initCLIMessages()
2737createOrReadConfig()
28- loadTranslations(globalConfig.language)
2938installResources()
3039setInitialBrigthness()
3140configureTray()
@@ -39,6 +48,8 @@ OnMessage(0x404, "trayEventsCapture")
3948
4049enableFireFlyFy()
4150gosub , initMouseFollower
51+ OnExit , ExitSub
52+ globalConfig.lookForUpdates ? lookForUpdates(1 ) : ""
4253return
4354
4455detectWindowChanged(wParam, lParam)
@@ -58,13 +69,13 @@ checkCurrentApp:
5869 processPrev := processCur
5970 for appK, appV in appsConfig.apps
6071 {
61- if (appV.activeBy == " process " ) {
62- if (processCur == appV.process ) {
72+ if (appV.activeBy == " title " ) {
73+ if (appCur == appV.title ) {
6374 applyFireFlyFy(appV)
6475 return
6576 }
6677 } else {
67- if (appCur == appV.title ) {
78+ if (processCur == appV.process ) {
6879 applyFireFlyFy(appV)
6980 return
7081 }
@@ -79,21 +90,8 @@ return
7990^Esc ::Reload
8091
8192/* TODO:
82- Add window / process -> FireFly follows mouse when choosing, enter chooses, escape cancels
83- title or processName (default by process)
84- brightnessValue 0-100 (default 50)
85- nightLightStrength 0-100 (default 50)
86- Block that if you have by title of the same process, you can not add a rule by process unless you remove the ones by title before, maybe prompt of those that match and offer removing?
87-
88-
8993application list
90-
91- Start with windows (default no)
9294Scheduler (default no)
93- progressive change yes/no (default yes)
94- multilingual
95- Clear config
96-
9795Update, autoreplace running executable
9896Add CLI
9997*/
0 commit comments