12 Commits
Author SHA1 Message Date
Hermes Agent d3286ef3b8 Block all keyboard (except ESC) and all mouse input via WH_MOUSE_LL; tagged idle nudge passes through own hook; hint updated 2026-09-18 13:02:58 +02:00
Hermes Agent d16a2db9ae Add periodic invisible mouse nudge (30s) to keep display awake and prevent ESC wake-swallow double-press; log SetThreadExecutionState result 2026-09-18 11:21:28 +02:00
Hermes Agent 0725915317 Keep display awake while running (SetThreadExecutionState) so the monitor does not enter standby and the DDC/CI brightness restore on exit no longer hangs ~30s; bound native DDC calls with a 2s timeout as defense 2026-09-17 22:33:29 +02:00
Hermes Agent d3437f924b Force wmi method on brightness fallback to skip slow DDC/VCP 49-retry 2026-09-16 17:30:43 +02:00
Hermes Agent bca41eadc4 Fix dxva2 arg: pass PHYSICAL_MONITOR array directly (not byref) for GetPhysicalMonitorsFromHMONITOR/DestroyPhysicalMonitors 2026-09-16 17:03:43 +02:00
Hermes Agent d0f6fd8818 Hybrid brightness: native DDC/CI (dxva2) with per-monitor WMI fallback
- BrightnessController enumerates monitors, opens each via dxva2 and reads/writes
  brightness directly (sub-ms); falls back per monitor to screen_brightness_control
  (WMI) for panels without DDC/CI (laptop internal screens)
- native dim sets each monitor to its minimum; restore sets saved value
- tagged v1-wmi-only before this change as safe rollback point
2026-09-16 16:57:18 +02:00
Hermes Agent dc2f754f86 Optimize startup: show black overlay first, dim brightness in a background thread; switch to one-folder PyInstaller build (no on-launch extraction)
- black screen now appears immediately (window creation), while the slow
  screen-brightness-control WMI queries (get+set) run in a daemon thread and
  are invisible behind the black overlay
- one-folder COLLECT build removes the ~2-3s one-file archive extraction
2026-09-16 16:39:20 +02:00
Hermes Agent 0027ca57fc Fix hint not clearing: InvalidateRect must request background erase (True) so the class brush repaints black 2026-09-16 16:31:34 +02:00
Hermes Agent d6e83565c1 Fix Win32 ctypes issues: wintypes aliases, DrawTextW belongs to user32, drop FillRect (use class brush), NULL ptr for EnumDisplayMonitors
Verified on Windows: module imports and enum_monitor_rects() returns correct
device-coordinate monitor rects.
2026-09-16 16:28:23 +02:00
Hermes Agent 0e88bf62f5 Rewrite overlay on Win32 (one borderless topmost window per monitor) + logging
- fixes second monitor not fully covered (gap at top): each monitor now gets its
  own window sized exactly to its rcMonitor in device coords, with per-monitor V2
  DPI awareness, so it covers the full screen regardless of layout/DPI
- dropped pygame; black fill + 'ESC - exit' hint drawn via GDI
- global ESC via low-level keyboard hook (works without window focus)
- logging to %TEMP%\black_screen_dim.log (start, monitor rects, brightness, errors)
- requirements.txt: pygame removed
2026-09-16 16:21:36 +02:00
Hermes Agent 87bdbd7226 Multi-monitor support: black overlay covers all displays, brightness dim/restore per monitor
- get_virtual_screen_rect(): bounds of the whole virtual desktop (negative x/y OK)
- window pinned topmost across every monitor via SetWindowPos + SetForegroundWindow
- brightness saved/restored as a per-monitor list (was only first monitor)
- resource_path() so icon.ico is found in the frozen exe; spec now bundles it
2026-09-16 16:02:34 +02:00
Hermes Agent 1e86958277 Initial import: Black Screen Dim (Pygame + PyInstaller)
Imported from matebook D:\BS (2026-03-11). Source only (no venv/build/dist).
Added requirements.txt, .gitignore, README.md, IDEA.md.
2026-09-16 15:26:14 +02:00