summaryrefslogtreecommitdiff
path: root/chromium/components/arc/common
diff options
context:
space:
mode:
authorAllan Sandfeld Jensen <allan.jensen@qt.io>2018-08-24 12:15:48 +0200
committerAllan Sandfeld Jensen <allan.jensen@qt.io>2018-08-28 13:30:04 +0000
commitb014812705fc80bff0a5c120dfcef88f349816dc (patch)
tree25a2e2d9fa285f1add86aa333389a839f81a39ae /chromium/components/arc/common
parent9f4560b1027ae06fdb497023cdcaf91b8511fa74 (diff)
downloadqtwebengine-chromium-b014812705fc80bff0a5c120dfcef88f349816dc.tar.gz
BASELINE: Update Chromium to 68.0.3440.125
Change-Id: I23f19369e01f688e496f5bf179abb521ad73874f Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Diffstat (limited to 'chromium/components/arc/common')
-rw-r--r--chromium/components/arc/common/BUILD.gn17
-rw-r--r--chromium/components/arc/common/app.mojom89
-rw-r--r--chromium/components/arc/common/arc_bridge.mojom9
-rw-r--r--chromium/components/arc/common/auth.mojom42
-rw-r--r--chromium/components/arc/common/bluetooth.mojom11
-rw-r--r--chromium/components/arc/common/ime.mojom10
-rw-r--r--chromium/components/arc/common/input_method_manager.mojom50
-rw-r--r--chromium/components/arc/common/notifications.mojom22
-rw-r--r--chromium/components/arc/common/policy.mojom20
9 files changed, 203 insertions, 67 deletions
diff --git a/chromium/components/arc/common/BUILD.gn b/chromium/components/arc/common/BUILD.gn
index ce86afffc18..b8da88bd7a0 100644
--- a/chromium/components/arc/common/BUILD.gn
+++ b/chromium/components/arc/common/BUILD.gn
@@ -17,7 +17,6 @@ if (is_chromeos) {
"audio.mojom",
"auth.mojom",
"backup_settings.mojom",
- "bitmap.mojom",
"bluetooth.mojom",
"boot_phase_monitor.mojom",
"cast_receiver.mojom",
@@ -27,13 +26,13 @@ if (is_chromeos) {
"enterprise_reporting.mojom",
"file_system.mojom",
"ime.mojom",
+ "input_method_manager.mojom",
"intent_helper.mojom",
"kiosk.mojom",
"lock_screen.mojom",
"metrics.mojom",
"midis.mojom",
"net.mojom",
- "notifications.mojom",
"obb_mounter.mojom",
"oemcrypto.mojom",
"oemcrypto_daemon.mojom",
@@ -58,12 +57,23 @@ if (is_chromeos) {
public_deps = [
":media",
+ ":notifications",
"//device/usb/public/mojom",
- "//mojo/common:common_custom_types",
"//mojo/public/mojom/base",
"//ui/gfx/geometry/mojo",
]
}
+
+ mojom("notifications") {
+ sources = [
+ "bitmap.mojom",
+ "notifications.mojom",
+ ]
+
+ deps = [
+ ":media", # for gfx.mojom
+ ]
+ }
}
# Media related mojo interfaces. There are used by
@@ -81,7 +91,6 @@ mojom("media") {
]
public_deps = [
- "//mojo/common:common_custom_types",
"//ui/gfx/geometry/mojo",
]
}
diff --git a/chromium/components/arc/common/app.mojom b/chromium/components/arc/common/app.mojom
index e4f00485f06..450e6879561 100644
--- a/chromium/components/arc/common/app.mojom
+++ b/chromium/components/arc/common/app.mojom
@@ -2,36 +2,13 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
-// Next MinVersion: 28
+// Next MinVersion: 32
module arc.mojom;
import "components/arc/common/gfx.mojom";
import "components/arc/common/scale_factor.mojom";
-// Describes OrientationLock request.
-// Note: ChromeOS currently assumes the internal panel is always landscape.
-// All rotation angles mentioned here are measured clockwise.
-// DEPRECATED: OrientationLock passed by Wayland instead.
-[Extensible]
-enum OrientationLockDeprecated {
- NONE = 0,
- // Rotated 90 or 270 deg.
- PORTRAIT = 1,
- // Rotated 0 or 180 deg.
- LANDSCAPE = 2,
- // Keep the current orientation.
- CURRENT = 3,
- // Rotated 90 deg.
- PORTRAIT_PRIMARY = 4,
- // Rotated 0 deg.
- LANDSCAPE_PRIMARY = 5,
- // Rotated 270 deg.
- PORTRAIT_SECONDARY = 6,
- // Rotated 180 deg.
- LANDSCAPE_SECONDARY = 7,
-};
-
// Describes installation result.
struct InstallationResult {
string package_name;
@@ -45,8 +22,6 @@ struct AppInfo {
string activity;
[MinVersion=2] bool sticky; // true if the app cannot be uninstalled
[MinVersion=7] bool notifications_enabled;
- // DEPRECATED: OrientationLock passed by Wayland instead.
- [MinVersion=12] OrientationLockDeprecated orientation_lock_deprecated;
};
// Describes ARC package.
@@ -135,14 +110,26 @@ enum AppDiscoveryRequestState {
PHONESKY_RESULT_INVALID_DATA = 16,
};
+// Describes the type/category of an app data search result.
+[Extensible]
+enum AppDataResultType {
+ PERSON = 0, // Person search result.
+ NOTE_DOCUMENT = 1, // Note document search result.
+};
+
// Describes an app data search result.
struct AppDataResult {
// Intent uri to launch the result.
- string launch_intent_uri;
+ string launch_intent_uri@0;
// Label for the result.
- string label;
- // Icon information in png format. It could be null if not provided.
- array<uint8>? icon_png_data;
+ string label@1;
+ // Text information for the result.
+ string text@3;
+ // Icon information in png format. It could be null if not provided. Decoded
+ // in the utility process.
+ array<uint8>? icon_png_data@2;
+ // Type of this app data search result.
+ [MinVersion=28] AppDataResultType type@4;
};
// Describes the status of an app data search request, including completed
@@ -169,6 +156,22 @@ enum AppDataRequestState {
FAILED_TO_CALL_GLOBALQUERY = 8,
};
+// Describes app shortcut that is published by Android's ShortcutManager.
+struct AppShortcutItem {
+ // The ID of this shortcut. Unique within each publisher app and stable across
+ // devices.
+ string shortcut_id;
+
+ // The short description of this shortcut.
+ string short_label;
+
+ // The icon for this shortcut, decoded in the utility process.
+ array<uint8> icon_png;
+
+ // The package name of the publisher app.
+ [MinVersion=31] string? package_name;
+};
+
// Next method ID: 18
interface AppHost {
// Sends newly added ARC app to Chrome. This message is sent when ARC receives
@@ -224,11 +227,6 @@ interface AppHost {
// Notifies that task has been destroyed.
[MinVersion=4] OnTaskDestroyed@5(int32 task_id);
- // Notifies that task requested orientation lock.
- // DEPRECATED: OrientationLock passed by Wayland instead.
- [MinVersion=12] OnTaskOrientationLockRequestedDeprecated@12(
- int32 task_id, OrientationLockDeprecated lock);
-
// Notifies that task has been activated.
[MinVersion=4] OnTaskSetActive@6(int32 task_id);
@@ -256,7 +254,7 @@ interface AppHost {
};
// TODO(lhchavez): Migrate all request/response messages to Mojo.
-// Next method ID: 23
+// Next method ID: 25
interface AppInstance {
// DEPRECATED: Please use Init@21 instead.
InitDeprecated@0(AppHost host_ptr);
@@ -286,6 +284,11 @@ interface AppInstance {
[MinVersion=23] LaunchApp@18(string package_name, string activity,
int64 display_id);
+ // Sends a request to ARC for the Android launcher to launch the specified app
+ // shortcut.
+ [MinVersion=30] LaunchAppShortcutItem@24(
+ string package_name, string shortcut_id, int64 display_id);
+
[MinVersion=9] LaunchIntentDeprecated@12(string intent_uri,
Rect? dimension_on_screen);
@@ -340,13 +343,19 @@ interface AppInstance {
// happens) is ignored, and uninstall option should appear in the UI.
[MinVersion=2] UninstallPackage@5(string package_name);
- // Starts a query for Play Store apps.
- [MinVersion=20] GetRecentAndSuggestedAppsFromPlayStore@16(
- string query, int32 max_results) =>
- (AppDiscoveryRequestState state@1, array<AppDiscoveryResult> results@0);
+ // Sends a request to ARC to get app shortcuts for app with |package_name|. If
+ // |package_name| is empty, it will query for all launchable activities.
+ [MinVersion=29] GetAppShortcutItems@23(string package_name) =>
+ (array<AppShortcutItem> shortcut_items);
// Starts a query for app data, which is querying icing indexable contents.
[MinVersion=27] GetIcingGlobalQueryResults@22(
string query, int32 max_results) =>
(AppDataRequestState state, array<AppDataResult> results);
+
+ // Starts a query for Play Store apps.
+ [MinVersion=20] GetRecentAndSuggestedAppsFromPlayStore@16(
+ string query, int32 max_results) =>
+ (AppDiscoveryRequestState state@1,
+ array<AppDiscoveryResult> results@0);
};
diff --git a/chromium/components/arc/common/arc_bridge.mojom b/chromium/components/arc/common/arc_bridge.mojom
index 778c73dc266..6966f3e53be 100644
--- a/chromium/components/arc/common/arc_bridge.mojom
+++ b/chromium/components/arc/common/arc_bridge.mojom
@@ -18,6 +18,7 @@ import "components/arc/common/crash_collector.mojom";
import "components/arc/common/enterprise_reporting.mojom";
import "components/arc/common/file_system.mojom";
import "components/arc/common/ime.mojom";
+import "components/arc/common/input_method_manager.mojom";
import "components/arc/common/intent_helper.mojom";
import "components/arc/common/kiosk.mojom";
import "components/arc/common/lock_screen.mojom";
@@ -45,9 +46,9 @@ import "components/arc/common/volume_mounter.mojom";
import "components/arc/common/wake_lock.mojom";
import "components/arc/common/wallpaper.mojom";
-// Next MinVersion: 38
+// Next MinVersion: 39
// Deprecated method IDs: 101, 105
-// Next method ID: 143
+// Next method ID: 144
interface ArcBridgeHost {
// Keep the entries alphabetical. In order to do so without breaking
// compatibility with the ARC instance, explicitly assign each interface a
@@ -102,6 +103,10 @@ interface ArcBridgeHost {
// Notifies Chrome that the ImeInstance interface is ready.
[MinVersion=3] OnImeInstanceReady@110(ImeInstance instance_ptr);
+ // Notifies Chrome that the InputMethodManagerInstance interface is ready.
+ [MinVersion=38] OnInputMethodManagerInstanceReady@143(
+ InputMethodManagerInstance instance_ptr);
+
// Notifies Chrome that the IntentHelperInstance interface is ready.
[MinVersion=4] OnIntentHelperInstanceReady@111(
IntentHelperInstance instance_ptr);
diff --git a/chromium/components/arc/common/auth.mojom b/chromium/components/arc/common/auth.mojom
index e1975919ac2..5cf12bdbfec 100644
--- a/chromium/components/arc/common/auth.mojom
+++ b/chromium/components/arc/common/auth.mojom
@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-// Next MinVersion: 13
+// Next MinVersion: 14
module arc.mojom;
@@ -99,6 +99,32 @@ enum AccountCheckStatus {
// corresponding UMA callsite in Chrome arc::UpdateAuthAccountCheckStatus.
};
+// These values describe the result of ARC attempting to change supervision
+// state after an account type change.
+[Extensible]
+enum SupervisionChangeStatus {
+ // CloudDPC supervision was disabled successfully.
+ [MinVersion=13] CLOUD_DPC_DISABLED = 0,
+
+ // CloudDPC supervision was already disabled.
+ [MinVersion=13] CLOUD_DPC_ALREADY_DISABLED = 1,
+
+ // CloudDPC supervision was enabled successfully.
+ [MinVersion=13] CLOUD_DPC_ENABLED = 2,
+
+ // CloudDPC supervision was already enabled.
+ [MinVersion=13] CLOUD_DPC_ALREADY_ENABLED = 3,
+
+ // Invalid state returned from Chrome.
+ [MinVersion=13] INVALID_SUPERVISION_STATE = 4,
+
+ // Failed to disable CloudDPC due to an unspecified error.
+ [MinVersion=13] CLOUD_DPC_DISABLING_FAILED = 5,
+
+ // Failed to enable CloudDPC due to an unspecified error.
+ [MinVersion=13] CLOUD_DPC_ENABLING_FAILED = 6,
+};
+
// These values describe the type of the Chrome account to provision.
[Extensible]
enum ChromeAccountType {
@@ -144,8 +170,8 @@ struct AccountInfo {
[MinVersion=9] string? account_name@4;
// The authorization code that can be used in Android to sign in when
- // account_type is USER_ACCOUNT or ROBOT_ACCOUNT. If it is null in these
- // cases, sign-in will be skipped.
+ // account_type is USER_ACCOUNT, ROBOT_ACCOUNT or CHILD_ACCOUNT. If it is
+ // null in these cases, sign-in will be skipped.
string? auth_code@0;
// If account_type is ACTIVE_DIRECTORY_ACCOUNT, this contains an enrollment
@@ -160,7 +186,7 @@ struct AccountInfo {
bool is_managed@2;
};
-// Next Method ID: 11.
+// Next Method ID: 12.
interface AuthHost {
// Notifies Chrome that the authorization flow is completed and provides
// resulting |status|. If |initial_signin| is true then this indicates that
@@ -185,6 +211,13 @@ interface AuthHost {
// Reports result of account check.
[MinVersion=9] ReportAccountCheckStatus@9(AccountCheckStatus status);
+
+ // Reports to Chrome the result of changing the supervision state.
+ // Chrome informs ARC on every boot if a supervision transition is necessary
+ // or not (see https://crrev.com/c/1069031). ARC should report back only if
+ // a transition was necessary.
+ [MinVersion=13] ReportSupervisionChangeStatus@11(
+ SupervisionChangeStatus status);
};
// Next Method ID: 3
@@ -204,4 +237,5 @@ interface AuthInstance {
// of failure, other than SUCCESS.
[MinVersion=5] OnAccountInfoReady@1(
AccountInfo? account_info, [MinVersion=10] ArcSignInStatus status);
+
};
diff --git a/chromium/components/arc/common/bluetooth.mojom b/chromium/components/arc/common/bluetooth.mojom
index c3e0ebf5e4f..548f35b268d 100644
--- a/chromium/components/arc/common/bluetooth.mojom
+++ b/chromium/components/arc/common/bluetooth.mojom
@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-// Next MinVersion: 10
+// Next MinVersion: 11
module arc.mojom;
@@ -278,8 +278,8 @@ struct BluetoothSdpAttribute {
// change. This field is introduced between version 7 and 8, though
// MinVersion is not annotated because of breaking change, too.
// See details in the bug linked below.
- // TODO(crbug.com/767313): Use mojo/common/values.mojom, when new libmojo
- // (440057 or later) is rolled to ARC repository.
+ // TODO(crbug.com/767313): Use mojo/public/mojom/base/values.mojom, when new
+ // libmojo (440057 or later) is rolled to ARC repository.
string? json_value@3;
};
@@ -405,7 +405,7 @@ interface BluetoothHost {
=> (BluetoothGattStatus status);
};
-// Next Method ID: 19
+// Next Method ID: 20
interface BluetoothInstance {
// DEPRECATED: Please use Init@18 instead.
InitDeprecated@0(BluetoothHost host_ptr);
@@ -465,10 +465,11 @@ interface BluetoothInstance {
array<uint8> value,
[MinVersion=9] BluetoothGattDBAttributeType attribute_type)
=> (BluetoothGattStatus status);
+ [MinVersion=10] OnMTUReceived@19(BluetoothAddress remote_addr, uint16 mtu);
// Bluetooth SDP function
[MinVersion=5] OnGetSdpRecords@17(BluetoothStatus status,
- BluetoothAddress remove_addr,
+ BluetoothAddress remote_addr,
BluetoothUUID target_uuid,
array<BluetoothSdpRecord> records);
};
diff --git a/chromium/components/arc/common/ime.mojom b/chromium/components/arc/common/ime.mojom
index 032f539bd6a..732a37bcbd4 100644
--- a/chromium/components/arc/common/ime.mojom
+++ b/chromium/components/arc/common/ime.mojom
@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-// Next MinVersion: 9
+// Next MinVersion: 10
module arc.mojom;
@@ -34,7 +34,7 @@ struct CompositionSegment {
bool emphasized;
};
-// Next method ID: 4
+// Next method ID: 6
interface ImeHost {
// Notifies Chrome that the text input focus is changed.
OnTextInputTypeChanged@0(TextInputType type);
@@ -75,6 +75,12 @@ interface ImeHost {
[MinVersion=8] bool is_screen_coordinates // Whether or not the |rect|
// are in screen coordinates.
);
+
+ // Requests Chrome to hide the virtual keyboard.
+ // Howver, hiding can be canceled if a text field gets focus.
+ // TODO(yhanada): We might be able to remove this method by adding an argument
+ // to OnTextInputTypeChanged().
+ [MinVersion=9] RequestHideIme@5();
};
// Next method ID: 7
diff --git a/chromium/components/arc/common/input_method_manager.mojom b/chromium/components/arc/common/input_method_manager.mojom
new file mode 100644
index 00000000000..e7ffdec2b25
--- /dev/null
+++ b/chromium/components/arc/common/input_method_manager.mojom
@@ -0,0 +1,50 @@
+// Copyright 2018 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+module arc.mojom;
+
+// Represents the information of an Android IME.
+struct ImeInfo {
+ // The unique ID for the Android IME. Corresponds to InputMethodInfo.getId().
+ string ime_id;
+ // The user-displayed label for the IME. Corresponds to
+ // InputMethodInfo.loadLabel().
+ string display_name;
+ // Whether the IME is enabled or not. It's equivalent to whether the IME is
+ // in ENABLED_INPUT_METHODS settings.
+ bool enabled;
+ // intent: URL to open the settings activity of the IME.
+ string settings_url;
+};
+
+// This interface is called by container when Android's InputMethodManager state
+// is changed.
+// In Android container, ArcInputMethodService IME is pre-installed to bridge
+// Chrome OS's IME to Android apps. The bridge is defined in ime.mojom.
+//
+// Next method ID: 2
+interface InputMethodManagerHost {
+ // Notifies Chrome that active IME in Android is changed.
+ OnActiveImeChanged@0(string ime_id);
+
+ // Notifies Chrome of information of installed IMEs in Android.
+ // The passed list doesn't contain information of our bridge IME,
+ // ArcInputMethodService.
+ OnImeInfoChanged@1(array<ImeInfo> ime_infos);
+};
+
+// This interface provides methods to control Android's InputMethodManager.
+//
+// Next method ID: 3
+interface InputMethodManagerInstance {
+ // Establishes full-duplex communication with the host.
+ Init@0(InputMethodManagerHost host_ptr) => ();
+
+ // Enables/Disables an IME in Android. Calling this method will add/remove
+ // the specified IME to/from ENABLED_INPUT_METHODS settings.
+ EnableIme@1(string ime_id, bool enable) => (bool success);
+
+ // Switches active IME in Android.
+ SwitchImeTo@2(string ime_id) => (bool success);
+};
diff --git a/chromium/components/arc/common/notifications.mojom b/chromium/components/arc/common/notifications.mojom
index 12848868c07..ffcbcc5b67b 100644
--- a/chromium/components/arc/common/notifications.mojom
+++ b/chromium/components/arc/common/notifications.mojom
@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
-// Next MinVersion: 16
+// Next MinVersion: 17
module arc.mojom;
@@ -34,14 +34,16 @@ enum ArcNotificationType {
BUNDLED = 4,
};
-// These values are corresponding to the priorities of Android notification.
+// These values are corresponding to the priorities or importance of Android
+// notification.
[Extensible]
enum ArcNotificationPriority {
- MIN = -2, // same value as Notification.PRIORITY_MIN
- LOW = -1, // same value as Notification.PRIORITY_LOW
- DEFAULT = 0, // same value as Notification.PRIORITY_DEFAULT
- HIGH = 1, // same value as Notification.PRIORITY_HIGH
- MAX = 2, // same value as Notification.PRIORITY_MAX
+ NONE = -3,
+ MIN = -2,
+ LOW = -1,
+ DEFAULT = 0,
+ HIGH = 1,
+ MAX = 2,
};
// DEPRECATED
@@ -139,7 +141,7 @@ struct ArcNotificationData {
string? package_name;
};
-// Next Method ID: 6
+// Next Method ID: 7
interface NotificationsHost {
// Tells the Chrome that a notification is posted (created or updated) on
// Android. If you know that the notification exists, please consider to use
@@ -154,6 +156,10 @@ interface NotificationsHost {
[MinVersion=13]
// Notifies that an existing notiication is updated on Android.
OnNotificationUpdated@5(ArcNotificationData notification_data);
+
+ [MinVersion=16]
+ // Opens the Chrome OS message center.
+ OpenMessageCenter@6();
};
// Next Method ID: 6
diff --git a/chromium/components/arc/common/policy.mojom b/chromium/components/arc/common/policy.mojom
index 2c0f02589fe..f2a8804d84a 100644
--- a/chromium/components/arc/common/policy.mojom
+++ b/chromium/components/arc/common/policy.mojom
@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
-// Next MinVersion: 4
+// Next MinVersion: 5
module arc.mojom;
@@ -50,6 +50,15 @@ enum InstallErrorReason {
USER_INVALID = 10,
};
+// Should be kept in sync with device_management_backend.proto/
+// RemoteCommandResult/ResultType.
+[Extensible]
+enum CommandResultType {
+ IGNORED = 0, // The command was ignored as obsolete.
+ FAILURE = 1, // The command could not be executed.
+ SUCCESS = 2, // The command was successfully executed.
+};
+
// Next Method ID: 2
interface PolicyHost {
// Get policies from Chrome OS, as JSON-encoded dictionary with the policies'
@@ -76,7 +85,7 @@ interface PolicyHost {
InstallErrorReason reason);
};
-// Next Method ID: 3
+// Next Method ID: 4
interface PolicyInstance {
// DEPRECATED: Please use Init@2 instead.
InitDeprecated@0(PolicyHost host_ptr);
@@ -86,4 +95,11 @@ interface PolicyInstance {
// Indicates some policies have changed
OnPolicyUpdated@1();
+
+ // Forwards a command received from the management server. The payload is
+ // opaque to Chrome OS (it contains JSON from the RemoteCommand.payload field
+ // for the USER_ARC_COMMAND RemoteCommand - cf.
+ // device_management_backend.proto).
+ [MinVersion=4] OnCommandReceived@3(string command)
+ => (CommandResultType result);
};