OLD | NEW |
1 # Copyright (c) 2013 Google Inc. All rights reserved. | 1 # Copyright (c) 2013 Google Inc. All rights reserved. |
2 # | 2 # |
3 # Redistribution and use in source and binary forms, with or without | 3 # Redistribution and use in source and binary forms, with or without |
4 # modification, are permitted provided that the following conditions are | 4 # modification, are permitted provided that the following conditions are |
5 # met: | 5 # met: |
6 # | 6 # |
7 # * Redistributions of source code must retain the above copyright | 7 # * 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 # * Redistributions in binary form must reproduce the above | 9 # * Redistributions in binary form must reproduce the above |
10 # copyright notice, this list of conditions and the following disclaimer | 10 # copyright notice, this list of conditions and the following disclaimer |
(...skipping 339 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
350 } | 350 } |
351 | 351 |
352 void InspectorBackendDispatcherImpl::sendResponse(long callId, PassRefPtr<JSONOb
ject> result, const ErrorString& invocationError, PassRefPtr<JSONValue> errorDat
a) | 352 void InspectorBackendDispatcherImpl::sendResponse(long callId, PassRefPtr<JSONOb
ject> result, const ErrorString& invocationError, PassRefPtr<JSONValue> errorDat
a) |
353 { | 353 { |
354 if (invocationError.length()) { | 354 if (invocationError.length()) { |
355 reportProtocolError(&callId, ServerError, invocationError, errorData); | 355 reportProtocolError(&callId, ServerError, invocationError, errorData); |
356 return; | 356 return; |
357 } | 357 } |
358 | 358 |
359 RefPtr<JSONObject> responseMessage = JSONObject::create(); | 359 RefPtr<JSONObject> responseMessage = JSONObject::create(); |
| 360 responseMessage->setNumber("id", callId); |
360 responseMessage->setObject("result", result); | 361 responseMessage->setObject("result", result); |
361 responseMessage->setNumber("id", callId); | |
362 if (m_inspectorFrontendChannel) | 362 if (m_inspectorFrontendChannel) |
363 m_inspectorFrontendChannel->sendMessageToFrontend(responseMessage.releas
e()); | 363 m_inspectorFrontendChannel->sendMessageToFrontend(responseMessage.releas
e()); |
364 } | 364 } |
365 | 365 |
366 void InspectorBackendDispatcher::reportProtocolError(const long* const callId, C
ommonErrorCode code, const String& errorMessage) const | 366 void InspectorBackendDispatcher::reportProtocolError(const long* const callId, C
ommonErrorCode code, const String& errorMessage) const |
367 { | 367 { |
368 reportProtocolError(callId, code, errorMessage, PassRefPtr<JSONValue>()); | 368 reportProtocolError(callId, code, errorMessage, PassRefPtr<JSONValue>()); |
369 } | 369 } |
370 | 370 |
371 void InspectorBackendDispatcherImpl::reportProtocolError(const long* const callI
d, CommonErrorCode code, const String& errorMessage, PassRefPtr<JSONValue> data)
const | 371 void InspectorBackendDispatcherImpl::reportProtocolError(const long* const callI
d, CommonErrorCode code, const String& errorMessage, PassRefPtr<JSONValue> data)
const |
(...skipping 579 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
951 }; | 951 }; |
952 | 952 |
953 """) | 953 """) |
954 | 954 |
955 class_binding_builder_part_4 = ( | 955 class_binding_builder_part_4 = ( |
956 """ static Builder<NoFieldsSet> create() | 956 """ static Builder<NoFieldsSet> create() |
957 { | 957 { |
958 return Builder<NoFieldsSet>(JSONObject::create()); | 958 return Builder<NoFieldsSet>(JSONObject::create()); |
959 } | 959 } |
960 """) | 960 """) |
OLD | NEW |