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

Side by Side Diff: Source/core/dom/MessagePort.cpp

Issue 13844022: Remove code to support Objective-C bindings (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 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 | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2008 Apple Inc. All Rights Reserved. 2 * Copyright (C) 2008 Apple 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 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 // Don't need to call processMessagePortMessagesSoon() here, because the por t will not be opened until start() is invoked. 50 // Don't need to call processMessagePortMessagesSoon() here, because the por t will not be opened until start() is invoked.
51 } 51 }
52 52
53 MessagePort::~MessagePort() 53 MessagePort::~MessagePort()
54 { 54 {
55 close(); 55 close();
56 if (m_scriptExecutionContext) 56 if (m_scriptExecutionContext)
57 m_scriptExecutionContext->destroyedMessagePort(this); 57 m_scriptExecutionContext->destroyedMessagePort(this);
58 } 58 }
59 59
60 void MessagePort::postMessage(PassRefPtr<SerializedScriptValue> message, Message Port* port, ExceptionCode& ec)
61 {
62 MessagePortArray ports;
63 if (port)
64 ports.append(port);
65 postMessage(message, &ports, ec);
66 }
67
68 void MessagePort::postMessage(PassRefPtr<SerializedScriptValue> message, const M essagePortArray* ports, ExceptionCode& ec) 60 void MessagePort::postMessage(PassRefPtr<SerializedScriptValue> message, const M essagePortArray* ports, ExceptionCode& ec)
69 { 61 {
70 if (!isEntangled()) 62 if (!isEntangled())
71 return; 63 return;
72 ASSERT(m_scriptExecutionContext); 64 ASSERT(m_scriptExecutionContext);
73 65
74 OwnPtr<MessagePortChannelArray> channels; 66 OwnPtr<MessagePortChannelArray> channels;
75 // Make sure we aren't connected to any of the passed-in ports. 67 // Make sure we aren't connected to any of the passed-in ports.
76 if (ports) { 68 if (ports) {
77 for (unsigned int i = 0; i < ports->size(); ++i) { 69 for (unsigned int i = 0; i < ports->size(); ++i) {
(...skipping 165 matching lines...) Expand 10 before | Expand all | Expand 10 after
243 { 235 {
244 return &m_eventTargetData; 236 return &m_eventTargetData;
245 } 237 }
246 238
247 EventTargetData* MessagePort::ensureEventTargetData() 239 EventTargetData* MessagePort::ensureEventTargetData()
248 { 240 {
249 return &m_eventTargetData; 241 return &m_eventTargetData;
250 } 242 }
251 243
252 } // namespace WebCore 244 } // namespace WebCore
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698