Chromium Code Reviews| 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 <stdlib.h> | 5 #include <stdlib.h> |
| 6 | 6 |
| 7 #if defined(OS_WIN) | 7 #if defined(OS_WIN) |
| 8 #include <dwmapi.h> | 8 #include <dwmapi.h> |
| 9 #include <windows.h> | 9 #include <windows.h> |
| 10 #endif | 10 #endif |
| (...skipping 387 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 398 bool res = true; | 398 bool res = true; |
| 399 gpu::CollectInfoResult result = gpu::CollectContextGraphicsInfo(&gpu_info); | 399 gpu::CollectInfoResult result = gpu::CollectContextGraphicsInfo(&gpu_info); |
| 400 switch (result) { | 400 switch (result) { |
| 401 case gpu::kCollectInfoFatalFailure: | 401 case gpu::kCollectInfoFatalFailure: |
| 402 LOG(ERROR) << "gpu::CollectGraphicsInfo failed (fatal)."; | 402 LOG(ERROR) << "gpu::CollectGraphicsInfo failed (fatal)."; |
| 403 res = false; | 403 res = false; |
| 404 break; | 404 break; |
| 405 case gpu::kCollectInfoNonFatalFailure: | 405 case gpu::kCollectInfoNonFatalFailure: |
| 406 VLOG(1) << "gpu::CollectGraphicsInfo failed (non-fatal)."; | 406 VLOG(1) << "gpu::CollectGraphicsInfo failed (non-fatal)."; |
| 407 break; | 407 break; |
| 408 case gpu::kCollectInfoSuccess: | 408 default: |
|
piman
2014/09/03 00:50:55
nit: same here
Zhenyao Mo
2014/09/03 01:31:23
Done.
| |
| 409 break; | 409 break; |
| 410 } | 410 } |
| 411 GetContentClient()->SetGpuInfo(gpu_info); | 411 GetContentClient()->SetGpuInfo(gpu_info); |
| 412 return res; | 412 return res; |
| 413 } | 413 } |
| 414 #endif | 414 #endif |
| 415 | 415 |
| 416 #if defined(OS_LINUX) | 416 #if defined(OS_LINUX) |
| 417 #if !defined(OS_CHROMEOS) | 417 #if !defined(OS_CHROMEOS) |
| 418 bool CanAccessNvidiaDeviceFile() { | 418 bool CanAccessNvidiaDeviceFile() { |
| (...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 512 return true; | 512 return true; |
| 513 } | 513 } |
| 514 | 514 |
| 515 return false; | 515 return false; |
| 516 } | 516 } |
| 517 #endif // defined(OS_WIN) | 517 #endif // defined(OS_WIN) |
| 518 | 518 |
| 519 } // namespace. | 519 } // namespace. |
| 520 | 520 |
| 521 } // namespace content | 521 } // namespace content |
| OLD | NEW |