New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 687376 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Long OOO (go/where-is-mgiuca)
Closed: Jun 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: All
Pri: 3
Type: Bug



Sign in to add a comment

Web Share API's ShareService mojom should return error as enum, not string

Project Member Reported by constantina@google.com, Jan 31 2017

Issue description

Currently, ShareService returns an Optional string which contains an error message, if one occurred, or nullopt if successful. This should be changed to an enum for the error code, which the user of the API can map to a string.
 
Project Member

Comment 1 by bugdroid1@chromium.org, Mar 3 2017

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

commit 17e725cb4b30de97279784130bdb36b8a3162a26
Author: mgiuca <mgiuca@chromium.org>
Date: Fri Mar 03 02:57:23 2017

Web Share: Refactor Mojo interface to now return an enum error.

Previously returned a string containing the error message, which was a
source of inconsistency among the different platforms. Now all platforms
generate the same error messages for the user, and those are done in a
centralized place.

BUG= 687376 

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

[modify] https://crrev.com/17e725cb4b30de97279784130bdb36b8a3162a26/chrome/android/java/src/org/chromium/chrome/browser/webshare/ShareServiceImpl.java
[modify] https://crrev.com/17e725cb4b30de97279784130bdb36b8a3162a26/chrome/browser/webshare/share_service_impl.cc
[modify] https://crrev.com/17e725cb4b30de97279784130bdb36b8a3162a26/chrome/browser/webshare/share_service_impl_unittest.cc
[modify] https://crrev.com/17e725cb4b30de97279784130bdb36b8a3162a26/third_party/WebKit/LayoutTests/webshare/resources/mock-share-service.js
[modify] https://crrev.com/17e725cb4b30de97279784130bdb36b8a3162a26/third_party/WebKit/LayoutTests/webshare/share-arity.html
[modify] https://crrev.com/17e725cb4b30de97279784130bdb36b8a3162a26/third_party/WebKit/LayoutTests/webshare/share-error.html
[modify] https://crrev.com/17e725cb4b30de97279784130bdb36b8a3162a26/third_party/WebKit/LayoutTests/webshare/share-success.html
[modify] https://crrev.com/17e725cb4b30de97279784130bdb36b8a3162a26/third_party/WebKit/LayoutTests/webshare/share-types.html
[modify] https://crrev.com/17e725cb4b30de97279784130bdb36b8a3162a26/third_party/WebKit/Source/modules/webshare/NavigatorShare.cpp
[modify] https://crrev.com/17e725cb4b30de97279784130bdb36b8a3162a26/third_party/WebKit/public/platform/modules/webshare/webshare.mojom

Comment 2 by mgiuca@chromium.org, Jun 16 2017

Status: Fixed (was: Assigned)

Sign in to add a comment