summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authormathieui <mathieui@mathieui.net>2014-04-23 20:05:51 +0200
committermathieui <mathieui@mathieui.net>2014-04-23 20:05:51 +0200
commit3bfe93824c374b8c91aad177ff3e29b20c023030 (patch)
tree908dc9f74fee16395c773326771963956b4fc283 /src
parentefa6b4254df75a3c3fb41398f4efe020bd9a87b1 (diff)
downloadpoezio-3bfe93824c374b8c91aad177ff3e29b20c023030.tar.gz
poezio-3bfe93824c374b8c91aad177ff3e29b20c023030.tar.bz2
poezio-3bfe93824c374b8c91aad177ff3e29b20c023030.tar.xz
poezio-3bfe93824c374b8c91aad177ff3e29b20c023030.zip
Wrap yet another curses operation with a lock
Diffstat (limited to 'src')
-rw-r--r--src/tabs/basetabs.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/tabs/basetabs.py b/src/tabs/basetabs.py
index a7a16960..1e7564dc 100644
--- a/src/tabs/basetabs.py
+++ b/src/tabs/basetabs.py
@@ -35,6 +35,7 @@ from decorators import refresh_wrapper
from logger import logger
from text_buffer import TextBuffer
from theming import get_theme
+from windows import g_lock
MIN_WIDTH = 42
@@ -180,7 +181,8 @@ class Tab(object):
@staticmethod
def resize(scr):
- Tab.size = (Tab.height, Tab.width) = scr.getmaxyx()
+ with g_lock:
+ Tab.size = (Tab.height, Tab.width) = scr.getmaxyx()
if Tab.height < MIN_HEIGHT or Tab.width < MIN_WIDTH:
Tab.visible = False
else: