Merge to XFA: Remove typdefs for pointer types in fx_system.h.
[pdfium.git] / fpdfsdk / src / fpdfxfa / fpdfxfa_doc.cpp
index 106e3cb..c1f402e 100644 (file)
@@ -573,7 +573,7 @@ void CPDFXFA_Document::PageViewEvent(IXFA_PageView* pPageView, FX_DWORD dwFlags)
        }\r
 }\r
 \r
-void CPDFXFA_Document::WidgetEvent(IXFA_Widget* hWidget, CXFA_WidgetAcc* pWidgetData, FX_DWORD dwEvent, FX_LPVOID pParam, FX_LPVOID pAdditional)\r
+void CPDFXFA_Document::WidgetEvent(IXFA_Widget* hWidget, CXFA_WidgetAcc* pWidgetData, FX_DWORD dwEvent, void* pParam, void* pAdditional)\r
 {\r
        if (m_iDocType != DOCTYPE_DYNIMIC_XFA || NULL == hWidget)\r
                return;\r
@@ -745,7 +745,7 @@ void CPDFXFA_Document::ExportData(IXFA_Doc* hDoc, FX_WSTR wsFilePath, FX_BOOL bX
        if (fileType == FXFA_SAVEAS_XML)\r
        {\r
                content = "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\r\n";\r
-               fileWrite.WriteBlock((FX_LPCSTR)content, fileWrite.GetSize(), content.GetLength());\r
+               fileWrite.WriteBlock((const FX_CHAR*)content, fileWrite.GetSize(), content.GetLength());\r
                CFX_WideStringC data(L"data");\r
                if( pXFADocHander->SavePackage(m_pXFADocView->GetDoc(),data, &fileWrite))\r
                {\r
@@ -755,7 +755,7 @@ void CPDFXFA_Document::ExportData(IXFA_Doc* hDoc, FX_WSTR wsFilePath, FX_BOOL bX
        /*else if (fileType == FXFA_FILE_STATIC_XDP)\r
        {\r
                content = "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\r\n";\r
-               fileWrite.WriteBlock((FX_LPCSTR)content, fileWrite.GetSize(), content.GetLength());\r
+               fileWrite.WriteBlock((const FX_CHAR*)content, fileWrite.GetSize(), content.GetLength());\r
                CFX_WideStringC data(L"data");\r
                if( pXFADocHander->SavePackage(m_pXFADocView->GetDoc(), data, &fileWrite))\r
                {\r
@@ -766,8 +766,8 @@ void CPDFXFA_Document::ExportData(IXFA_Doc* hDoc, FX_WSTR wsFilePath, FX_BOOL bX
 //             wPath.FromUTF16LE(filePath);\r
                CFX_ByteString bPath = wPath.UTF8Encode();\r
                CFX_ByteString szFormat = "\n<pdf href=\"%s\" xmlns=\"http://ns.adobe.com/xdp/pdf/\"/>";\r
-               content.Format(szFormat,(char*)(FX_LPCSTR)bPath);\r
-               fileWrite.WriteBlock((FX_LPCSTR)content,fileWrite.GetSize(), content.GetLength());\r
+               content.Format(szFormat,(char*)(const FX_CHAR*)bPath);\r
+               fileWrite.WriteBlock((const FX_CHAR*)content,fileWrite.GetSize(), content.GetLength());\r
        }\r
        */\r
        else if (fileType == FXFA_SAVEAS_XDP)\r
@@ -817,11 +817,11 @@ void CPDFXFA_Document::ExportData(IXFA_Doc* hDoc, FX_WSTR wsFilePath, FX_BOOL bX
                                if (i == size-1)\r
                                {\r
                                        //CFX_WideString wPath = pEnv->FFI_GetFilePath(pFileHandler);\r
-                                       CFX_WideString wPath = CFX_WideString::FromUTF16LE((unsigned short*)(FX_LPCSTR)bs, bs.GetLength()/sizeof(unsigned short));\r
+                                       CFX_WideString wPath = CFX_WideString::FromUTF16LE((unsigned short*)(const FX_CHAR*)bs, bs.GetLength()/sizeof(unsigned short));\r
                                        CFX_ByteString bPath = wPath.UTF8Encode();\r
                                        CFX_ByteString szFormat = "\n<pdf href=\"%s\" xmlns=\"http://ns.adobe.com/xdp/pdf/\"/>";\r
-                                       content.Format(szFormat,(char*)(FX_LPCSTR)bPath);\r
-                                       fileWrite.WriteBlock((FX_LPCSTR)content,fileWrite.GetSize(), content.GetLength());\r
+                                       content.Format(szFormat,(char*)(const FX_CHAR*)bPath);\r
+                                       fileWrite.WriteBlock((const FX_CHAR*)content,fileWrite.GetSize(), content.GetLength());\r
                                }\r
 \r
                                CPDF_Stream* pStream = (CPDF_Stream*)pDirectObj;\r
@@ -1085,7 +1085,7 @@ FX_BOOL CPDFXFA_Document::_ExportSubmitFile(FPDF_FILEHANDLER* pFileHandler, int
                CFX_WideString ws;\r
                ws.FromLocal("data");\r
                CFX_ByteString content = "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\r\n";\r
-               fileStream.WriteBlock((FX_LPCSTR)content,0,content.GetLength());\r
+               fileStream.WriteBlock((const FX_CHAR*)content,0,content.GetLength());\r
                pDocHandler->SavePackage(m_pXFADoc, ws, &fileStream);\r
        }\r
        else if (fileType == FXFA_SAVEAS_XDP)\r