Bug 157291

Summary: File Upload: Photo upload name is always generic (image.jpg)
Product: WebKit Reporter: Jiewen Tan <jiewen_tan>
Component: FormsAssignee: Jiewen Tan <jiewen_tan>
Status: RESOLVED FIXED    
Severity: Normal CC: commit-queue, jiewen_tan, joepeck, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch none

Jiewen Tan
Reported 2016-05-02 18:12:09 PDT
File Upload: Photo upload name is always generic (image.jpg)
Attachments
Patch (7.01 KB, patch)
2016-05-02 18:21 PDT, Jiewen Tan
no flags
Patch (7.98 KB, patch)
2016-05-02 20:48 PDT, Jiewen Tan
no flags
Jiewen Tan
Comment 1 2016-05-02 18:12:40 PDT
Jiewen Tan
Comment 2 2016-05-02 18:21:34 PDT
Joseph Pecoraro
Comment 3 2016-05-02 18:45:44 PDT
Comment on attachment 277957 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=277957&action=review Rest of the patch looks good to me. > Source/WebKit2/Platform/spi/ios/PhotosSPI.h:34 > +#if USE(APPLE_INTERNAL_SDK) > + > +#import <Photos/Photos_Private.h> > + > +#endif Seems this should be defining the SPI if someone is building without the Internal SDK. Something like: ---- #if USE(APPLE_INTERNAL_SDK) ... #else @class PHAssetOriginalMetadataProperties; @interface PHAsset () - (PHAssetOriginalMetadataProperties *)originalMetadataProperties; - (void)fetchPropertySetsIfNeeded; @end #endif ---- Whatever is enough to get the iso-sim bot building! > Source/WebKit2/UIProcess/ios/forms/WKFileUploadPanel.mm:739 > + [result[0] fetchPropertySetsIfNeeded]; > + NSString *originalFilename = [[result[0] originalMetadataProperties] originalFilename]; > + ASSERT(originalFilename); This code is doing a lot of result[0], which is probably non-optimal. Could that be stored into a temporary variable? PHAsset *firstAsset = result[0];
Jiewen Tan
Comment 4 2016-05-02 20:48:34 PDT
WebKit Commit Bot
Comment 5 2016-05-03 18:03:19 PDT
Comment on attachment 277970 [details] Patch Clearing flags on attachment: 277970 Committed r200395: <http://trac.webkit.org/changeset/200395>
WebKit Commit Bot
Comment 6 2016-05-03 18:03:23 PDT
All reviewed patches have been landed. Closing bug.
Note You need to log in before you can comment on or make changes to this bug.