Bug 105140 - [Chromium] Dragging a .jpg to Finder saves it as .jpeg
Summary: [Chromium] Dragging a .jpg to Finder saves it as .jpeg
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Platform (show other bugs)
Version: 528+ (Nightly build)
Hardware: Other All
: P2 Minor
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-12-16 16:34 PST by Avi Drissman
Modified: 2012-12-17 14:42 PST (History)
5 users (show)

See Also:


Attachments
fix (2.59 KB, patch)
2012-12-16 17:49 PST, Avi Drissman
tony: review+
Details | Formatted Diff | Diff
fix nits (2.57 KB, patch)
2012-12-17 12:50 PST, Avi Drissman
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Avi Drissman 2012-12-16 16:34:17 PST
https://code.google.com/p/chromium/issues/detail?id=35811

This is a bug in the Chromium code in WebKit.
Comment 1 Avi Drissman 2012-12-16 16:34:33 PST
What steps will reproduce the problem?
1. Load an image with the .jpg extension.
2. Drag it to the desktop or a finder window.

What is the expected result?
Image should be saved with the same extension (.jpg). 

What happens instead?
Image is saved with a .jpeg extension.
Comment 2 Avi Drissman 2012-12-16 17:49:53 PST
Created attachment 179672 [details]
fix
Comment 3 Tony Chang 2012-12-17 12:17:12 PST
Comment on attachment 179672 [details]
fix

View in context: https://bugs.webkit.org/attachment.cgi?id=179672&action=review

> Source/WebCore/platform/chromium/ClipboardChromium.cpp:387
> +    // Keep the existing extension if it is valid for the MIME type of the
> +    // image, and replace it if it is not.

Nit: I think WebKit style would not include this comment since it's describing the code below.
Comment 4 Tony Chang 2012-12-17 12:19:14 PST
Comment on attachment 179672 [details]
fix

View in context: https://bugs.webkit.org/attachment.cgi?id=179672&action=review

> Source/WebCore/ChangeLog:12
> +
> +        * platform/chromium/ClipboardChromium.cpp:

There should be a sentence here explaining why there's no LayoutTest.  You can say it's not possible since it involves dragging to the desktop.  If you wanted to be more thorough, you could add a test to ManualTests.
Comment 5 Avi Drissman 2012-12-17 12:50:15 PST
Created attachment 179783 [details]
fix nits
Comment 6 WebKit Review Bot 2012-12-17 13:29:20 PST
Comment on attachment 179783 [details]
fix nits

Clearing flags on attachment: 179783

Committed r137934: <http://trac.webkit.org/changeset/137934>
Comment 7 WebKit Review Bot 2012-12-17 13:29:23 PST
All reviewed patches have been landed.  Closing bug.
Comment 8 noel gordon 2012-12-17 14:42:54 PST
(In reply to comment #4)
> There should be a sentence here explaining why there's no LayoutTest.  You can say it's not possible since it involves dragging to the desktop.  If you wanted to be more thorough, you could add a test to ManualTests.

Would a JPEG variant of fast/events/drag-image-filename.html work?