Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(79)

Unified Diff: chrome/browser/media/router/mojo/media_router_mojo_impl.cc

Issue 2112673002: Removing references to Off the Record from MediaRouter (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/media/router/mojo/media_router_mojo_impl.cc
diff --git a/chrome/browser/media/router/mojo/media_router_mojo_impl.cc b/chrome/browser/media/router/mojo/media_router_mojo_impl.cc
index 9ba4318b0f292932144f542509f5e351429c539d..15a53db7280c5bdee03734cf77a16495c0f3559c 100644
--- a/chrome/browser/media/router/mojo/media_router_mojo_impl.cc
+++ b/chrome/browser/media/router/mojo/media_router_mojo_impl.cc
@@ -272,7 +272,7 @@ void MediaRouterMojoImpl::OnRoutesUpdated(
void MediaRouterMojoImpl::RouteResponseReceived(
const std::string& presentation_id,
- bool off_the_record,
+ bool incognito,
const std::vector<MediaRouteResponseCallback>& callbacks,
interfaces::MediaRoutePtr media_route,
mojo::String error_text,
@@ -285,12 +285,12 @@ void MediaRouterMojoImpl::RouteResponseReceived(
!error_text.get().empty() ? error_text.get() : "Unknown error.";
result = RouteRequestResult::FromError(
error, mojo::RouteRequestResultCodeFromMojo(result_code));
- } else if (media_route->off_the_record != off_the_record) {
+ } else if (media_route->incognito != incognito) {
std::string error = base::StringPrintf(
- "Mismatch in off the record status: request = %d, response = %d",
- off_the_record, media_route->off_the_record);
+ "Mismatch in incognito status: request = %d, response = %d", incognito,
+ media_route->incognito);
result = RouteRequestResult::FromError(
- error, RouteRequestResult::OFF_THE_RECORD_MISMATCH);
+ error, RouteRequestResult::INCOGNITO_MISMATCH);
} else {
result = RouteRequestResult::FromSuccess(
media_route.To<std::unique_ptr<MediaRoute>>(), presentation_id);
@@ -308,7 +308,7 @@ void MediaRouterMojoImpl::CreateRoute(
content::WebContents* web_contents,
const std::vector<MediaRouteResponseCallback>& callbacks,
base::TimeDelta timeout,
- bool off_the_record) {
+ bool incognito) {
DCHECK(thread_checker_.CalledOnValidThread());
if (!origin.is_valid()) {
@@ -326,7 +326,7 @@ void MediaRouterMojoImpl::CreateRoute(
RunOrDefer(base::Bind(&MediaRouterMojoImpl::DoCreateRoute,
base::Unretained(this), source_id, sink_id,
origin.is_empty() ? "" : origin.spec(), tab_id,
- callbacks, timeout, off_the_record));
+ callbacks, timeout, incognito));
}
void MediaRouterMojoImpl::JoinRoute(
@@ -336,7 +336,7 @@ void MediaRouterMojoImpl::JoinRoute(
content::WebContents* web_contents,
const std::vector<MediaRouteResponseCallback>& callbacks,
base::TimeDelta timeout,
- bool off_the_record) {
+ bool incognito) {
DCHECK(thread_checker_.CalledOnValidThread());
std::unique_ptr<RouteRequestResult> error_result;
@@ -361,7 +361,7 @@ void MediaRouterMojoImpl::JoinRoute(
RunOrDefer(base::Bind(&MediaRouterMojoImpl::DoJoinRoute,
base::Unretained(this), source_id, presentation_id,
origin.is_empty() ? "" : origin.spec(), tab_id,
- callbacks, timeout, off_the_record));
+ callbacks, timeout, incognito));
}
void MediaRouterMojoImpl::ConnectRouteByRouteId(
@@ -371,7 +371,7 @@ void MediaRouterMojoImpl::ConnectRouteByRouteId(
content::WebContents* web_contents,
const std::vector<MediaRouteResponseCallback>& callbacks,
base::TimeDelta timeout,
- bool off_the_record) {
+ bool incognito) {
DCHECK(thread_checker_.CalledOnValidThread());
if (!origin.is_valid()) {
@@ -388,7 +388,7 @@ void MediaRouterMojoImpl::ConnectRouteByRouteId(
RunOrDefer(base::Bind(&MediaRouterMojoImpl::DoConnectRouteByRouteId,
base::Unretained(this), source_id, route_id,
origin.is_empty() ? "" : origin.spec(), tab_id,
- callbacks, timeout, off_the_record));
+ callbacks, timeout, incognito));
}
void MediaRouterMojoImpl::TerminateRoute(const MediaRoute::Id& route_id) {
@@ -628,17 +628,17 @@ void MediaRouterMojoImpl::DoCreateRoute(
int tab_id,
const std::vector<MediaRouteResponseCallback>& callbacks,
base::TimeDelta timeout,
- bool off_the_record) {
+ bool incognito) {
std::string presentation_id = MediaRouterBase::CreatePresentationId();
DVLOG_WITH_INSTANCE(1) << "DoCreateRoute " << source_id << "=>" << sink_id
<< ", presentation ID: " << presentation_id;
media_route_provider_->CreateRoute(
source_id, sink_id, presentation_id, origin, tab_id,
- timeout > base::TimeDelta() ? timeout.InMilliseconds() : 0,
- off_the_record, base::Bind(&MediaRouterMojoImpl::RouteResponseReceived,
- base::Unretained(this), presentation_id,
- off_the_record, callbacks));
+ timeout > base::TimeDelta() ? timeout.InMilliseconds() : 0, incognito,
+ base::Bind(&MediaRouterMojoImpl::RouteResponseReceived,
+ base::Unretained(this), presentation_id, incognito,
+ callbacks));
}
void MediaRouterMojoImpl::DoJoinRoute(
@@ -648,16 +648,16 @@ void MediaRouterMojoImpl::DoJoinRoute(
int tab_id,
const std::vector<MediaRouteResponseCallback>& callbacks,
base::TimeDelta timeout,
- bool off_the_record) {
+ bool incognito) {
DVLOG_WITH_INSTANCE(1) << "DoJoinRoute " << source_id
<< ", presentation ID: " << presentation_id;
media_route_provider_->JoinRoute(
source_id, presentation_id, origin, tab_id,
- timeout > base::TimeDelta() ? timeout.InMilliseconds() : 0,
- off_the_record, base::Bind(&MediaRouterMojoImpl::RouteResponseReceived,
- base::Unretained(this), presentation_id,
- off_the_record, callbacks));
+ timeout > base::TimeDelta() ? timeout.InMilliseconds() : 0, incognito,
+ base::Bind(&MediaRouterMojoImpl::RouteResponseReceived,
+ base::Unretained(this), presentation_id, incognito,
+ callbacks));
}
void MediaRouterMojoImpl::DoConnectRouteByRouteId(
@@ -667,7 +667,7 @@ void MediaRouterMojoImpl::DoConnectRouteByRouteId(
int tab_id,
const std::vector<MediaRouteResponseCallback>& callbacks,
base::TimeDelta timeout,
- bool off_the_record) {
+ bool incognito) {
std::string presentation_id = MediaRouterBase::CreatePresentationId();
DVLOG_WITH_INSTANCE(1) << "DoConnectRouteByRouteId " << source_id
<< ", route ID: " << route_id
@@ -675,10 +675,10 @@ void MediaRouterMojoImpl::DoConnectRouteByRouteId(
media_route_provider_->ConnectRouteByRouteId(
source_id, route_id, presentation_id, origin, tab_id,
- timeout > base::TimeDelta() ? timeout.InMilliseconds() : 0,
- off_the_record, base::Bind(&MediaRouterMojoImpl::RouteResponseReceived,
- base::Unretained(this), presentation_id,
- off_the_record, callbacks));
+ timeout > base::TimeDelta() ? timeout.InMilliseconds() : 0, incognito,
+ base::Bind(&MediaRouterMojoImpl::RouteResponseReceived,
+ base::Unretained(this), presentation_id, incognito,
+ callbacks));
}
void MediaRouterMojoImpl::DoTerminateRoute(const MediaRoute::Id& route_id) {

Powered by Google App Engine
This is Rietveld 408576698