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

Unified Diff: chrome/browser/android/webapk/webapk_installer.cc

Issue 2221823002: Send orientation and display mode from Web Manifest to WebAPK server (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Merge branch 'master' into webapk_builder_impl22 Created 4 years, 4 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
« no previous file with comments | « no previous file | content/common/manifest_util_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/android/webapk/webapk_installer.cc
diff --git a/chrome/browser/android/webapk/webapk_installer.cc b/chrome/browser/android/webapk/webapk_installer.cc
index 79a12d031ab657f61e60c8adc079cfd02ddfdb24..3764492c26c4a9e529df7dd9ce5687dcfb47ccd8 100644
--- a/chrome/browser/android/webapk/webapk_installer.cc
+++ b/chrome/browser/android/webapk/webapk_installer.cc
@@ -22,6 +22,7 @@
#include "chrome/common/chrome_switches.h"
#include "components/version_info/version_info.h"
#include "content/public/browser/browser_thread.h"
+#include "content/public/common/manifest_util.h"
#include "jni/WebApkInstaller_jni.h"
#include "net/http/http_status_code.h"
#include "net/url_request/url_fetcher.h"
@@ -253,7 +254,11 @@ std::unique_ptr<webapk::WebApk> WebApkInstaller::BuildWebApkProto() {
web_app_manifest->set_short_name(
base::UTF16ToUTF8(shortcut_info_.short_name));
web_app_manifest->set_start_url(shortcut_info_.url.spec());
- // TODO(pkotwicz): Add "display mode" and "orientation" to proto.
+ web_app_manifest->set_orientation(
+ content::WebScreenOrientationLockTypeToString(
+ shortcut_info_.orientation));
+ web_app_manifest->set_display_mode(
+ content::WebDisplayModeToString(shortcut_info_.display));
web_app_manifest->set_background_color(
ColorToString(shortcut_info_.background_color));
web_app_manifest->set_theme_color(ColorToString(shortcut_info_.theme_color));
« no previous file with comments | « no previous file | content/common/manifest_util_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698