From 7a72a369dbce5062fb1d5cad116fd006848ac432 Mon Sep 17 00:00:00 2001 From: bobzel Date: Wed, 12 Aug 2020 23:26:30 -0400 Subject: made addDocTab(..,"replace") reuse the right tab --- src/client/views/collections/CollectionDockingView.tsx | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'src/client/views/collections') diff --git a/src/client/views/collections/CollectionDockingView.tsx b/src/client/views/collections/CollectionDockingView.tsx index 998e41bd2..ffa0b6439 100644 --- a/src/client/views/collections/CollectionDockingView.tsx +++ b/src/client/views/collections/CollectionDockingView.tsx @@ -839,12 +839,8 @@ export class DockedFrameRenderer extends React.Component { } else if (location === "close") { return CollectionDockingView.CloseRightSplit(doc); } else if (location === "replace") { - const alias = CollectionDockingView.ReplaceTab(doc, this._stack); - if (alias) { - runInAction(() => this._document = alias); - return true; - } - return false; + CollectionDockingView.UseRightSplit(doc); + return true; } else {// if (location === "inPlace") { return CollectionDockingView.Instance.AddTab(this._stack, doc, libraryPath); } -- cgit v1.2.3-70-g09d2