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

Unified Diff: chrome/browser/media/router/presentation_helper.cc

Issue 1132903002: [MediaRouter] Add implementation of PresentationServiceDelegate (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addresses Derek's comments Created 5 years, 7 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/presentation_helper.cc
diff --git a/chrome/browser/media/router/media_route_id.h b/chrome/browser/media/router/presentation_helper.cc
similarity index 50%
copy from chrome/browser/media/router/media_route_id.h
copy to chrome/browser/media/router/presentation_helper.cc
index 7bdfb57415459a7a00cb5822d92f6e4897607def..bfd84dde962fc348b12e3e38214fb4ee5749e748 100644
--- a/chrome/browser/media/router/media_route_id.h
+++ b/chrome/browser/media/router/presentation_helper.cc
@@ -2,15 +2,15 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef CHROME_BROWSER_MEDIA_ROUTER_MEDIA_ROUTE_ID_H_
-#define CHROME_BROWSER_MEDIA_ROUTER_MEDIA_ROUTE_ID_H_
+#include "chrome/browser/media/router/presentation_helper.h"
-#include <string>
+#include "url/gurl.h"
namespace media_router {
-using MediaRouteId = std::string;
+bool IsValidPresentationUrl(const std::string& url) {
+ GURL gurl(url);
+ return gurl.is_valid() && gurl.SchemeIsHTTPOrHTTPS();
+}
} // namespace media_router
-
-#endif // CHROME_BROWSER_MEDIA_ROUTER_MEDIA_ROUTE_ID_H_

Powered by Google App Engine
This is Rietveld 408576698