Kaydet (Commit) 5cdeec07 authored tarafından Hakan Dündar's avatar Hakan Dündar

Several bug fixes and minor improvements

üst 0b166e6b
......@@ -70,4 +70,4 @@ modules:
sources:
- type: git
url: https://github.com/hakandundar34coding/system-monitoring-center.git
commit: 12d324fe3ae4d2de6a78e1bb050cb60f42546a25
commit: 1bea9e1ff79a8f1b228a9dff54dd0df285e3abeb
This diff is collapsed.
......@@ -20,6 +20,9 @@ class Performance:
# ----------------------- Always called when object is generated -----------------------
def __init__(self):
# Define data unit conversion variables before they are used.
self.performance_define_data_unit_converter_variables_func()
# Set chart performance data line and point highligting off. "chart_line_highlight" takes chart name or "" for highlighting or not. "chart_point_highlight" takes data point index or "-1" for not highlighting.
self.chart_line_highlight = ""
self.chart_point_highlight = -1
......@@ -2173,7 +2176,7 @@ class Performance:
chart_y_limit = 100
# Check if widget is the drawingarea on the headerbar for CPU usage.
if widget_name == "ps_hb_cpu_drawing_area":
if widget_name == "ps_hb_cpu_da":
# Get performance data to be drawn.
performance_data1 = self.cpu_usage_percent_ave[-1]
......@@ -2185,7 +2188,7 @@ class Performance:
chart_y_limit = 100
# Check if widget is the drawingarea on the headerbar for RAM usage.
if widget_name == "ps_hb_ram_drawing_area":
if widget_name == "ps_hb_ram_da":
# Get performance data to be drawn.
performance_data1 = self.ram_usage_percent[-1]
......
......@@ -703,7 +703,7 @@ class SettingsWindow:
Performance.network_send_speed[i] = Performance.network_send_speed[i][chart_data_history_current-chart_data_history_new:] # "network_send_speed" list has sub-lists and trimming is performed for every sub-lists (for every network card).
if MainWindow.gpu_tb.get_active() == True:
from Gpu import Gpu
Gpu.fps_count = Gpu.fps_count[chart_data_history_current-chart_data_history_new:] # "fps_count" list has no sub-lists and trimming is performed in this way.
Gpu.gpu_load_list = Gpu.gpu_load_list[chart_data_history_current-chart_data_history_new:] # "gpu_load_list" list has no sub-lists and trimming is performed in this way.
if chart_data_history_current < chart_data_history_new: # Add list of zeroes to the beginning part of the lists if new "chart_data_history" value is bigger than the old value.
list_to_add = [0] * (chart_data_history_new - chart_data_history_current) # Generate list of zeroes for adding to the beginning of te lists.
Performance.cpu_usage_percent_ave = list_to_add + Performance.cpu_usage_percent_ave # "cpu_usage_percent_ave" list has no sub-lists and addition is performed in this way.
......@@ -721,7 +721,7 @@ class SettingsWindow:
Performance.network_send_speed[i] = list_to_add + Performance.network_send_speed[i] # "network_send_speed" list has sub-lists and addition is performed for every sub-lists (for every network card).
if MainWindow.gpu_tb.get_active() == True:
from Gpu import Gpu
Gpu.fps_count = list_to_add + Gpu.fps_count # "fps_count" list has no sub-lists and addition is performed in this way.
Gpu.gpu_load_list = list_to_add + Gpu.gpu_load_list # "gpu_load_list" list has no sub-lists and addition is performed in this way.
# ----------------------- Called for applying settings for all opened tabs (since application start) without waiting update interval -----------------------
......
......@@ -127,6 +127,7 @@ class System:
performance_info_grid.set_row_homogeneous(True)
performance_info_grid.set_column_spacing(12)
performance_info_grid.set_row_spacing(10)
performance_info_grid.set_margin_top(5)
performance_info_grid.get_style_context().add_provider(style_provider_grid, Gtk.STYLE_PROVIDER_PRIORITY_APPLICATION)
self.system_tab_grid.attach(performance_info_grid, 0, 1, 1, 1)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment