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

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

Issue 1601283003: DevTools: deoilpanize inspector/v8 and related classes. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: review comments addressed. Created 4 years, 11 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 /* 1 /*
2 * Copyright (C) 2011, 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2011, 2012 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after
148 { 148 {
149 ASSERT(m_bridge); 149 ASSERT(m_bridge);
150 m_bridge->close(code, reason); 150 m_bridge->close(code, reason);
151 } 151 }
152 152
153 void WorkerWebSocketChannel::fail(const String& reason, MessageLevel level, cons t String& sourceURL, unsigned lineNumber) 153 void WorkerWebSocketChannel::fail(const String& reason, MessageLevel level, cons t String& sourceURL, unsigned lineNumber)
154 { 154 {
155 if (!m_bridge) 155 if (!m_bridge)
156 return; 156 return;
157 157
158 RefPtrWillBeRawPtr<ScriptCallStack> callStack = currentScriptCallStack(1); 158 RefPtr<ScriptCallStack> callStack = currentScriptCallStack(1);
159 if (callStack && callStack->size()) { 159 if (callStack && callStack->size()) {
160 // In order to emulate the ConsoleMessage behavior, 160 // In order to emulate the ConsoleMessage behavior,
161 // we should ignore the specified url and line number if 161 // we should ignore the specified url and line number if
162 // we can get the JavaScript context. 162 // we can get the JavaScript context.
163 m_bridge->fail(reason, level, callStack->at(0).sourceURL(), callStack->a t(0).lineNumber()); 163 m_bridge->fail(reason, level, callStack->at(0).sourceURL(), callStack->a t(0).lineNumber());
164 } else if (sourceURL.isEmpty() && !lineNumber) { 164 } else if (sourceURL.isEmpty() && !lineNumber) {
165 // No information is specified by the caller - use the url 165 // No information is specified by the caller - use the url
166 // and the line number at the connection. 166 // and the line number at the connection.
167 m_bridge->fail(reason, level, m_sourceURLAtConnection, m_lineNumberAtCon nection); 167 m_bridge->fail(reason, level, m_sourceURLAtConnection, m_lineNumberAtCon nection);
168 } else { 168 } else {
(...skipping 308 matching lines...) Expand 10 before | Expand all | Expand 10 after
477 477
478 DEFINE_TRACE(Bridge) 478 DEFINE_TRACE(Bridge)
479 { 479 {
480 visitor->trace(m_client); 480 visitor->trace(m_client);
481 visitor->trace(m_workerGlobalScope); 481 visitor->trace(m_workerGlobalScope);
482 visitor->trace(m_syncHelper); 482 visitor->trace(m_syncHelper);
483 visitor->trace(m_peer); 483 visitor->trace(m_peer);
484 } 484 }
485 485
486 } // namespace blink 486 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698