It's hardly possible to have similar effect than on KitKat due to nature of recents in LP. They have completely different layout and functionality. E.g. it's possible to dismiss only those tasks that are visible since there are no views at all for those tasks that are currently not on screen. So GB has to clear visible stack than check if there are more tasks available, and if yes, wait a bit until recents panel creates views for those tasks that should become visible and only then it's possible to dismiss them. This results in effect you described. I was trying many different approaches but this is the best I could come up with so far (spent quite a lot of time with it to figure it out). If there's anyone having experience with different implementation seen in some of the custom ROMs that seems to work better, I can look into it again.
I was kind of waiting for who is going to be the first to ask this
Long-press would be suitable but cannot be used as it's already occupied.
Looks like having another option is inevitable.
I highly doubt GB has anything to do with this app. I just don't see any reason. GB is operating within system processes like SystemUI and services. It doesn't change anything about 3rd party apps.
I was skeptical about that but now i am sure its GB causing the issue. I disabled all other modules except GB and its still causing the symptoms. As soon as I disabled GravityBox, everything come back to normal. I tried this on different device and its working fine. May be because i modded systemui and android. Policy. Jar before appling xposed? But why thjs specific app