Rename class CFX_FontSourceEnum_File to CFGAS_FontSourceEnumFile.

Straight rename, no functional change.

This class, along with the rest of fgas/font, may wind up being
GC'd down the road, and CFX_-prefixed classes shouldn't be GC'd,
since (in theory) their name suggests that they could be used on
either side (non-XFA vs. XFA).

- Remove second underscore in class name.

Change-Id: Ib01b2d85d4cd7c438e0b03f3e7dbf862a3a244f2
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/72950
Reviewed-by: Lei Zhang <thestig@chromium.org>
Commit-Queue: Tom Sepez <tsepez@chromium.org>
diff --git a/xfa/fgas/BUILD.gn b/xfa/fgas/BUILD.gn
index c4c68b2..17e60cd 100644
--- a/xfa/fgas/BUILD.gn
+++ b/xfa/fgas/BUILD.gn
@@ -41,8 +41,8 @@
 
   if (!is_win) {
     sources += [
-      "font/cfx_fontsourceenum_file.cpp",
-      "font/cfx_fontsourceenum_file.h",
+      "font/cfgas_fontsource_enum_file.cpp",
+      "font/cfgas_fontsource_enum_file.h",
     ]
   }
 }
diff --git a/xfa/fgas/font/cfgas_fontmgr.cpp b/xfa/fgas/font/cfgas_fontmgr.cpp
index 044ad47..cacb962 100644
--- a/xfa/fgas/font/cfgas_fontmgr.cpp
+++ b/xfa/fgas/font/cfgas_fontmgr.cpp
@@ -24,7 +24,7 @@
 #include "xfa/fgas/font/fgas_fontutils.h"
 
 #if !defined(OS_WIN)
-#include "xfa/fgas/font/cfx_fontsourceenum_file.h"
+#include "xfa/fgas/font/cfgas_fontsource_enum_file.h"
 #endif
 
 namespace {
@@ -609,7 +609,7 @@
 CFX_FontDescriptor::~CFX_FontDescriptor() = default;
 
 CFGAS_FontMgr::CFGAS_FontMgr()
-    : m_pFontSource(std::make_unique<CFX_FontSourceEnum_File>()) {}
+    : m_pFontSource(std::make_unique<CFGAS_FontSourceEnumFile>()) {}
 
 CFGAS_FontMgr::~CFGAS_FontMgr() = default;
 
diff --git a/xfa/fgas/font/cfgas_fontmgr.h b/xfa/fgas/font/cfgas_fontmgr.h
index bc7768e..6bc32d9 100644
--- a/xfa/fgas/font/cfgas_fontmgr.h
+++ b/xfa/fgas/font/cfgas_fontmgr.h
@@ -21,9 +21,9 @@
 #include "core/fxge/fx_freetype.h"
 #include "xfa/fgas/font/cfgas_pdffontmgr.h"
 
+class CFGAS_FontSourceEnumFile;
 class CFGAS_GEFont;
 class CFX_FontMapper;
-class CFX_FontSourceEnum_File;
 class IFX_SeekableReadStream;
 
 #if defined(OS_WIN)
@@ -151,7 +151,7 @@
 #if defined(OS_WIN)
   std::deque<FX_FONTDESCRIPTOR> m_FontFaces;
 #else
-  std::unique_ptr<CFX_FontSourceEnum_File> m_pFontSource;
+  std::unique_ptr<CFGAS_FontSourceEnumFile> m_pFontSource;
   std::vector<std::unique_ptr<CFX_FontDescriptor>> m_InstalledFonts;
   std::map<uint32_t, std::unique_ptr<std::vector<CFX_FontDescriptorInfo>>>
       m_Hash2CandidateList;
diff --git a/xfa/fgas/font/cfx_fontsourceenum_file.cpp b/xfa/fgas/font/cfgas_fontsource_enum_file.cpp
similarity index 86%
rename from xfa/fgas/font/cfx_fontsourceenum_file.cpp
rename to xfa/fgas/font/cfgas_fontsource_enum_file.cpp
index f4c4d08..eb57acf 100644
--- a/xfa/fgas/font/cfx_fontsourceenum_file.cpp
+++ b/xfa/fgas/font/cfgas_fontsource_enum_file.cpp
@@ -4,7 +4,7 @@
 
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
-#include "xfa/fgas/font/cfx_fontsourceenum_file.h"
+#include "xfa/fgas/font/cfgas_fontsource_enum_file.h"
 
 #include <iterator>
 
@@ -31,12 +31,12 @@
 
 }  // namespace
 
-CFX_FontSourceEnum_File::CFX_FontSourceEnum_File()
+CFGAS_FontSourceEnumFile::CFGAS_FontSourceEnumFile()
     : m_FolderPaths(std::begin(kFontFolders), std::end(kFontFolders)) {}
 
-CFX_FontSourceEnum_File::~CFX_FontSourceEnum_File() = default;
+CFGAS_FontSourceEnumFile::~CFGAS_FontSourceEnumFile() = default;
 
-ByteString CFX_FontSourceEnum_File::GetNextFile() {
+ByteString CFGAS_FontSourceEnumFile::GetNextFile() {
   FX_FolderHandle* pCurHandle =
       !m_FolderQueue.empty() ? m_FolderQueue.back().pFolderHandle : nullptr;
   if (!pCurHandle) {
@@ -82,15 +82,15 @@
   return bsName;
 }
 
-void CFX_FontSourceEnum_File::GetNext() {
+void CFGAS_FontSourceEnumFile::GetNext() {
   m_wsNext = WideString::FromUTF8(GetNextFile().AsStringView());
 }
 
-bool CFX_FontSourceEnum_File::HasNext() const {
+bool CFGAS_FontSourceEnumFile::HasNext() const {
   return !m_wsNext.IsEmpty();
 }
 
-RetainPtr<IFX_SeekableStream> CFX_FontSourceEnum_File::GetStream() const {
+RetainPtr<IFX_SeekableStream> CFGAS_FontSourceEnumFile::GetStream() const {
   ASSERT(HasNext());
   return IFX_SeekableStream::CreateFromFilename(m_wsNext.c_str(),
                                                 FX_FILEMODE_ReadOnly);
diff --git a/xfa/fgas/font/cfx_fontsourceenum_file.h b/xfa/fgas/font/cfgas_fontsource_enum_file.h
similarity index 79%
rename from xfa/fgas/font/cfx_fontsourceenum_file.h
rename to xfa/fgas/font/cfgas_fontsource_enum_file.h
index 9e93a97..d7b0c6b 100644
--- a/xfa/fgas/font/cfx_fontsourceenum_file.h
+++ b/xfa/fgas/font/cfgas_fontsource_enum_file.h
@@ -4,8 +4,8 @@
 
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
-#ifndef XFA_FGAS_FONT_CFX_FONTSOURCEENUM_FILE_H_
-#define XFA_FGAS_FONT_CFX_FONTSOURCEENUM_FILE_H_
+#ifndef XFA_FGAS_FONT_CFGAS_FONTSOURCE_ENUM_FILE_H_
+#define XFA_FGAS_FONT_CFGAS_FONTSOURCE_ENUM_FILE_H_
 
 #include <vector>
 
@@ -19,10 +19,10 @@
 #error "Not used on Windows"
 #endif
 
-class CFX_FontSourceEnum_File {
+class CFGAS_FontSourceEnumFile {
  public:
-  CFX_FontSourceEnum_File();
-  ~CFX_FontSourceEnum_File();
+  CFGAS_FontSourceEnumFile();
+  ~CFGAS_FontSourceEnumFile();
 
   void GetNext();
   bool HasNext() const;
@@ -46,4 +46,4 @@
   std::vector<ByteString> m_FolderPaths;
 };
 
-#endif  // XFA_FGAS_FONT_CFX_FONTSOURCEENUM_FILE_H_
+#endif  // XFA_FGAS_FONT_CFGAS_FONTSOURCE_ENUM_FILE_H_