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

Side by Side Diff: ppapi/proxy/ppapi_proxy_test.cc

Issue 14371021: Implementation of URLLoader using PluginResource/ResourceHost. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Rebase, track src/webkit gypi changes. 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
« no previous file with comments | « ppapi/proxy/ppapi_messages.h ('k') | ppapi/proxy/ppb_url_loader_proxy.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "ppapi/proxy/ppapi_proxy_test.h" 5 #include "ppapi/proxy/ppapi_proxy_test.h"
6 6
7 #include <sstream> 7 #include <sstream>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/bind_helpers.h" 10 #include "base/bind_helpers.h"
(...skipping 23 matching lines...) Expand all
34 NOTREACHED(); 34 NOTREACHED();
35 return 0; 35 return 0;
36 } 36 }
37 37
38 void SetReserveInstanceIDCallback(PP_Module module, 38 void SetReserveInstanceIDCallback(PP_Module module,
39 PP_Bool (*is_seen)(PP_Module, PP_Instance)) { 39 PP_Bool (*is_seen)(PP_Module, PP_Instance)) {
40 // This function gets called in HostDispatcher's constructor. We simply don't 40 // This function gets called in HostDispatcher's constructor. We simply don't
41 // worry about Instance uniqueness in tests, so we can ignore the call. 41 // worry about Instance uniqueness in tests, so we can ignore the call.
42 } 42 }
43 43
44 int32_t GetURLLoaderBufferedBytes(PP_Resource url_loader) {
45 NOTREACHED();
46 return 0;
47 }
48
49 void AddRefModule(PP_Module module) {} 44 void AddRefModule(PP_Module module) {}
50 void ReleaseModule(PP_Module module) {} 45 void ReleaseModule(PP_Module module) {}
51 PP_Bool IsInModuleDestructor(PP_Module module) { return PP_FALSE; } 46 PP_Bool IsInModuleDestructor(PP_Module module) { return PP_FALSE; }
52 47
53 PPB_Proxy_Private ppb_proxy_private = { 48 PPB_Proxy_Private ppb_proxy_private = {
54 &PluginCrashed, 49 &PluginCrashed,
55 &GetInstanceForResource, 50 &GetInstanceForResource,
56 &SetReserveInstanceIDCallback, 51 &SetReserveInstanceIDCallback,
57 &GetURLLoaderBufferedBytes,
58 &AddRefModule, 52 &AddRefModule,
59 &ReleaseModule, 53 &ReleaseModule,
60 &IsInModuleDestructor 54 &IsInModuleDestructor
61 }; 55 };
62 56
63 // We allow multiple harnesses at a time to respond to 'GetInterface' calls. 57 // We allow multiple harnesses at a time to respond to 'GetInterface' calls.
64 // We assume that only 1 harness's GetInterface function will ever support a 58 // We assume that only 1 harness's GetInterface function will ever support a
65 // given interface name. In practice, there will either be only 1 GetInterface 59 // given interface name. In practice, there will either be only 1 GetInterface
66 // handler (for PluginProxyTest or HostProxyTest), or there will be only 2 60 // handler (for PluginProxyTest or HostProxyTest), or there will be only 2
67 // GetInterface handlers (for TwoWayTest). In the latter case, one handler is 61 // GetInterface handlers (for TwoWayTest). In the latter case, one handler is
(...skipping 513 matching lines...) Expand 10 before | Expand all | Expand 10 after
581 plugin_thread_.message_loop_proxy()->PostTask(FROM_HERE, 575 plugin_thread_.message_loop_proxy()->PostTask(FROM_HERE,
582 base::Bind(&RunTaskOnRemoteHarness, 576 base::Bind(&RunTaskOnRemoteHarness,
583 task, 577 task,
584 &task_complete)); 578 &task_complete));
585 task_complete.Wait(); 579 task_complete.Wait();
586 } 580 }
587 581
588 582
589 } // namespace proxy 583 } // namespace proxy
590 } // namespace ppapi 584 } // namespace ppapi
OLDNEW
« no previous file with comments | « ppapi/proxy/ppapi_messages.h ('k') | ppapi/proxy/ppb_url_loader_proxy.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698