From 271fd662a18d0a289fa73c1f42885a451accb1b8 Mon Sep 17 00:00:00 2001 From: Florent Le Coz Date: Fri, 1 Aug 2014 16:00:01 +0200 Subject: Entirely remove the g_lock (used to avoid a few race conditions with ncures) --- src/size_manager.py | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) (limited to 'src/size_manager.py') diff --git a/src/size_manager.py b/src/size_manager.py index 7e01d5d0..1cad83fd 100644 --- a/src/size_manager.py +++ b/src/size_manager.py @@ -3,8 +3,6 @@ Size Manager: used to check size boundaries of the whole window and specific tabs """ -from windows import g_lock - THRESHOLD_WIDTH_DEGRADE = 45 THRESHOLD_HEIGHT_DEGRADE = 10 @@ -27,26 +25,22 @@ class SizeManager(object): @property def tab_degrade_x(self): - with g_lock: - _, x = self.tab_scr.getmaxyx() + _, x = self.tab_scr.getmaxyx() return x < THRESHOLD_WIDTH_DEGRADE @property def tab_degrade_y(self): - with g_lock: - y, x = self.tab_scr.getmaxyx() + y, x = self.tab_scr.getmaxyx() return y < THRESHOLD_HEIGHT_DEGRADE @property def core_degrade_x(self): - with g_lock: - y, x = self.core_scr.getmaxyx() + y, x = self.core_scr.getmaxyx() return x < FULL_WIDTH_DEGRADE @property def core_degrade_y(self): - with g_lock: - y, x = self.core_scr.getmaxyx() + y, x = self.core_scr.getmaxyx() return y < FULL_HEIGHT_DEGRADE -- cgit v1.2.3