summaryrefslogtreecommitdiff
path: root/src/windows/misc.py
diff options
context:
space:
mode:
authorFlorent Le Coz <louiz@louiz.org>2014-08-01 16:00:01 +0200
committerFlorent Le Coz <louiz@louiz.org>2014-08-01 16:00:01 +0200
commit271fd662a18d0a289fa73c1f42885a451accb1b8 (patch)
tree269f43afb5f345a4cb0bc290366aa96c17cbae45 /src/windows/misc.py
parentba93f3f236e68b14d84c9bc621c638c4f79207f9 (diff)
downloadpoezio-271fd662a18d0a289fa73c1f42885a451accb1b8.tar.gz
poezio-271fd662a18d0a289fa73c1f42885a451accb1b8.tar.bz2
poezio-271fd662a18d0a289fa73c1f42885a451accb1b8.tar.xz
poezio-271fd662a18d0a289fa73c1f42885a451accb1b8.zip
Entirely remove the g_lock (used to avoid a few race conditions with ncures)
Diffstat (limited to 'src/windows/misc.py')
-rw-r--r--src/windows/misc.py17
1 files changed, 8 insertions, 9 deletions
diff --git a/src/windows/misc.py b/src/windows/misc.py
index 0f6bce59..07c91bbd 100644
--- a/src/windows/misc.py
+++ b/src/windows/misc.py
@@ -7,7 +7,7 @@ log = logging.getLogger(__name__)
import curses
-from . import Win, g_lock
+from . import Win
from theming import get_theme, to_curses_attr
class VerticalSeparator(Win):
@@ -19,9 +19,9 @@ class VerticalSeparator(Win):
Win.__init__(self)
def rewrite_line(self):
- with g_lock:
- self._win.vline(0, 0, curses.ACS_VLINE, self.height, to_curses_attr(get_theme().COLOR_VERTICAL_SEPARATOR))
- self._refresh()
+ self._win.vline(0, 0, curses.ACS_VLINE, self.height,
+ to_curses_attr(get_theme().COLOR_VERTICAL_SEPARATOR))
+ self._refresh()
def refresh(self):
log.debug('Refresh: %s', self.__class__.__name__)
@@ -53,9 +53,8 @@ class SimpleTextWin(Win):
def refresh(self):
log.debug('Refresh: %s', self.__class__.__name__)
- with g_lock:
- self._win.erase()
- for y, line in enumerate(self.built_lines):
- self.addstr_colored(line, y, 0)
- self._refresh()
+ self._win.erase()
+ for y, line in enumerate(self.built_lines):
+ self.addstr_colored(line, y, 0)
+ self._refresh()