Commit 03475079 authored by Becca Hughes's avatar Becca Hughes Committed by Commit Bot

Use separate product for Chrome Kaleidoscope

We have our own product in Feedback for Kaleidoscope
so we should use that for feedback.

BUG=1111981

Change-Id: I107a8d9a50557e6e1ffcb308a94ba5760e1c1062
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2343633Reviewed-by: default avatarAhmed Fakhry <afakhry@chromium.org>
Reviewed-by: default avatarMiriam Zimmerman <mutexlox@chromium.org>
Commit-Queue: Becca Hughes <beccahughes@chromium.org>
Cr-Commit-Position: refs/heads/master@{#796539}
parent 494d7c39
...@@ -115,7 +115,7 @@ void ShowFeedbackPage(const GURL& page_url, ...@@ -115,7 +115,7 @@ void ShowFeedbackPage(const GURL& page_url,
api->RequestFeedbackForFlow( api->RequestFeedbackForFlow(
description_template, description_placeholder_text, category_tag, description_template, description_placeholder_text, category_tag,
extra_diagnostics, page_url, flow, source == kFeedbackSourceAssistant, extra_diagnostics, page_url, flow, source == kFeedbackSourceAssistant,
include_bluetooth_logs); include_bluetooth_logs, source == kFeedbackSourceKaleidoscope);
} }
} // namespace chrome } // namespace chrome
...@@ -65,6 +65,8 @@ constexpr base::FilePath::CharType kBluetoothLogsFilePathOld[] = ...@@ -65,6 +65,8 @@ constexpr base::FilePath::CharType kBluetoothLogsFilePathOld[] =
constexpr char kBluetoothLogsAttachmentName[] = "bluetooth_logs.bz2"; constexpr char kBluetoothLogsAttachmentName[] = "bluetooth_logs.bz2";
constexpr char kBluetoothLogsAttachmentNameOld[] = "bluetooth_logs.old.bz2"; constexpr char kBluetoothLogsAttachmentNameOld[] = "bluetooth_logs.old.bz2";
constexpr int kKaleidoscopeProductId = 5192933;
// Getting the filename of a blob prepends a "C:\fakepath" to the filename. // Getting the filename of a blob prepends a "C:\fakepath" to the filename.
// This is undesirable, strip it if it exists. // This is undesirable, strip it if it exists.
std::string StripFakepath(const std::string& path) { std::string StripFakepath(const std::string& path) {
...@@ -126,7 +128,8 @@ void FeedbackPrivateAPI::RequestFeedbackForFlow( ...@@ -126,7 +128,8 @@ void FeedbackPrivateAPI::RequestFeedbackForFlow(
const GURL& page_url, const GURL& page_url,
api::feedback_private::FeedbackFlow flow, api::feedback_private::FeedbackFlow flow,
bool from_assistant, bool from_assistant,
bool include_bluetooth_logs) { bool include_bluetooth_logs,
bool from_kaleidoscope) {
if (browser_context_ && EventRouter::Get(browser_context_)) { if (browser_context_ && EventRouter::Get(browser_context_)) {
FeedbackInfo info; FeedbackInfo info;
info.description = description_template; info.description = description_template;
...@@ -162,6 +165,12 @@ void FeedbackPrivateAPI::RequestFeedbackForFlow( ...@@ -162,6 +165,12 @@ void FeedbackPrivateAPI::RequestFeedbackForFlow(
info.use_system_window_frame = info.use_system_window_frame =
std::make_unique<bool>(use_system_window_frame); std::make_unique<bool>(use_system_window_frame);
// If the feedback is from Kaleidoscope then this should use a custom
// product ID.
if (from_kaleidoscope) {
info.product_id = std::make_unique<int>(kKaleidoscopeProductId);
}
std::unique_ptr<base::ListValue> args = std::unique_ptr<base::ListValue> args =
feedback_private::OnFeedbackRequested::Create(info); feedback_private::OnFeedbackRequested::Create(info);
......
...@@ -43,7 +43,8 @@ class FeedbackPrivateAPI : public BrowserContextKeyedAPI { ...@@ -43,7 +43,8 @@ class FeedbackPrivateAPI : public BrowserContextKeyedAPI {
const GURL& page_url, const GURL& page_url,
api::feedback_private::FeedbackFlow flow, api::feedback_private::FeedbackFlow flow,
bool from_assistant = false, bool from_assistant = false,
bool include_bluetooth_logs = false); bool include_bluetooth_logs = false,
bool from_kaleidoscope = false);
// BrowserContextKeyedAPI implementation. // BrowserContextKeyedAPI implementation.
static BrowserContextKeyedAPIFactory<FeedbackPrivateAPI>* static BrowserContextKeyedAPIFactory<FeedbackPrivateAPI>*
......
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