| OLD | NEW |
| 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/ppapi_plugin_instance.h" | 5 #include "webkit/plugins/ppapi/ppapi_plugin_instance.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/callback_helpers.h" | 8 #include "base/callback_helpers.h" |
| 9 #include "base/debug/trace_event.h" | 9 #include "base/debug/trace_event.h" |
| 10 #include "base/logging.h" | 10 #include "base/logging.h" |
| (...skipping 560 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 571 | 571 |
| 572 UpdateTouchEventRequest(); | 572 UpdateTouchEventRequest(); |
| 573 container_->setWantsWheelEvents(IsAcceptingWheelEvents()); | 573 container_->setWantsWheelEvents(IsAcceptingWheelEvents()); |
| 574 | 574 |
| 575 SetGPUHistogram(delegate_->GetPreferences(), arg_names, arg_values); | 575 SetGPUHistogram(delegate_->GetPreferences(), arg_names, arg_values); |
| 576 | 576 |
| 577 argn_ = arg_names; | 577 argn_ = arg_names; |
| 578 argv_ = arg_values; | 578 argv_ = arg_values; |
| 579 scoped_array<const char*> argn_array(StringVectorToArgArray(argn_)); | 579 scoped_array<const char*> argn_array(StringVectorToArgArray(argn_)); |
| 580 scoped_array<const char*> argv_array(StringVectorToArgArray(argv_)); | 580 scoped_array<const char*> argv_array(StringVectorToArgArray(argv_)); |
| 581 return PP_ToBool(instance_interface_->DidCreate(pp_instance(), | 581 bool success = PP_ToBool(instance_interface_->DidCreate(pp_instance(), |
| 582 argn_.size(), | 582 argn_.size(), |
| 583 argn_array.get(), | 583 argn_array.get(), |
| 584 argv_array.get())); | 584 argv_array.get())); |
| 585 if (success) |
| 586 message_channel_->DidCreateFinished(); |
| 587 return success; |
| 585 } | 588 } |
| 586 | 589 |
| 587 bool PluginInstance::HandleDocumentLoad(PPB_URLLoader_Impl* loader) { | 590 bool PluginInstance::HandleDocumentLoad(PPB_URLLoader_Impl* loader) { |
| 588 if (!document_loader_) | 591 if (!document_loader_) |
| 589 document_loader_ = loader; | 592 document_loader_ = loader; |
| 590 DCHECK(loader == document_loader_.get()); | 593 DCHECK(loader == document_loader_.get()); |
| 591 | 594 |
| 592 return PP_ToBool(instance_interface_->HandleDocumentLoad( | 595 return PP_ToBool(instance_interface_->HandleDocumentLoad( |
| 593 pp_instance(), loader->pp_resource())); | 596 pp_instance(), loader->pp_resource())); |
| 594 } | 597 } |
| (...skipping 1883 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2478 screen_size_for_fullscreen_ = gfx::Size(); | 2481 screen_size_for_fullscreen_ = gfx::Size(); |
| 2479 WebElement element = container_->element(); | 2482 WebElement element = container_->element(); |
| 2480 element.setAttribute(WebString::fromUTF8(kWidth), width_before_fullscreen_); | 2483 element.setAttribute(WebString::fromUTF8(kWidth), width_before_fullscreen_); |
| 2481 element.setAttribute(WebString::fromUTF8(kHeight), height_before_fullscreen_); | 2484 element.setAttribute(WebString::fromUTF8(kHeight), height_before_fullscreen_); |
| 2482 element.setAttribute(WebString::fromUTF8(kBorder), border_before_fullscreen_); | 2485 element.setAttribute(WebString::fromUTF8(kBorder), border_before_fullscreen_); |
| 2483 element.setAttribute(WebString::fromUTF8(kStyle), style_before_fullscreen_); | 2486 element.setAttribute(WebString::fromUTF8(kStyle), style_before_fullscreen_); |
| 2484 } | 2487 } |
| 2485 | 2488 |
| 2486 } // namespace ppapi | 2489 } // namespace ppapi |
| 2487 } // namespace webkit | 2490 } // namespace webkit |
| OLD | NEW |