summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjlklein <jlklein@chromium.org>2015-05-01 12:35:44 -0700
committerCommit bot <commit-bot@chromium.org>2015-05-01 19:36:19 +0000
commitf0c5abbfb8e955069a64a8bfd52fbe4dc7a38522 (patch)
tree01588062dd8387da4044ba8859159f4f6e247393
parentc155d75ee1a50b8e9f4139f16e72297f753526d0 (diff)
downloadchromium_src-f0c5abbfb8e955069a64a8bfd52fbe4dc7a38522.zip
chromium_src-f0c5abbfb8e955069a64a8bfd52fbe4dc7a38522.tar.gz
chromium_src-f0c5abbfb8e955069a64a8bfd52fbe4dc7a38522.tar.bz2
Add a build flag to include polymer 0.8 in the binary
BUG=483080 Review URL: https://codereview.chromium.org/1118673004 Cr-Commit-Position: refs/heads/master@{#327959}
-rw-r--r--ui/resources/ui_resources.gyp9
-rw-r--r--ui/webui/resources/cr_elements_resources.grdp20
-rw-r--r--ui/webui/resources/polymer_resources.grdp52
3 files changed, 47 insertions, 34 deletions
diff --git a/ui/resources/ui_resources.gyp b/ui/resources/ui_resources.gyp
index 10eb97d..f46e1f2 100644
--- a/ui/resources/ui_resources.gyp
+++ b/ui/resources/ui_resources.gyp
@@ -9,6 +9,9 @@
'target_name': 'ui_resources',
'type': 'none',
'variables': {
+ # Enable to include Polymer 0.8 in the binary.
+ 'enable_polymer_v08%': 0,
+
'grit_out_dir': '<(SHARED_INTERMEDIATE_DIR)/ui/resources',
},
'actions': [
@@ -23,6 +26,12 @@
'action_name': 'webui_resources',
'variables': {
'grit_grd_file': '../webui/resources/webui_resources.grd',
+
+ 'conditions': [
+ ['enable_polymer_v08==1', {
+ 'grit_defines': ['-D', 'enable_polymer_v08'],
+ }],
+ ],
},
'includes': [ '../../build/grit_action.gypi' ],
},
diff --git a/ui/webui/resources/cr_elements_resources.grdp b/ui/webui/resources/cr_elements_resources.grdp
index 6c44a42..bad164f 100644
--- a/ui/webui/resources/cr_elements_resources.grdp
+++ b/ui/webui/resources/cr_elements_resources.grdp
@@ -104,13 +104,15 @@
type="chrome_html" />
<!-- Polymer 0.8 Elements -->
- <structure name="IDR_CR_ELEMENTS_08_CR_CHECKBOX_CSS"
- file="../../webui/resources/cr_elements/v0_8/cr_checkbox/cr_checkbox.css"
- type="chrome_html" />
- <structure name="IDR_CR_ELEMENTS_08_CR_CHECKBOX_HTML"
- file="../../webui/resources/cr_elements/v0_8/cr_checkbox/cr_checkbox.html"
- type="chrome_html" />
- <structure name="IDR_CR_ELEMENTS_08_CR_CHECKBOX_JS"
- file="../../webui/resources/cr_elements/v0_8/cr_checkbox/cr_checkbox.js"
- type="chrome_html" />
+ <if expr="enable_polymer_v08">
+ <structure name="IDR_CR_ELEMENTS_08_CR_CHECKBOX_CSS"
+ file="../../webui/resources/cr_elements/v0_8/cr_checkbox/cr_checkbox.css"
+ type="chrome_html" />
+ <structure name="IDR_CR_ELEMENTS_08_CR_CHECKBOX_HTML"
+ file="../../webui/resources/cr_elements/v0_8/cr_checkbox/cr_checkbox.html"
+ type="chrome_html" />
+ <structure name="IDR_CR_ELEMENTS_08_CR_CHECKBOX_JS"
+ file="../../webui/resources/cr_elements/v0_8/cr_checkbox/cr_checkbox.js"
+ type="chrome_html" />
+ </if>
</grit-part>
diff --git a/ui/webui/resources/polymer_resources.grdp b/ui/webui/resources/polymer_resources.grdp
index 2af362c..5886972 100644
--- a/ui/webui/resources/polymer_resources.grdp
+++ b/ui/webui/resources/polymer_resources.grdp
@@ -475,29 +475,31 @@
file="../../../third_party/web-animations-js/sources/web-animations-next-lite.min.js.map"
type="chrome_html" />
- <!-- Polymer 0.8 Elements, -->
- <structure name="IDR_POLYMER_08_POLYMER_POLYMER_HTML"
- file="../../../third_party/polymer/v0_8/components-chromium/polymer/polymer.html"
- type="chrome_html" />
- <structure name="IDR_POLYMER_08_POLYMER_POLYMER_JS"
- file="../../../third_party/polymer/v0_8/components-chromium/polymer/polymer.js"
- type="chrome_html" />
- <structure name="IDR_POLYMER_08_PAPER_CHECKBOX_PAPER_CHECKBOX_CSS"
- file="../../../third_party/polymer/v0_8/components-chromium/paper-checkbox/paper-checkbox.css"
- type="chrome_html" />
- <structure name="IDR_POLYMER_08_PAPER_CHECKBOX_PAPER_CHECKBOX_EXTRACTED_JS"
- file="../../../third_party/polymer/v0_8/components-chromium/paper-checkbox/paper-checkbox-extracted.js"
- type="chrome_html" />
- <structure name="IDR_POLYMER_08_PAPER_CHECKBOX_PAPER_CHECKBOX_HTML"
- file="../../../third_party/polymer/v0_8/components-chromium/paper-checkbox/paper-checkbox.html"
- type="chrome_html" />
- <structure name="IDR_POLYMER_08_PAPER_RIPPLE_PAPER_RIPPLE_EXTRACTED_JS"
- file="../../../third_party/polymer/v0_8/components-chromium/paper-ripple/paper-ripple-extracted.js"
- type="chrome_html" />
- <structure name="IDR_POLYMER_08_PAPER_RIPPLE_PAPER_RIPPLE_HTML"
- file="../../../third_party/polymer/v0_8/components-chromium/paper-ripple/paper-ripple.html"
- type="chrome_html" />
- <structure name="IDR_POLYMER_08_PAPER_STYLES_DEFAULT_THEME_HTML"
- file="../../../third_party/polymer/v0_8/components-chromium/paper-styles/default-theme.html"
- type="chrome_html" />
+ <!-- Polymer 0.8 -->
+ <if expr="enable_polymer_v08">
+ <structure name="IDR_POLYMER_08_POLYMER_POLYMER_HTML"
+ file="../../../third_party/polymer/v0_8/components-chromium/polymer/polymer.html"
+ type="chrome_html" />
+ <structure name="IDR_POLYMER_08_POLYMER_POLYMER_JS"
+ file="../../../third_party/polymer/v0_8/components-chromium/polymer/polymer.js"
+ type="chrome_html" />
+ <structure name="IDR_POLYMER_08_PAPER_CHECKBOX_PAPER_CHECKBOX_CSS"
+ file="../../../third_party/polymer/v0_8/components-chromium/paper-checkbox/paper-checkbox.css"
+ type="chrome_html" />
+ <structure name="IDR_POLYMER_08_PAPER_CHECKBOX_PAPER_CHECKBOX_EXTRACTED_JS"
+ file="../../../third_party/polymer/v0_8/components-chromium/paper-checkbox/paper-checkbox-extracted.js"
+ type="chrome_html" />
+ <structure name="IDR_POLYMER_08_PAPER_CHECKBOX_PAPER_CHECKBOX_HTML"
+ file="../../../third_party/polymer/v0_8/components-chromium/paper-checkbox/paper-checkbox.html"
+ type="chrome_html" />
+ <structure name="IDR_POLYMER_08_PAPER_RIPPLE_PAPER_RIPPLE_EXTRACTED_JS"
+ file="../../../third_party/polymer/v0_8/components-chromium/paper-ripple/paper-ripple-extracted.js"
+ type="chrome_html" />
+ <structure name="IDR_POLYMER_08_PAPER_RIPPLE_PAPER_RIPPLE_HTML"
+ file="../../../third_party/polymer/v0_8/components-chromium/paper-ripple/paper-ripple.html"
+ type="chrome_html" />
+ <structure name="IDR_POLYMER_08_PAPER_STYLES_DEFAULT_THEME_HTML"
+ file="../../../third_party/polymer/v0_8/components-chromium/paper-styles/default-theme.html"
+ type="chrome_html" />
+ </if>
</grit-part>