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

Unified Diff: third_party/WebKit/Source/platform/inspector_protocol/templates/TypeBuilder_h.template

Issue 2413693002: Rename DOM.getLayoutTreeNodes to CSS.getLayoutTreeAndStyles (Closed)
Patch Set: Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/platform/inspector_protocol/templates/TypeBuilder_h.template
diff --git a/third_party/WebKit/Source/platform/inspector_protocol/templates/TypeBuilder_h.template b/third_party/WebKit/Source/platform/inspector_protocol/templates/TypeBuilder_h.template
index 553ba55f7c0de6956c1d0bf5900149a1a6c814b5..25b90ed88ec2cc3a9b4738a97aff108524d0adca 100644
--- a/third_party/WebKit/Source/platform/inspector_protocol/templates/TypeBuilder_h.template
+++ b/third_party/WebKit/Source/platform/inspector_protocol/templates/TypeBuilder_h.template
@@ -89,9 +89,9 @@ public:
{% if property.optional %}
bool has{{property.name | to_title_case}}() { return m_{{property.name}}.isJust(); }
- {{resolve_type(property).raw_return_type}} get{{property.name | to_title_case}}({{resolve_type(property).raw_pass_type}} defaultValue) { return m_{{property.name}}.isJust() ? m_{{property.name}}.fromJust() : defaultValue; }
+ {{resolve_type(property).raw_return_type}} get{{property.name | to_title_case}}({{resolve_type(property).raw_pass_type}} defaultValue) const { return m_{{property.name}}.isJust() ? m_{{property.name}}.fromJust() : defaultValue; }
{% else %}
- {{resolve_type(property).raw_return_type}} get{{property.name | to_title_case}}() { return {{resolve_type(property).to_raw_type % ("m_" + property.name)}}; }
+ const {{resolve_type(property).return_type}}& get{{property.name | to_title_case}}() const { return {{"m_" + property.name}}; }
dgozman 2016/10/12 21:00:40 Could you please describe why this change is neede
alex clarke (OOO till 29th) 2016/10/13 20:25:10 Before my change it returned the object by value i
dgozman 2016/10/14 01:32:33 - Note that Strings are cheap in blink - they are
{% endif %}
void set{{property.name | to_title_case}}({{resolve_type(property).pass_type}} value) { m_{{property.name}} = {{resolve_type(property).to_rvalue % "value"}}; }
{% endfor %}

Powered by Google App Engine
This is Rietveld 408576698