فهرست منبع

Add missing getter functions for pattern_lock and pause_event

These functions are called by main.py and playlist_manager.py but
were missing from the reverted pattern_manager.py.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
tuanchris 1 هفته پیش
والد
کامیت
44a52af395
1فایلهای تغییر یافته به همراه8 افزوده شده و 0 حذف شده
  1. 8 0
      modules/core/pattern_manager.py

+ 8 - 0
modules/core/pattern_manager.py

@@ -114,6 +114,14 @@ pause_event.set()  # Initially not paused
 # Create an asyncio Lock for pattern execution
 pattern_lock = asyncio.Lock()
 
+def get_pattern_lock():
+    """Get the pattern lock for external modules to check lock state."""
+    return pattern_lock
+
+def get_pause_event():
+    """Get the pause event for external modules."""
+    return pause_event
+
 # Progress update task
 progress_update_task = None