Commit c3f957be authored by Ivan.Shulga's avatar Ivan.Shulga Committed by Alexander Trofimov

linux build

git-svn-id: svn://fileserver/activex/AVS/Sources/TeamlabOffice/trunk/ServerComponents@59125 954022d7-b5bf-4e40-9824-e11837661b57
parent 6ec3a4cf
//#include "stdafx.h" //#include "stdafx.h"
#include "Directory.h" #include "Directory.h"
#include <strsafe.h> //#include <strsafe.h>
//#include <shlobj.h> //#include <shlobj.h>
namespace FileSystem { namespace FileSystem {
......
#pragma once #pragma once
#include "Settings.h" #include "Settings.h"
#ifdef _WIN32
#include <windows.h> #include <windows.h>
#else
#endif
namespace FileSystem { namespace FileSystem {
class Directory { class Directory {
......
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
#include "BinReaderWriterDefines.h" #include "BinReaderWriterDefines.h"
#include "../../Common/Base64.h" #include "../../Common/Base64.h"
#include "ImageManager.h" #include "imagemanager.h"
#include "./XmlWriter.h" #include "./XmlWriter.h"
#include "BinaryFileReaderWriter.h" #include "BinaryFileReaderWriter.h"
#include "../PPTXFormat/FileContainer.h" #include "../PPTXFormat/FileContainer.h"
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
#include "../../ASCOfficeDocxFile2/DocWrapper/DocxSerializer.h" #include "../../ASCOfficeDocxFile2/DocWrapper/DocxSerializer.h"
#include "FontPicker.h" #include "FontPicker.h"
#include "../../DesktopEditor/Common/File.h" #include "../../DesktopEditor/common/File.h"
#define BYTE_SIZEOF sizeof(BYTE) #define BYTE_SIZEOF sizeof(BYTE)
#define USHORT_SIZEOF sizeof(USHORT) #define USHORT_SIZEOF sizeof(USHORT)
...@@ -239,6 +239,7 @@ namespace NSBinPptxRW ...@@ -239,6 +239,7 @@ namespace NSBinPptxRW
} }
CString CImageManager2::DownloadImage(const CString& strFile) CString CImageManager2::DownloadImage(const CString& strFile)
{ {
#ifndef DISABLE_FILE_DOWNLOADER
CFileDownloader oDownloader(strFile, TRUE); CFileDownloader oDownloader(strFile, TRUE);
oDownloader.Start( 1 ); oDownloader.Start( 1 );
while ( oDownloader.IsRunned() ) while ( oDownloader.IsRunned() )
...@@ -250,6 +251,7 @@ namespace NSBinPptxRW ...@@ -250,6 +251,7 @@ namespace NSBinPptxRW
{ {
return GenerateImage( oDownloader.GetFilePath(), strFile ); return GenerateImage( oDownloader.GetFilePath(), strFile );
} }
#endif
return _T(""); return _T("");
} }
...@@ -681,10 +683,12 @@ namespace NSBinPptxRW ...@@ -681,10 +683,12 @@ namespace NSBinPptxRW
oFile.ReadFile(pBuffer, dwLen); oFile.ReadFile(pBuffer, dwLen);
int nBase64BufferLen = Base64::Base64EncodeGetRequiredLength((int)dwLen, Base64::B64_BASE64_FLAG_NOCRLF); int nBase64BufferLen = Base64::Base64EncodeGetRequiredLength((int)dwLen, Base64::B64_BASE64_FLAG_NOCRLF);
LPSTR pbBase64Buffer = new CHAR[nBase64BufferLen]; LPSTR pbBase64Buffer = new CHAR[nBase64BufferLen + 1];
pbBase64Buffer[nBase64BufferLen] = '\0';
if (TRUE == Base64::Base64Encode(pBuffer, (int)dwLen, pbBase64Buffer, &nBase64BufferLen, Base64::B64_BASE64_FLAG_NOCRLF)) if (TRUE == Base64::Base64Encode(pBuffer, (int)dwLen, pbBase64Buffer, &nBase64BufferLen, Base64::B64_BASE64_FLAG_NOCRLF))
{ {
strDst64.SetString(pbBase64Buffer, nBase64BufferLen); //strDst64.SetString(pbBase64Buffer, nBase64BufferLen);
strDst64 = pbBase64Buffer;
} }
RELEASEARRAYOBJECTS(pBuffer); RELEASEARRAYOBJECTS(pBuffer);
......
...@@ -79,7 +79,7 @@ SOURCES += pptxformatlib.cpp \ ...@@ -79,7 +79,7 @@ SOURCES += pptxformatlib.cpp \
../../../Editor/BinaryFileReaderWriter.cpp \ ../../../Editor/BinaryFileReaderWriter.cpp \
../../../Editor/FontPicker.cpp \ ../../../Editor/FontPicker.cpp \
../../../../Common/DocxFormat/Source/SystemUtility/SystemUtility.cpp \ ../../../../Common/DocxFormat/Source/SystemUtility/SystemUtility.cpp \
../../Directory.cpp \ ../../../Directory.cpp \
../../File.cpp ../../File.cpp
HEADERS += pptxformatlib.h \ HEADERS += pptxformatlib.h \
......
...@@ -2,8 +2,11 @@ ...@@ -2,8 +2,11 @@
#include <string> #include <string>
#include <vector> #include <vector>
#ifdef _WIN32
#include <atlbase.h> #include <atlbase.h>
#include <atlstr.h> #include <atlstr.h>
#endif
namespace FileSystem { namespace FileSystem {
#ifdef UNICODE #ifdef UNICODE
......
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE QtCreatorProject> <!DOCTYPE QtCreatorProject>
<!-- Written by QtCreator 3.1.1, 2014-10-17T16:55:21. --> <!-- Written by QtCreator 3.1.1, 2014-10-22T16:04:23. -->
<qtcreator> <qtcreator>
<data> <data>
<variable>ProjectExplorer.Project.ActiveTarget</variable> <variable>ProjectExplorer.Project.ActiveTarget</variable>
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment