Add-flag-to-disable-WebGL.patch 2.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. From: csagan5 <32685696+csagan5@users.noreply.github.com>
  2. Date: Sat, 16 Nov 2019 11:18:09 +0100
  3. Subject: Add flag to disable WebGL
  4. ---
  5. chrome/browser/about_flags.cc | 3 +++
  6. chrome/browser/flag_descriptions.cc | 4 ++++
  7. chrome/browser/flag_descriptions.h | 3 +++
  8. 3 files changed, 10 insertions(+)
  9. diff --git a/chrome/browser/about_flags.cc b/chrome/browser/about_flags.cc
  10. --- a/chrome/browser/about_flags.cc
  11. +++ b/chrome/browser/about_flags.cc
  12. @@ -2619,6 +2619,9 @@ const FeatureEntry kFeatureEntries[] = {
  13. flag_descriptions::kAccelerated2dCanvasName,
  14. flag_descriptions::kAccelerated2dCanvasDescription, kOsAll,
  15. SINGLE_DISABLE_VALUE_TYPE(switches::kDisableAccelerated2dCanvas)},
  16. + {switches::kDisableWebGL, flag_descriptions::kDisableWebGLName,
  17. + flag_descriptions::kDisableWebGLDescription, kOsAll,
  18. + SINGLE_DISABLE_VALUE_TYPE(switches::kDisableWebGL)},
  19. {"composited-layer-borders", flag_descriptions::kCompositedLayerBordersName,
  20. flag_descriptions::kCompositedLayerBordersDescription, kOsAll,
  21. SINGLE_VALUE_TYPE(cc::switches::kShowCompositedLayerBorders)},
  22. diff --git a/chrome/browser/flag_descriptions.cc b/chrome/browser/flag_descriptions.cc
  23. --- a/chrome/browser/flag_descriptions.cc
  24. +++ b/chrome/browser/flag_descriptions.cc
  25. @@ -562,6 +562,10 @@ const char kEnableAudioFocusEnforcementName[] = "Audio Focus Enforcement";
  26. const char kEnableAudioFocusEnforcementDescription[] =
  27. "Enables enforcement of a single media session having audio focus at "
  28. "any one time. Requires #enable-media-session-service to be enabled too.";
  29. +const char kDisableWebGLName[] = "WebGL";
  30. +
  31. +const char kDisableWebGLDescription[] = "Enable or disable all versions of WebGL";
  32. +
  33. const char kEnableAutofillAccountWalletStorageName[] =
  34. "Enable the account data storage for autofill";
  35. diff --git a/chrome/browser/flag_descriptions.h b/chrome/browser/flag_descriptions.h
  36. --- a/chrome/browser/flag_descriptions.h
  37. +++ b/chrome/browser/flag_descriptions.h
  38. @@ -347,6 +347,9 @@ extern const char kDisallowDocWrittenScriptsUiDescription[];
  39. extern const char kEnableAccessibilityObjectModelName[];
  40. extern const char kEnableAccessibilityObjectModelDescription[];
  41. +extern const char kDisableWebGLName[];
  42. +extern const char kDisableWebGLDescription[];
  43. +
  44. extern const char kEnableAudioFocusEnforcementName[];
  45. extern const char kEnableAudioFocusEnforcementDescription[];
  46. --
  47. 2.17.1