Commit 5e7a6ac8 authored by Andy Lu's avatar Andy Lu Committed by Commit Bot

ios: Change Open URLs in Incognito shortcut parameter from URLs to URL.

Changed the parameter name from "Open {URLs} in Incognito" to
"Open {URL} in Incognito" for the Open URLs in Chrome Incognito Siri
shortcut. This makes more sense since the UI shows one URL to enter
at a time, and only one URL can be entered in that field. Added in the
new screenshot associated with this parameter change.

Bug: 1115243
Change-Id: I0a821b36c838b1b033f745875f11c99c046ef0a5
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2350236Reviewed-by: default avatarMark Cogan <marq@chromium.org>
Reviewed-by: default avatarJustin Cohen <justincohen@chromium.org>
Commit-Queue: Andy Lu <andyhylu@google.com>
Cr-Commit-Position: refs/heads/master@{#797273}
parent 63b5f989
...@@ -208,11 +208,11 @@ std::vector<GURL> createGURLVectorFromIntentURLs(NSArray<NSURL*>* intentURLs) { ...@@ -208,11 +208,11 @@ std::vector<GURL> createGURLVectorFromIntentURLs(NSArray<NSURL*>* intentURLs) {
base::mac::ObjCCastStrict<OpenInChromeIncognitoIntent>( base::mac::ObjCCastStrict<OpenInChromeIncognitoIntent>(
userActivity.interaction.intent); userActivity.interaction.intent);
if (!intent.urls || intent.urls.count == 0) { if (!intent.url || intent.url.count == 0) {
return NO; return NO;
} }
std::vector<GURL> URLs = createGURLVectorFromIntentURLs(intent.urls); std::vector<GURL> URLs = createGURLVectorFromIntentURLs(intent.url);
AppStartupParameters* startupParams = AppStartupParameters* startupParams =
[[AppStartupParameters alloc] initWithURLs:URLs]; [[AppStartupParameters alloc] initWithURLs:URLs];
......
...@@ -465,7 +465,7 @@ TEST_F(UserActivityHandlerTest, ContinueUserActivityIntentIncognitoBackground) { ...@@ -465,7 +465,7 @@ TEST_F(UserActivityHandlerTest, ContinueUserActivityIntentIncognitoBackground) {
OpenInChromeIncognitoIntent* intent = OpenInChromeIncognitoIntent* intent =
[[OpenInChromeIncognitoIntent alloc] init]; [[OpenInChromeIncognitoIntent alloc] init];
intent.urls = urls; intent.url = urls;
INInteraction* interaction = [[INInteraction alloc] initWithIntent:intent INInteraction* interaction = [[INInteraction alloc] initWithIntent:intent
response:nil]; response:nil];
...@@ -487,8 +487,8 @@ TEST_F(UserActivityHandlerTest, ContinueUserActivityIntentIncognitoBackground) { ...@@ -487,8 +487,8 @@ TEST_F(UserActivityHandlerTest, ContinueUserActivityIntentIncognitoBackground) {
AppStartupParameters* startupParameters = AppStartupParameters* startupParameters =
(AppStartupParameters*)value; (AppStartupParameters*)value;
const GURL calledURL = startupParameters.externalURL; const GURL calledURL = startupParameters.externalURL;
EXPECT_TRUE((int)[intent.urls count] == 3); EXPECT_TRUE((int)[intent.url count] == 3);
return [intent.urls containsObject:(net::NSURLWithGURL(calledURL))]; return [intent.url containsObject:(net::NSURLWithGURL(calledURL))];
} else { } else {
return YES; return YES;
} }
...@@ -576,7 +576,7 @@ TEST_F(UserActivityHandlerTest, ContinueUserActivityIntentIncognitoForeground) { ...@@ -576,7 +576,7 @@ TEST_F(UserActivityHandlerTest, ContinueUserActivityIntentIncognitoForeground) {
OpenInChromeIncognitoIntent* intent = OpenInChromeIncognitoIntent* intent =
[[OpenInChromeIncognitoIntent alloc] init]; [[OpenInChromeIncognitoIntent alloc] init];
intent.urls = urls; intent.url = urls;
INInteraction* interaction = [[INInteraction alloc] initWithIntent:intent INInteraction* interaction = [[INInteraction alloc] initWithIntent:intent
response:nil]; response:nil];
...@@ -598,8 +598,8 @@ TEST_F(UserActivityHandlerTest, ContinueUserActivityIntentIncognitoForeground) { ...@@ -598,8 +598,8 @@ TEST_F(UserActivityHandlerTest, ContinueUserActivityIntentIncognitoForeground) {
AppStartupParameters* startupParameters = AppStartupParameters* startupParameters =
(AppStartupParameters*)value; (AppStartupParameters*)value;
const GURL calledURL = startupParameters.externalURL; const GURL calledURL = startupParameters.externalURL;
EXPECT_TRUE((int)[intent.urls count] == 3); EXPECT_TRUE((int)[intent.url count] == 3);
return [intent.urls containsObject:(net::NSURLWithGURL(calledURL))]; return [intent.url containsObject:(net::NSURLWithGURL(calledURL))];
} else { } else {
return YES; return YES;
} }
......
...@@ -215,17 +215,17 @@ ...@@ -215,17 +215,17 @@
<key>INIntentIneligibleForSuggestions</key> <key>INIntentIneligibleForSuggestions</key>
<true/> <true/>
<key>INIntentInput</key> <key>INIntentInput</key>
<string>urls</string> <string>url</string>
<key>INIntentLastParameterTag</key> <key>INIntentLastParameterTag</key>
<integer>4</integer> <integer>4</integer>
<key>INIntentManagedParameterCombinations</key> <key>INIntentManagedParameterCombinations</key>
<dict> <dict>
<key>urls</key> <key>url</key>
<dict> <dict>
<key>INIntentParameterCombinationSupportsBackgroundExecution</key> <key>INIntentParameterCombinationSupportsBackgroundExecution</key>
<true/> <true/>
<key>INIntentParameterCombinationTitle</key> <key>INIntentParameterCombinationTitle</key>
<string>Open ${urls} in Incognito</string> <string>Open ${url} in Incognito</string>
<key>INIntentParameterCombinationTitleID</key> <key>INIntentParameterCombinationTitleID</key>
<string>6TwrYB</string> <string>6TwrYB</string>
<key>INIntentParameterCombinationUpdatesLinked</key> <key>INIntentParameterCombinationUpdatesLinked</key>
...@@ -240,20 +240,20 @@ ...@@ -240,20 +240,20 @@
<key>INIntentParameterConfigurable</key> <key>INIntentParameterConfigurable</key>
<true/> <true/>
<key>INIntentParameterDisplayName</key> <key>INIntentParameterDisplayName</key>
<string>URLs</string> <string>URL</string>
<key>INIntentParameterDisplayNameID</key> <key>INIntentParameterDisplayNameID</key>
<string>C8MCpv</string> <string>C8MCpv</string>
<key>INIntentParameterDisplayPriority</key> <key>INIntentParameterDisplayPriority</key>
<integer>1</integer> <integer>1</integer>
<key>INIntentParameterName</key> <key>INIntentParameterName</key>
<string>urls</string> <string>url</string>
<key>INIntentParameterPromptDialogs</key> <key>INIntentParameterPromptDialogs</key>
<array> <array>
<dict> <dict>
<key>INIntentParameterPromptDialogCustom</key> <key>INIntentParameterPromptDialogCustom</key>
<true/> <true/>
<key>INIntentParameterPromptDialogFormatString</key> <key>INIntentParameterPromptDialogFormatString</key>
<string>What URLs?</string> <string>What URL?</string>
<key>INIntentParameterPromptDialogFormatStringID</key> <key>INIntentParameterPromptDialogFormatStringID</key>
<string>sNz7Cu</string> <string>sNz7Cu</string>
<key>INIntentParameterPromptDialogType</key> <key>INIntentParameterPromptDialogType</key>
......
...@@ -955,7 +955,7 @@ Because your account is managed by <ph name="HOSTED_DOMAIN">$1<ex>google.com</ex ...@@ -955,7 +955,7 @@ Because your account is managed by <ph name="HOSTED_DOMAIN">$1<ex>google.com</ex
Opens the inputted URLs in Google Chrome in Incognito. Opens the inputted URLs in Google Chrome in Incognito.
</message> </message>
<message name="IDS_IOS_INTENTS_OPEN_IN_CHROME_INCOGNITO_PARAMETER_COMBINATION_TITLE" desc="Apple Shortcuts.app format for displaying the URL input [iOS only]."> <message name="IDS_IOS_INTENTS_OPEN_IN_CHROME_INCOGNITO_PARAMETER_COMBINATION_TITLE" desc="Apple Shortcuts.app format for displaying the URL input [iOS only].">
Open ${urls} in Incognito Open ${url} in Incognito
</message> </message>
<message name="IDS_IOS_INTENTS_SEARCH_IN_CHROME_DESCRIPTION" desc="Siri Shortcut for search in chrome description [iOS only]."> <message name="IDS_IOS_INTENTS_SEARCH_IN_CHROME_DESCRIPTION" desc="Siri Shortcut for search in chrome description [iOS only].">
Start a search in a new Chrome tab. Start a search in a new Chrome tab.
......
6bd0e2112cf7b407cc5ea7adee64a55981d83751 d2895617942b5b046ac5584ed3ebe037448c3288
\ No newline at end of file \ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment