Bug 1287653 - Strip EOL whitespace from gfx/thebes/gfxWindowsPlatform.cpp. draft
authorJeff Gilbert <jdashg@gmail.com>
Fri, 15 Jul 2016 18:09:51 -0700
changeset 394098 ee29afa8a7166139cad7bb458d7ac21e7443ef7f
parent 394016 d9762a7de374a5d59dfb9119311191dace721f5c
child 394099 b059b5c87f2c7a0b50353594fffd9f25dcaa5526
push id24492
push userbmo:jgilbert@mozilla.com
push dateFri, 29 Jul 2016 03:02:43 +0000
bugs1287653
milestone50.0a1
Bug 1287653 - Strip EOL whitespace from gfx/thebes/gfxWindowsPlatform.cpp. MozReview-Commit-ID: BEi4lo83HAK
gfx/thebes/gfxWindowsPlatform.cpp
--- a/gfx/thebes/gfxWindowsPlatform.cpp
+++ b/gfx/thebes/gfxWindowsPlatform.cpp
@@ -334,36 +334,36 @@ gfxWindowsPlatform::gfxWindowsPlatform()
   , mDeviceLock("gfxWindowsPlatform.mDeviceLock")
   , mHasDeviceReset(false)
   , mHasFakeDeviceReset(false)
   , mHasD3D9DeviceReset(false)
 {
   mUseClearTypeForDownloadableFonts = UNINITIALIZED_VALUE;
   mUseClearTypeAlways = UNINITIALIZED_VALUE;
 
-  /* 
-   * Initialize COM 
-   */ 
-  CoInitialize(nullptr); 
+  /*
+   * Initialize COM
+   */
+  CoInitialize(nullptr);
 
   RegisterStrongMemoryReporter(new GfxD2DVramReporter());
   RegisterStrongMemoryReporter(new GPUAdapterReporter());
   RegisterStrongMemoryReporter(new D3DSharedTexturesReporter());
 }
 
 gfxWindowsPlatform::~gfxWindowsPlatform()
 {
   DeviceManagerD3D11::Shutdown();
   mDeviceManager = nullptr;
 
   mozilla::gfx::Factory::D2DCleanup();
 
-  /* 
-   * Uninitialize COM 
-   */ 
+  /*
+   * Uninitialize COM
+   */
   CoUninitialize();
 }
 
 static void
 UpdateANGLEConfig()
 {
   if (!gfxConfig::IsEnabled(Feature::D3D11_COMPOSITING)) {
     gfxConfig::Disable(Feature::D3D11_HW_ANGLE, FeatureStatus::Disabled, "D3D11 compositing is disabled");
@@ -1037,61 +1037,61 @@ gfxWindowsPlatform::UseClearTypeAlways()
 {
     if (mUseClearTypeAlways == UNINITIALIZED_VALUE) {
         mUseClearTypeAlways = Preferences::GetBool(GFX_USE_CLEARTYPE_ALWAYS, false);
     }
 
     return mUseClearTypeAlways;
 }
 
-void 
+void
 gfxWindowsPlatform::GetDLLVersion(char16ptr_t aDLLPath, nsAString& aVersion)
 {
     DWORD versInfoSize, vers[4] = {0};
     // version info not available case
     aVersion.AssignLiteral(u"0.0.0.0");
     versInfoSize = GetFileVersionInfoSizeW(aDLLPath, nullptr);
     AutoTArray<BYTE,512> versionInfo;
-    
+
     if (versInfoSize == 0 ||
         !versionInfo.AppendElements(uint32_t(versInfoSize)))
     {
         return;
     }
 
-    if (!GetFileVersionInfoW(aDLLPath, 0, versInfoSize, 
+    if (!GetFileVersionInfoW(aDLLPath, 0, versInfoSize,
            LPBYTE(versionInfo.Elements())))
     {
         return;
-    } 
+    }
 
     UINT len = 0;
     VS_FIXEDFILEINFO *fileInfo = nullptr;
     if (!VerQueryValue(LPBYTE(versionInfo.Elements()), TEXT("\\"),
            (LPVOID *)&fileInfo, &len) ||
         len == 0 ||
         fileInfo == nullptr)
     {
         return;
     }
 
-    DWORD fileVersMS = fileInfo->dwFileVersionMS; 
+    DWORD fileVersMS = fileInfo->dwFileVersionMS;
     DWORD fileVersLS = fileInfo->dwFileVersionLS;
 
     vers[0] = HIWORD(fileVersMS);
     vers[1] = LOWORD(fileVersMS);
     vers[2] = HIWORD(fileVersLS);
     vers[3] = LOWORD(fileVersLS);
 
     char buf[256];
     snprintf_literal(buf, "%u.%u.%u.%u", vers[0], vers[1], vers[2], vers[3]);
     aVersion.Assign(NS_ConvertUTF8toUTF16(buf));
 }
 
-void 
+void
 gfxWindowsPlatform::GetCleartypeParams(nsTArray<ClearTypeParameterInfo>& aParams)
 {
     HKEY  hKey, subKey;
     DWORD i, rv, size, type;
     WCHAR displayName[256], subkeyName[256];
 
     aParams.Clear();
 
@@ -1153,17 +1153,17 @@ gfxWindowsPlatform::GetCleartypeParams(n
         if (subrv == ERROR_SUCCESS) {
             size = sizeof(value);
             subrv = RegQueryValueExW(subKey, L"ClearTypeLevel", nullptr, &type,
                                      (LPBYTE)&value, &size);
             if (subrv == ERROR_SUCCESS && type == REG_DWORD) {
                 foundData = true;
                 ctinfo.clearTypeLevel = value;
             }
-      
+
             size = sizeof(value);
             subrv = RegQueryValueExW(subKey, L"EnhancedContrastLevel",
                                      nullptr, &type, (LPBYTE)&value, &size);
             if (subrv == ERROR_SUCCESS && type == REG_DWORD) {
                 foundData = true;
                 ctinfo.enhancedContrast = value;
             }
 
@@ -1193,17 +1193,17 @@ gfxWindowsPlatform::FontsPrefsChanged(co
     } else if (!strcmp(GFX_USE_CLEARTYPE_ALWAYS, aPref)) {
         mUseClearTypeAlways = UNINITIALIZED_VALUE;
     } else if (!strncmp(GFX_CLEARTYPE_PARAMS, aPref, strlen(GFX_CLEARTYPE_PARAMS))) {
         SetupClearTypeParams();
     } else {
         clearTextFontCaches = false;
     }
 
-    if (clearTextFontCaches) {    
+    if (clearTextFontCaches) {
         gfxFontCache *fc = gfxFontCache::GetCache();
         if (fc) {
             fc->Flush();
         }
     }
 }
 
 #define ENHANCED_CONTRAST_REGISTRY_KEY \