Commit 44368530 authored by Bram Schoenmakers's avatar Bram Schoenmakers

When the last column is deleted, show the add column window

parent e91e9cab
...@@ -155,8 +155,11 @@ class UIApplication(CLIApplicationBase): ...@@ -155,8 +155,11 @@ class UIApplication(CLIApplicationBase):
lambda: self._update_view(self.viewwidget.data)) lambda: self._update_view(self.viewwidget.data))
def hide_viewwidget(): def hide_viewwidget():
self._viewwidget_visible = False # prevent the view widget to be hidden when the last column was
self._blur_commandline() # deleted
if self.columns.contents:
self._viewwidget_visible = False
self._blur_commandline()
urwid.connect_signal(self.viewwidget, 'close', hide_viewwidget) urwid.connect_signal(self.viewwidget, 'close', hide_viewwidget)
...@@ -376,7 +379,7 @@ class UIApplication(CLIApplicationBase): ...@@ -376,7 +379,7 @@ class UIApplication(CLIApplicationBase):
if self.columns.contents: if self.columns.contents:
self.columns.focus_position = focus self.columns.focus_position = focus
else: else:
self._focus_commandline() self._append_column()
except IndexError: except IndexError:
# no columns # no columns
pass pass
......
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