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

Side by Side Diff: third_party/WebKit/Source/platform/inspector_protocol/Frontend_cpp.template

Issue 1979963002: Remove OwnPtr::release() calls in platform/ (part inspector). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // This file is generated 1 // This file is generated
2 2
3 // Copyright (c) 2016 The Chromium Authors. All rights reserved. 3 // Copyright (c) 2016 The Chromium Authors. All rights reserved.
4 // Use of this source code is governed by a BSD-style license that can be 4 // Use of this source code is governed by a BSD-style license that can be
5 // found in the LICENSE file. 5 // found in the LICENSE file.
6 6
7 #include "platform/inspector_protocol/{{class_name}}.h" 7 #include "platform/inspector_protocol/{{class_name}}.h"
8 8
9 #include "platform/inspector_protocol/String16.h" 9 #include "platform/inspector_protocol/String16.h"
10 10
(...skipping 24 matching lines...) Expand all
35 jsonMessage->setString("method", "{{domain.domain}}.{{event.name}}"); 35 jsonMessage->setString("method", "{{domain.domain}}.{{event.name}}");
36 OwnPtr<protocol::DictionaryValue> paramsObject = DictionaryValue::create(); 36 OwnPtr<protocol::DictionaryValue> paramsObject = DictionaryValue::create();
37 {% for parameter in event.parameters %} 37 {% for parameter in event.parameters %}
38 {% if "optional" in parameter %} 38 {% if "optional" in parameter %}
39 if ({{parameter.name}}.isJust()) 39 if ({{parameter.name}}.isJust())
40 paramsObject->setValue("{{parameter.name}}", toValue({{parameter.name}}. fromJust())); 40 paramsObject->setValue("{{parameter.name}}", toValue({{parameter.name}}. fromJust()));
41 {% else %} 41 {% else %}
42 paramsObject->setValue("{{parameter.name}}", toValue({{resolve_type(paramete r).to_raw_type % parameter.name}})); 42 paramsObject->setValue("{{parameter.name}}", toValue({{resolve_type(paramete r).to_raw_type % parameter.name}}));
43 {% endif %} 43 {% endif %}
44 {% endfor %} 44 {% endfor %}
45 jsonMessage->setObject("params", paramsObject.release()); 45 jsonMessage->setObject("params", std::move(paramsObject));
46 if (m_frontendChannel) 46 if (m_frontendChannel)
47 m_frontendChannel->sendProtocolNotification(jsonMessage.release()); 47 m_frontendChannel->sendProtocolNotification(std::move(jsonMessage));
48 } 48 }
49 {% endfor %} 49 {% endfor %}
50 {% endfor %} 50 {% endfor %}
51 51
52 } // namespace protocol 52 } // namespace protocol
53 } // namespace blink 53 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698