New issue
Advanced search Search tips

Issue 733143 link

Starred by 1 user

Issue metadata

Status: Archived
Owner:
Closed: Jun 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 3
Type: Bug



Sign in to add a comment

Stop calling chrome.fileManagerPrivate.getDirectorySize() excessively

Project Member Reported by tetsui@chromium.org, Jun 14 2017

Issue description

Chrome Version: 51.0.3130.0 (Developer Build) (64-bit)
OS: ChromeOS

What steps will reproduce the problem?
(1) Open FilesApp.
(2) Copy multiple files to a directory by Ctrl-C Ctrl-V.
(3) Select the destination directory in the parent directory.
(4) Press space to open QuickView.

What is the expected result?
chrome.fileManagerPrivate.getDirectorySize() should not be called again before its callback.

What happens instead?
chrome.fileManagerPrivate.getDirectorySize() is called every time a file is copied.


MetadataBoxController.setDirectorySize_ should ignore the call when waiting callback.
https://codesearch.chromium.org/chromium/src/ui/file_manager/file_manager/foreground/js/metadata_box_controller.js?l=183&rcl=e2d1d93c5b61ce06be4b0620b7e40429365e3582

Related: https://codereview.chromium.org/2938763002/
 

Comment 1 by tetsui@chromium.org, Jun 14 2017

Summary: Stop calling chrome.fileManagerPrivate.getDirectorySize() excessively (was: Stop calling chrome.fileManagerPrivate.getDirectorySize())
Project Member

Comment 2 by bugdroid1@chromium.org, Jun 14 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/f34801c28ded7c524030c5fe565e9ac420c4ce28

commit f34801c28ded7c524030c5fe565e9ac420c4ce28
Author: tetsui <tetsui@chromium.org>
Date: Wed Jun 14 09:13:24 2017

Keep previous size in Directory QuickView.

In QuickView of a directory, size field was flickering becuase every
time the directory is updated, the size field was hidden until its size
is retrieved from fileManagerPrivate.getDirectorySize.
Now it show previous directory size until the new size is retrieved if
the selected directory is not changed.

BUG= 731484 , 733143 
TEST=manual
CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:closure_compilation

Review-Url: https://codereview.chromium.org/2938763002
Cr-Commit-Position: refs/heads/master@{#479333}

[modify] https://crrev.com/f34801c28ded7c524030c5fe565e9ac420c4ce28/ui/file_manager/file_manager/foreground/elements/files_metadata_box.js
[modify] https://crrev.com/f34801c28ded7c524030c5fe565e9ac420c4ce28/ui/file_manager/file_manager/foreground/js/metadata_box_controller.js

Comment 3 by tetsui@chromium.org, Jun 21 2017

Status: Started (was: Assigned)
Project Member

Comment 4 by bugdroid1@chromium.org, Jun 27 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/ab62a8b172d7d04bf021d9f010c9a1c9fa92d66b

commit ab62a8b172d7d04bf021d9f010c9a1c9fa92d66b
Author: tetsui <tetsui@chromium.org>
Date: Tue Jun 27 03:31:56 2017

Discard getDirectorySize request until the last one finishes.

fileManagerPrivate.getDirectorySize() was called excessively, because
MetadataBoxController.setDirectorySize_ was called before the last
callback had been finished.

BUG= 733143 
TEST=manual
CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:closure_compilation

Review-Url: https://codereview.chromium.org/2945793002
Cr-Commit-Position: refs/heads/master@{#482528}

[modify] https://crrev.com/ab62a8b172d7d04bf021d9f010c9a1c9fa92d66b/ui/file_manager/file_manager/foreground/js/metadata_box_controller.js

Comment 5 by tetsui@chromium.org, Jun 27 2017

Status: Fixed (was: Started)

Comment 6 by dchan@chromium.org, Jan 22 2018

Status: Archived (was: Fixed)

Sign in to add a comment