Skip to content

Fix AddBehavior being ignored when splitting multiple times in the same direction

Andrew Gunnerson requested to merge chenxiaolong/konsole:split into master

Previously, when eg. hitting Ctrl+Shift+( multiple times, the resulting panes would look like:

-------------------------------------
|        |        |        |        |
| Pane 1 | Pane 4 | Pane 3 | Pane 2 |
|        |        |        |        |
-------------------------------------

This was caused by AddBehavior being ignored when splitting more than once in the same orientation. The new pane would always be created at the index of the current pane. This commit fixes the problem so that AddBehavior::AddAfter will open a new pane downwards or to the right in all scenarios.

Merge request reports