Upstream version 7.36.153.0 50/23050/1
authorEurogiciel-BOT <eurogiciel.tizen@gmail.com>
Mon, 16 Jun 2014 13:41:14 +0000 (13:41 +0000)
committerEurogiciel-BOT <eurogiciel.tizen@gmail.com>
Mon, 16 Jun 2014 13:41:14 +0000 (13:41 +0000)
Upstream commit-id a1c1aa3bdadcde86e0331db86093a0c73fcfb7af

Change-Id: Iebbff0888a6e9f6087e6783c51630ffb9e4d9d46
Signed-off-by: Eurogiciel-BOT <eurogiciel.tizen@gmail.com>
52 files changed:
packaging/crosswalk.spec
src/.DEPS.git
src/DEPS
src/base/base.gypi
src/content/child/runtime_features.cc
src/content/public/android/java/src/org/chromium/content/browser/ContentViewRenderView.java
src/third_party/WebKit/Source/web/WebRuntimeFeatures.cpp
src/third_party/WebKit/public/web/WebRuntimeFeatures.h
src/xwalk/DEPS.xwalk
src/xwalk/VERSION
src/xwalk/app/tools/android/customize.py
src/xwalk/app/tools/android/gyp/javac.py
src/xwalk/app/tools/android/make_apk.py
src/xwalk/application/browser/application.cc
src/xwalk/application/browser/application.h
src/xwalk/application/browser/application_tizen.cc
src/xwalk/application/browser/application_tizen.h
src/xwalk/application/common/application_data.cc
src/xwalk/application/common/application_data.h
src/xwalk/application/common/application_manifest_constants.cc
src/xwalk/application/common/application_manifest_constants.h
src/xwalk/application/common/security_policy.cc
src/xwalk/application/common/security_policy.h
src/xwalk/experimental/native_file_system/virtual_root_provider_android.cc
src/xwalk/experimental/native_file_system/virtual_root_provider_tizen.cc
src/xwalk/extensions/test/external_extension_multi_process.cc
src/xwalk/packaging/crosswalk.spec
src/xwalk/runtime/android/core/src/org/xwalk/core/XWalkContent.java
src/xwalk/runtime/android/core/src/org/xwalk/core/XWalkPathHelper.java [new file with mode: 0644]
src/xwalk/runtime/android/core/src/org/xwalk/core/XWalkView.java
src/xwalk/runtime/android/core/src/org/xwalk/core/extension/XWalkExtensionManager.java
src/xwalk/runtime/app/android/xwalk_jni_registrar.cc
src/xwalk/runtime/browser/android/xwalk_content.cc
src/xwalk/runtime/browser/android/xwalk_path_helper.cc [new file with mode: 0644]
src/xwalk/runtime/browser/android/xwalk_path_helper.h [new file with mode: 0644]
src/xwalk/runtime/browser/devtools/xwalk_devtools_browsertest.cc
src/xwalk/runtime/browser/runtime.cc
src/xwalk/runtime/browser/runtime.h
src/xwalk/runtime/browser/runtime_resource_dispatcher_host_delegate_android.cc
src/xwalk/runtime/browser/runtime_resource_dispatcher_host_delegate_android.h
src/xwalk/runtime/browser/xwalk_runtime_browsertest.cc
src/xwalk/runtime/renderer/tizen/xwalk_content_renderer_client_tizen.cc
src/xwalk/runtime/renderer/tizen/xwalk_content_renderer_client_tizen.h
src/xwalk/test/android/data/native_file_system.html [new file with mode: 0644]
src/xwalk/test/android/runtime_client/javatests/src/org/xwalk/runtime/client/test/NativeFileSystemTest.java [new file with mode: 0644]
src/xwalk/test/android/runtime_client_embedded/javatests/src/org/xwalk/runtime/client/embedded/test/NativeFileSystemTest.java [new file with mode: 0644]
src/xwalk/test/android/util/runtime_client/src/org/xwalk/test/util/RuntimeClientApiTestBase.java
src/xwalk/test/base/in_process_browser_test.cc
src/xwalk/test/base/in_process_browser_test.h
src/xwalk/xwalk.gyp
src/xwalk/xwalk_android.gypi
src/xwalk/xwalk_android_tests.gypi

index be4777e..b9775a7 100644 (file)
@@ -1,18 +1,22 @@
 %bcond_with x
 %bcond_with wayland
 
-%ifarch x86_64
+%ifarch x86_64 %{arm}
+### x86_64
 # NaCl build on 64bit system require libc 32bit to build the 32 IRT.
 # While Tizen 64bit image does not offer 32bit packages at all,
 # check https://bugs.tizen.org/jira/browse/PTREL-803 for details.
 # So disable nacl for 64bit now.
+### ARM
+# Due to OBS build for ARM some files needed by NaCl to be build
+# are not present.
 %define _disable_nacl 1
 %else
 %define _disable_nacl 0
 %endif
 
 Name:           crosswalk
-Version:        7.36.152.0
+Version:        7.36.153.0
 Release:        0
 Summary:        Crosswalk is an app runtime based on Chromium
 License:        (BSD-3-Clause and LGPL-2.1+)
@@ -56,6 +60,7 @@ BuildRequires:  pkgconfig(libdrm)
 BuildRequires:  pkgconfig(libexif)
 BuildRequires:  pkgconfig(libpci)
 BuildRequires:  pkgconfig(libpulse)
+BuildRequires:  pkgconfig(libtzplatform-config)
 BuildRequires:  pkgconfig(libudev)
 BuildRequires:  pkgconfig(libxml-2.0)
 BuildRequires:  pkgconfig(libxslt)
@@ -160,7 +165,7 @@ if [ -n "${BUILDDIR_NAME}" ]; then
 fi
 
 %if %{with wayland}
-GYP_EXTRA_FLAGS="${GYP_EXTRA_FLAGS} -Duse_ozone=1 -Denable_ozone_wayland_vkb=1 -Denable_xdg_shell=1"
+GYP_EXTRA_FLAGS="${GYP_EXTRA_FLAGS} -Duse_ozone=1 -Denable_ozone_wayland_vkb=1 -Denable_xdg_shell=0"
 %endif
 
 GYP_EXTRA_FLAGS="${GYP_EXTRA_FLAGS} -Ddisable_nacl=%{_disable_nacl}"
index 6518637..71bea0a 100644 (file)
@@ -4,19 +4,33 @@
 # SEE http://code.google.com/p/chromium/wiki/UsingGit
 # FOR HOW TO ROLL DEPS
 vars = {
-    'ffmpeg_hash':
-         '@ac4a9f31fe2610bd146857bbd55d7a260003a888',
     'webkit_url':
          'https://chromium.googlesource.com/chromium/blink.git',
     'git_url':
          'https://chromium.googlesource.com',
     'webkit_rev':
-         '@0a2c3c6e6bc0f036aa5a86baadeb9b0f6946efce',
+         '@6906abdf7000dfa89f383060c5397496342bc474',
     'angle_revision':
          '74697cf2064c0a2c0d7e1b1b28db439286766a05'
 }
 
 deps = {
+    'build':
+        Var('git_url') + '/chromium/tools/build.git@ab76c6104de10e18d1e0beb6405964550ccfe274',
+    'build/scripts/command_wrapper/bin':
+        Var('git_url') + '/chromium/tools/command_wrapper/bin.git@2eeebba9a512cae9e4e9312f5ec728dbdad80bd0',
+    'build/scripts/gsd_generate_index':
+        Var('git_url') + '/chromium/tools/gsd_generate_index.git@d2f5d5a5d212d8fb337d751c0351644a6ac83ac8',
+    'build/scripts/private/data/reliability':
+        Var('git_url') + '/chromium/src.git@b0936d257dbc943ee00dd91a86d659ea346b135b',
+    'build/scripts/tools/deps2git':
+        Var('git_url') + '/chromium/tools/deps2git.git@05bbcc31bde9ab58b6e8f8d231088f2467480314',
+    'build/third_party/lighttpd':
+        Var('git_url') + '/chromium/deps/lighttpd.git@9dfa55d15937a688a92cbf2b7a8621b0927d06eb',
+    'depot_tools':
+        Var('git_url') + '/chromium/tools/depot_tools.git@c4396a1b4e231e3b271e36d7b76e280e89245b04',
+    'src':
+        Var('git_url') + '/chromium/src.git@5378fff02dd75b1bb75b472060735a56bff45171',
     'src/breakpad/src':
         Var('git_url') + '/external/google-breakpad/src.git@c7c6e51faeb9c1e8fbe285a1b28a5039b345f139',
     'src/chrome/browser/resources/pdf/html_office':
@@ -58,7 +72,7 @@ deps = {
     'src/third_party/cld_2/src':
         Var('git_url') + '/external/cld2.git@3fced387543ba9bed402923b3c6feb459fb61f58',
     'src/third_party/ffmpeg':
-        Var('git_url') + '/chromium/third_party/ffmpeg.git' + Var('ffmpeg_hash'),
+        Var('git_url') + '/chromium/deps/ffmpeg.git@95191a6415e5ee6ca1be0686ad14b68136930eaa',
     'src/third_party/flac':
         Var('git_url') + '/chromium/deps/flac.git@71e33f190a7bb144fe4e2014897b8d15c8247198',
     'src/third_party/hunspell':
@@ -144,7 +158,7 @@ deps = {
     'src/third_party/webpagereplay':
         Var('git_url') + '/external/web-page-replay.git@1cf80576c1c4beb6185af0ac70eb7379c5e8262b',
     'src/third_party/webrtc':
-        Var('git_url') + '/external/webrtc/trunk/webrtc.git@e1f0419756d58f744f902fe62fa31da126c55abe',
+        Var('git_url') + '/external/webrtc/trunk/webrtc.git@66968c632394aa0240665a3cbcbc00dc1a62e1a7',
     'src/third_party/yasm/source/patched-yasm':
         Var('git_url') + '/chromium/deps/yasm/patched-yasm.git@c960eb11ccda80b10ed50be39df4f0663b371d1d',
     'src/tools/deps2git':
@@ -158,12 +172,14 @@ deps = {
     'src/tools/swarming_client':
         Var('git_url') + '/external/swarming.client.git@ae8085b09e6162b4ec869e430d7d09c16b32b433',
     'src/v8':
-        Var('git_url') + '/external/v8.git@af6f699b0be532b73bc2f6c9e1cf40a57fa7e234',
+        Var('git_url') + '/external/v8.git@034baa6039e0995e44e298fb3e644331c8d56918',
 }
 
 deps_os = {
     'android':
     {
+        'src/pdf':
+            None,
         'src/third_party/android_tools':
             Var('git_url') + '/android_tools.git@bf45c76e0eb23b7b7a9d5f26b28c16983daa173b',
         'src/third_party/aosp':
@@ -211,8 +227,12 @@ deps_os = {
             None,
         'src/native_client/src/third_party/ppapi':
             None,
+        'src/pdf':
+            None,
         'src/testing/iossim/third_party/class-dump':
             Var('git_url') + '/chromium/deps/class-dump.git@89bd40883c767584240b4dade8b74e6f57b9bdab',
+        'src/third_party/WebKit':
+            None,
         'src/third_party/WebKit/LayoutTests/w3c/csswg-test':
             None,
         'src/third_party/WebKit/LayoutTests/w3c/web-platform-tests':
@@ -297,7 +317,7 @@ deps_os = {
         'src/chrome/installer/mac/third_party/xz/xz':
             Var('git_url') + '/chromium/deps/xz.git@eecaf55632ca72e90eb2641376bce7cdbc7284f7',
         'src/chrome/tools/test/reference_build/chrome_mac':
-            Var('git_url') + '/chromium/reference_builds/chrome_mac.git@78cf441c4ed0727b7bdadd63818e529898c3e4dd',
+            Var('git_url') + '/chromium/reference_builds/chrome.git@1add884151176e42ddb946b68530e61c971ee3fa',
         'src/third_party/google_toolbox_for_mac/src':
             Var('git_url') + '/external/google-toolbox-for-mac.git@704fb56df6a9a0884801045a158e021945d9d991',
         'src/third_party/lighttpd':
@@ -311,12 +331,16 @@ deps_os = {
     },
     'unix':
     {
+        'build/third_party/cbuildbot_chromite':
+            Var('git_url') + '/chromiumos/chromite.git@004471a95329dd59ada2d64f5c0e1331aa734b23',
+        'build/third_party/xvfb':
+            Var('git_url') + '/chromium/tools/third_party/xvfb.git@aebb1aadf1422e4d81e831e13746b8f7ae322e07',
         'src/chrome/tools/test/reference_build/chrome_linux':
-            Var('git_url') + '/chromium/reference_builds/chrome_linux64.git@5186d1b279358de0d9a581399281f2268932cd37',
+            Var('git_url') + '/chromium/reference_builds/chrome.git@1add884151176e42ddb946b68530e61c971ee3fa',
         'src/third_party/chromite':
             Var('git_url') + '/chromiumos/chromite.git@63193a4393f6e964bfca992bfb03e40183554f7d',
         'src/third_party/cros_system_api':
-            Var('git_url') + '/chromiumos/platform/system_api.git@826b4567a5f3b01e2f52022759990dac56c14ea6',
+            Var('git_url') + '/chromiumos/platform/system_api.git@5b855c05cbbd9d4dcd7430fa58e73a296d038047',
         'src/third_party/fontconfig/src':
             Var('git_url') + '/external/fontconfig.git@f16c3118e25546c1b749f9823c51827a60aeb5c1',
         'src/third_party/freetype2/src':
@@ -337,7 +361,7 @@ deps_os = {
     'win':
     {
         'src/chrome/tools/test/reference_build/chrome_win':
-            Var('git_url') + '/chromium/reference_builds/chrome_win.git@126d11ec7462975e6f073214929fca0f3c54756e',
+            Var('git_url') + '/chromium/reference_builds/chrome.git@1add884151176e42ddb946b68530e61c971ee3fa',
         'src/third_party/bison':
             Var('git_url') + '/chromium/deps/bison.git@083c9a45e4affdd5464ee2b224c2df649c6e26c3',
         'src/third_party/cygwin':
index 0ef11f0..65664aa 100644 (file)
--- a/src/DEPS
+++ b/src/DEPS
-# This file is automatically processed to create .DEPS.git which is the file
-# that gclient uses under git.
-#
-# See http://code.google.com/p/chromium/wiki/UsingGit
-#
-# To test manually, run:
-#   python tools/deps2git/deps2git.py -o .DEPS.git -w <gclientdir>
-#   gclient runhooks
-# where <gcliendir> is the absolute path to the directory containing the
-# .gclient file (the parent of "src").
-# DO NOT CHECK IN CHANGES TO .DEPS.git. It will be automatically updated by
-# a bot when you modify this one.
-#
-# When adding a new dependency, please update the top-level .gitignore file
-# to list the dependency's destination directory.
-
+#  
+#  To use this DEPS file to re-create a Chromium release you
+#  need the tools from http://dev.chromium.org installed.
+#  
+#  This DEPS file corresponds to Chromium 36.0.1985.18
+#  
+#  
+#  
 vars = {
-  # Use this googlecode_url variable only if there is an internal mirror for it.
-  # If you do not know, use the full path while defining your new deps entry.
-  "googlecode_url": "http://%s.googlecode.com/svn",
-  "sourceforge_url": "http://svn.code.sf.net/p/%(repo)s/code",
-  "llvm_url": "http://src.chromium.org/llvm-project",
-  "llvm_git": "https://llvm.googlesource.com",
-  "libcxx_revision": "206024",
-  "libcxxabi_revision": "206024",
-  "webkit_trunk": "http://src.chromium.org/blink/trunk",
-  "nacl_trunk": "http://src.chromium.org/native_client/trunk",
-  "webkit_revision": "173750",
-  "chromium_git": "https://chromium.googlesource.com",
-  "chromiumos_git": "https://chromium.googlesource.com/chromiumos",
-  "skia_git": "https://skia.googlesource.com",
-  "swig_revision": "230490",
-  "nacl_revision": "13159",
-  # After changing nacl_revision, run 'glient sync' and check native_client/DEPS
-  # to update other nacl_*_revision's.
-  "nacl_tools_revision": "13077",  # native_client/DEPS: tools_rev
-  "google_toolbox_for_mac_revision": "662",
-  "libaddressinput_revision": "176",
-  "libphonenumber_revision": "621",
-  "libvpx_revision": "269083",
-  "lss_revision": "26",
-
-  # These two FFmpeg variables must be updated together.  One is used for SVN
-  # checkouts and the other for Git checkouts.
-  "ffmpeg_revision": "264299",
-  "ffmpeg_hash": "ac4a9f31fe2610bd146857bbd55d7a260003a888",
-
-  "sfntly_revision": "228",
-  "lighttpd_revision": "33737",
-  "skia_revision": "14592",
-  "skia_hash": "24f6e29fc133f1082c73e2a96f30bee92e3123aa",
-  # Three lines of non-changing comments so that
-  # the commit queue can handle CLs rolling Skia
-  # and V8 without interference from each other.
-  "v8_branch": "trunk",
-  "v8_revision": "21152",
-  # Three lines of non-changing comments so that
-  # the commit queue can handle CLs rolling WebRTC
-  # and V8 without interference from each other.
-  "webrtc_revision": "6085",
-  "jsoncpp_revision": "248",
-  "nss_revision": "267366",
-  # Three lines of non-changing comments so that
-  # the commit queue can handle CLs rolling swarming_client
-  # and whatever else without interference from each other.
-  "swarming_revision": "ae8085b09e6162b4ec869e430d7d09c16b32b433",
-  # Three lines of non-changing comments so that
-  # the commit queue can handle CLs rolling openssl
-  # and whatever else without interference from each other.
-  "openssl_revision": "267674",
-  # Three lines of non-changing comments so that
-  # the commit queue can handle CLs rolling ANGLE
-  # and whatever else without interference from each other.
-  "angle_revision": "74697cf2064c0a2c0d7e1b1b28db439286766a05",
+  'pymox':
+    'http://pymox.googlecode.com/svn',
+  'sfntly':
+    'http://sfntly.googlecode.com/svn',
+  'eyes-free':
+    'http://eyes-free.googlecode.com/svn',
+  'rlz':
+    'http://rlz.googlecode.com/svn',
+  'smhasher':
+    'http://smhasher.googlecode.com/svn',
+  'blink':
+    'http://src.chromium.org/blink',
+  'bidichecker':
+    'http://bidichecker.googlecode.com/svn',
+  'native_client':
+    'http://src.chromium.org/native_client',
+  'trace-viewer':
+    'http://trace-viewer.googlecode.com/svn',
+  'skia':
+    'http://skia.googlecode.com/svn',
+  'google-breakpad':
+    'http://google-breakpad.googlecode.com/svn',
+  'sawbuck':
+    'http://sawbuck.googlecode.com/svn',
+  'v8-i18n':
+    'http://v8-i18n.googlecode.com/svn',
+  'mozc':
+    'http://mozc.googlecode.com/svn',
+  'git.chromium.org':
+    'https://chromium.googlesource.com',
+  'webkit_trunk':
+    'http://src.chromium.org/blink/trunk',
+  'selenium':
+    'http://selenium.googlecode.com/svn',
+  'snappy':
+    'http://snappy.googlecode.com/svn',
+  'ppapi':
+    'http://ppapi.googlecode.com/svn',
+  'googlemock':
+    'http://googlemock.googlecode.com/svn',
+  'grit-i18n':
+    'http://grit-i18n.googlecode.com/svn',
+  'pywebsocket':
+    'http://pywebsocket.googlecode.com/svn',
+  'libaddressinput':
+    'http://libaddressinput.googlecode.com/svn',
+  'pyftpdlib':
+    'http://pyftpdlib.googlecode.com/svn',
+  'pdfsqueeze':
+    'http://pdfsqueeze.googlecode.com/svn',
+  'protobuf':
+    'http://protobuf.googlecode.com/svn',
+  'google-url':
+    'http://google-url.googlecode.com/svn',
+  'google-toolbox-for-mac':
+    'http://google-toolbox-for-mac.googlecode.com/svn',
+  'leveldb':
+    'http://leveldb.googlecode.com/svn',
+  'googletest':
+    'http://googletest.googlecode.com/svn',
+  'libyuv':
+    'http://libyuv.googlecode.com/svn',
+  'gyp':
+    'http://gyp.googlecode.com/svn',
+  'v8':
+    'http://v8.googlecode.com/svn',
+  'seccompsandbox':
+    'http://seccompsandbox.googlecode.com/svn',
+  'ots':
+    'http://ots.googlecode.com/svn',
+  'angleproject':
+    'http://angleproject.googlecode.com/svn',
+  'pefile':
+    'http://pefile.googlecode.com/svn',
+  'open-vcdiff':
+    'http://open-vcdiff.googlecode.com/svn',
+  'octane-benchmark':
+    'http://octane-benchmark.googlecode.com/svn',
+  'linux-syscall-support':
+    'http://linux-syscall-support.googlecode.com/svn',
+  'sctp-refimpl':
+    'https://sctp-refimpl.googlecode.com/svn',
+  'jsoncpp':
+    'http://svn.code.sf.net/p/jsoncpp/code',
+  'webrtc':
+    'http://webrtc.googlecode.com/svn',
+  'web-page-replay':
+    'http://web-page-replay.googlecode.com/svn',
+  'libjingle':
+    'http://libjingle.googlecode.com/svn',
+  'libphonenumber':
+    'http://libphonenumber.googlecode.com/svn',
+  'cld2':
+    'https://cld2.googlecode.com/svn',
+  'jsr-305':
+    'http://jsr-305.googlecode.com/svn',
+  'google-cache-invalidation-api':
+    'http://google-cache-invalidation-api.googlecode.com/svn',
+  'google-safe-browsing':
+    'http://google-safe-browsing.googlecode.com/svn',
 }
 
-deps = {
-  "src/breakpad/src":
-    (Var("googlecode_url") % "google-breakpad") + "/trunk/src@1325",
-
-  "src/sdch/open-vcdiff":
-    (Var("googlecode_url") % "open-vcdiff") + "/trunk@42",
-
-  "src/testing/gtest":
-    (Var("googlecode_url") % "googletest") + "/trunk@643",
-
-  "src/testing/gmock":
-    (Var("googlecode_url") % "googlemock") + "/trunk@410",
-
-  "src/third_party/angle":
-    Var("chromium_git") + "/angle/angle.git@" + Var("angle_revision"),
-
-  "src/third_party/trace-viewer":
-    (Var("googlecode_url") % "trace-viewer") + "/trunk@1267",
-
-  "src/third_party/WebKit":
-    Var("webkit_trunk") + "@" + Var("webkit_revision"),
-
-  "src/third_party/WebKit/LayoutTests/w3c/web-platform-tests":
-    Var("chromium_git") +
-    "/external/w3c/web-platform-tests.git@6bed4516fe8522d65512c76ef02e4f0ae8234395",
-
-  "src/third_party/WebKit/LayoutTests/w3c/csswg-test":
-    Var("chromium_git") +
-    "/external/w3c/csswg-test.git@bacbb4a8dca702cd86646761fde96793db13d4f1",
-
-  "src/third_party/icu":
-    "/trunk/deps/third_party/icu46@262949",
-
-  "src/third_party/libexif/sources":
-    "/trunk/deps/third_party/libexif/sources@265008",
-
-  "src/third_party/hunspell":
-   "/trunk/deps/third_party/hunspell@256272",
-
-  "src/third_party/hunspell_dictionaries":
-    "/trunk/deps/third_party/hunspell_dictionaries@255132",
-
-  "src/third_party/safe_browsing/testing":
-    (Var("googlecode_url") % "google-safe-browsing") + "/trunk/testing@112",
-
-  "src/third_party/cacheinvalidation/src":
-    (Var("googlecode_url") % "google-cache-invalidation-api") +
-    "/trunk/src@331",
-
-  "src/third_party/leveldatabase/src":
-    (Var("googlecode_url") % "leveldb") + "/trunk@80",
-
-  "src/third_party/libc++/trunk":
-    Var("llvm_url") + "/libcxx/trunk@" + Var("libcxx_revision"),
-
-  "src/third_party/libc++abi/trunk":
-    Var("llvm_url") + "/libcxxabi/trunk@" + Var("libcxxabi_revision"),
-
-  "src/third_party/snappy/src":
-    (Var("googlecode_url") % "snappy") + "/trunk@80",
-
-  "src/tools/grit":
-    (Var("googlecode_url") % "grit-i18n") + "/trunk@167",
-
-  "src/tools/gyp":
-    (Var("googlecode_url") % "gyp") + "/trunk@1918",
-
-  "src/tools/swarming_client":
-    Var("chromium_git") + "/external/swarming.client.git@" +
-        Var("swarming_revision"),
-
-  "src/v8":
-    (Var("googlecode_url") % "v8") + "/" + Var("v8_branch") + "@" +
-    Var("v8_revision"),
-
-  "src/native_client":
-    Var("nacl_trunk") + "/src/native_client@" + Var("nacl_revision"),
-
-  "src/chrome/test/data/extensions/api_test/permissions/nacl_enabled/bin":
-    Var("nacl_trunk") + "/src/native_client/tests/prebuilt@" +
-    Var("nacl_revision"),
-
-  "src/third_party/sfntly/cpp/src":
-    (Var("googlecode_url") % "sfntly") + "/trunk/cpp/src@" +
-    Var("sfntly_revision"),
-
-  "src/third_party/skia/src":
-    (Var("googlecode_url") % "skia") + "/trunk/src@" + Var("skia_revision"),
-
-  "src/third_party/skia/gyp":
-    (Var("googlecode_url") % "skia") + "/trunk/gyp@" + Var("skia_revision"),
-
-  "src/third_party/skia/include":
-    (Var("googlecode_url") % "skia") + "/trunk/include@" + Var("skia_revision"),
-
-  "src/third_party/ots":
-    (Var("googlecode_url") % "ots") + "/trunk@113",
-
-  "src/third_party/brotli/src":
-    Var("chromium_git") +
-    "/external/font-compression-reference.git@0829e37293abc2523a1d2b0f4d68ff7b5fcd8e01",
-
-  "src/tools/page_cycler/acid3":
-    "/trunk/deps/page_cycler/acid3@171600",
-
-  "src/chrome/test/data/perf/canvas_bench":
-    "/trunk/deps/canvas_bench@122605",
-
-  "src/chrome/test/data/perf/frame_rate/content":
-    "/trunk/deps/frame_rate/content@93671",
-
-  "src/chrome/test/data/perf/third_party/octane":
-    (Var("googlecode_url") % "octane-benchmark") + "/trunk@19",
-
-  "src/third_party/bidichecker":
-    (Var("googlecode_url") % "bidichecker") + "/trunk/lib@4",
-
-  "src/third_party/webgl/src":
-    Var("chromium_git") +
-    "/external/khronosgroup/webgl.git@1700aa98cc8bc494b305d4ec1045797bc4030f45",
-
-  "src/third_party/swig/Lib":
-    "/trunk/deps/third_party/swig/Lib@" + Var("swig_revision"),
-
-  # Make sure you update the two functional.DEPS and webdriver.DEPS too.
-  "src/third_party/webdriver/pylib":
-    (Var("googlecode_url") % "selenium") + "/trunk/py@18337",
-
-  "src/third_party/libvpx":
-    "/trunk/deps/third_party/libvpx@" +
-    Var("libvpx_revision"),
-
-  "src/third_party/ffmpeg":
-    "/trunk/deps/third_party/ffmpeg@" +
-    Var("ffmpeg_revision"),
-
-  "src/third_party/libjingle/source/talk":
-    (Var("googlecode_url") % "webrtc") + "/trunk/talk@" +
-    Var("webrtc_revision"),
-
-  "src/third_party/usrsctp/usrsctplib":
-    (Var("googlecode_url") % "sctp-refimpl") +
-    "/trunk/KERN/usrsctp/usrsctplib@8838",
-
-  "src/third_party/libsrtp":
-    "/trunk/deps/third_party/libsrtp@261337",
-
-  "src/third_party/speex":
-    "/trunk/deps/third_party/speex@198168",
-
-  "src/third_party/yasm/source/patched-yasm":
-    "/trunk/deps/third_party/yasm/patched-yasm@167605",
-
-  "src/third_party/libjpeg_turbo":
-    "/trunk/deps/third_party/libjpeg_turbo@263594",
-
-  "src/third_party/flac":
-    "/trunk/deps/third_party/flac@222897",
-
-  "src/third_party/pyftpdlib/src":
-    (Var("googlecode_url") % "pyftpdlib") + "/trunk@977",
-
-  "src/third_party/scons-2.0.1":
-    Var("nacl_trunk") + "/src/third_party/scons-2.0.1@" +
-        Var("nacl_tools_revision"),
-
-  "src/third_party/webrtc":
-    (Var("googlecode_url") % "webrtc") + "/trunk/webrtc@" + Var("webrtc_revision"),
-
-  "src/third_party/openmax_dl":
-    (Var("googlecode_url") % "webrtc") + "/deps/third_party/openmax@6024",
-
-  "src/third_party/jsoncpp/source/include":
-    (Var("sourceforge_url") % {"repo": "jsoncpp"}) +
-        "/trunk/jsoncpp/include@" + Var("jsoncpp_revision"),
-
-  "src/third_party/jsoncpp/source/src/lib_json":
-    (Var("sourceforge_url") % {"repo": "jsoncpp"}) +
-        "/trunk/jsoncpp/src/lib_json@" + Var("jsoncpp_revision"),
-
-  "src/third_party/libyuv":
-    (Var("googlecode_url") % "libyuv") + "/trunk@1000",
-
-  "src/third_party/smhasher/src":
-    (Var("googlecode_url") % "smhasher") + "/trunk@152",
-
-  "src/third_party/libaddressinput/src/cpp":
-    (Var("googlecode_url") % "libaddressinput") + "/trunk/cpp@" +
-        Var("libaddressinput_revision"),
-  "src/third_party/libaddressinput/src/testdata":
-    (Var("googlecode_url") % "libaddressinput") + "/trunk/testdata@" +
-        Var("libaddressinput_revision"),
-
-  "src/third_party/libphonenumber/src/phonenumbers":
-    (Var("googlecode_url") % "libphonenumber") +
-        "/trunk/cpp/src/phonenumbers@" + Var("libphonenumber_revision"),
-  "src/third_party/libphonenumber/src/test":
-    (Var("googlecode_url") % "libphonenumber") + "/trunk/cpp/test@" +
-        Var("libphonenumber_revision"),
-  "src/third_party/libphonenumber/src/resources":
-    (Var("googlecode_url") % "libphonenumber") + "/trunk/resources@" +
-        Var("libphonenumber_revision"),
-
-  "src/tools/deps2git":
-    "/trunk/tools/deps2git@262731",
-
-  "src/third_party/clang_format/script":
-    Var("llvm_url") + "/cfe/trunk/tools/clang-format@206068",
-
-  "src/third_party/webpagereplay":
-    (Var("googlecode_url") % "web-page-replay") + "/trunk@544",
-
-  "src/third_party/pywebsocket/src":
-    (Var("googlecode_url") % "pywebsocket") + "/trunk/src@790",
-
-  "src/third_party/opus/src":
-    "/trunk/deps/third_party/opus@256783",
-
-  "src/media/cdm/ppapi/api":
-    "/trunk/deps/cdm@262570",
-
-  "src/third_party/mesa/src":
-    "/trunk/deps/third_party/mesa@265279",
-
-  "src/third_party/cld_2/src":
-    (Var("googlecode_url") % "cld2") + "/trunk@160",
-
-  "src/chrome/browser/resources/pdf/html_office":
-     Var("chromium_git") +
-         "/chromium/html-office-public.git@eeff97614f65e0578529490d44d412032c3d7359",
-
-  "src/third_party/libwebm/source":
-    Var("chromium_git") +
-      "/webm/libwebm.git@fb6b6e64444c637f27d103fd113e0c7bf4f107dd",
-
-  "src/third_party/openssl":
-    "/trunk/deps/third_party/openssl@" + Var("openssl_revision"),
-}
-
-
 deps_os = {
-  "win": {
-    "src/chrome/tools/test/reference_build/chrome_win":
-      "/trunk/deps/reference_builds/chrome_win@254637",
-
-    "src/third_party/cygwin":
-      "/trunk/deps/third_party/cygwin@231940",
-
-    "src/third_party/psyco_win32":
-      "/trunk/deps/third_party/psyco_win32@237949",
-
-    "src/third_party/bison":
-      "/trunk/deps/third_party/bison@147303",
-
-    "src/third_party/gperf":
-      "/trunk/deps/third_party/gperf@147304",
-
-    "src/third_party/perl":
-      "/trunk/deps/third_party/perl@147900",
-
-    "src/third_party/lighttpd":
-      "/trunk/deps/third_party/lighttpd@" + Var("lighttpd_revision"),
-
-    # Parses Windows PE/COFF executable format.
-    "src/third_party/pefile":
-      (Var("googlecode_url") % "pefile") + "/trunk@63",
-
-    # NSS, for SSLClientSocketNSS.
-    "src/third_party/nss":
-      "/trunk/deps/third_party/nss@" + Var("nss_revision"),
-
-    "src/third_party/swig/win":
-      "/trunk/deps/third_party/swig/win@" + Var("swig_revision"),
-
-    # GNU binutils assembler for x86-32.
-    "src/third_party/gnu_binutils":
-      (Var("nacl_trunk") + "/deps/third_party/gnu_binutils@" +
-       Var("nacl_tools_revision")),
-    # GNU binutils assembler for x86-64.
-    "src/third_party/mingw-w64/mingw/bin":
-      (Var("nacl_trunk") + "/deps/third_party/mingw-w64/mingw/bin@" +
-       Var("nacl_tools_revision")),
-
-    # Dependencies used by libjpeg-turbo
-    "src/third_party/yasm/binaries":
-      "/trunk/deps/third_party/yasm/binaries@154708",
-
-    # Binary level profile guided optimizations. This points to the
-    # latest release binaries for the toolchain.
-    "src/third_party/syzygy/binaries":
-      (Var("googlecode_url") % "sawbuck") + "/trunk/syzygy/binaries@2134",
-
-    # Binaries for nacl sdk.
-    "src/third_party/nacl_sdk_binaries":
-      "/trunk/deps/third_party/nacl_sdk_binaries@111576",
-  },
-  "ios": {
-    "src/third_party/google_toolbox_for_mac/src":
-      (Var("googlecode_url") % "google-toolbox-for-mac") + "/trunk@" +
-      Var("google_toolbox_for_mac_revision"),
-
-    "src/third_party/nss":
-      "/trunk/deps/third_party/nss@" + Var("nss_revision"),
-
-    # class-dump utility to generate header files for undocumented SDKs
-    "src/testing/iossim/third_party/class-dump":
-      "/trunk/deps/third_party/class-dump@199203",
-
-    # Code that's not needed due to not building everything
-    "src/build/util/support": None,
-    "src/chrome/test/data/extensions/api_test/permissions/nacl_enabled/bin": None,
-    "src/chrome/test/data/perf/canvas_bench": None,
-    "src/chrome/test/data/perf/frame_rate/content": None,
-    "src/chrome/test/data/perf/third_party/octane": None,
-    "src/media/cdm/ppapi/api": None,
-    "src/native_client": None,
-    "src/native_client/src/third_party/ppapi": None,
-    "src/third_party/angle": None,
-    "src/third_party/bidichecker": None,
-    "src/third_party/brotli/src": None,
-    "src/third_party/cld_2/src": None,
-    "src/third_party/ffmpeg": None,
-    "src/third_party/hunspell_dictionaries": None,
-    "src/third_party/hunspell": None,
-    "src/third_party/libaddressinput/src/cpp": None,
-    "src/third_party/libaddressinput/src/testdata": None,
-    "src/third_party/libc++/trunk": None,
-    "src/third_party/libc++abi/trunk": None,
-    "src/third_party/libexif/sources": None,
-    "src/third_party/libjpeg_turbo": None,
-    "src/third_party/libsrtp": None,
-    "src/third_party/libvpx": None,
-    "src/third_party/libyuv": None,
-    "src/third_party/mesa/src": None,
-    "src/third_party/opus/src": None,
-    "src/third_party/openmax_dl": None,
-    "src/third_party/ots": None,
-    "src/third_party/pymox/src": None,
-    "src/third_party/safe_browsing/testing": None,
-    "src/third_party/scons-2.0.1": None,
-    "src/third_party/sfntly/cpp/src": None,
-    "src/third_party/speex": None,
-    "src/third_party/swig/Lib": None,
-    "src/third_party/usrsctp/usrsctplib": None,
-    "src/third_party/v8-i18n": None,
-    "src/third_party/webdriver/pylib": None,
-    "src/third_party/webgl": None,
-    "src/third_party/webpagereplay": None,
-    "src/third_party/webrtc": None,
-    "src/third_party/WebKit/LayoutTests/w3c/web-platform-tests": None,
-    "src/third_party/WebKit/LayoutTests/w3c/csswg-test": None,
-    "src/third_party/yasm/source/patched-yasm": None,
-    "src/tools/page_cycler/acid3": None,
-    "src/v8": None,
-  },
-  "mac": {
-    "src/chrome/tools/test/reference_build/chrome_mac":
-      "/trunk/deps/reference_builds/chrome_mac@255182",
-
-    "src/third_party/google_toolbox_for_mac/src":
-      (Var("googlecode_url") % "google-toolbox-for-mac") + "/trunk@" +
-      Var("google_toolbox_for_mac_revision"),
-
-    "src/third_party/pdfsqueeze":
-      (Var("googlecode_url") % "pdfsqueeze") + "/trunk@5",
-
-    "src/third_party/lighttpd":
-      "/trunk/deps/third_party/lighttpd@" + Var("lighttpd_revision"),
-
-    "src/third_party/swig/mac":
-      "/trunk/deps/third_party/swig/mac@" + Var("swig_revision"),
-
-    # NSS, for SSLClientSocketNSS.
-    "src/third_party/nss":
-      "/trunk/deps/third_party/nss@" + Var("nss_revision"),
-
-    "src/chrome/installer/mac/third_party/xz/xz":
-      "/trunk/deps/third_party/xz@233311",
-  },
-  "unix": {
-    # Linux, really.
-    "src/chrome/tools/test/reference_build/chrome_linux":
-      "/trunk/deps/reference_builds/chrome_linux64@254637",
-
-    "src/third_party/xdg-utils":
-      "/trunk/deps/third_party/xdg-utils@203785",
-
-    "src/third_party/swig/linux":
-      "/trunk/deps/third_party/swig/linux@" + Var("swig_revision"),
-
-    "src/third_party/lss":
-      ((Var("googlecode_url") % "linux-syscall-support") + "/trunk/lss@" +
-       Var("lss_revision")),
-
-    # For Linux and Chromium OS.
-    "src/third_party/cros_system_api":
-      Var("chromiumos_git") + "/platform/system_api.git" +
-      "@5b855c05cbbd9d4dcd7430fa58e73a296d038047",
-
-    # Note that this is different from Android's freetype repo.
-    "src/third_party/freetype2/src":
-      Var("chromium_git") + "/chromium/src/third_party/freetype2.git" +
-      "@d699c2994ecc178c4ed05ac2086061b2034c2178",
-
-    # Build tools for targeting ChromeOS.
-    "src/third_party/chromite":
-      Var("chromiumos_git") + "/chromite.git" +
-      "@63193a4393f6e964bfca992bfb03e40183554f7d",
-
-    # Dependency of chromite.git.
-    "src/third_party/pyelftools":
-      Var("chromiumos_git") + "/third_party/pyelftools.git" +
-      "@bdc1d380acd88d4bfaf47265008091483b0d614e",
-
-    "src/third_party/undoview":
-      "/trunk/deps/third_party/undoview@119694",
-
-    "src/third_party/liblouis/src":
-      Var("chromium_git") +
-      "/external/liblouis.git@3c2daee56250162e5a75830871601d74328d39f5",
-
-    # Used for embedded builds. CrOS & Linux use the system version.
-    "src/third_party/fontconfig/src":
-      Var("chromium_git") + "/external/fontconfig.git" +
-      "@f16c3118e25546c1b749f9823c51827a60aeb5c1",
-  },
-  "android": {
-    "src/third_party/android_tools":
-      Var("chromium_git") + "/android_tools.git" +
-      "@bf45c76e0eb23b7b7a9d5f26b28c16983daa173b",
-
-    "src/third_party/aosp":
-      "/trunk/deps/third_party/aosp@148330",
-
-    "src/third_party/apache-mime4j":
-      "/trunk/deps/third_party/apache-mime4j@170888",
-
-    "src/third_party/findbugs":
-      "/trunk/deps/third_party/findbugs@245039",
-
-    "src/third_party/freetype":
-      Var("chromium_git") + "/chromium/src/third_party/freetype.git" +
-      "@a2b9955b49034a51dfbc8bf9f4e9d312149cecac",
-
-    "src/third_party/guava/src":
-      Var("chromium_git") + "/external/guava-libraries.git" +
-      "@c523556ab7d0f05afadebd20e7768d4c16af8771",
-
-    "src/third_party/httpcomponents-client":
-      "/trunk/deps/third_party/httpcomponents-client@170888",
-
-    "src/third_party/httpcomponents-core":
-      "/trunk/deps/third_party/httpcomponents-core@170888",
-
-    "src/third_party/jarjar":
-      "/trunk/deps/third_party/jarjar@170888",
-
-    "src/third_party/jsr-305/src":
-      (Var("googlecode_url") % "jsr-305") + "/trunk@51",
-
-    "src/third_party/lss":
-      ((Var("googlecode_url") % "linux-syscall-support") + "/trunk/lss@" +
-       Var("lss_revision")),
-
-    "src/third_party/eyesfree/src/android/java/src/com/googlecode/eyesfree/braille":
-      (Var("googlecode_url") % "eyes-free") + "/trunk/braille/client/src/com/googlecode/eyesfree/braille@797",
-
-    # Android shouldn't use this address validation library.
-    "src/third_party/libaddressinput/src/cpp": None,
-    "src/third_party/libaddressinput/src/testdata": None,
-  },
+   'win': {
+      'src/third_party/yasm/binaries':
+      '/trunk/deps/third_party/yasm/binaries@154708',
+      'src/third_party/nacl_sdk_binaries':
+      '/trunk/deps/third_party/nacl_sdk_binaries@111576',
+      'src/third_party/pefile':
+      Var("pefile") + '/trunk@63',
+      'src/third_party/swig/win':
+      '/trunk/deps/third_party/swig/win@230490',
+      'src/third_party/lighttpd':
+      '/trunk/deps/third_party/lighttpd@33737',
+      'src/chrome/tools/test/reference_build/chrome_win':
+      '/trunk/deps/reference_builds/chrome_win@254637',
+      'src/third_party/bison':
+      '/trunk/deps/third_party/bison@147303',
+      'src/third_party/gnu_binutils':
+      Var("native_client") + '/trunk/deps/third_party/gnu_binutils@13077',
+      'src/third_party/psyco_win32':
+      '/trunk/deps/third_party/psyco_win32@237949',
+      'src/third_party/mingw-w64/mingw/bin':
+      Var("native_client") + '/trunk/deps/third_party/mingw-w64/mingw/bin@13077',
+      'src/third_party/perl':
+      '/trunk/deps/third_party/perl@147900',
+      'src/third_party/gperf':
+      '/trunk/deps/third_party/gperf@147304',
+      'src/third_party/cygwin':
+      '/trunk/deps/third_party/cygwin@231940',
+      'src/third_party/syzygy/binaries':
+      Var("sawbuck") + '/trunk/syzygy/binaries@2134',
+      'src/third_party/nss':
+      '/trunk/deps/third_party/nss@267366',
+   },
+   'mac': {
+      'src/third_party/google_toolbox_for_mac/src':
+      Var("google-toolbox-for-mac") + '/trunk@662',
+      'src/third_party/pdfsqueeze':
+      Var("pdfsqueeze") + '/trunk@5',
+      'src/chrome/installer/mac/third_party/xz/xz':
+      '/trunk/deps/third_party/xz@233311',
+      'src/third_party/swig/mac':
+      '/trunk/deps/third_party/swig/mac@230490',
+      'src/third_party/lighttpd':
+      '/trunk/deps/third_party/lighttpd@33737',
+      'src/chrome/tools/test/reference_build/chrome_mac':
+      '/trunk/deps/reference_builds/chrome_mac@255182',
+      'src/third_party/nss':
+      '/trunk/deps/third_party/nss@267366',
+   },
+   'ios': {
+      'src/third_party/sfntly/cpp/src':
+      None,
+      'src/third_party/libc++/trunk':
+      None,
+      'src/third_party/libc++abi/trunk':
+      None,
+      'src/media/cdm/ppapi/api':
+      None,
+      'src/third_party/v8-i18n':
+      None,
+      'src/chrome/test/data/perf/frame_rate/content':
+      None,
+      'src/third_party/ots':
+      None,
+      'src/third_party/libaddressinput/src/testdata':
+      None,
+      'src/third_party/mesa/src':
+      None,
+      'src/third_party/opus/src':
+      None,
+      'src/third_party/hunspell_dictionaries':
+      None,
+      'src/third_party/brotli/src':
+      None,
+      'src/third_party/webgl':
+      None,
+      'src/chrome/test/data/perf/third_party/octane':
+      None,
+      'src/third_party/scons-2.0.1':
+      None,
+      'src/third_party/webdriver/pylib':
+      None,
+      'src/chrome/test/data/perf/canvas_bench':
+      None,
+      'src/third_party/libexif/sources':
+      None,
+      'src/third_party/safe_browsing/testing':
+      None,
+      'src/third_party/libaddressinput/src/cpp':
+      None,
+      'src/third_party/usrsctp/usrsctplib':
+      None,
+      'src/third_party/webrtc':
+      None,
+      'src/third_party/libjpeg_turbo':
+      None,
+      'src/third_party/nss':
+      '/trunk/deps/third_party/nss@267366',
+      'src/third_party/bidichecker':
+      None,
+      'src/third_party/WebKit':
+      None,
+      'src/third_party/openmax_dl':
+      None,
+      'src/third_party/WebKit/LayoutTests/w3c/csswg-test':
+      None,
+      'src/third_party/google_toolbox_for_mac/src':
+      Var("google-toolbox-for-mac") + '/trunk@662',
+      'src/third_party/WebKit/LayoutTests/w3c/web-platform-tests':
+      None,
+      'src/third_party/libsrtp':
+      None,
+      'src/chrome/test/data/extensions/api_test/permissions/nacl_enabled/bin':
+      None,
+      'src/third_party/WebKit/public':
+      Var("webkit_trunk")[:-6] + '/branches/chromium/1985/public@174328',
+      'src/native_client':
+      None,
+      'src/testing/iossim/third_party/class-dump':
+      '/trunk/deps/third_party/class-dump@199203',
+      'src/third_party/cld_2/src':
+      None,
+      'src/third_party/libyuv':
+      None,
+      'src/third_party/ffmpeg':
+      None,
+      'src/native_client/src/third_party/ppapi':
+      None,
+      'src/tools/page_cycler/acid3':
+      None,
+      'src/build/util/support':
+      None,
+      'src/pdf':
+      None,
+      'src/third_party/pymox/src':
+      None,
+      'src/third_party/yasm/source/patched-yasm':
+      None,
+      'src/third_party/speex':
+      None,
+      'src/third_party/webpagereplay':
+      None,
+      'src/third_party/hunspell':
+      None,
+      'src/third_party/angle':
+      None,
+      'src/v8':
+      None,
+      'src/third_party/libvpx':
+      None,
+      'src/third_party/swig/Lib':
+      None,
+   },
+   'unix': {
+      'src/third_party/chromite':
+      Var("git.chromium.org") + '/chromiumos/chromite.git@63193a4393f6e964bfca992bfb03e40183554f7d',
+      'build/third_party/xvfb':
+      '/trunk/tools/third_party/xvfb@125214',
+      'src/third_party/xdg-utils':
+      '/trunk/deps/third_party/xdg-utils@203785',
+      'src/third_party/undoview':
+      '/trunk/deps/third_party/undoview@119694',
+      'src/third_party/cros_system_api':
+      Var("git.chromium.org") + '/chromiumos/platform/system_api.git@5b855c05cbbd9d4dcd7430fa58e73a296d038047',
+      'src/third_party/liblouis/src':
+      Var("git.chromium.org") + '/external/liblouis.git@3c2daee56250162e5a75830871601d74328d39f5',
+      'src/third_party/freetype2/src':
+      Var("git.chromium.org") + '/chromium/src/third_party/freetype2.git@d699c2994ecc178c4ed05ac2086061b2034c2178',
+      'src/third_party/fontconfig/src':
+      Var("git.chromium.org") + '/external/fontconfig.git@f16c3118e25546c1b749f9823c51827a60aeb5c1',
+      'build/third_party/cbuildbot_chromite':
+      Var("git.chromium.org") + '/chromiumos/chromite.git@004471a95329dd59ada2d64f5c0e1331aa734b23',
+      'src/third_party/pyelftools':
+      Var("git.chromium.org") + '/chromiumos/third_party/pyelftools.git@bdc1d380acd88d4bfaf47265008091483b0d614e',
+      'src/chrome/tools/test/reference_build/chrome_linux':
+      '/trunk/deps/reference_builds/chrome_linux64@254637',
+      'src/third_party/swig/linux':
+      '/trunk/deps/third_party/swig/linux@230490',
+      'src/third_party/lss':
+      Var("linux-syscall-support") + '/trunk/lss@26',
+   },
+   'android': {
+      'src/third_party/libaddressinput/src/testdata':
+      None,
+      'src/third_party/libaddressinput/src/cpp':
+      None,
+      'src/third_party/findbugs':
+      '/trunk/deps/third_party/findbugs@245039',
+      'src/third_party/guava/src':
+      Var("git.chromium.org") + '/external/guava-libraries.git@c523556ab7d0f05afadebd20e7768d4c16af8771',
+      'src/third_party/jarjar':
+      '/trunk/deps/third_party/jarjar@170888',
+      'src/third_party/android_tools':
+      Var("git.chromium.org") + '/android_tools.git@bf45c76e0eb23b7b7a9d5f26b28c16983daa173b',
+      'src/third_party/freetype':
+      Var("git.chromium.org") + '/chromium/src/third_party/freetype.git@a2b9955b49034a51dfbc8bf9f4e9d312149cecac',
+      'src/third_party/apache-mime4j':
+      '/trunk/deps/third_party/apache-mime4j@170888',
+      'src/third_party/eyesfree/src/android/java/src/com/googlecode/eyesfree/braille':
+      Var("eyes-free") + '/trunk/braille/client/src/com/googlecode/eyesfree/braille@797',
+      'src/third_party/httpcomponents-client':
+      '/trunk/deps/third_party/httpcomponents-client@170888',
+      'src/pdf':
+      None,
+      'src/third_party/lss':
+      Var("linux-syscall-support") + '/trunk/lss@26',
+      'src/third_party/httpcomponents-core':
+      '/trunk/deps/third_party/httpcomponents-core@170888',
+      'src/third_party/jsr-305/src':
+      Var("jsr-305") + '/trunk@51',
+      'src/third_party/aosp':
+      '/trunk/deps/third_party/aosp@148330',
+   },
 }
 
+deps = {
+   'src/third_party/sfntly/cpp/src':
+      Var("sfntly") + '/trunk/cpp/src@228',
+   'src/third_party/libc++/trunk':
+      'http://src.chromium.org/llvm-project/libcxx/trunk@206024',
+   'src/third_party/skia/include':
+      Var("skia") + '/trunk/include@14592',
+   'src/third_party/openssl':
+      '/trunk/deps/third_party/openssl@267674',
+   'src/third_party/libc++abi/trunk':
+      'http://src.chromium.org/llvm-project/libcxxabi/trunk@206024',
+   'build/scripts/private/data/reliability':
+      '/trunk/src/chrome/test/data/reliability@237714',
+   'src/third_party/flac':
+      '/trunk/deps/third_party/flac@222897',
+   'src/media/cdm/ppapi/api':
+      '/trunk/deps/cdm@262570',
+   'src/chrome/test/data/perf/frame_rate/content':
+      '/trunk/deps/frame_rate/content@93671',
+   'src/third_party/ots':
+      Var("ots") + '/trunk@113',
+   'src/third_party/libaddressinput/src/testdata':
+      Var("libaddressinput") + '/trunk/testdata@176',
+   'src/third_party/mesa/src':
+      '/trunk/deps/third_party/mesa@265279',
+   'src/third_party/hunspell_dictionaries':
+      '/trunk/deps/third_party/hunspell_dictionaries@255132',
+   'src/third_party/brotli/src':
+      Var("git.chromium.org") + '/external/font-compression-reference.git@0829e37293abc2523a1d2b0f4d68ff7b5fcd8e01',
+   'src/third_party/cacheinvalidation/src':
+      Var("google-cache-invalidation-api") + '/trunk/src@331',
+   'src/chrome/test/data/perf/third_party/octane':
+      Var("octane-benchmark") + '/trunk@19',
+   'src/third_party/skia/gyp':
+      Var("skia") + '/trunk/gyp@14592',
+   'src/third_party/scons-2.0.1':
+      Var("native_client") + '/trunk/src/third_party/scons-2.0.1@13077',
+   'src/third_party/webdriver/pylib':
+      Var("selenium") + '/trunk/py@18337',
+   'src/third_party/cld_2/src':
+      Var("cld2") + '/trunk@160',
+   'src/third_party/libyuv':
+      Var("libyuv") + '/trunk@1000',
+   'src/third_party/hunspell':
+      '/trunk/deps/third_party/hunspell@256272',
+   'src/third_party/libphonenumber/src/phonenumbers':
+      Var("libphonenumber") + '/trunk/cpp/src/phonenumbers@621',
+   'src/third_party/libphonenumber/src/resources':
+      Var("libphonenumber") + '/trunk/resources@621',
+   'src/third_party/safe_browsing/testing':
+      Var("google-safe-browsing") + '/trunk/testing@112',
+   'src/sdch/open-vcdiff':
+      Var("open-vcdiff") + '/trunk@42',
+   'src/third_party/pyftpdlib/src':
+      Var("pyftpdlib") + '/trunk@977',
+   'src/third_party/libaddressinput/src/cpp':
+      Var("libaddressinput") + '/trunk/cpp@176',
+   'src/third_party/WebKit/LayoutTests/w3c/csswg-test':
+      Var("git.chromium.org") + '/external/w3c/csswg-test.git@bacbb4a8dca702cd86646761fde96793db13d4f1',
+   'src/third_party/snappy/src':
+      Var("snappy") + '/trunk@80',
+   'src/third_party/webrtc':
+      Var("webrtc") + '/branches/3.53/webrtc@6133',
+   'src/tools/deps2git':
+      '/trunk/tools/deps2git@262731',
+   'src/third_party/libjpeg_turbo':
+      '/trunk/deps/third_party/libjpeg_turbo@263594',
+   'src/third_party/pywebsocket/src':
+      Var("pywebsocket") + '/trunk/src@790',
+   'depot_tools':
+      '/trunk/tools/depot_tools@269489',
+   'src/third_party/bidichecker':
+      Var("bidichecker") + '/trunk/lib@4',
+   'src/third_party/WebKit':
+      Var("webkit_trunk")[:-6] + '/branches/chromium/1985@174328',
+   'src/breakpad/src':
+      Var("google-breakpad") + '/trunk/src@1325',
+   'src/third_party/openmax_dl':
+      Var("webrtc") + '/deps/third_party/openmax@6024',
+   'src/third_party/jsoncpp/source/src/lib_json':
+      Var("jsoncpp") + '/trunk/jsoncpp/src/lib_json@248',
+   'src/third_party/clang_format/script':
+      'http://src.chromium.org/llvm-project/cfe/trunk/tools/clang-format@206068',
+   'src/third_party/WebKit/LayoutTests/w3c/web-platform-tests':
+      Var("git.chromium.org") + '/external/w3c/web-platform-tests.git@6bed4516fe8522d65512c76ef02e4f0ae8234395',
+   'build/scripts/gsd_generate_index':
+      '/trunk/tools/gsd_generate_index@164784',
+   'src/third_party/webgl/src':
+      Var("git.chromium.org") + '/external/khronosgroup/webgl.git@1700aa98cc8bc494b305d4ec1045797bc4030f45',
+   'src/testing/gmock':
+      Var("googlemock") + '/trunk@410',
+   'src/third_party/skia/src':
+      Var("skia") + '/trunk/src@14592',
+   'src/chrome/test/data/extensions/api_test/permissions/nacl_enabled/bin':
+      Var("native_client") + '/trunk/src/native_client/tests/prebuilt@13159',
+   'src/third_party/smhasher/src':
+      Var("smhasher") + '/trunk@152',
+   'src/third_party/webpagereplay':
+      Var("web-page-replay") + '/trunk@544',
+   'build/scripts/tools/deps2git':
+      '/trunk/tools/deps2git@263285',
+   'src/native_client':
+      Var("native_client") + '/trunk/src/native_client@13159',
+   'src/tools/page_cycler/acid3':
+      '/trunk/deps/page_cycler/acid3@171600',
+   'src/third_party/leveldatabase/src':
+      Var("leveldb") + '/trunk@80',
+   'build':
+      '/trunk/tools/build@269491',
+   'src/tools/gyp':
+      Var("gyp") + '/trunk@1918',
+   'src/chrome/test/data/perf/canvas_bench':
+      '/trunk/deps/canvas_bench@122605',
+   'src/third_party/ffmpeg':
+      '/trunk/deps/third_party/ffmpeg@264299',
+   'src/third_party/libjingle/source/talk':
+      Var("webrtc") + '/trunk/talk@6085',
+   'src/third_party/usrsctp/usrsctplib':
+      Var("sctp-refimpl") + '/trunk/KERN/usrsctp/usrsctplib@8838',
+   'src/third_party/libexif/sources':
+      '/trunk/deps/third_party/libexif/sources@265008',
+   'build/third_party/lighttpd':
+      '/trunk/deps/third_party/lighttpd@58968',
+   'src/third_party/jsoncpp/source/include':
+      Var("jsoncpp") + '/trunk/jsoncpp/include@248',
+   'src/third_party/libsrtp':
+      '/trunk/deps/third_party/libsrtp@261337',
+   'src/third_party/libphonenumber/src/test':
+      Var("libphonenumber") + '/trunk/cpp/test@621',
+   'src/third_party/trace-viewer':
+      Var("trace-viewer") + '/trunk@1267',
+   'src/third_party/yasm/source/patched-yasm':
+      '/trunk/deps/third_party/yasm/patched-yasm@167605',
+   'build/scripts/command_wrapper/bin':
+      '/trunk/tools/command_wrapper/bin@135178',
+   'src/testing/gtest':
+      Var("googletest") + '/trunk@643',
+   'src':
+      '/branches/1985/src@271517',
+   'src/third_party/icu':
+      '/trunk/deps/third_party/icu46@262949',
+   'src/third_party/speex':
+      '/trunk/deps/third_party/speex@198168',
+   'src/third_party/opus/src':
+      '/trunk/deps/third_party/opus@256783',
+   'src/tools/grit':
+      Var("grit-i18n") + '/trunk@167',
+   'src/tools/swarming_client':
+      Var("git.chromium.org") + '/external/swarming.client.git@ae8085b09e6162b4ec869e430d7d09c16b32b433',
+   'src/chrome/browser/resources/pdf/html_office':
+      Var("git.chromium.org") + '/chromium/html-office-public.git@eeff97614f65e0578529490d44d412032c3d7359',
+   'src/third_party/angle':
+      Var("git.chromium.org") + '/angle/angle.git@74697cf2064c0a2c0d7e1b1b28db439286766a05',
+   'src/v8':
+      Var("v8") + '/branches/3.26@21367',
+   'src/third_party/libwebm/source':
+      Var("git.chromium.org") + '/webm/libwebm.git@fb6b6e64444c637f27d103fd113e0c7bf4f107dd',
+   'src/third_party/libvpx':
+      '/trunk/deps/third_party/libvpx@269083',
+   'src/third_party/swig/Lib':
+      '/trunk/deps/third_party/swig/Lib@230490',
+}
 
-include_rules = [
-  # Everybody can use some things.
-  "+base",
-  "+build",
-  "+ipc",
-
-  # Everybody can use headers generated by tools/generate_library_loader.
-  "+library_loaders",
-
-  "+testing",
-  "+third_party/icu/source/common/unicode",
-  "+third_party/icu/source/i18n/unicode",
-  "+url",
-]
-
-
-# checkdeps.py shouldn't check include paths for files in these dirs:
-skip_child_includes = [
-  "breakpad",
-  "delegate_execute",
-  "metro_driver",
-  "native_client_sdk",
-  "o3d",
-  "pdf",
-  "sdch",
-  "skia",
-  "testing",
-  "third_party",
-  "v8",
-  "win8",
-]
+skip_child_includes =  ['breakpad', 'delegate_execute', 'metro_driver', 'native_client_sdk', 'o3d', 'pdf', 'sdch', 'skia', 'testing', 'third_party', 'v8', 'win8'] 
 
+hooks =  [{'action': ['python', 'src/build/download_nacl_toolchains.py', '--exclude', 'arm_trusted'], 'pattern': '.', 'name': 'nacltools'}, {'action': ['python', 'src/build/linux/install-arm-sysroot.py', '--linux-only'], 'pattern': '.', 'name': 'sysroot'}, {'action': ['python', 'src/chrome/installer/linux/sysroot_scripts/install-debian.wheezy.sysroot.py', '--linux-only', '--arch=amd64'], 'pattern': '.', 'name': 'sysroot'}, {'action': ['python', 'src/chrome/installer/linux/sysroot_scripts/install-debian.wheezy.sysroot.py', '--linux-only', '--arch=i386'], 'pattern': '.', 'name': 'sysroot'}, {'action': ['python', 'src/tools/clang/scripts/update.py', '--if-needed'], 'pattern': '.', 'name': 'clang'}, {'action': ['python', 'src/build/vs_toolchain.py', 'update'], 'pattern': '.', 'name': 'win_toolchain'}, {'action': ['python', 'src/build/util/lastchange.py', '-o', 'src/build/util/LASTCHANGE'], 'pattern': '.', 'name': 'lastchange'}, {'action': ['python', 'src/build/util/lastchange.py', '-s', 'src/third_party/WebKit', '-o', 'src/build/util/LASTCHANGE.blink'], 'pattern': '.', 'name': 'lastchange'}, {'action': ['download_from_google_storage', '--no_resume', '--platform=win32', '--no_auth', '--bucket', 'chromium-gn', '-s', 'src/tools/gn/bin/win/gn.exe.sha1'], 'pattern': '.', 'name': 'gn_win'}, {'action': ['download_from_google_storage', '--no_resume', '--platform=darwin', '--no_auth', '--bucket', 'chromium-gn', '-s', 'src/tools/gn/bin/mac/gn.sha1'], 'pattern': '.', 'name': 'gn_mac'}, {'action': ['download_from_google_storage', '--no_resume', '--platform=linux*', '--no_auth', '--bucket', 'chromium-gn', '-s', 'src/tools/gn/bin/linux/gn.sha1'], 'pattern': '.', 'name': 'gn_linux'}, {'action': ['download_from_google_storage', '--no_resume', '--platform=linux*', '--no_auth', '--bucket', 'chromium-gn', '-s', 'src/tools/gn/bin/linux/gn32.sha1'], 'pattern': '.', 'name': 'gn_linux32'}, {'action': ['download_from_google_storage', '--no_resume', '--platform=win32', '--no_auth', '--bucket', 'chromium-clang-format', '-s', 'src/third_party/clang_format/bin/win/clang-format.exe.sha1'], 'pattern': '.', 'name': 'clang_format_win'}, {'action': ['download_from_google_storage', '--no_resume', '--platform=darwin', '--no_auth', '--bucket', 'chromium-clang-format', '-s', 'src/third_party/clang_format/bin/mac/clang-format.sha1'], 'pattern': '.', 'name': 'clang_format_mac'}, {'action': ['download_from_google_storage', '--no_resume', '--platform=linux*', '--no_auth', '--bucket', 'chromium-clang-format', '-s', 'src/third_party/clang_format/bin/linux/clang-format.sha1'], 'pattern': '.', 'name': 'clang_format_linux'}, {'action': ['python', 'src/third_party/binutils/download.py'], 'pattern': 'src/third_party/binutils', 'name': 'binutils'}, {'action': ['download_from_google_storage', '--no_resume', '--platform=linux*', '--no_auth', '--bucket', 'chromium-eu-strip', '-s', 'src/build/linux/bin/eu-strip.sha1'], 'pattern': '.', 'name': 'eu-strip'}, {'action': ['python', 'src/build/gyp_chromium'], 'pattern': '.', 'name': 'gyp'}] 
 
-hooks = [
-  {
-    # This downloads binaries for Native Client's newlib toolchain.
-    # Done in lieu of building the toolchain from scratch as it can take
-    # anywhere from 30 minutes to 4 hours depending on platform to build.
-    "name": "nacltools",
-    "pattern": ".",
-    "action": [
-        "python", "src/build/download_nacl_toolchains.py",
-        "--exclude", "arm_trusted",
-    ],
-  },
-  {
-    # Downloads an ARM sysroot image to src/arm-sysroot. This image updates
-    # at about the same rate that the chrome build deps change.
-    # This script is a no-op except for linux users who have
-    # target_arch=arm in their GYP_DEFINES.
-    "name": "sysroot",
-    "pattern": ".",
-    "action": ["python", "src/build/linux/install-arm-sysroot.py",
-               "--linux-only"],
-  },
-  {
-    # Downloads the Debian Wheezy sysroot to chrome/installer/linux if needed.
-    # This sysroot updates at about the same rate that the chrome build deps
-    # change. This script is a no-op except for linux users who are doing
-    # official chrome builds.
-    "name": "sysroot",
-    "pattern": ".",
-    "action": [
-        "python",
-        "src/chrome/installer/linux/sysroot_scripts/install-debian.wheezy.sysroot.py",
-        "--linux-only",
-        "--arch=amd64"],
-  },
-  {
-    # Same as above, but for 32-bit Linux.
-    "name": "sysroot",
-    "pattern": ".",
-    "action": [
-        "python",
-        "src/chrome/installer/linux/sysroot_scripts/install-debian.wheezy.sysroot.py",
-        "--linux-only",
-        "--arch=i386"],
-  },
-  {
-    # Pull clang if on Mac or clang is requested via GYP_DEFINES.
-    "name": "clang",
-    "pattern": ".",
-    "action": ["python", "src/tools/clang/scripts/update.py", "--if-needed"],
-  },
-  {
-    # Update the Windows toolchain if necessary.
-    "name": "win_toolchain",
-    "pattern": ".",
-    "action": ["python", "src/build/vs_toolchain.py", "update"],
-  },
-  {
-    # Update LASTCHANGE. This is also run by export_tarball.py in
-    # src/tools/export_tarball - please keep them in sync.
-    "name": "lastchange",
-    "pattern": ".",
-    "action": ["python", "src/build/util/lastchange.py",
-               "-o", "src/build/util/LASTCHANGE"],
-  },
-  {
-    # Update LASTCHANGE.blink. This is also run by export_tarball.py in
-    # src/tools/export_tarball - please keep them in sync.
-    "name": "lastchange",
-    "pattern": ".",
-    "action": ["python", "src/build/util/lastchange.py",
-               "-s", "src/third_party/WebKit",
-               "-o", "src/build/util/LASTCHANGE.blink"],
-  },
-  # Pull GN binaries. This needs to be before running GYP below.
-  {
-    "name": "gn_win",
-    "pattern": ".",
-    "action": [ "download_from_google_storage",
-                "--no_resume",
-                "--platform=win32",
-                "--no_auth",
-                "--bucket", "chromium-gn",
-                "-s", "src/tools/gn/bin/win/gn.exe.sha1",
-    ],
-  },
-  {
-    "name": "gn_mac",
-    "pattern": ".",
-    "action": [ "download_from_google_storage",
-                "--no_resume",
-                "--platform=darwin",
-                "--no_auth",
-                "--bucket", "chromium-gn",
-                "-s", "src/tools/gn/bin/mac/gn.sha1",
-    ],
-  },
-  {
-    "name": "gn_linux",
-    "pattern": ".",
-    "action": [ "download_from_google_storage",
-                "--no_resume",
-                "--platform=linux*",
-                "--no_auth",
-                "--bucket", "chromium-gn",
-                "-s", "src/tools/gn/bin/linux/gn.sha1",
-    ],
-  },
-  {
-    "name": "gn_linux32",
-    "pattern": ".",
-    "action": [ "download_from_google_storage",
-                "--no_resume",
-                "--platform=linux*",
-                "--no_auth",
-                "--bucket", "chromium-gn",
-                "-s", "src/tools/gn/bin/linux/gn32.sha1",
-    ],
-  },
-  # Pull clang-format binaries using checked-in hashes.
-  {
-    "name": "clang_format_win",
-    "pattern": ".",
-    "action": [ "download_from_google_storage",
-                "--no_resume",
-                "--platform=win32",
-                "--no_auth",
-                "--bucket", "chromium-clang-format",
-                "-s", "src/third_party/clang_format/bin/win/clang-format.exe.sha1",
-    ],
-  },
-  {
-    "name": "clang_format_mac",
-    "pattern": ".",
-    "action": [ "download_from_google_storage",
-                "--no_resume",
-                "--platform=darwin",
-                "--no_auth",
-                "--bucket", "chromium-clang-format",
-                "-s", "src/third_party/clang_format/bin/mac/clang-format.sha1",
-    ],
-  },
-  {
-    "name": "clang_format_linux",
-    "pattern": ".",
-    "action": [ "download_from_google_storage",
-                "--no_resume",
-                "--platform=linux*",
-                "--no_auth",
-                "--bucket", "chromium-clang-format",
-                "-s", "src/third_party/clang_format/bin/linux/clang-format.sha1",
-    ],
-  },
-  # Pull binutils for linux, enabled debug fission for faster linking /
-  # debugging when used with clang on Ubuntu Precise.
-  # https://code.google.com/p/chromium/issues/detail?id=352046
-  {
-    "name": "binutils",
-    "pattern": "src/third_party/binutils",
-    "action": [
-        "python",
-        "src/third_party/binutils/download.py",
-    ],
-  },
-  # Pull eu-strip binaries using checked-in hashes.
-  {
-    "name": "eu-strip",
-    "pattern": ".",
-    "action": [ "download_from_google_storage",
-                "--no_resume",
-                "--platform=linux*",
-                "--no_auth",
-                "--bucket", "chromium-eu-strip",
-                "-s", "src/build/linux/bin/eu-strip.sha1",
-    ],
-  },
-  {
-    # A change to a .gyp, .gypi, or to GYP itself should run the generator.
-    "name": "gyp",
-    "pattern": ".",
-    "action": ["python", "src/build/gyp_chromium"],
-  },
-]
+include_rules =  ['+base', '+build', '+ipc', '+library_loaders', '+testing', '+third_party/icu/source/common/unicode', '+third_party/icu/source/i18n/unicode', '+url']
\ No newline at end of file
index 520f567..b4eba71 100644 (file)
               'strings/string16.cc',
             ],
           },],
-          ['<(use_ozone) == 1', {
-            'sources!': [
-              'message_loop/message_pump_glib.cc',
-            ]
-          }],
           ['OS == "linux" and >(nacl_untrusted_build)==0', {
             'sources!': [
               'files/file_path_watcher_kqueue.cc',
index bc0c204..c1e74d1 100644 (file)
@@ -48,6 +48,10 @@ static void SetRuntimeFeatureDefaultsForPlatform() {
 #else
   WebRuntimeFeatures::enableNavigatorContentUtils(true);
 #endif  // defined(OS_ANDROID)
+#if defined(OS_TIZEN)
+  WebRuntimeFeatures::enableScreenOrientation(true);
+  WebRuntimeFeatures::enableOrientationEvent(true);
+#endif  // defined(OS_TIZEN)
 }
 
 void SetRuntimeFeaturesDefaultsAndUpdateFromArgs(
index fb27733..5a8f85b 100644 (file)
@@ -167,6 +167,7 @@ public class ContentViewRenderView extends FrameLayout implements WindowAndroid.
 
         mRootWindow = rootWindow;
         rootWindow.setVSyncClient(this);
+        initContentReadbackHandler();
 
         mCompositingSurfaceType = surfaceType;
         if (surfaceType == CompositingSurfaceType.TEXTURE_VIEW) {
@@ -223,6 +224,9 @@ public class ContentViewRenderView extends FrameLayout implements WindowAndroid.
                         FrameLayout.LayoutParams.MATCH_PARENT,
                         FrameLayout.LayoutParams.MATCH_PARENT));
 
+    }
+
+    private void initContentReadbackHandler() {
         mContentReadbackHandler = new ContentReadbackHandler() {
             @Override
             protected boolean readyForReadback() {
index 38b9d2b..526127f 100644 (file)
@@ -281,4 +281,9 @@ void WebRuntimeFeatures::enablePreciseMemoryInfo(bool enable)
     RuntimeEnabledFeatures::setPreciseMemoryInfoEnabled(enable);
 }
 
+void WebRuntimeFeatures::enableScreenOrientation(bool enable)
+{
+    RuntimeEnabledFeatures::setScreenOrientationEnabled(enable);
+}
+
 } // namespace blink
index 15c2f2c..66430a3 100644 (file)
@@ -126,6 +126,8 @@ public:
     BLINK_EXPORT static void enableTargetedStyleRecalc(bool);
 
     BLINK_EXPORT static void enablePreciseMemoryInfo(bool);
+    
+    BLINK_EXPORT static void enableScreenOrientation(bool);
 
 private:
     WebRuntimeFeatures();
index 3077e66..86a3a19 100644 (file)
@@ -7,8 +7,8 @@
 # Use 'Trunk' for trunk.
 # If using trunk, will use '.DEPS.git' for gclient.
 chromium_version = '36.0.1985.18'
-chromium_crosswalk_point = 'c282374abcd161a82bbcd5a51e02e33b1be0b1c4'
-blink_crosswalk_point = '7425f4985931cbd48e669c205a707cf1ff4ff6c6'
+chromium_crosswalk_point = '00026639160639f24b3fc3e0d29b6540ba0dcb0a'
+blink_crosswalk_point = '07920aa9d1a9ae404ba8fb574ae1a9b109b22083'
 v8_crosswalk_point = '535cd006e5174ff00fd7b745a581980b1d371a9f'
 ozone_wayland_point = 'a5ca2e9203e6a0567751cc0400995982b703dde4'
 
index 2b9d8c7..dc2a3c0 100644 (file)
@@ -1,4 +1,4 @@
 MAJOR=7
 MINOR=36
-BUILD=152
+BUILD=153
 PATCH=0
index bb66a0b..f3ce2de 100755 (executable)
@@ -41,7 +41,8 @@ def VerifyAppName(value, mode='default'):
   if not re.match(regex, value):
     print('Error: %s name should be started with letters and should not '
           'contain invalid characters.\n'
-          'It may contain letters, numbers, blank spaces and underscores\n'
+          'It may contain lowercase letters, numbers, blank spaces and '
+          'underscores\n'
           'Sample: %s' % (descrpt, sample))
     sys.exit(6)
 
index 0f96241..7584e62 100755 (executable)
@@ -17,13 +17,11 @@ from util import md5_check
 def DoJavac(options):
   output_dir = options.output_dir
 
-  src_dirs = options.src_dirs.split()
-  java_files = build_utils.FindInDirectories(src_dirs, '*.java')
+  java_files = build_utils.FindInDirectories(options.src_dirs, '*.java')
   if options.javac_includes:
-    javac_includes = options.javac_includes.split()
     filtered_java_files = []
     for f in java_files:
-      for include in javac_includes:
+      for include in options.javac_includes:
         if fnmatch.fnmatch(f, include):
           filtered_java_files.append(f)
           break
@@ -33,10 +31,9 @@ def DoJavac(options):
   # crash... Sorted order works, so use that.
   # See https://code.google.com/p/guava-libraries/issues/detail?id=950
   java_files.sort()
-  classpath = options.classpath.split()
 
   jar_inputs = []
-  for path in classpath:
+  for path in options.classpath:
     if os.path.exists(path + '.TOC'):
       jar_inputs.append(path + '.TOC')
     else:
@@ -47,7 +44,7 @@ def DoJavac(options):
       '-g',
       '-source', '1.5',
       '-target', '1.5',
-      '-classpath', os.pathsep.join(classpath),
+      '-classpath', os.pathsep.join(options.classpath),
       '-d', output_dir,
       '-Xlint:unchecked',
       '-Xlint:deprecation',
@@ -73,11 +70,13 @@ def DoJavac(options):
 
 def main():
   parser = optparse.OptionParser()
-  parser.add_option('--src-dirs', help='Directories containing java files.')
-  parser.add_option('--javac-includes',
+  parser.add_option('--src-dirs', action='append',
+                    help='Directories containing java files.')
+  parser.add_option('--javac-includes', action='append',
       help='A list of file patterns. If provided, only java files that match' +
         'one of the patterns will be compiled.')
-  parser.add_option('--classpath', help='Classpath for javac.')
+  parser.add_option('--classpath', action='append',
+                    help='Classpaths for javac.')
   parser.add_option('--output-dir', help='Directory for javac output.')
   parser.add_option('--stamp', help='Path to touch on success.')
   parser.add_option('--chromium-code', type='int', help='Whether code being '
index 375fdbf..f942547 100755 (executable)
@@ -362,17 +362,16 @@ def Execution(options, name):
     sys.exit(5)
 
   # Compile App source code with app runtime code.
-  classpath = '--classpath='
-  classpath += os.path.join(os.getcwd(), 'libs',
-                            'xwalk_app_runtime_java.jar')
-  classpath += ' ' + sdk_jar_path
-  src_dirs = '--src-dirs=' + os.path.join(os.getcwd(), name, 'src') +\
-             ' ' + os.path.join(os.getcwd(), 'out', 'gen')
   cmd = ['python', os.path.join('scripts', 'gyp', 'javac.py'),
          '--output-dir=%s' % os.path.join('out', 'classes'),
-         classpath,
-         src_dirs,
-         '--javac-includes=',
+         '--classpath',
+         os.path.join(os.getcwd(), 'libs', 'xwalk_app_runtime_java.jar'),
+         '--classpath',
+         sdk_jar_path,
+         '--src-dirs',
+         os.path.join(os.getcwd(), name, 'src'),
+         '--src-dirs',
+         os.path.join(os.getcwd(), 'out', 'gen'),
          '--chromium-code=0',
          '--stamp=compile.stam']
   RunCommand(cmd, options.verbose)
index 8f1aad2..1cb3a4f 100644 (file)
@@ -27,7 +27,6 @@
 #include "xwalk/runtime/browser/runtime.h"
 #include "xwalk/runtime/browser/runtime_context.h"
 #include "xwalk/runtime/browser/xwalk_runner.h"
-#include "xwalk/runtime/common/xwalk_common_messages.h"
 
 using content::RenderProcessHost;
 
@@ -351,83 +350,20 @@ bool Application::SetPermission(PermissionType type,
 }
 
 void Application::InitSecurityPolicy() {
-  if (data_->GetPackageType() != Package::WGT)
-    return;
-
-  const WARPInfo* info = static_cast<WARPInfo*>(
-      data_->GetManifestData(widget_keys::kAccessKey));
-  // Need to enable WARP mode by default.
-  if (!info) {
-    security_mode_enabled_ = true;
-    DCHECK(render_process_host_);
-    render_process_host_->Send(
-        new ViewMsg_EnableSecurityMode(
-            ApplicationData::GetBaseURLFromApplicationId(id()),
-            SecurityPolicy::WARP));
-    return;
-  }
-
-  const base::ListValue* whitelist = info->GetWARP();
-  for (base::ListValue::const_iterator it = whitelist->begin();
-       it != whitelist->end(); ++it) {
-    base::DictionaryValue* value = NULL;
-    (*it)->GetAsDictionary(&value);
-    std::string dest;
-    if (!value || !value->GetString(widget_keys::kAccessOriginKey, &dest) ||
-        dest.empty())
-      continue;
-    if (dest == "*") {
-      security_mode_enabled_ = false;
-      break;
-    }
-
-    GURL dest_url(dest);
-    // The default subdomains attrubute should be "false".
-    std::string subdomains = "false";
-    value->GetString(widget_keys::kAccessSubdomainsKey, &subdomains);
-    AddSecurityPolicy(dest_url, (subdomains == "true"));
-    security_mode_enabled_ = true;
-  }
-  if (security_mode_enabled_) {
-    DCHECK(render_process_host_);
-    render_process_host_->Send(
-        new ViewMsg_EnableSecurityMode(
-            ApplicationData::GetBaseURLFromApplicationId(id()),
-            SecurityPolicy::WARP));
-  }
-}
-
-void Application::AddSecurityPolicy(const GURL& url, bool subdomains) {
-  GURL app_url = data_->URL();
-  DCHECK(render_process_host_);
-  render_process_host_->Send(
-      new ViewMsg_SetAccessWhiteList(
-          app_url, url, subdomains));
-  security_policy_.push_back(new SecurityPolicy(url, subdomains));
+  // CSP policy takes precedence over WARP.
+  if (data_->HasCSPDefined())
+    security_policy_.reset(new SecurityPolicyCSP(this));
+  else if (data_->GetPackageType() == Package::WGT)
+    security_policy_.reset(new SecurityPolicyWARP(this));
+
+  if (security_policy_)
+    security_policy_->Enforce();
 }
 
 bool Application::CanRequestURL(const GURL& url) const {
-  if (!security_mode_enabled_)
-    return true;
-
-  // Only WGT package need to check the url request permission.
-  if (data_->GetPackageType() != Package::WGT)
-    return true;
-
-  // Always can request itself resources.
-  if (url.SchemeIs(application::kApplicationScheme) &&
-      url.host() == id())
-    return true;
-
-  for (unsigned i = 0; i < security_policy_.size(); ++i) {
-    const GURL& policy = security_policy_[i]->url();
-    bool subdomains = security_policy_[i]->subdomains();
-    bool is_host_matched = subdomains ?
-        url.DomainIs(policy.host().c_str()) : url.host() == policy.host();
-    if (url.scheme() == policy.scheme() && is_host_matched)
-      return true;
-  }
-  return false;
+  if (security_policy_)
+    return security_policy_->IsAccessAllowed(url);
+  return true;
 }
 
 }  // namespace application
index 76a27e2..d944efb 100644 (file)
@@ -97,6 +97,8 @@ class Application : public Runtime::Observer,
   // (ApplicationData objects).
   std::string id() const { return data_->ID(); }
   int GetRenderProcessHostID() const;
+  content::RenderProcessHost* render_process_host() {
+    return render_process_host_; }
 
   const ApplicationData* data() const { return data_; }
   ApplicationData* data() { return data_; }
@@ -129,7 +131,6 @@ class Application : public Runtime::Observer,
               Observer* observer);
   virtual bool Launch(const LaunchParams& launch_params);
   virtual void InitSecurityPolicy();
-  void AddSecurityPolicy(const GURL& url, bool subdomains);
 
   std::set<Runtime*> runtimes_;
   scoped_refptr<ApplicationData> const data_;
@@ -169,8 +170,8 @@ class Application : public Runtime::Observer,
   std::map<std::string, std::string> name_perm_map_;
   // Application's session permissions.
   StoredPermissionMap permission_map_;
-  // Security policy set.
-  ScopedVector<SecurityPolicy> security_policy_;
+  // Security policy.
+  scoped_ptr<SecurityPolicy> security_policy_;
   // WeakPtrFactory should be always declared the last.
   base::WeakPtrFactory<Application> weak_factory_;
   DISALLOW_COPY_AND_ASSIGN(Application);
index d599145..2d8aacc 100644 (file)
@@ -12,6 +12,7 @@
 #include "content/public/browser/render_process_host.h"
 #include "content/browser/screen_orientation/screen_orientation_dispatcher_host.h"
 
+#include "xwalk/runtime/browser/ui/native_app_window.h"
 #include "xwalk/runtime/browser/ui/native_app_window_tizen.h"
 #include "xwalk/runtime/common/xwalk_common_messages.h"
 
@@ -25,8 +26,6 @@
 #endif
 
 #include "xwalk/application/common/application_manifest_constants.h"
-#include "xwalk/application/common/manifest_handlers/csp_handler.h"
-#include "xwalk/application/common/manifest_handlers/navigation_handler.h"
 
 namespace xwalk {
 
@@ -34,39 +33,6 @@ namespace widget_keys = application_widget_keys;
 
 namespace application {
 
-namespace {
-const char kAsterisk[] = "*";
-
-const char kDirectiveValueSelf[] = "'self'";
-const char kDirectiveValueNone[] = "'none'";
-
-const char kDirectiveNameDefault[] = "default-src";
-const char kDirectiveNameScript[] = "script-src";
-const char kDirectiveNameStyle[] = "style-src";
-const char kDirectiveNameObject[] = "object-src";
-
-CSPInfo* GetDefaultCSPInfo() {
-  static CSPInfo default_csp_info;
-  if (default_csp_info.GetDirectives().empty()) {
-    std::vector<std::string> directive_all;
-    std::vector<std::string> directive_self;
-    std::vector<std::string> directive_none;
-    directive_all.push_back(kAsterisk);
-    directive_self.push_back(kDirectiveValueSelf);
-    directive_none.push_back(kDirectiveValueNone);
-
-    default_csp_info.SetDirective(kDirectiveNameDefault, directive_all);
-    default_csp_info.SetDirective(kDirectiveNameScript, directive_self);
-    default_csp_info.SetDirective(kDirectiveNameStyle, directive_self);
-    default_csp_info.SetDirective(kDirectiveNameObject, directive_none);
-  }
-
-  return (new CSPInfo(default_csp_info));
-}
-
-}  // namespace
-
-
 ApplicationTizen::ApplicationTizen(
     scoped_refptr<ApplicationData> data,
     RuntimeContext* runtime_context,
@@ -102,54 +68,6 @@ bool ApplicationTizen::Launch(const LaunchParams& launch_params) {
   return false;
 }
 
-void ApplicationTizen::InitSecurityPolicy() {
-  // On Tizen, CSP mode has higher priority, and WARP will be disabled
-  // if the application is under CSP mode.
-  if (!data_->HasCSPDefined()) {
-    Application::InitSecurityPolicy();
-    return;
-  }
-
-  if (data_->GetPackageType() != Package::WGT)
-    return;
-
-  CSPInfo* csp_info =
-      static_cast<CSPInfo*>(data_->GetManifestData(widget_keys::kCSPKey));
-  if (!csp_info || csp_info->GetDirectives().empty())
-    data_->SetManifestData(widget_keys::kCSPKey, GetDefaultCSPInfo());
-
-  // Always enable security mode when under CSP mode.
-  security_mode_enabled_ = true;
-  NavigationInfo* info = static_cast<NavigationInfo*>(
-      data_->GetManifestData(widget_keys::kAllowNavigationKey));
-  if (info) {
-    const std::vector<std::string>& allowed_list = info->GetAllowedDomains();
-    for (std::vector<std::string>::const_iterator it = allowed_list.begin();
-         it != allowed_list.end(); ++it) {
-      // If the policy is "*", it represents that any external link is allowed
-      // to navigate to.
-      if ((*it) == kAsterisk) {
-        security_mode_enabled_ = false;
-        return;
-      }
-
-      // If the policy start with "*.", like this: *.domain,
-      // means that can access to all subdomains for 'domain',
-      // otherwise, the host of request url should exactly the same
-      // as policy.
-      bool subdomains = ((*it).find("*.") == 0);
-      std::string host = subdomains ? (*it).substr(2) : (*it);
-      AddSecurityPolicy(GURL("http://" + host), subdomains);
-      AddSecurityPolicy(GURL("https://" + host), subdomains);
-    }
-  }
-  DCHECK(render_process_host_);
-  render_process_host_->Send(
-      new ViewMsg_EnableSecurityMode(
-          ApplicationData::GetBaseURLFromApplicationId(id()),
-          SecurityPolicy::CSP));
-}
-
 #if defined(USE_OZONE)
 void ApplicationTizen::WillProcessEvent(const ui::PlatformEvent& event) {}
 
index aa5dec5..08ea60d 100644 (file)
@@ -32,7 +32,6 @@ class ApplicationTizen :  // NOLINT
                    RuntimeContext* context,
                    Application::Observer* observer);
   virtual bool Launch(const LaunchParams& launch_params) OVERRIDE;
-  virtual void InitSecurityPolicy() OVERRIDE;
 
 #if defined(USE_OZONE)
   virtual void WillProcessEvent(const ui::PlatformEvent& event) OVERRIDE;
index d5f8b87..fe2c09b 100644 (file)
@@ -347,13 +347,15 @@ PermissionSet ApplicationData::GetManifestPermissions() const {
   return permissions;
 }
 
-#if defined(OS_TIZEN)
 bool ApplicationData::HasCSPDefined() const {
-  return (manifest_->HasPath(widget_keys::kCSPKey) ||
+#if defined(OS_TIZEN)
+  return  manifest_->HasPath(GetCSPKey(package_type_)) ||
           manifest_->HasPath(widget_keys::kCSPReportOnlyKey) ||
-          manifest_->HasPath(widget_keys::kAllowNavigationKey));
-}
+          manifest_->HasPath(widget_keys::kAllowNavigationKey);
+#else
+  return manifest_->HasPath(GetCSPKey(package_type_));
 #endif
+}
 
 bool ApplicationData::SetApplicationLocale(const std::string& locale,
                                            base::string16* error) {
index ed6fc62..d0f41ce 100644 (file)
@@ -129,9 +129,7 @@ class ApplicationData : public base::RefCountedThreadSafe<ApplicationData> {
 
   Package::Type GetPackageType() const { return package_type_; }
 
-#if defined(OS_TIZEN)
   bool HasCSPDefined() const;
-#endif
 
   bool SetApplicationLocale(const std::string& locale, base::string16* error);
 
index baed924..3dfbc87 100644 (file)
@@ -8,7 +8,8 @@ namespace xwalk {
 
 namespace application_manifest_keys {
 const char kAppKey[] = "app";
-const char kCSPKey[] = "content_security_policy";
+const char kCSPKey[] = "csp";
+const char kCSPKeyLegacy[] = "content_security_policy";
 const char kDescriptionKey[] = "description";
 const char kDisplay[] = "display";
 const char kLaunchLocalPathKey[] = "app.launch.local_path";
index ab5ff07..0f66f06 100644 (file)
@@ -11,6 +11,7 @@ namespace xwalk {
 namespace application_manifest_keys {
   extern const char kAppKey[];
   extern const char kCSPKey[];
+  extern const char kCSPKeyLegacy[];
   extern const char kDescriptionKey[];
   extern const char kDisplay[];
   extern const char kLaunchLocalPathKey[];
index f5da81f..3f29070 100644 (file)
 
 #include "xwalk/application/common/security_policy.h"
 
+#include <map>
+#include <string>
+
+#include "content/public/browser/render_process_host.h"
+#include "xwalk/application/browser/application.h"
+#include "xwalk/application/common/application_manifest_constants.h"
+#include "xwalk/application/common/constants.h"
+#include "xwalk/application/common/manifest_handlers/csp_handler.h"
+#include "xwalk/application/common/manifest_handlers/navigation_handler.h"
+#include "xwalk/application/common/manifest_handlers/warp_handler.h"
+#include "xwalk/runtime/common/xwalk_common_messages.h"
+
 namespace xwalk {
+
+namespace keys = application_manifest_keys;
+namespace widget_keys = application_widget_keys;
+
 namespace application {
 
-SecurityPolicy::SecurityPolicy(const GURL& url, bool subdomains)
-    : url_(url),
-      subdomains_(subdomains) {
+namespace {
+const char kAsterisk[] = "*";
+
+const char kDirectiveValueSelf[] = "'self'";
+const char kDirectiveValueNone[] = "'none'";
+
+const char kDirectiveNameDefault[] = "default-src";
+const char kDirectiveNameScript[] = "script-src";
+const char kDirectiveNameStyle[] = "style-src";
+const char kDirectiveNameObject[] = "object-src";
+
+// By default:
+// default-src * ; script-src 'self' ; style-src 'self' ; object-src 'none'
+CSPInfo* GetDefaultCSPInfo() {
+  static CSPInfo default_csp_info;
+  if (default_csp_info.GetDirectives().empty()) {
+    std::vector<std::string> directive_all;
+    std::vector<std::string> directive_self;
+    std::vector<std::string> directive_none;
+    directive_all.push_back(kAsterisk);
+    directive_self.push_back(kDirectiveValueSelf);
+    directive_none.push_back(kDirectiveValueNone);
+
+    default_csp_info.SetDirective(kDirectiveNameDefault, directive_all);
+    default_csp_info.SetDirective(kDirectiveNameScript, directive_self);
+    default_csp_info.SetDirective(kDirectiveNameStyle, directive_self);
+    default_csp_info.SetDirective(kDirectiveNameObject, directive_none);
+  }
+
+  return (new CSPInfo(default_csp_info));
+}
+
+}  // namespace
+
+SecurityPolicy::WhitelistEntry::WhitelistEntry(const GURL& url, bool subdomains)
+  : url(url),
+    subdomains(subdomains) {
+}
+
+SecurityPolicy::SecurityPolicy(Application* app)
+  : app_(app),
+    enabled_(false) {
+}
+
+SecurityPolicy::~SecurityPolicy() {
+}
+
+bool SecurityPolicy::IsAccessAllowed(const GURL& url) const {
+  if (!enabled_)
+    return true;
+
+  // Accessing own resources is always allowed.
+  if (url.SchemeIs(application::kApplicationScheme) &&
+      url.host() == app_->id())
+    return true;
+
+  for (std::vector<WhitelistEntry>::const_iterator it =
+      whitelist_entries_.begin(); it != whitelist_entries_.end(); ++it) {
+    const GURL& policy = it->url;
+    bool subdomains = it->subdomains;
+    bool is_host_matched = subdomains ?
+        url.DomainIs(policy.host().c_str()) : url.host() == policy.host();
+    if (url.scheme() == policy.scheme() && is_host_matched)
+      return true;
+  }
+  return false;
+}
+
+void SecurityPolicy::Enforce() {
+}
+
+void SecurityPolicy::AddWhitelistEntry(const GURL& url, bool subdomains) {
+  GURL app_url = app_->data()->URL();
+  DCHECK(app_->render_process_host());
+  WhitelistEntry entry = WhitelistEntry(url, subdomains);
+
+  std::vector<WhitelistEntry>::iterator it =
+      std::find(whitelist_entries_.begin(), whitelist_entries_.end(), entry);
+  if (it != whitelist_entries_.end())
+    return;
+
+  app_->render_process_host()->Send(new ViewMsg_SetAccessWhiteList(
+      app_url, url, subdomains));
+  whitelist_entries_.push_back(entry);
+}
+
+SecurityPolicyWARP::SecurityPolicyWARP(Application* app)
+  : SecurityPolicy(app) {
+}
+
+SecurityPolicyWARP::~SecurityPolicyWARP() {
+}
+
+void SecurityPolicyWARP::Enforce() {
+  const WARPInfo* info = static_cast<WARPInfo*>(
+      app_->data()->GetManifestData(widget_keys::kAccessKey));
+  if (!info) {
+    enabled_ = true;
+    DCHECK(app_->render_process_host());
+    app_->render_process_host()->Send(
+        new ViewMsg_EnableSecurityMode(
+            ApplicationData::GetBaseURLFromApplicationId(app_->id()),
+            SecurityPolicy::WARP));
+    return;
+  }
+
+  const base::ListValue* whitelist = info->GetWARP();
+  for (base::ListValue::const_iterator it = whitelist->begin();
+       it != whitelist->end(); ++it) {
+    base::DictionaryValue* value = NULL;
+    (*it)->GetAsDictionary(&value);
+    std::string dest;
+    if (!value || !value->GetString(widget_keys::kAccessOriginKey, &dest) ||
+        dest.empty())
+      continue;
+    if (dest == "*") {
+      enabled_ = false;
+      break;
+    }
+
+    GURL dest_url(dest);
+    // The default subdomains attribute should be "false".
+    std::string subdomains = "false";
+    value->GetString(widget_keys::kAccessSubdomainsKey, &subdomains);
+    AddWhitelistEntry(dest_url, (subdomains == "true"));
+    enabled_ = true;
+  }
+
+  if (enabled_) {
+    DCHECK(app_->render_process_host());
+    app_->render_process_host()->Send(
+        new ViewMsg_EnableSecurityMode(
+            ApplicationData::GetBaseURLFromApplicationId(app_->id()),
+            SecurityPolicy::WARP));
+  }
+}
+
+SecurityPolicyCSP::SecurityPolicyCSP(Application* app)
+  : SecurityPolicy(app) {
+}
+
+SecurityPolicyCSP::~SecurityPolicyCSP() {
+}
+
+void SecurityPolicyCSP::Enforce() {
+  Package::Type package_type = app_->data()->GetPackageType();
+  const char* scp_key = GetCSPKey(package_type);
+  CSPInfo* csp_info =
+      static_cast<CSPInfo*>(app_->data()->GetManifestData(scp_key));
+  if (package_type = Package::WGT) {
+#if defined(OS_TIZEN)
+    if (!csp_info || csp_info->GetDirectives().empty())
+       app_->data()->SetManifestData(scp_key, GetDefaultCSPInfo());
+    // Always enable security mode when under CSP mode.
+    enabled_ = true;
+    NavigationInfo* info = static_cast<NavigationInfo*>(
+        app_->data()->GetManifestData(widget_keys::kAllowNavigationKey));
+    if (info) {
+      const std::vector<std::string>& allowed_list = info->GetAllowedDomains();
+      for (std::vector<std::string>::const_iterator it = allowed_list.begin();
+           it != allowed_list.end(); ++it) {
+        // If the policy is "*", it represents that any external link is allowed
+        // to navigate to.
+        if ((*it) == kAsterisk) {
+          enabled_ = false;
+          return;
+        }
+
+        // If the policy start with "*.", like this: *.domain,
+        // means that can access to all subdomains for 'domain',
+        // otherwise, the host of request url should exactly the same
+        // as policy.
+        bool subdomains = ((*it).find("*.") == 0);
+        std::string host = subdomains ? (*it).substr(2) : (*it);
+        AddWhitelistEntry(GURL("http://" + host), subdomains);
+        AddWhitelistEntry(GURL("https://" + host), subdomains);
+      }
+    }
+#endif
+  } else {
+    if (!csp_info || csp_info->GetDirectives().empty()) {
+      LOG(ERROR) << "Failed to obtain CSP directives from the manifest";
+      return;
+    }
+    enabled_ = true;
+    const std::map<std::string, std::vector<std::string> >& policies =
+        csp_info->GetDirectives();
+    std::map<std::string, std::vector<std::string> >::const_iterator it =
+        policies.begin();
+    for (; it != policies.end(); ++it) {
+      const std::vector<std::string>& allowed_list = it->second;
+      for (std::vector<std::string>::const_iterator it = allowed_list.begin();
+           it != allowed_list.end(); ++it) {
+        GURL url(*it);
+        if (url.is_valid())
+          AddWhitelistEntry(url, false);
+      }
+    }
+  }
+
+  if (enabled_) {
+    DCHECK(app_->render_process_host());
+    app_->render_process_host()->Send(
+        new ViewMsg_EnableSecurityMode(
+            ApplicationData::GetBaseURLFromApplicationId(app_->id()),
+            SecurityPolicy::CSP));
+  }
 }
 
 }  // namespace application
index 3bf5319..9c14a74 100644 (file)
@@ -4,11 +4,18 @@
 
 #ifndef XWALK_APPLICATION_COMMON_SECURITY_POLICY_H_
 #define XWALK_APPLICATION_COMMON_SECURITY_POLICY_H_
+
+#include <vector>
+
 #include "url/gurl.h"
 
 namespace xwalk {
 namespace application {
 
+class Application;
+
+// FIXME(Mikhail): Move to application/browser folder.
+// Rename to ApplicationSecurityPolicy.
 class SecurityPolicy {
  public:
   enum SecurityMode {
@@ -16,13 +23,46 @@ class SecurityPolicy {
     CSP,
     WARP
   };
-  SecurityPolicy(const GURL& url, bool subdomains);
-  const GURL& url() const { return url_; }
-  bool subdomains() const { return subdomains_; }
 
- private:
-  GURL url_;
-  bool subdomains_;
+  explicit SecurityPolicy(Application* app);
+  virtual ~SecurityPolicy();
+
+  bool IsAccessAllowed(const GURL& url) const;
+
+  virtual void Enforce() = 0;
+
+ protected:
+  struct WhitelistEntry {
+    WhitelistEntry(const GURL& url, bool subdomains);
+    GURL url;
+    bool subdomains;
+
+    bool operator==(const WhitelistEntry& o) const {
+      return o.url == url && o.subdomains == subdomains;
+    }
+  };
+
+  void AddWhitelistEntry(const GURL& url, bool subdomains);
+
+  std::vector<WhitelistEntry> whitelist_entries_;
+  Application* app_;
+  bool enabled_;
+};
+
+class SecurityPolicyWARP : public SecurityPolicy {
+ public:
+  explicit SecurityPolicyWARP(Application* app);
+  virtual ~SecurityPolicyWARP();
+
+  virtual void Enforce() OVERRIDE;
+};
+
+class SecurityPolicyCSP : public SecurityPolicy {
+ public:
+  explicit SecurityPolicyCSP(Application* app);
+  virtual ~SecurityPolicyCSP();
+
+  virtual void Enforce() OVERRIDE;
 };
 
 }  // namespace application
index 8cab464..854af39 100644 (file)
@@ -4,9 +4,8 @@
 
 #include "xwalk/experimental/native_file_system/virtual_root_provider.h"
 
-#include "base/logging.h"
+#include "xwalk/runtime/browser/android/xwalk_path_helper.h"
 
 VirtualRootProvider::VirtualRootProvider() {
-  // TODO(shawngao5): Android support to be added.
-  NOTIMPLEMENTED();
+  virtual_root_map_ = xwalk::XWalkPathHelper::GetVirtualRootMap();
 }
index 3408bb4..5c723a2 100644 (file)
@@ -4,9 +4,35 @@
 
 #include "xwalk/experimental/native_file_system/virtual_root_provider.h"
 
-#include "base/logging.h"
+#include <tzplatform_config.h>
+
+#include <map>
+#include <string>
 
 VirtualRootProvider::VirtualRootProvider() {
-  // TODO(shawngao5): Tizen support to be added.
-  NOTIMPLEMENTED();
+  const char* names[] = {
+      "CAMERA",
+      "DOCUMENTS",
+      "IMAGES",
+      "SOUNDS",
+      "VIDEOS",
+  };
+
+  tzplatform_variable dirs[] = {
+      TZ_USER_CAMERA,
+      TZ_USER_DOCUMENTS,
+      TZ_USER_IMAGES,
+      TZ_USER_SOUNDS,
+      TZ_USER_VIDEOS
+  };
+
+  for (unsigned int i = 0; i < sizeof(names) / sizeof(names[0]); ++i) {
+    virtual_root_map_[names[i]] =
+        base::FilePath::FromUTF8Unsafe(
+            std::string(tzplatform_getenv(dirs[i])));
+  }
+
+  virtual_root_map_["RINGTONES"] =
+      base::FilePath::FromUTF8Unsafe(
+          std::string(tzplatform_mkpath(TZ_USER_SHARE, "settings/Ringtones")));
 }
index 98017e8..f554653 100644 (file)
@@ -125,7 +125,7 @@ IN_PROC_BROWSER_TEST_F(ExternalExtensionMultiProcessTest,
   EXPECT_EQ(1, CountRegisterExtensions());
 
   Runtime* new_runtime = Runtime::CreateWithDefaultWindow(
-      runtime()->runtime_context(), url, runtime_registry());
+      GetRuntimeContext(), url, runtime_registry());
   EXPECT_EQ(new_runtime, WaitForSingleNewRuntime());
   EXPECT_NE(runtime(), new_runtime);
   content::RunAllPendingInMessageLoop();
index be4777e..b9775a7 100644 (file)
@@ -1,18 +1,22 @@
 %bcond_with x
 %bcond_with wayland
 
-%ifarch x86_64
+%ifarch x86_64 %{arm}
+### x86_64
 # NaCl build on 64bit system require libc 32bit to build the 32 IRT.
 # While Tizen 64bit image does not offer 32bit packages at all,
 # check https://bugs.tizen.org/jira/browse/PTREL-803 for details.
 # So disable nacl for 64bit now.
+### ARM
+# Due to OBS build for ARM some files needed by NaCl to be build
+# are not present.
 %define _disable_nacl 1
 %else
 %define _disable_nacl 0
 %endif
 
 Name:           crosswalk
-Version:        7.36.152.0
+Version:        7.36.153.0
 Release:        0
 Summary:        Crosswalk is an app runtime based on Chromium
 License:        (BSD-3-Clause and LGPL-2.1+)
@@ -56,6 +60,7 @@ BuildRequires:  pkgconfig(libdrm)
 BuildRequires:  pkgconfig(libexif)
 BuildRequires:  pkgconfig(libpci)
 BuildRequires:  pkgconfig(libpulse)
+BuildRequires:  pkgconfig(libtzplatform-config)
 BuildRequires:  pkgconfig(libudev)
 BuildRequires:  pkgconfig(libxml-2.0)
 BuildRequires:  pkgconfig(libxslt)
@@ -160,7 +165,7 @@ if [ -n "${BUILDDIR_NAME}" ]; then
 fi
 
 %if %{with wayland}
-GYP_EXTRA_FLAGS="${GYP_EXTRA_FLAGS} -Duse_ozone=1 -Denable_ozone_wayland_vkb=1 -Denable_xdg_shell=1"
+GYP_EXTRA_FLAGS="${GYP_EXTRA_FLAGS} -Duse_ozone=1 -Denable_ozone_wayland_vkb=1 -Denable_xdg_shell=0"
 %endif
 
 GYP_EXTRA_FLAGS="${GYP_EXTRA_FLAGS} -Ddisable_nacl=%{_disable_nacl}"
index efd00c5..1591291 100644 (file)
@@ -58,9 +58,6 @@ class XWalkContent extends FrameLayout implements XWalkPreferences.KeyValueChang
 
     long mXWalkContent;
     long mWebContents;
-    boolean mReadyToLoad = false;
-    String mPendingUrl = null;
-    String mPendingData = null;
 
     public XWalkContent(Context context, AttributeSet attrs, XWalkView xwView) {
         super(context, attrs);
@@ -81,13 +78,8 @@ class XWalkContent extends FrameLayout implements XWalkPreferences.KeyValueChang
                 animated ? CompositingSurfaceType.TEXTURE_VIEW : CompositingSurfaceType.SURFACE_VIEW;
         mContentViewRenderView = new ContentViewRenderView(context, mWindow, surfaceType) {
             protected void onReadyToRender() {
-                if (mPendingUrl != null) {
-                    doLoadUrl(mPendingUrl, mPendingData);
-                    mPendingUrl = null;
-                    mPendingData = null;
-                }
-
-                mReadyToLoad = true;
+                // Anything depending on the underlying Surface readiness should
+                // be placed here.
             }
         };
         mLaunchScreenManager = new XWalkLaunchScreenManager(context, mXWalkView);
@@ -160,25 +152,17 @@ class XWalkContent extends FrameLayout implements XWalkPreferences.KeyValueChang
             return;
         }
 
-        if (mReadyToLoad) {
-            doLoadUrl(url, data);
-        } else {
-            mPendingUrl = url;
-            mPendingData = data;
-        }
+        doLoadUrl(url, data);
     }
 
     public void reload(int mode) {
-        if (mReadyToLoad) {
-            switch (mode) {
-                case XWalkView.RELOAD_IGNORE_CACHE:
-                    mContentViewCore.reloadIgnoringCache(true);
-                    break;
-                case XWalkView.RELOAD_NORMAL:
-                default:
-                    mContentViewCore.reload(true);
-
-            }
+        switch (mode) {
+            case XWalkView.RELOAD_IGNORE_CACHE:
+                mContentViewCore.reloadIgnoringCache(true);
+                break;
+            case XWalkView.RELOAD_NORMAL:
+            default:
+                mContentViewCore.reload(true);
         }
     }
 
diff --git a/src/xwalk/runtime/android/core/src/org/xwalk/core/XWalkPathHelper.java b/src/xwalk/runtime/android/core/src/org/xwalk/core/XWalkPathHelper.java
new file mode 100644 (file)
index 0000000..958dfb7
--- /dev/null
@@ -0,0 +1,60 @@
+// Copyright (c) 2014 Intel Corporation. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package org.xwalk.core.extension;
+
+import android.os.Environment;
+
+import java.util.ArrayList;
+
+import org.chromium.base.CalledByNative;
+import org.chromium.base.JNINamespace;
+
+@JNINamespace("xwalk")
+public class XWalkPathHelper {
+    private final static String TAG = "XWalkPathHelper";
+
+    public XWalkPathHelper() {}
+
+    public static void initialize() {
+        nativeSetDirectory("EXTERNAL", Environment.getExternalStorageDirectory().getPath());
+
+        String names[] = {
+            "ALARMS",
+            "DCIM",
+            "DOWNLOADS",
+            "MOVIES",
+            "MUSIC",
+            "NOTIFICATIONS",
+            "PICTURES",
+            "PODCASTS",
+            "RINGTONES"
+        };
+        String dirs[] = {
+            Environment.DIRECTORY_ALARMS,
+            Environment.DIRECTORY_DCIM,
+            Environment.DIRECTORY_DOWNLOADS,
+            Environment.DIRECTORY_MOVIES,
+            Environment.DIRECTORY_MUSIC,
+            Environment.DIRECTORY_NOTIFICATIONS,
+            Environment.DIRECTORY_PICTURES,
+            Environment.DIRECTORY_PODCASTS,
+            Environment.DIRECTORY_RINGTONES
+        };
+        for (int i = 0; i < names.length; ++i) {
+            nativeSetDirectory(names[i],
+                  Environment.getExternalStoragePublicDirectory(dirs[i]).getPath());
+        }
+    }
+
+    public static void setCacheDirectory(String path) {
+        nativeSetDirectory("CACHEDIR", path);
+    }
+
+    public static void setExternalCacheDirectory(String path) {
+        nativeSetDirectory("EXTERNAL_CACHEDIR", path);
+    }
+
+    private static native void nativeSetDirectory(String virtualRoot, String path);
+}
index c46ff78..4341f9f 100644 (file)
@@ -27,6 +27,7 @@ import org.chromium.base.ActivityState;
 import org.chromium.base.ApplicationStatus;
 
 import org.xwalk.core.extension.XWalkExtensionManager;
+import org.xwalk.core.extension.XWalkPathHelper;
 
 /**
  * <p>XWalkView represents an Android view for web apps/pages. Thus most of attributes
@@ -54,7 +55,11 @@ import org.xwalk.core.extension.XWalkExtensionManager;
  *
  * <p>Unlike other Android views, this class has to listen to system events like application life
  * cycle, intents, and activity result. The web engine inside this view need to get and handle
- * them. For example:</p>
+ * them. And the onDestroy() method of XWalkView MUST be called explicitly when an XWalkView
+ * won't be used anymore, otherwise it will cause the memory leak from the native side of the web
+ * engine. It's similar to the 
+ * <a href="http://developer.android.com/reference/android/webkit/WebView.html#destroy()">
+ * destroy()</a> method of Android WebView. For example:</p>
  *
  * <pre>
  *   import android.app.Activity;
@@ -311,6 +316,12 @@ public class XWalkView extends android.widget.FrameLayout {
         // Note that it has to be after above initialization.
         mExtensionManager = new XWalkExtensionManager(context, getActivity());
         mExtensionManager.loadExtensions();
+
+        XWalkPathHelper.initialize();
+        XWalkPathHelper.setCacheDirectory(
+                mContext.getApplicationContext().getCacheDir().getPath());
+        XWalkPathHelper.setExternalCacheDirectory(
+                mContext.getApplicationContext().getExternalCacheDir().getPath());
     }
 
     /**
index 1845580..1d85647 100644 (file)
@@ -137,7 +137,7 @@ public class XWalkExtensionManager implements XWalkExtensionContext {
         //        jsApiContent = getExtensionJSFileContent(mContext, Device.JS_API_PATH, true);
         //        new Device(jsApiContent, mExtensionContextImpl);
         //    } catch(IOException e) {
-        //        Log.e(TAG, "Failed to read js API file of internal extension: Device");
+        //        Log.w(TAG, "Failed to read js API file of internal extension: Device");
         //    }
         {
             String jsApiContent = "";
@@ -147,7 +147,7 @@ public class XWalkExtensionManager implements XWalkExtensionContext {
                 // Load PresentationExtension as an internal extension.
                 new PresentationExtension(PresentationExtension.NAME, jsApiContent, this);
             } catch (IOException e) {
-                Log.e(TAG, "Failed to read JS API file: " + PresentationExtension.JS_API_PATH);
+                Log.w(TAG, "Failed to read JS API file: " + PresentationExtension.JS_API_PATH);
             }
         }
 
@@ -159,7 +159,7 @@ public class XWalkExtensionManager implements XWalkExtensionContext {
                 new ScreenOrientationExtension(ScreenOrientationExtension.NAME, jsApiContent,
                                                ScreenOrientationExtension.JS_ENTRY_POINTS, this);
             } catch (IOException e) {
-                Log.e(TAG, "Failed to read JS API file: " + ScreenOrientationExtension.JS_API_PATH);
+                Log.w(TAG, "Failed to read JS API file: " + ScreenOrientationExtension.JS_API_PATH);
             }
         }
 
@@ -172,7 +172,7 @@ public class XWalkExtensionManager implements XWalkExtensionContext {
                 new LaunchScreenExtension(LaunchScreenExtension.NAME, jsApiContent,
                                           LaunchScreenExtension.JS_ENTRY_POINTS, this);
             } catch (IOException e) {
-                Log.e(TAG, "Failed to read JS API file: " + LaunchScreenExtension.JS_API_PATH);
+                Log.w(TAG, "Failed to read JS API file: " + LaunchScreenExtension.JS_API_PATH);
             }
         }
 
@@ -183,7 +183,7 @@ public class XWalkExtensionManager implements XWalkExtensionContext {
                         mContext, Contacts.JS_API_PATH, true);
                 new Contacts(jsApiContent, this);
             } catch(IOException e) {
-                Log.e(TAG, "Failed to read JS API file: " + Contacts.JS_API_PATH);
+                Log.w(TAG, "Failed to read JS API file: " + Contacts.JS_API_PATH);
             }
         }
 
@@ -194,7 +194,7 @@ public class XWalkExtensionManager implements XWalkExtensionContext {
                         mContext, DeviceCapabilities.JS_API_PATH, true);
                 new DeviceCapabilities(jsApiContent, this);
             } catch(IOException e) {
-                Log.e(TAG, "Failed to read JS API file: " + DeviceCapabilities.JS_API_PATH);
+                Log.w(TAG, "Failed to read JS API file: " + DeviceCapabilities.JS_API_PATH);
             }
         }
         {
@@ -204,7 +204,7 @@ public class XWalkExtensionManager implements XWalkExtensionContext {
                         mContext, Messaging.JS_API_PATH, true);
                 new Messaging(jsApiContent, this);
             } catch(IOException e) {
-                Log.e(TAG, "Failed to read JS API file: " + Messaging.JS_API_PATH);
+                Log.w(TAG, "Failed to read JS API file: " + Messaging.JS_API_PATH);
             }
         }
     }
@@ -217,7 +217,7 @@ public class XWalkExtensionManager implements XWalkExtensionContext {
         try {
             configFileContent = getExtensionJSFileContent(mActivity, EXTENSION_CONFIG_FILE, false);
         } catch (IOException e) {
-            Log.e(TAG, "Failed to read extensions-config.json");
+            Log.w(TAG, "Failed to read extensions-config.json");
             return;
         }
 
@@ -240,7 +240,7 @@ public class XWalkExtensionManager implements XWalkExtensionContext {
                 try {
                     jsApi = getExtensionJSFileContent(mActivity, jsApiFile, false);
                 } catch (IOException e) {
-                    Log.e(TAG, "Failed to read the file " + jsApiFile);
+                    Log.w(TAG, "Failed to read the file " + jsApiFile);
                     return;
                 }
 
@@ -249,7 +249,7 @@ public class XWalkExtensionManager implements XWalkExtensionContext {
                 }
             }
         } catch (JSONException e) {
-            Log.e(TAG, "Failed to parse extensions-config.json");
+            Log.w(TAG, "Failed to parse extensions-config.json");
         }
     }
 
index 9c9849a..4df3726 100644 (file)
@@ -18,6 +18,7 @@
 #include "xwalk/runtime/browser/android/xwalk_contents_io_thread_client_impl.h"
 #include "xwalk/runtime/browser/android/xwalk_dev_tools_server.h"
 #include "xwalk/runtime/browser/android/xwalk_http_auth_handler.h"
+#include "xwalk/runtime/browser/android/xwalk_path_helper.h"
 #include "xwalk/runtime/browser/android/xwalk_settings.h"
 #include "xwalk/runtime/browser/android/xwalk_view_delegate.h"
 #include "xwalk/runtime/browser/android/xwalk_web_contents_delegate.h"
@@ -41,6 +42,7 @@ static base::android::RegistrationMethod kXWalkRegisteredMethods[] = {
   { "XWalkDevToolsServer", RegisterXWalkDevToolsServer },
   { "XWalkExtensionAndroid", extensions::RegisterXWalkExtensionAndroid },
   { "XWalkHttpAuthHandler", RegisterXWalkHttpAuthHandler },
+  { "XWalkPathHelper", RegisterXWalkPathHelper },
   { "XWalkSettings", RegisterXWalkSettings },
   { "XWalkViewDelegate", RegisterXWalkViewDelegate },
   { "XWalkWebContentsDelegate", RegisterXWalkWebContentsDelegate },
index 805a51b..852c4e9 100644 (file)
@@ -145,10 +145,10 @@ content::WebContents* XWalkContent::CreateWebContents(
       contents_client_bridge_.get());
   XWalkContentsIoThreadClientImpl::Associate(web_contents,
       ScopedJavaLocalRef<jobject>(env, io_thread_client));
-  int child_id = web_contents->GetRenderProcessHost()->GetID();
-  int route_id = web_contents->GetRoutingID();
+  int render_process_id = web_contents->GetRenderProcessHost()->GetID();
+  int render_frame_id = web_contents->GetRoutingID();
   RuntimeResourceDispatcherHostDelegateAndroid::OnIoThreadClientReady(
-      child_id, route_id);
+      render_process_id, render_frame_id);
   InterceptNavigationDelegate::Associate(web_contents,
       make_scoped_ptr(new InterceptNavigationDelegate(
           env, intercept_navigation_delegate)));
@@ -235,7 +235,9 @@ jboolean XWalkContent::SetManifest(JNIEnv* env,
   render_view_host_ext_->SetOriginAccessWhitelist(url, match_patterns);
 
   std::string csp;
-  manifest.GetString(keys::kCSPKey, &csp);
+  // FIXME: Switch to 'csp' field, accordingly to
+  // http://w3c.github.io/manifest-csp/.
+  manifest.GetString(keys::kCSPKeyLegacy, &csp);
   RuntimeContext* runtime_context =
       XWalkRunner::GetInstance()->runtime_context();
   CHECK(runtime_context);
diff --git a/src/xwalk/runtime/browser/android/xwalk_path_helper.cc b/src/xwalk/runtime/browser/android/xwalk_path_helper.cc
new file mode 100644 (file)
index 0000000..e7566d1
--- /dev/null
@@ -0,0 +1,44 @@
+// Copyright (c) 2014 Intel Corporation. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "xwalk/runtime/browser/android/xwalk_path_helper.h"
+
+#include "base/android/jni_android.h"
+#include "base/android/jni_weak_ref.h"
+#include "base/bind.h"
+#include "jni/XWalkPathHelper_jni.h"
+#include "xwalk/extensions/common/xwalk_extension.h"
+#include "xwalk/runtime/browser/xwalk_browser_main_parts.h"
+#include "xwalk/runtime/browser/xwalk_content_browser_client.h"
+
+namespace xwalk {
+
+typedef std::map<std::string, base::FilePath> VirtualRootMap;
+VirtualRootMap XWalkPathHelper::virtual_root_map_;
+
+VirtualRootMap XWalkPathHelper::GetVirtualRootMap() {
+  return virtual_root_map_;
+}
+
+void XWalkPathHelper::SetDirectory(const std::string& virtualRoot,
+                                   const std::string& path) {
+  virtual_root_map_[virtualRoot] =
+      base::FilePath::FromUTF8Unsafe(path);
+}
+
+static void SetDirectory(JNIEnv* env, jclass clazz,
+    jstring virtualRoot, jstring path) {
+  const char* strVirtualRoot = env->GetStringUTFChars(virtualRoot, NULL);
+  const char* strPath = env->GetStringUTFChars(path, NULL);
+  XWalkPathHelper::SetDirectory(
+      std::string(strVirtualRoot), std::string(strPath));
+  env->ReleaseStringUTFChars(virtualRoot, strVirtualRoot);
+  env->ReleaseStringUTFChars(path, strPath);
+}
+
+bool RegisterXWalkPathHelper(JNIEnv* env) {
+  return RegisterNativesImpl(env) >= 0;
+}
+
+}  // namespace xwalk
diff --git a/src/xwalk/runtime/browser/android/xwalk_path_helper.h b/src/xwalk/runtime/browser/android/xwalk_path_helper.h
new file mode 100644 (file)
index 0000000..223f3ee
--- /dev/null
@@ -0,0 +1,34 @@
+// Copyright (c) 2014 Intel Corporation. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef XWALK_RUNTIME_BROWSER_ANDROID_XWALK_PATH_HELPER_H_
+#define XWALK_RUNTIME_BROWSER_ANDROID_XWALK_PATH_HELPER_H_
+
+#include <jni.h>
+#include <map>
+#include <string>
+
+#include "base/files/file_path.h"
+
+namespace xwalk {
+
+typedef std::map<std::string, base::FilePath> VirtualRootMap;
+
+class XWalkPathHelper {
+ public:
+  static void SetDirectory(const std::string& virtualRoot,
+                           const std::string& path);
+  static VirtualRootMap GetVirtualRootMap();
+
+ private:
+  static VirtualRootMap virtual_root_map_;
+
+  DISALLOW_COPY_AND_ASSIGN(XWalkPathHelper);
+};
+
+bool RegisterXWalkPathHelper(JNIEnv* env);
+
+}  // namespace xwalk
+
+#endif  // XWALK_RUNTIME_BROWSER_ANDROID_XWALK_PATH_HELPER_H_
index 45574d3..229ff6f 100644 (file)
@@ -31,7 +31,7 @@ class XWalkDevToolsTest : public InProcessBrowserTest {
 IN_PROC_BROWSER_TEST_F(XWalkDevToolsTest, RemoteDebugging) {
   GURL localhost_url("http://127.0.0.1:9222");
   Runtime* debugging_host = Runtime::CreateWithDefaultWindow(
-      runtime()->runtime_context(), localhost_url, runtime_registry());
+      GetRuntimeContext(), localhost_url, runtime_registry());
   content::WaitForLoadStop(debugging_host->web_contents());
   base::string16 real_title = debugging_host->web_contents()->GetTitle();
   base::string16 expected_title = base::ASCIIToUTF16("XWalk Remote Debugging");
index f039da8..929a474 100644 (file)
@@ -76,7 +76,6 @@ Runtime::Runtime(content::WebContents* web_contents, Observer* observer)
       fullscreen_options_(NO_FULLSCREEN),
       observer_(observer) {
   web_contents_->SetDelegate(this);
-  runtime_context_ = RuntimeContext::FromWebContents(web_contents);
   content::NotificationService::current()->Notify(
        xwalk::NOTIFICATION_RUNTIME_OPENED,
        content::Source<Runtime>(this),
index 23fb581..51be3f3 100644 (file)
@@ -74,7 +74,6 @@ class Runtime : public content::WebContentsDelegate,
 
   content::WebContents* web_contents() const { return web_contents_.get(); }
   NativeAppWindow* window() const { return window_; }
-  RuntimeContext* runtime_context() const { return runtime_context_; }
   gfx::Image app_icon() const { return app_icon_; }
 
   content::RenderProcessHost* GetRenderProcessHost();
@@ -163,9 +162,6 @@ class Runtime : public content::WebContentsDelegate,
   void InitRootWindow();
 #endif
 
-  // The browsing context.
-  xwalk::RuntimeContext* runtime_context_;
-
   // Notification manager.
   content::NotificationRegistrar registrar_;
 
index 52dd22c..daa625a 100644 (file)
@@ -55,13 +55,13 @@ namespace xwalk {
 
 // Calls through the IoThreadClient to check the embedders settings to determine
 // if the request should be cancelled. There may not always be an IoThreadClient
-// available for the |child_id|, |route_id| pair (in the case of newly created
-// pop up windows, for example) and in that case the request and the client
-// callbacks will be deferred the request until a client is ready.
+// available for the |render_process_id|, |render_frame_id| pair (in the case of
+// newly created pop up windows, for example) and in that case the request and
+// the client callbacks will be deferred the request until a client is ready.
 class IoThreadClientThrottle : public content::ResourceThrottle {
  public:
-  IoThreadClientThrottle(int child_id,
-                         int route_id,
+  IoThreadClientThrottle(int render_process_id,
+                         int render_frame_id,
                          net::URLRequest* request);
   virtual ~IoThreadClientThrottle();
 
@@ -71,23 +71,24 @@ class IoThreadClientThrottle : public content::ResourceThrottle {
   virtual const char* GetNameForLogging() const OVERRIDE;
 
   bool MaybeDeferRequest(bool* defer);
-  void OnIoThreadClientReady(int new_child_id, int new_route_id);
+  void OnIoThreadClientReady(int new_render_process_id,
+                             int new_render_frame_id);
   bool MaybeBlockRequest();
   bool ShouldBlockRequest();
-  int get_child_id() const { return child_id_; }
-  int get_route_id() const { return route_id_; }
+  int render_process_id() const { return render_process_id_; }
+  int render_frame_id() const { return render_frame_id_; }
 
  private:
-  int child_id_;
-  int route_id_;
+  int render_process_id_;
+  int render_frame_id_;
   net::URLRequest* request_;
 };
 
-IoThreadClientThrottle::IoThreadClientThrottle(int child_id,
-                                               int route_id,
+IoThreadClientThrottle::IoThreadClientThrottle(int render_process_id,
+                                               int render_frame_id,
                                                net::URLRequest* request)
-    : child_id_(child_id),
-      route_id_(route_id),
+    : render_process_id_(render_process_id),
+      render_frame_id_(render_frame_id),
       request_(request) { }
 
 IoThreadClientThrottle::~IoThreadClientThrottle() {
@@ -97,12 +98,12 @@ IoThreadClientThrottle::~IoThreadClientThrottle() {
 }
 
 void IoThreadClientThrottle::WillStartRequest(bool* defer) {
-  if (route_id_ < 1) {
+  if (render_frame_id_ < 1) {
     // OPTIONS is used for preflighted requests which are generated internally.
     DCHECK_EQ("OPTIONS", request_->method());
     return;
   }
-  DCHECK(child_id_);
+  DCHECK(render_process_id_);
   if (!MaybeDeferRequest(defer)) {
     MaybeBlockRequest();
   }
@@ -123,17 +124,17 @@ bool IoThreadClientThrottle::MaybeDeferRequest(bool* defer) {
   // Defer all requests of a pop up that is still not associated with Java
   // client so that the client will get a chance to override requests.
   scoped_ptr<XWalkContentsIoThreadClient> io_client =
-      XWalkContentsIoThreadClient::FromID(child_id_, route_id_);
+      XWalkContentsIoThreadClient::FromID(render_process_id_, render_frame_id_);
   if (io_client && io_client->PendingAssociation()) {
     *defer = true;
     RuntimeResourceDispatcherHostDelegateAndroid::AddPendingThrottle(
-        child_id_, route_id_, this);
+        render_process_id_, render_frame_id_, this);
   }
   return *defer;
 }
 
-void IoThreadClientThrottle::OnIoThreadClientReady(int new_child_id,
-                                                   int new_route_id) {
+void IoThreadClientThrottle::OnIoThreadClientReady(int new_render_process_id,
+                                                   int new_render_frame_id) {
   DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
 
   if (!MaybeBlockRequest()) {
@@ -151,7 +152,7 @@ bool IoThreadClientThrottle::MaybeBlockRequest() {
 
 bool IoThreadClientThrottle::ShouldBlockRequest() {
   scoped_ptr<XWalkContentsIoThreadClient> io_client =
-      XWalkContentsIoThreadClient::FromID(child_id_, route_id_);
+      XWalkContentsIoThreadClient::FromID(render_process_id_, render_frame_id_);
   DCHECK(io_client.get());
 
   // Part of implementation of WebSettings.allowContentAccess.
@@ -220,6 +221,9 @@ void RuntimeResourceDispatcherHostDelegateAndroid::RequestBeginning(
     int child_id,
     int route_id,
     ScopedVector<content::ResourceThrottle>* throttles) {
+  const content::ResourceRequestInfo* request_info =
+      content::ResourceRequestInfo::ForRequest(request);
+
   // We allow intercepting only navigations within main frames. This
   // is used to post onPageStarted. We handle shouldOverrideUrlLoading
   // via a sync IPC for url loading in iframe.
@@ -233,12 +237,13 @@ void RuntimeResourceDispatcherHostDelegateAndroid::RequestBeginning(
   // request relates to a not-yet-created popup window, then the client will
   // be non-NULL but PopupPendingAssociation() will be set.
   scoped_ptr<XWalkContentsIoThreadClient> io_client =
-      XWalkContentsIoThreadClient::FromID(child_id, route_id);
+      XWalkContentsIoThreadClient::FromID(
+          child_id, request_info->GetRenderFrameID());
   if (!io_client)
     return;
 
   throttles->push_back(new IoThreadClientThrottle(
-      child_id, route_id, request));
+      child_id, request_info->GetRenderFrameID(), request));
 }
 
 void RuntimeResourceDispatcherHostDelegateAndroid::DownloadStarting(
@@ -269,8 +274,12 @@ void RuntimeResourceDispatcherHostDelegateAndroid::DownloadStarting(
 
   request->Cancel();
 
+  const content::ResourceRequestInfo* request_info =
+      content::ResourceRequestInfo::ForRequest(request);
+
   scoped_ptr<XWalkContentsIoThreadClient> io_client =
-      XWalkContentsIoThreadClient::FromID(child_id, route_id);
+      XWalkContentsIoThreadClient::FromID(
+          child_id, request_info->GetRenderFrameID());
 
   // POST request cannot be repeated in general, so prevent client from
   // retrying the same request, even if it is with a GET.
@@ -321,7 +330,7 @@ void RuntimeResourceDispatcherHostDelegateAndroid::OnResponseStarted(
             request, auto_login_parser::ALLOW_ANY_REALM, &header_data)) {
       scoped_ptr<XWalkContentsIoThreadClient> io_client =
           XWalkContentsIoThreadClient::FromID(request_info->GetChildID(),
-                                              request_info->GetRouteID());
+                                              request_info->GetRenderFrameID());
       if (io_client) {
         io_client->NewLoginRequest(
             header_data.realm, header_data.account, header_data.args);
@@ -335,7 +344,8 @@ RemovePendingThrottleOnIoThread(
     IoThreadClientThrottle* throttle) {
   DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
   PendingThrottleMap::iterator it = pending_throttles_.find(
-      ChildRouteIDPair(throttle->get_child_id(), throttle->get_route_id()));
+      FrameRouteIDPair(throttle->render_process_id(),
+                       throttle->render_frame_id()));
   if (it != pending_throttles_.end()) {
     pending_throttles_.erase(it);
   }
@@ -343,21 +353,21 @@ RemovePendingThrottleOnIoThread(
 
 // static
 void RuntimeResourceDispatcherHostDelegateAndroid::OnIoThreadClientReady(
-    int new_child_id,
-    int new_route_id) {
+    int new_render_process_id,
+    int new_render_frame_id) {
   BrowserThread::PostTask(BrowserThread::IO, FROM_HERE,
       base::Bind(
           &RuntimeResourceDispatcherHostDelegateAndroid::
           OnIoThreadClientReadyInternal,
           base::Unretained(
               g_runtime_resource_dispatcher_host_delegate_android.Pointer()),
-          new_child_id, new_route_id));
+          new_render_process_id, new_render_frame_id));
 }
 
 // static
 void RuntimeResourceDispatcherHostDelegateAndroid::AddPendingThrottle(
-    int child_id,
-    int route_id,
+    int render_process_id,
+    int render_frame_id,
     IoThreadClientThrottle* pending_throttle) {
   BrowserThread::PostTask(BrowserThread::IO, FROM_HERE,
       base::Bind(
@@ -365,31 +375,33 @@ void RuntimeResourceDispatcherHostDelegateAndroid::AddPendingThrottle(
               AddPendingThrottleOnIoThread,
           base::Unretained(
               g_runtime_resource_dispatcher_host_delegate_android.Pointer()),
-          child_id, route_id, pending_throttle));
+          render_process_id, render_frame_id, pending_throttle));
 }
 
 void RuntimeResourceDispatcherHostDelegateAndroid::
     AddPendingThrottleOnIoThread(
-        int child_id,
-        int route_id,
+        int render_process_id,
+        int render_frame_id,
         IoThreadClientThrottle* pending_throttle) {
   DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
   pending_throttles_.insert(
-      std::pair<ChildRouteIDPair, IoThreadClientThrottle*>(
-          ChildRouteIDPair(child_id, route_id), pending_throttle));
+      std::pair<FrameRouteIDPair, IoThreadClientThrottle*>(
+          FrameRouteIDPair(render_process_id, render_frame_id),
+          pending_throttle));
 }
 
 void RuntimeResourceDispatcherHostDelegateAndroid::
 OnIoThreadClientReadyInternal(
-    int new_child_id,
-    int new_route_id) {
+    int new_render_process_id,
+    int new_render_frame_id) {
   DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
   PendingThrottleMap::iterator it = pending_throttles_.find(
-      ChildRouteIDPair(new_child_id, new_route_id));
+      FrameRouteIDPair(new_render_process_id, new_render_frame_id));
 
   if (it != pending_throttles_.end()) {
     IoThreadClientThrottle* throttle = it->second;
-    throttle->OnIoThreadClientReady(new_child_id, new_route_id);
+    throttle->OnIoThreadClientReady(new_render_process_id,
+                                    new_render_frame_id);
     pending_throttles_.erase(it);
   }
 }
index 0b517f2..559b8df 100644 (file)
@@ -65,21 +65,23 @@ class RuntimeResourceDispatcherHostDelegateAndroid
 
   void RemovePendingThrottleOnIoThread(IoThreadClientThrottle* throttle);
 
-  static void OnIoThreadClientReady(int new_child_id, int new_route_id);
-  static void AddPendingThrottle(int child_id,
-                                 int route_id,
+  static void OnIoThreadClientReady(int new_render_process_id,
+                                    int new_render_frame_id);
+  static void AddPendingThrottle(int render_process_id,
+                                 int render_frame_id,
                                  IoThreadClientThrottle* pending_throttle);
  private:
   friend struct base::DefaultLazyInstanceTraits<
       RuntimeResourceDispatcherHostDelegateAndroid>;
   // These methods must be called on IO thread.
-  void OnIoThreadClientReadyInternal(int child_id, int route_id);
-  void AddPendingThrottleOnIoThread(int child_id,
-                                    int route_id,
+  void OnIoThreadClientReadyInternal(int new_render_process_id,
+                                     int new_render_frame_id);
+  void AddPendingThrottleOnIoThread(int render_process_id,
+                                    int render_frame_id,
                                     IoThreadClientThrottle* pending_throttle);
 
-  typedef std::pair<int, int> ChildRouteIDPair;
-  typedef std::map<ChildRouteIDPair, IoThreadClientThrottle*>
+  typedef std::pair<int, int> FrameRouteIDPair;
+  typedef std::map<FrameRouteIDPair, IoThreadClientThrottle*>
       PendingThrottleMap;
 
   // Only accessed on the IO thread.
index 6e3f772..4c4ba30 100644 (file)
@@ -110,7 +110,7 @@ IN_PROC_BROWSER_TEST_F(XWalkRuntimeTest, CreateAndCloseRuntime) {
   // Create a new Runtime instance.
   GURL url(test_server()->GetURL("test.html"));
   Runtime* new_runtime = Runtime::CreateWithDefaultWindow(
-      runtime()->runtime_context(), url, runtime_registry());
+      GetRuntimeContext(), url, runtime_registry());
   EXPECT_TRUE(url == new_runtime->web_contents()->GetURL());
   EXPECT_EQ(new_runtime, WaitForSingleNewRuntime());
   content::RunAllPendingInMessageLoop();
@@ -136,7 +136,7 @@ IN_PROC_BROWSER_TEST_F(XWalkRuntimeTest, LoadURLAndClose) {
 IN_PROC_BROWSER_TEST_F(XWalkRuntimeTest, CloseNativeWindow) {
   GURL url(test_server()->GetURL("test.html"));
   Runtime* new_runtime = Runtime::CreateWithDefaultWindow(
-      runtime()->runtime_context(), url, runtime_registry());
+      GetRuntimeContext(), url, runtime_registry());
   size_t len = runtimes().size();
   new_runtime->window()->Close();
   content::RunAllPendingInMessageLoop();
@@ -147,7 +147,7 @@ IN_PROC_BROWSER_TEST_F(XWalkRuntimeTest, CloseNativeWindow) {
 IN_PROC_BROWSER_TEST_F(XWalkRuntimeTest, LaunchWithFullscreenWindow) {
   GURL url(test_server()->GetURL("test.html"));
   Runtime* new_runtime = Runtime::Create(
-      runtime()->runtime_context(), runtime_registry());
+      GetRuntimeContext(), runtime_registry());
 
   NativeAppWindow::CreateParams params;
   params.state = ui::SHOW_STATE_FULLSCREEN;
index 0835049..9f9fd52 100644 (file)
@@ -7,9 +7,12 @@
 #include <string>
 
 #include "base/files/file_path.h"
+#include "base/strings/stringprintf.h"
 #include "net/base/filename_util.h"
+#include "net/base/net_errors.h"
 #include "url/gurl.h"
 #include "xwalk/application/common/constants.h"
+#include "third_party/WebKit/public/platform/WebURLError.h"
 #include "third_party/WebKit/public/web/WebFrame.h"
 #include "third_party/WebKit/public/web/WebDocument.h"
 
@@ -88,4 +91,24 @@ bool XWalkContentRendererClientTizen::WillSendRequest(
   return true;
 }
 
+bool XWalkContentRendererClientTizen::HasErrorPage(int http_status_code,
+                                                   std::string* error_domain) {
+  return true;
+}
+
+void XWalkContentRendererClientTizen::GetNavigationErrorStrings(
+    content::RenderView* render_view,
+    blink::WebFrame* frame,
+    const blink::WebURLRequest& failed_request,
+    const blink::WebURLError& error,
+    std::string* error_html,
+    base::string16* error_description) {
+  if (error_html) {
+    *error_html =
+        base::StringPrintf("<html><body style=\"text-align: center;\">"
+                           "<h1>NET ERROR : %s</h1></body></html>",
+                           net::ErrorToString(error.reason));
+  }
+}
+
 }  // namespace xwalk
index 258369b..22cf7d5 100644 (file)
@@ -5,6 +5,8 @@
 #ifndef XWALK_RUNTIME_RENDERER_TIZEN_XWALK_CONTENT_RENDERER_CLIENT_TIZEN_H_
 #define XWALK_RUNTIME_RENDERER_TIZEN_XWALK_CONTENT_RENDERER_CLIENT_TIZEN_H_
 
+#include <string>
+
 #include "xwalk/runtime/renderer/xwalk_content_renderer_client.h"
 
 namespace xwalk {
@@ -18,6 +20,18 @@ class XWalkContentRendererClientTizen : public XWalkContentRendererClient {
                                const GURL& url,
                                const GURL& first_party_for_cookies,
                                GURL* new_url) OVERRIDE;
+
+  virtual bool HasErrorPage(int http_status_code,
+                            std::string* error_domain) OVERRIDE;
+
+  virtual void GetNavigationErrorStrings(
+      content::RenderView* render_view,
+      blink::WebFrame* frame,
+      const blink::WebURLRequest& failed_request,
+      const blink::WebURLError& error,
+      std::string* error_html,
+      base::string16* error_description) OVERRIDE;
+
  private:
   DISALLOW_COPY_AND_ASSIGN(XWalkContentRendererClientTizen);
 };
diff --git a/src/xwalk/test/android/data/native_file_system.html b/src/xwalk/test/android/data/native_file_system.html
new file mode 100644 (file)
index 0000000..518bd0f
--- /dev/null
@@ -0,0 +1,135 @@
+<html>
+  <head>
+    <title></title>
+  </head>
+  <body>
+    <script>
+      var current_test = 0;
+      var test_list = [
+        writeFile,
+        readFile,
+        removeFile,
+        createDirectory,
+        readDirectoryEntries,
+        removeDirectory,
+        endTest
+      ];
+
+      function runNextTest() {
+        if (current_test < test_list.length) {
+          test_list[current_test++]();
+        }
+      };
+
+      function reportFail(message) {
+        console.log(message);
+        document.title = "Fail";
+        document.body.innerText = "Fail";
+      };
+
+      function endTest() {
+        document.title = "Pass";
+        document.body.innerText = "Pass";
+      };
+      
+      function writeFile() {
+        xwalk.experimental.native_file_system.requestNativeFileSystem("cachedir",
+          function(fs) {
+            fs.root.getFile("/cachedir/1.txt", {create: true}, function (entry) {
+              entry.createWriter(function (writer) {
+                var blob = new Blob(["1234567890"], {type: "text/plain"});
+                writer.write(blob);
+                runNextTest();
+              },
+              function(e) {reportFail(JSON.stringify(e))});
+            },
+          function(e) {reportFail(JSON.stringify(e))});
+        });
+      }
+
+      function readFile() {
+        xwalk.experimental.native_file_system.requestNativeFileSystem("cachedir",
+          function(fs) {
+            fs.root.getFile("/cachedir/1.txt", {create: false}, function (entry) {
+                entry.file(function(file) {
+                  reader = new FileReader();
+                  reader.onloadend = function(e) {
+                    if ("1234567890" == this.result) {
+                      runNextTest();
+                    } else {
+                      reportFail();
+                    }
+                  };
+                  reader.readAsText(file);
+                },
+                function(e) {reportFail(JSON.stringify(e))});
+            },
+            function(e) {reportFail(JSON.stringify(e))});
+        },
+        function(e) {reportFail(JSON.stringify(e))});
+      };
+
+
+      function removeFile() {
+        xwalk.experimental.native_file_system.requestNativeFileSystem("cachedir",
+            function(fs) {
+              fs.root.getFile("/cachedir/1.txt", {create: false}, function (entry) {
+                entry.remove(function () {
+                      runNextTest();
+                    },
+                    function(e) {reportFail(JSON.stringify(e))});
+              },
+              function(e) {reportFail(JSON.stringify(e))});
+            }
+        );
+      }
+
+      function createDirectory() {
+        xwalk.experimental.native_file_system.requestNativeFileSystem("cachedir",
+            function(fs) {
+              fs.root.getDirectory("/cachedir/justfortest", {create: true}, function (entry) {
+                runNextTest();
+              },
+              function(e) {reportFail(JSON.stringify(e))});
+            }
+        );
+      }
+
+      function readDirectoryEntries() {
+        xwalk.experimental.native_file_system.requestNativeFileSystem("cachedir",
+            function(fs) {
+              fs.root.getDirectory("/cachedir/", {create: false}, function (entry) {
+                var dirReader = entry.createReader();
+                var entries = [];
+                dirReader.readEntries(function(results) {
+                    if (0 < results.length) {
+                      runNextTest();
+                    } else {
+                      reportFail("You app home directory is empty!");
+                    }
+                  },
+                  function(e) {reportFail(JSON.stringify(e))}
+                );
+                runNextTest();
+              },
+              function(e) {reportFail(JSON.stringify(e))});
+            }
+        );
+      }
+
+      function removeDirectory() {
+        xwalk.experimental.native_file_system.requestNativeFileSystem("cachedir",
+            function(fs) {
+              fs.root.getDirectory("/cachedir/justfortest", {create: false}, function (entry) {
+                entry.remove(function () {runNextTest();},
+                    function(e) {reportFail(JSON.stringify(e))});
+              },
+              function(e) {reportFail(JSON.stringify(e))});
+            }
+        );
+      }
+
+      runNextTest();
+    </script>
+  </body>
+</html>
diff --git a/src/xwalk/test/android/runtime_client/javatests/src/org/xwalk/runtime/client/test/NativeFileSystemTest.java b/src/xwalk/test/android/runtime_client/javatests/src/org/xwalk/runtime/client/test/NativeFileSystemTest.java
new file mode 100644 (file)
index 0000000..af797a9
--- /dev/null
@@ -0,0 +1,26 @@
+// Copyright (c) 2014 Intel Corporation. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package org.xwalk.runtime.client.test;
+
+import android.test.suitebuilder.annotation.SmallTest;
+import org.chromium.base.test.util.DisabledTest;
+import org.chromium.base.test.util.Feature;
+import org.xwalk.runtime.client.shell.XWalkRuntimeClientShellActivity;
+import org.xwalk.test.util.RuntimeClientApiTestBase;
+
+/**
+ * Test suite for Native File System API.
+ */
+public class NativeFileSystemTest extends XWalkRuntimeClientTestBase {
+    // @SmallTest
+    // @Feature({"NativeFileSystem"})
+    @DisabledTest
+    public void testNativeFileSystem() throws Throwable {
+        RuntimeClientApiTestBase<XWalkRuntimeClientShellActivity> helper =
+                new RuntimeClientApiTestBase<XWalkRuntimeClientShellActivity>(
+                        getTestUtil(), this);
+        helper.testNativeFileSystem();
+    }
+}
diff --git a/src/xwalk/test/android/runtime_client_embedded/javatests/src/org/xwalk/runtime/client/embedded/test/NativeFileSystemTest.java b/src/xwalk/test/android/runtime_client_embedded/javatests/src/org/xwalk/runtime/client/embedded/test/NativeFileSystemTest.java
new file mode 100644 (file)
index 0000000..37a2bd0
--- /dev/null
@@ -0,0 +1,26 @@
+// Copyright (c) 2014 Intel Corporation. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package org.xwalk.runtime.client.embedded.test;
+
+import android.test.suitebuilder.annotation.SmallTest;
+import org.chromium.base.test.util.DisabledTest;
+import org.chromium.base.test.util.Feature;
+import org.xwalk.runtime.client.embedded.shell.XWalkRuntimeClientEmbeddedShellActivity;
+import org.xwalk.test.util.RuntimeClientApiTestBase;
+
+/**
+ * Test suite for Native File System API.
+ */
+public class NativeFileSystemTest extends XWalkRuntimeClientTestBase {
+    // @SmallTest
+    // @Feature({"NativeFileSystem"})
+    @DisabledTest
+    public void testNativeFileSystem() throws Throwable {
+        RuntimeClientApiTestBase<XWalkRuntimeClientEmbeddedShellActivity> helper =
+                new RuntimeClientApiTestBase<XWalkRuntimeClientEmbeddedShellActivity>(
+                        getTestUtil(), this);
+        helper.testNativeFileSystem();
+    }
+}
index 607ac69..5340d3b 100644 (file)
@@ -328,6 +328,13 @@ public class RuntimeClientApiTestBase<T extends Activity> {
         String title = mTestUtil.loadAssetFileAndWaitForTitle("messaging_mini.html");
         mTestCase.assertEquals("Pass", title);
     }
+
+    // For internal extension implementation of NativeFileSystem.
+    public void testNativeFileSystem() throws Throwable {
+        String title = mTestUtil.loadAssetFileAndWaitForTitle("native_file_system.html");
+        mTestCase.assertEquals("Pass", title);
+    }
+
     // For onPause, onResume.
     public void testPauseAndResume() throws Throwable {
         String title = "";
index a54a81f..a0ba604 100644 (file)
@@ -126,6 +126,10 @@ void InProcessBrowserTest::SetUp() {
   BrowserTestBase::SetUp();
 }
 
+xwalk::RuntimeContext* InProcessBrowserTest::GetRuntimeContext() const {
+  return XWalkRunner::GetInstance()->runtime_context();
+}
+
 void InProcessBrowserTest::PrepareTestCommandLine(
     base::CommandLine* command_line) {
   // Propagate commandline settings from test_launcher_utils.
@@ -145,7 +149,7 @@ void InProcessBrowserTest::RunTestOnMainThreadLoop() {
   // when needed and thus the 'runtime()' method should be removed
   // as well as 'runtime_' initialization below.
   runtime_ = Runtime::CreateWithDefaultWindow(
-      XWalkRunner::GetInstance()->runtime_context(),
+          GetRuntimeContext(),
           GURL(), runtime_registry_.get());
   content::WaitForLoadStop(runtime_->web_contents());
   content::RunAllPendingInMessageLoop();
index e9d1bcd..e84f872 100644 (file)
@@ -70,6 +70,8 @@ class InProcessBrowserTest : public content::BrowserTestBase {
   RuntimeRegistry* runtime_registry() const {
       return runtime_registry_.get(); }
 
+  xwalk::RuntimeContext* GetRuntimeContext() const;
+
   // Override this to add any custom cleanup code that needs to be done on the
   // main thread before the browser is torn down.
   virtual void ProperMainThreadCleanup() {}
index c2d9dd0..4a63200 100644 (file)
         'runtime/browser/android/xwalk_http_auth_handler_base.h',
         'runtime/browser/android/xwalk_login_delegate.cc',
         'runtime/browser/android/xwalk_login_delegate.h',
+        'runtime/browser/android/xwalk_path_helper.cc',
+        'runtime/browser/android/xwalk_path_helper.h',
         'runtime/browser/android/xwalk_request_interceptor.cc',
         'runtime/browser/android/xwalk_request_interceptor.h',
         'runtime/browser/android/xwalk_settings.cc',
             'tizen/xwalk_tizen.gypi:xwalk_tizen_lib',
             '<(DEPTH)/third_party/jsoncpp/jsoncpp.gyp:jsoncpp',
           ],
+          'cflags': [
+            '<!@(pkg-config --cflags libtzplatform-config)',
+          ],
+          'link_settings': {
+            'libraries': [
+              '<!@(pkg-config --libs libtzplatform-config)',
+            ],
+          },
           'sources': [
             'experimental/native_file_system/virtual_root_provider_tizen.cc',
             'runtime/browser/tizen/tizen_locale_listener.cc',
index 24136f9..c42879c 100644 (file)
         'runtime/android/core/src/org/xwalk/core/XWalkContent.java',
         'runtime/android/core/src/org/xwalk/core/XWalkCookieManager.java',
         'runtime/android/core/src/org/xwalk/core/XWalkDevToolsServer.java',
+        'runtime/android/core/src/org/xwalk/core/XWalkPathHelper.java',
         'runtime/android/core/src/org/xwalk/core/XWalkSettings.java',
         'runtime/android/core/src/org/xwalk/core/XWalkViewDelegate.java',
         'runtime/android/core/src/org/xwalk/core/XWalkWebContentsDelegate.java',
index e152f99..ca26d69 100644 (file)
           '<(PRODUCT_DIR)/runtime_client_test/assets/echo.html',
           '<(PRODUCT_DIR)/runtime_client_test/assets/echoSync.html',
           '<(PRODUCT_DIR)/runtime_client_test/assets/messaging_mini.html',
+          '<(PRODUCT_DIR)/runtime_client_test/assets/native_file_system.html',
           '<(PRODUCT_DIR)/runtime_client_test/assets/screen_orientation.html',
           '<(PRODUCT_DIR)/runtime_client_test/assets/timer.html',
         ],
             'test/android/data/displayAvailableTest.html',
             'test/android/data/echo.html',
             'test/android/data/echoSync.html',
+            'test/android/data/native_file_system.html',
             'test/android/data/screen_orientation.html',
             'test/android/data/sysapps/messaging/messaging_mini.html',
             'test/android/data/timer.html',
           '<(PRODUCT_DIR)/runtime_client_embedded_test/assets/echo.html',
           '<(PRODUCT_DIR)/runtime_client_embedded_test/assets/echoSync.html',
           '<(PRODUCT_DIR)/runtime_client_embedded_test/assets/messaging_mini.html',
+          '<(PRODUCT_DIR)/runtime_client_embedded_test/assets/native_file_system.html',
           '<(PRODUCT_DIR)/runtime_client_embedded_test/assets/screen_orientation.html',
           '<(PRODUCT_DIR)/runtime_client_embedded_test/assets/timer.html',
         ],
             'test/android/data/displayAvailableTest.html',
             'test/android/data/echo.html',
             'test/android/data/echoSync.html',
+            'test/android/data/native_file_system.html',
             'test/android/data/screen_orientation.html',
             'test/android/data/sysapps/messaging/messaging_mini.html',
             'test/android/data/timer.html',