OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 "chrome/default_plugin/plugin_impl_win.h" | 5 #include "chrome/default_plugin/plugin_impl_win.h" |
6 | 6 |
7 #include <shellapi.h> | 7 #include <shellapi.h> |
8 | 8 |
9 #include "base/file_util.h" | 9 #include "base/file_util.h" |
10 #include "base/path_service.h" | 10 #include "base/path_service.h" |
(...skipping 324 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
335 void PluginInstallerImpl::DownloadPlugin() { | 335 void PluginInstallerImpl::DownloadPlugin() { |
336 set_plugin_installer_state(PluginDownloadInitiated); | 336 set_plugin_installer_state(PluginDownloadInitiated); |
337 | 337 |
338 DVLOG(1) << "Initiating download for plugin URL " | 338 DVLOG(1) << "Initiating download for plugin URL " |
339 << plugin_download_url_.c_str(); | 339 << plugin_download_url_.c_str(); |
340 | 340 |
341 DisplayStatus(IDS_DEFAULT_PLUGIN_DOWNLOADING_PLUGIN_MSG); | 341 DisplayStatus(IDS_DEFAULT_PLUGIN_DOWNLOADING_PLUGIN_MSG); |
342 | 342 |
343 if (!plugin_download_url_for_display_) { | 343 if (!plugin_download_url_for_display_) { |
344 ChildThread::current()->Send(new PluginProcessHostMsg_DownloadUrl( | 344 ChildThread::current()->Send(new PluginProcessHostMsg_DownloadUrl( |
345 plugin_download_url_, ::GetCurrentProcessId(), hwnd())); | 345 plugin_download_url_, hwnd())); |
346 } else { | 346 } else { |
347 default_plugin::g_browser->geturl(instance(), | 347 default_plugin::g_browser->geturl(instance(), |
348 plugin_download_url_.c_str(), | 348 plugin_download_url_.c_str(), |
349 "_blank"); | 349 "_blank"); |
350 set_plugin_installer_state(PluginInstallerLaunchSuccess); | 350 set_plugin_installer_state(PluginInstallerLaunchSuccess); |
351 DisplayStatus(IDS_DEFAULT_PLUGIN_REFRESH_PLUGIN_MSG); | 351 DisplayStatus(IDS_DEFAULT_PLUGIN_REFRESH_PLUGIN_MSG); |
352 enable_click_ = true; | 352 enable_click_ = true; |
353 RefreshDisplay(); | 353 RefreshDisplay(); |
354 } | 354 } |
355 } | 355 } |
(...skipping 292 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
648 return true; | 648 return true; |
649 } | 649 } |
650 | 650 |
651 void PluginInstallerImpl::NotifyPluginStatus(int status) { | 651 void PluginInstallerImpl::NotifyPluginStatus(int status) { |
652 default_plugin::g_browser->getvalue( | 652 default_plugin::g_browser->getvalue( |
653 instance_, | 653 instance_, |
654 static_cast<NPNVariable>( | 654 static_cast<NPNVariable>( |
655 webkit::npapi::default_plugin::kMissingPluginStatusStart + status), | 655 webkit::npapi::default_plugin::kMissingPluginStatusStart + status), |
656 NULL); | 656 NULL); |
657 } | 657 } |
OLD | NEW |