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

Side by Side Diff: webkit/plugins/ppapi/ppb_flash_menu_impl.cc

Issue 10909244: PPAPI: Get TrackedCallback ready for running on non-main threads. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Merged. Created 8 years, 1 month 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
« no previous file with comments | « webkit/plugins/ppapi/ppb_broker_impl.cc ('k') | webkit/plugins/ppapi/ppb_graphics_2d_impl.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 "webkit/plugins/ppapi/ppb_flash_menu_impl.h" 5 #include "webkit/plugins/ppapi/ppb_flash_menu_impl.h"
6 6
7 #include "base/utf_string_conversions.h" 7 #include "base/utf_string_conversions.h"
8 #include "ppapi/c/pp_completion_callback.h" 8 #include "ppapi/c/pp_completion_callback.h"
9 #include "ui/gfx/point.h" 9 #include "ui/gfx/point.h"
10 #include "webkit/glue/webmenuitem.h" 10 #include "webkit/glue/webmenuitem.h"
(...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after
169 if (action == 0 || action >= menu_id_map_.size()) { 169 if (action == 0 || action >= menu_id_map_.size()) {
170 NOTREACHED() << "Invalid action received."; 170 NOTREACHED() << "Invalid action received.";
171 rv = PP_ERROR_FAILED; 171 rv = PP_ERROR_FAILED;
172 } else { 172 } else {
173 *selected_id_out_ = menu_id_map_[action]; 173 *selected_id_out_ = menu_id_map_[action];
174 } 174 }
175 } 175 }
176 } 176 }
177 177
178 selected_id_out_ = NULL; 178 selected_id_out_ = NULL;
179 TrackedCallback::ClearAndRun(&callback_, rv); 179 callback_->Run(rv);
180 } 180 }
181 181
182 } // namespace ppapi 182 } // namespace ppapi
183 } // namespace webkit 183 } // namespace webkit
OLDNEW
« no previous file with comments | « webkit/plugins/ppapi/ppb_broker_impl.cc ('k') | webkit/plugins/ppapi/ppb_graphics_2d_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698