Commit 98c35f6f authored by Manuel Cortez's avatar Manuel Cortez

Removed a small error with threads being out of control

parent 2f488a5d
Pipeline #714 passed with stage
in 4 minutes and 5 seconds
...@@ -535,7 +535,7 @@ class Controller(object): ...@@ -535,7 +535,7 @@ class Controller(object):
del self.longpoll del self.longpoll
self.create_longpoll_thread(notify=True) self.create_longpoll_thread(notify=True)
# @wx_call_after @wx_call_after
def create_buffer(self, buffer_type="baseBuffer", buffer_title="", parent_tab=None, loadable=False, get_items=False, kwargs={}): def create_buffer(self, buffer_type="baseBuffer", buffer_title="", parent_tab=None, loadable=False, get_items=False, kwargs={}):
""" Create and insert a buffer in the specified place. """ Create and insert a buffer in the specified place.
@buffer_type str: name of the buffer type to be created. This should be a class in the buffers.py module. @buffer_type str: name of the buffer type to be created. This should be a class in the buffers.py module.
...@@ -551,9 +551,9 @@ class Controller(object): ...@@ -551,9 +551,9 @@ class Controller(object):
buffer.can_get_items = False buffer.can_get_items = False
self.buffers.append(buffer) self.buffers.append(buffer)
if parent_tab == None: if parent_tab == None:
wx.CallAfter(self.window.add_buffer, buffer.tab, buffer_title) self.window.add_buffer(buffer.tab, buffer_title)
else: else:
wx.CallAfter(self.window.insert_buffer, buffer.tab, buffer_title, self.window.search(parent_tab)) self.window.insert_buffer(buffer.tab, buffer_title, self.window.search(parent_tab))
if get_items: if get_items:
call_threaded(buffer.get_items) call_threaded(buffer.get_items)
......
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