diff options
author | Patrick McDermott <pj@pehjota.net> | 2017-10-25 14:45:41 (EDT) |
---|---|---|
committer | Patrick McDermott <pj@pehjota.net> | 2017-10-25 14:45:41 (EDT) |
commit | e62c6624caadedf32648a5525d799ba9bc12f800 (patch) | |
tree | f75a896faa847a8064d712a55cb82121e5d30260 /src | |
parent | 6f6a4991a97fc09a28ce6d6d5c80cec865fabed3 (diff) | |
download | marquee-e62c6624caadedf32648a5525d799ba9bc12f800.zip marquee-e62c6624caadedf32648a5525d799ba9bc12f800.tar.gz marquee-e62c6624caadedf32648a5525d799ba9bc12f800.tar.bz2 |
mq_notebook_remove_page(): Always keep at least one tab open
Diffstat (limited to 'src')
-rw-r--r-- | src/notebook.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/notebook.c b/src/notebook.c index b4e2864..0edd0d0 100644 --- a/src/notebook.c +++ b/src/notebook.c @@ -432,6 +432,10 @@ mq_notebook_remove_page(MqNotebook *notebook, MqTabPage *page) mq_tree_position(notebook->found_node)); g_free(notebook->found_node); + + if (mq_tree_size(MQ_TREE(notebook->tree)) == 1) { + mq_notebook_insert_top(notebook, NULL, TRUE); + } } gint |