Reland: Gallery: skip to write thumbnail data if there isn't enough space.
commit5ccf32e53447e89eac516ab43d8408a0f6c2fda6
authoryawano <yawano@chromium.org>
Tue, 8 Sep 2015 02:41:59 +0000 (7 19:41 -0700)
committerCommit bot <commit-bot@chromium.org>
Tue, 8 Sep 2015 02:42:27 +0000 (8 02:42 +0000)
treeb6b19986e99dfb545f9a29689b2b45b888fb4085
parent48757dcab33604f0f30016700fb3fc32dd38bf3b
Reland: Gallery: skip to write thumbnail data if there isn't enough space.

The original CL is the following and it has an issue that unit test
fails on Debug build. With this CL, in addition to the original CL,
fixed the unit test by measuring the thumbnail size at runtime.

The original CL:
patch from issue 1304933004 at patchset 60001 (http://crrev.com/1304933004#ps60001)
Committed: https://crrev.com/475854c54374f59e702784c423e8fd45cf822542
Cr-Commit-Position: refs/heads/master@{#346820}

Reverted by: crrev.com/1309983007

BUG=526904
TEST=browser_tests:GalleryJsTest.ExifEncoderTest

Review URL: https://codereview.chromium.org/1330643004

Cr-Commit-Position: refs/heads/master@{#347657}
chrome/browser/chromeos/file_manager/gallery_jstest.cc
ui/file_manager/gallery/js/image_editor/exif_encoder.js
ui/file_manager/gallery/js/image_editor/exif_encoder_unittest.js
ui/file_manager/gallery/js/image_editor/image_encoder.js