summaryrefslogtreecommitdiff
path: root/core/fxcrt/cfx_fileaccess_windows.cpp
diff options
context:
space:
mode:
authorLei Zhang <thestig@chromium.org>2018-07-25 17:35:19 +0000
committerChromium commit bot <commit-bot@chromium.org>2018-07-25 17:35:19 +0000
commit8481c71db0e3abed7bd12669116b223a65bebbb4 (patch)
tree9330a14cfba4a3aaf83870b4803e2ecd0ccacd82 /core/fxcrt/cfx_fileaccess_windows.cpp
parent5b322338073162afab98bb28c920692c73b995ed (diff)
downloadpdfium-8481c71db0e3abed7bd12669116b223a65bebbb4.tar.xz
Only build cfx_fileaccess_windows.cpp on Windows.
- Remove #if guards in the .cpp file and flip the #if guard in the header to produce an error when incorrectly included. - Do the same for cfx_fileaccess_posix.cpp. - Also remove forward declarations for win32 APIs. Change-Id: I81056ea6198d342e62744bd3240b3a28ac53d5c0 Reviewed-on: https://pdfium-review.googlesource.com/38410 Reviewed-by: Tom Sepez <tsepez@chromium.org> Commit-Queue: Lei Zhang <thestig@chromium.org>
Diffstat (limited to 'core/fxcrt/cfx_fileaccess_windows.cpp')
-rw-r--r--core/fxcrt/cfx_fileaccess_windows.cpp15
1 files changed, 0 insertions, 15 deletions
diff --git a/core/fxcrt/cfx_fileaccess_windows.cpp b/core/fxcrt/cfx_fileaccess_windows.cpp
index f416bb6b77..242c202984 100644
--- a/core/fxcrt/cfx_fileaccess_windows.cpp
+++ b/core/fxcrt/cfx_fileaccess_windows.cpp
@@ -11,8 +11,6 @@
#include "core/fxcrt/fx_string.h"
#include "third_party/base/ptr_util.h"
-#if _FX_PLATFORM_ == _FX_PLATFORM_WINDOWS_
-
namespace {
void GetFileMode(uint32_t dwMode,
@@ -36,18 +34,6 @@ std::unique_ptr<FileAccessIface> FileAccessIface::Create() {
return pdfium::MakeUnique<CFX_FileAccess_Windows>();
}
-#ifdef __cplusplus
-extern "C" {
-#endif
-WINBASEAPI BOOL WINAPI GetFileSizeEx(HANDLE hFile, PLARGE_INTEGER lpFileSize);
-WINBASEAPI BOOL WINAPI SetFilePointerEx(HANDLE hFile,
- LARGE_INTEGER liDistanceToMove,
- PLARGE_INTEGER lpNewFilePointer,
- DWORD dwMoveMethod);
-#ifdef __cplusplus
-}
-#endif
-
CFX_FileAccess_Windows::CFX_FileAccess_Windows() : m_hFile(nullptr) {}
CFX_FileAccess_Windows::~CFX_FileAccess_Windows() {
@@ -193,4 +179,3 @@ bool CFX_FileAccess_Windows::Truncate(FX_FILESIZE szFile) {
return !!::SetEndOfFile(m_hFile);
}
-#endif