fixbug开始黑屏
This commit is contained in:
parent
36c4f6153c
commit
0458195df7
@ -295,6 +295,13 @@ try:
|
||||
|
||||
def toggle_monitoring(self):
|
||||
if not self.running:
|
||||
# 开始监控时重置所有计时相关变量
|
||||
self.last_face_time = time.time()
|
||||
self.no_face_duration = 0
|
||||
self.progress_bar.setValue(0)
|
||||
self.progress_bar.setFormat("离开时间: 0s")
|
||||
self.set_progress_bar_style("#4CAF50")
|
||||
|
||||
self.running = True
|
||||
self.start_stop_btn.setText("停止监控")
|
||||
self.start_stop_btn.setStyleSheet("background-color: #ff4444;")
|
||||
|
Loading…
Reference in New Issue
Block a user