| 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/npapi/plugin_list.h" | 5 #include "webkit/plugins/npapi/plugin_list.h" |
| 6 | 6 |
| 7 #include <tchar.h> | 7 #include <tchar.h> |
| 8 | 8 |
| 9 #include <set> | 9 #include <set> |
| 10 | 10 |
| (...skipping 377 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 388 int major, minor, update; | 388 int major, minor, update; |
| 389 if (ver.size() == 4 && | 389 if (ver.size() == 4 && |
| 390 base::StringToInt(ver[0], &major) && | 390 base::StringToInt(ver[0], &major) && |
| 391 base::StringToInt(ver[1], &minor) && | 391 base::StringToInt(ver[1], &minor) && |
| 392 base::StringToInt(ver[2], &update)) { | 392 base::StringToInt(ver[2], &update)) { |
| 393 if (major == 6 && minor == 0 && update < 120) | 393 if (major == 6 && minor == 0 && update < 120) |
| 394 return false; // Java SE6 Update 11 or older. | 394 return false; // Java SE6 Update 11 or older. |
| 395 } | 395 } |
| 396 } | 396 } |
| 397 | 397 |
| 398 if (base::win::GetMetroModule()) { | 398 if (base::win::IsMetroProcess()) { |
| 399 // In metro mode we only allow pepper plugins. | 399 // In metro mode we only allow pepper plugins. |
| 400 if (info.type == WebPluginInfo::PLUGIN_TYPE_NPAPI) | 400 if (info.type == WebPluginInfo::PLUGIN_TYPE_NPAPI) |
| 401 return false; | 401 return false; |
| 402 } | 402 } |
| 403 | 403 |
| 404 // Special WMP handling | 404 // Special WMP handling |
| 405 | 405 |
| 406 // If both the new and old WMP plugins exist, only load the new one. | 406 // If both the new and old WMP plugins exist, only load the new one. |
| 407 if (filename == kNewWMPPlugin) { | 407 if (filename == kNewWMPPlugin) { |
| 408 if (dont_load_new_wmp_) | 408 if (dont_load_new_wmp_) |
| (...skipping 30 matching lines...) Expand all Loading... |
| 439 | 439 |
| 440 if (file_util::PathExists(info.path) && (!IsValid32BitImage(info.path))) | 440 if (file_util::PathExists(info.path) && (!IsValid32BitImage(info.path))) |
| 441 load_plugin = false; | 441 load_plugin = false; |
| 442 break; | 442 break; |
| 443 } | 443 } |
| 444 return load_plugin; | 444 return load_plugin; |
| 445 } | 445 } |
| 446 | 446 |
| 447 } // namespace npapi | 447 } // namespace npapi |
| 448 } // namespace webkit | 448 } // namespace webkit |
| OLD | NEW |