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

Side by Side Diff: third_party/WebKit/Source/modules/websockets/InspectorWebSocketEvents.cpp

Issue 2700123003: DO NOT COMMIT: Results of running old (current) clang-format on Blink (Closed)
Patch Set: Created 3 years, 10 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 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "modules/websockets/InspectorWebSocketEvents.h" 5 #include "modules/websockets/InspectorWebSocketEvents.h"
6 6
7 #include <memory>
7 #include "core/dom/Document.h" 8 #include "core/dom/Document.h"
8 #include "platform/weborigin/KURL.h" 9 #include "platform/weborigin/KURL.h"
9 #include <memory>
10 10
11 namespace blink { 11 namespace blink {
12 12
13 std::unique_ptr<TracedValue> InspectorWebSocketCreateEvent::data( 13 std::unique_ptr<TracedValue> InspectorWebSocketCreateEvent::data(
14 Document* document, 14 Document* document,
15 unsigned long identifier, 15 unsigned long identifier,
16 const KURL& url, 16 const KURL& url,
17 const String& protocol) { 17 const String& protocol) {
18 std::unique_ptr<TracedValue> value = TracedValue::create(); 18 std::unique_ptr<TracedValue> value = TracedValue::create();
19 value->setInteger("identifier", identifier); 19 value->setInteger("identifier", identifier);
20 value->setString("url", url.getString()); 20 value->setString("url", url.getString());
21 value->setString("frame", toHexString(document->frame())); 21 value->setString("frame", toHexString(document->frame()));
22 if (!protocol.isNull()) 22 if (!protocol.isNull())
23 value->setString("webSocketProtocol", protocol); 23 value->setString("webSocketProtocol", protocol);
24 setCallStack(value.get()); 24 setCallStack(value.get());
25 return value; 25 return value;
26 } 26 }
27 27
28 std::unique_ptr<TracedValue> InspectorWebSocketEvent::data( 28 std::unique_ptr<TracedValue> InspectorWebSocketEvent::data(
29 Document* document, 29 Document* document,
30 unsigned long identifier) { 30 unsigned long identifier) {
31 std::unique_ptr<TracedValue> value = TracedValue::create(); 31 std::unique_ptr<TracedValue> value = TracedValue::create();
32 value->setInteger("identifier", identifier); 32 value->setInteger("identifier", identifier);
33 value->setString("frame", toHexString(document->frame())); 33 value->setString("frame", toHexString(document->frame()));
34 setCallStack(value.get()); 34 setCallStack(value.get());
35 return value; 35 return value;
36 } 36 }
37 37
38 } // namespace blink 38 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698