diff --git a/src/services/__pycache__/system_monitor.cpython-313.pyc b/src/services/__pycache__/system_monitor.cpython-313.pyc index 0953971..22bfd95 100644 Binary files a/src/services/__pycache__/system_monitor.cpython-313.pyc and b/src/services/__pycache__/system_monitor.cpython-313.pyc differ diff --git a/src/services/__pycache__/tetris_game.cpython-313.pyc b/src/services/__pycache__/tetris_game.cpython-313.pyc index f741033..6610eca 100644 Binary files a/src/services/__pycache__/tetris_game.cpython-313.pyc and b/src/services/__pycache__/tetris_game.cpython-313.pyc differ diff --git a/src/services/__pycache__/threads_manager.cpython-313.pyc b/src/services/__pycache__/threads_manager.cpython-313.pyc index 3c0f203..1de9aa9 100644 Binary files a/src/services/__pycache__/threads_manager.cpython-313.pyc and b/src/services/__pycache__/threads_manager.cpython-313.pyc differ diff --git a/src/services/system_monitor.py b/src/services/system_monitor.py index a0d10e9..87f610e 100644 --- a/src/services/system_monitor.py +++ b/src/services/system_monitor.py @@ -19,7 +19,12 @@ class SystemMonitor: "data": [], "fetch_func": lambda: psutil.virtual_memory().percent, "interval": 1 - } + }, + "Processes": { + "data": [], + "fetch_func": lambda: self.get_process_count, + "interval": 1 + } } self.graphs = {} self.init_graphs() @@ -74,4 +79,8 @@ class SystemMonitor: graph["axis"].set_xlim(0, len(data)) graph["figure"].canvas.draw() - self.parent_frame.after(0, redraw) \ No newline at end of file + self.parent_frame.after(0, redraw) + + def get_process_count(self): + """Obtiene el nĂºmero de procesos actuales.""" + return len(psutil.pids()) \ No newline at end of file