Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1069)

Unified Diff: public/fpdf_edit.h

Issue 1172793002: Merge to XFA: Use stdint.h types throughout PDFium. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@xfa
Patch Set: Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « fpdfsdk/src/pdfwindow/PWL_Wnd.cpp ('k') | xfa/include/fwl/adapter/fwl_adapterclipboardmgr.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: public/fpdf_edit.h
diff --git a/public/fpdf_edit.h b/public/fpdf_edit.h
index 33c51c5336d4c74dd122f20a4e884fac2dcf08cd..7032d6078c6c10bb9958f696765351ceec281bd2 100644
--- a/public/fpdf_edit.h
+++ b/public/fpdf_edit.h
@@ -7,16 +7,18 @@
#ifndef PUBLIC_FPDF_EDIT_H_
#define PUBLIC_FPDF_EDIT_H_
+#include <stdint.h>
+
#include "fpdfview.h"
// Define all types used in the SDK. Note they can be simply regarded as opaque pointers
// or long integer numbers.
-#define FPDF_ARGB(a,r,g,b) ((((FX_DWORD)(((FX_BYTE)(b)|((FX_WORD)((FX_BYTE)(g))<<8))|(((FX_DWORD)(FX_BYTE)(r))<<16)))) | (((FX_DWORD)(FX_BYTE)(a))<<24))
-#define FPDF_GetBValue(argb) ((FX_BYTE)(argb))
-#define FPDF_GetGValue(argb) ((FX_BYTE)(((FX_WORD)(argb)) >> 8))
-#define FPDF_GetRValue(argb) ((FX_BYTE)((argb)>>16))
-#define FPDF_GetAValue(argb) ((FX_BYTE)((argb)>>24))
+#define FPDF_ARGB(a,r,g,b) ((((uint32_t)(((uint8_t)(b)|((FX_WORD)((uint8_t)(g))<<8))|(((FX_DWORD)(uint8_t)(r))<<16)))) | (((FX_DWORD)(uint8_t)(a))<<24))
+#define FPDF_GetBValue(argb) ((uint8_t)(argb))
+#define FPDF_GetGValue(argb) ((uint8_t)(((uint16_t)(argb)) >> 8))
+#define FPDF_GetRValue(argb) ((uint8_t)((argb)>>16))
+#define FPDF_GetAValue(argb) ((uint8_t)((argb)>>24))
#ifdef __cplusplus
extern "C" {
« no previous file with comments | « fpdfsdk/src/pdfwindow/PWL_Wnd.cpp ('k') | xfa/include/fwl/adapter/fwl_adapterclipboardmgr.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698