diff options
author | Pranam Lashkari <lpranam@collabora.com> | 2024-04-24 02:29:38 +0100 |
---|---|---|
committer | Pranam Lashkari <plashkari628@gmail.com> | 2024-04-25 20:27:25 +0100 |
commit | 38efd68c14eb2614a04ecacf09e526ef366ab24f (patch) | |
tree | ef7abb35c35882972eb91b5911bd24292f63a8d8 | |
parent | annotation: make comment section scrollable with mouse (diff) | |
download | online-38efd68c14eb2614a04ecacf09e526ef366ab24f.tar.gz online-38efd68c14eb2614a04ecacf09e526ef366ab24f.zip |
annotation: avoid explicit unselect before select
select function now can take care of reselection and layout update
Signed-off-by: Pranam Lashkari <lpranam@collabora.com>
Change-Id: I2a061643ec190d5b2d005b940923a28131ed6cb0
-rw-r--r-- | browser/src/layer/tile/CommentListSection.ts | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/browser/src/layer/tile/CommentListSection.ts b/browser/src/layer/tile/CommentListSection.ts index 609377fbb1..56ee4865f7 100644 --- a/browser/src/layer/tile/CommentListSection.ts +++ b/browser/src/layer/tile/CommentListSection.ts @@ -631,9 +631,8 @@ export class CommentSection extends CanvasSectionObject { } } else { - this.unselect(); annotation.reply(); - this.select(annotation); + this.select(annotation, true); annotation.focus(); } } @@ -649,11 +648,6 @@ export class CommentSection extends CanvasSectionObject { }.bind(this), /* isMod */ true); } else { - if (this.sectionProperties.docLayer._docType !== 'spreadsheet') { - this.unselect(); - this.select(annotation); - } - // Make sure that comment is not transitioning and comment menu is not open. var tempFunction = function() { setTimeout(function() { |