Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mpc-hc/mpc-hc.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorXhmikosR <xhmikosr@users.sourceforge.net>2010-09-25 03:50:52 +0400
committerXhmikosR <xhmikosr@users.sourceforge.net>2010-09-25 03:50:52 +0400
commitb77331e97a8983fecc23e6f8a0936628a060c444 (patch)
tree5bd1c8c1fe9d9a5737b714b3db87c543c00a9ce3
parent8f129aa0e146c33518c3ac63c179ed2963f9a2ca (diff)
legacy branch: merge changes from trunk r2599-r2620, fixed compilation of some apps after recent source tree refactoring, added VS2008 projects for subresync and vsconv (they don't compile yet)
git-svn-id: https://mpc-hc.svn.sourceforge.net/svnroot/mpc-hc/branches/legacy@2621 10f7b99b-c216-0410-bff0-8a66a9350fd8
-rw-r--r--distrib/innosetup_cpu_detection.iss184
-rw-r--r--src/Subtitles/STS.cpp2
-rw-r--r--src/apps/VSRip/VSRip.cpp5
-rw-r--r--src/apps/VSRip/VSRip.rc4
-rw-r--r--src/apps/VSRip/VSRipDlg.cpp4
-rw-r--r--src/apps/VSRip/res/VSRip.icobin67777 -> 21630 bytes
-rw-r--r--src/apps/VSRip/res/VSRip_2010.icobin0 -> 67777 bytes
-rw-r--r--src/apps/VSRip/stdafx.h2
-rw-r--r--src/apps/asf2mkv/asf2mkv.sln4
-rw-r--r--src/apps/asf2mkv/asf2mkv_2010.sln4
-rw-r--r--src/apps/asf2mkv/stdafx.h12
-rw-r--r--src/apps/mpcinfo/stdafx.h14
-rw-r--r--src/apps/mplayerc/AppSettings.cpp38
-rw-r--r--src/apps/mplayerc/AppSettings.h321
-rw-r--r--src/apps/mplayerc/Changelog.txt8
-rw-r--r--src/apps/mplayerc/ChildView.cpp41
-rw-r--r--src/apps/mplayerc/FGManagerBDA.cpp44
-rw-r--r--src/apps/mplayerc/MainFrm.cpp14
-rw-r--r--src/apps/mplayerc/OpenCapDeviceDlg.cpp62
-rw-r--r--src/apps/mplayerc/OpenFileDlg.cpp6
-rw-r--r--src/apps/mplayerc/PPageAccelTbl.cpp2071
-rw-r--r--src/apps/mplayerc/PPageFileMediaInfo.cpp18
-rw-r--r--src/apps/mplayerc/PPageFormats.cpp38
-rw-r--r--src/apps/mplayerc/PPageSubtitles.cpp14
-rw-r--r--src/apps/mplayerc/PPageWebServer.cpp2
-rw-r--r--src/apps/mplayerc/PlayerPlaylistBar.cpp44
-rw-r--r--src/apps/mplayerc/PlayerSeekBar.cpp12
-rw-r--r--src/apps/mplayerc/PlayerSeekBar.h1
-rw-r--r--src/apps/mplayerc/PlayerToolBar.cpp64
-rw-r--r--src/apps/mplayerc/PlayerToolBar.h2
-rw-r--r--src/apps/mplayerc/Playlist.cpp38
-rw-r--r--src/apps/mplayerc/QuicktimeGraph.cpp4
-rw-r--r--src/apps/mplayerc/RealMediaGraph.cpp12
-rw-r--r--src/apps/mplayerc/SaveDlg.cpp2
-rw-r--r--src/apps/mplayerc/StaticLink.cpp2
-rw-r--r--src/apps/mplayerc/VolumeCtrl.cpp7
-rw-r--r--src/apps/mplayerc/VolumeCtrl.h2
-rw-r--r--src/apps/mplayerc/WebServer.cpp4
-rw-r--r--src/apps/mplayerc/mpcresources/common.pl6
-rw-r--r--src/apps/mplayerc/mpcresources/rcfile.pl70
-rw-r--r--src/apps/mplayerc/mplayerc.cpp39
-rw-r--r--src/apps/mplayerc/mplayerc.h2
-rw-r--r--src/apps/subresync/stdafx.cpp2
-rw-r--r--src/apps/subresync/stdafx.h26
-rw-r--r--src/apps/subresync/subresync.cpp63
-rw-r--r--src/apps/subresync/subresync.h10
-rw-r--r--src/apps/subresync/subresync.sln36
-rw-r--r--src/apps/subresync/subresync.vcproj260
-rw-r--r--src/apps/subresync/subresyncDlg.cpp156
-rw-r--r--src/apps/subresync/subresyncDlg.h84
-rw-r--r--src/apps/vsconv/stdafx.cpp5
-rw-r--r--src/apps/vsconv/stdafx.h26
-rw-r--r--src/apps/vsconv/vsconv.cpp277
-rw-r--r--src/apps/vsconv/vsconv.h6
-rw-r--r--src/apps/vsconv/vsconv.sln58
-rw-r--r--src/apps/vsconv/vsconv.vcproj271
-rw-r--r--src/apps/vsconv/vsconvDlg.cpp147
-rw-r--r--src/apps/vsconv/vsconvDlg.h22
-rw-r--r--src/filters/PinInfoWnd.cpp16
-rw-r--r--src/filters/renderer/SyncClock/SyncClock.vcproj284
-rw-r--r--src/filters/renderer/SyncClock/SyncClock.vcxproj154
-rw-r--r--src/thirdparty/libpng/CHANGES70
-rw-r--r--src/thirdparty/libpng/LICENSE6
-rw-r--r--src/thirdparty/libpng/README12
-rw-r--r--src/thirdparty/libpng/png.c6
-rw-r--r--src/thirdparty/libpng/png.h430
-rw-r--r--src/thirdparty/libpng/pngconf.h117
-rw-r--r--src/thirdparty/libpng/pngpread.c62
-rw-r--r--src/thirdparty/libpng/pngpriv.h22
-rw-r--r--src/thirdparty/libpng/pngrutil.c66
-rw-r--r--src/thirdparty/libpng/pngtest.c8
-rw-r--r--src/thirdparty/libpng/pngtrans.c2
72 files changed, 3195 insertions, 2732 deletions
diff --git a/distrib/innosetup_cpu_detection.iss b/distrib/innosetup_cpu_detection.iss
index d68ed83d4..9b5b1bd42 100644
--- a/distrib/innosetup_cpu_detection.iss
+++ b/distrib/innosetup_cpu_detection.iss
@@ -2,68 +2,68 @@
[Code]
Type
- TSystemInfo = record
- wProcessorArchitecture: Word;
- wReserved: Word;
- dwPageSize: DWORD;
- lpMinimumApplicationAddress: Integer;
- lpMaximumApplicationAddress: Integer;
- dwActiveProcessorMask: DWORD;
- dwNumberOfProcessors: DWORD;
- dwProcessorType: DWORD;
- dwAllocationGranularity: DWORD;
- wProcessorLevel: Word;
- wProcessorRevision: Word;
- end;
-
- TCPUCoreInfo_T = record
- dwCPUType,
- dwCPUFamily,
- dwCPUModel,
- dwCPUExtFamily,
- dwCPUExtModel,
- dwCPUStepping,
- dwCPUFeatures, // result from edx when cpuid called with eax=1
- dwCPUAMDExtSignature, // AMD extended features
- dwBrandIndex,
- dwCLFlushLineSize,
- dwCPUExtFeatures: DWORD; // cpuid result when eax = 1
- end;
-
- THTInfo = record
- htResultCode: DWord;
- nPhysicalProcs, // Number of physical processors
- nLogicalProcs, // Number of logical processors (including physical processors)
- nLogicalPerPackage: Integer;
- dwPhysicalAffinity, // Mask for physical CPUs
- dwLogicalAffinity: DWORD; // Mask for non-physical CPUs
- nMaxPhysGetProcAff: Integer; // Max number of physical processors to get Phys/Log Affinity table
- pPhysProcAff: Integer; // Allocate nMaxPhysGetProcAff*sizeof(PHYSPROCAFF_T) before calling WinCPUID_Init
- end;
-
- TCPUInfo = record
- bIsInitialized, // Check this to see if structure was successfully initialized
- bCPUID_Supported,
- bCloneFlag, // 0 -> Intel CPU, non-zero -> non-Intel CPU
- bMMX_Supported,
- bSSE_Supported,
- bSSE2_Supported,
- bSSEMMXExt_Supported, // Some AMD CPUs support SSE MMX (integer) extensions only
- b3DNow_Supported,
- bExt3DNow_Supported,
- bHT_Supported, // HT supported and available for use, check htInfo for more details
- bDAZ_Supported,
- bRDTSC_Supported,
- bCMOV_Supported,
- EmulCode: Integer;
- llCPUFreqL,
- llCPUFreqH: DWord;
- eCPUVendor: DWORD;
- coreInfo: TCPUCoreInfo_T;
- htInfo: THTInfo;
- pCacheInfo: Integer;
- pProcString: String;
- end;
+ TSystemInfo = record
+ wProcessorArchitecture: Word;
+ wReserved: Word;
+ dwPageSize: DWORD;
+ lpMinimumApplicationAddress: Integer;
+ lpMaximumApplicationAddress: Integer;
+ dwActiveProcessorMask: DWORD;
+ dwNumberOfProcessors: DWORD;
+ dwProcessorType: DWORD;
+ dwAllocationGranularity: DWORD;
+ wProcessorLevel: Word;
+ wProcessorRevision: Word;
+ end;
+
+ TCPUCoreInfo_T = record
+ dwCPUType,
+ dwCPUFamily,
+ dwCPUModel,
+ dwCPUExtFamily,
+ dwCPUExtModel,
+ dwCPUStepping,
+ dwCPUFeatures, // result from edx when cpuid called with eax=1
+ dwCPUAMDExtSignature, // AMD extended features
+ dwBrandIndex,
+ dwCLFlushLineSize,
+ dwCPUExtFeatures: DWORD; // cpuid result when eax = 1
+ end;
+
+ THTInfo = record
+ htResultCode: DWord;
+ nPhysicalProcs, // Number of physical processors
+ nLogicalProcs, // Number of logical processors (including physical processors)
+ nLogicalPerPackage: Integer;
+ dwPhysicalAffinity, // Mask for physical CPUs
+ dwLogicalAffinity: DWORD; // Mask for non-physical CPUs
+ nMaxPhysGetProcAff: Integer; // Max number of physical processors to get Phys/Log Affinity table
+ pPhysProcAff: Integer; // Allocate nMaxPhysGetProcAff*sizeof(PHYSPROCAFF_T) before calling WinCPUID_Init
+ end;
+
+ TCPUInfo = record
+ bIsInitialized, // Check this to see if structure was successfully initialized
+ bCPUID_Supported,
+ bCloneFlag, // 0 -> Intel CPU, non-zero -> non-Intel CPU
+ bMMX_Supported,
+ bSSE_Supported,
+ bSSE2_Supported,
+ bSSEMMXExt_Supported, // Some AMD CPUs support SSE MMX (integer) extensions only
+ b3DNow_Supported,
+ bExt3DNow_Supported,
+ bHT_Supported, // HT supported and available for use, check htInfo for more details
+ bDAZ_Supported,
+ bRDTSC_Supported,
+ bCMOV_Supported,
+ EmulCode: Integer;
+ llCPUFreqL,
+ llCPUFreqH: DWord;
+ eCPUVendor: DWORD;
+ coreInfo: TCPUCoreInfo_T;
+ htInfo: THTInfo;
+ pCacheInfo: Integer;
+ pProcString: String;
+ end;
var
cpu_sse: Boolean;
@@ -80,57 +80,57 @@ procedure GetSystemInfo(var lpSystemInfo: TSystemInfo); external 'GetSystemInfo@
procedure CPUCheck();
var
- CPUInfo: TCPUInfo;
+ CPUInfo: TCPUInfo;
begin
- cpu_cores := 1;
- cpu_family := 6;
-
- WinCPUID_Init(0, CPUInfo);
-
- if (CPUInfo.bIsInitialized = 0) then begin
- // something went wrong
- end
- else begin
- if (CPUInfo.bSSE_Supported = 1) then begin
- cpu_sse := true;
- end;
- if (CPUInfo.bSSE2_Supported = 1) then begin
- cpu_sse2 := true;
- end;
-
- cpu_cores := CPUInfo.htInfo.nPhysicalProcs;
- if cpu_cores > 8 then begin
- cpu_cores := 8;
- end;
- if cpu_cores < 1 then begin
cpu_cores := 1;
+ cpu_family := 6;
+
+ WinCPUID_Init(0, CPUInfo);
+
+ if (CPUInfo.bIsInitialized = 0) then begin
+ // something went wrong
+ end
+ else begin
+ if (CPUInfo.bSSE_Supported = 1) then begin
+ cpu_sse := true;
+ end;
+ if (CPUInfo.bSSE2_Supported = 1) then begin
+ cpu_sse2 := true;
+ end;
+
+ cpu_cores := CPUInfo.htInfo.nPhysicalProcs;
+ if cpu_cores > 8 then begin
+ cpu_cores := 8;
+ end;
+ if cpu_cores < 1 then begin
+ cpu_cores := 1;
+ end;
+
+ cpu_family := CPUInfo.coreInfo.dwCPUFamily;
end;
-
- cpu_family := CPUInfo.coreInfo.dwCPUFamily;
- end;
end;
function Is_SSE_Supported(): Boolean;
begin
- Result := cpu_sse;
+ Result := cpu_sse;
end;
function Is_SSE2_Supported(): Boolean;
begin
- Result := cpu_sse2;
+ Result := cpu_sse2;
end;
function GetNumberOfCores(): Integer;
begin
- Result := cpu_cores;
+ Result := cpu_cores;
end;
function HasMultipleCores(): Boolean;
begin
- Result := (cpu_cores > 1);
+ Result := (cpu_cores > 1);
end;
function HasSupportedCPU(): Boolean;
begin
- Result := (cpu_family >= 6);
+ Result := (cpu_family >= 6);
end;
diff --git a/src/Subtitles/STS.cpp b/src/Subtitles/STS.cpp
index dc3cd9598..fa05ea303 100644
--- a/src/Subtitles/STS.cpp
+++ b/src/Subtitles/STS.cpp
@@ -3175,7 +3175,7 @@ void STSStyle::SetDefault()
fBlur = 0;
fGaussianBlur = 0;
fontShiftX = fontShiftY = fontAngleZ = fontAngleX = fontAngleY = 0;
- relativeTo = 2;
+ relativeTo = 1;
#ifdef _VSMOD
// patch m001. Vertical fontspacing
mod_verticalSpace = 0;
diff --git a/src/apps/VSRip/VSRip.cpp b/src/apps/VSRip/VSRip.cpp
index 6f3314e98..b7d5fef52 100644
--- a/src/apps/VSRip/VSRip.cpp
+++ b/src/apps/VSRip/VSRip.cpp
@@ -25,11 +25,6 @@
#include "VSRip.h"
#include "VSRipDlg.h"
-#ifdef _DEBUG
-#define new DEBUG_NEW
-#endif
-
-
// CVSRipApp
BEGIN_MESSAGE_MAP(CVSRipApp, CWinApp)
diff --git a/src/apps/VSRip/VSRip.rc b/src/apps/VSRip/VSRip.rc
index 828d4904e..fcd348ebc 100644
--- a/src/apps/VSRip/VSRip.rc
+++ b/src/apps/VSRip/VSRip.rc
@@ -26,7 +26,11 @@ LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
// Icon with lowest ID value placed first to ensure application icon
// remains consistent on all systems.
+#if _MSC_VER < 1600
IDR_MAINFRAME ICON "res\\VSRip.ico"
+#else
+IDR_MAINFRAME ICON "res\\VSRip_2010.ico"
+#endif
/////////////////////////////////////////////////////////////////////////////
//
diff --git a/src/apps/VSRip/VSRipDlg.cpp b/src/apps/VSRip/VSRipDlg.cpp
index f0dc1ec0b..8b2995f3c 100644
--- a/src/apps/VSRip/VSRipDlg.cpp
+++ b/src/apps/VSRip/VSRipDlg.cpp
@@ -26,10 +26,6 @@
#include "VSRip.h"
#include "VSRipDlg.h"
-#ifdef _DEBUG
-#define new DEBUG_NEW
-#endif
-
// CVSRipDlg dialog
diff --git a/src/apps/VSRip/res/VSRip.ico b/src/apps/VSRip/res/VSRip.ico
index d56fbcdfd..8a84ca3d3 100644
--- a/src/apps/VSRip/res/VSRip.ico
+++ b/src/apps/VSRip/res/VSRip.ico
Binary files differ
diff --git a/src/apps/VSRip/res/VSRip_2010.ico b/src/apps/VSRip/res/VSRip_2010.ico
new file mode 100644
index 000000000..d56fbcdfd
--- /dev/null
+++ b/src/apps/VSRip/res/VSRip_2010.ico
Binary files differ
diff --git a/src/apps/VSRip/stdafx.h b/src/apps/VSRip/stdafx.h
index aad729f56..2efc10c67 100644
--- a/src/apps/VSRip/stdafx.h
+++ b/src/apps/VSRip/stdafx.h
@@ -39,8 +39,6 @@
#include <afxwin.h> // MFC core and standard components
#include <afxext.h> // MFC extensions
#include <afxdisp.h> // MFC Automation classes
-#include <afxdtctl.h> // MFC support for Internet Explorer 4 Common Controls
-#include <afxdlgs.h>
#ifndef _AFX_NO_AFXCMN_SUPPORT
#include <afxcmn.h> // MFC support for Windows Common Controls
diff --git a/src/apps/asf2mkv/asf2mkv.sln b/src/apps/asf2mkv/asf2mkv.sln
index 1f256beb3..f8cbad2f1 100644
--- a/src/apps/asf2mkv/asf2mkv.sln
+++ b/src/apps/asf2mkv/asf2mkv.sln
@@ -12,9 +12,9 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "asf2mkv", "asf2mkv.vcproj",
{E8A3F6FA-AE1C-4C8E-A0B6-9C8480324EAA} = {E8A3F6FA-AE1C-4C8E-A0B6-9C8480324EAA}
EndProjectSection
EndProject
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "CmdUI", "..\..\ui\CmdUI\CmdUI.vcproj", "{03208025-D5C2-426A-B0FA-251D4338F30C}"
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "CmdUI", "..\..\CmdUI\CmdUI.vcproj", "{03208025-D5C2-426A-B0FA-251D4338F30C}"
EndProject
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "ResizableLib", "..\..\ui\ResizableLib\ResizableLib.vcproj", "{4CC7AE86-3E0A-430A-BFF4-BF00204CAFB0}"
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "ResizableLib", "..\..\thirdparty\ui\ResizableLib\ResizableLib.vcproj", "{4CC7AE86-3E0A-430A-BFF4-BF00204CAFB0}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DSUtil", "..\..\DSUtil\DSUtil.vcproj", "{FC70988B-1AE5-4381-866D-4F405E28AC42}"
EndProject
diff --git a/src/apps/asf2mkv/asf2mkv_2010.sln b/src/apps/asf2mkv/asf2mkv_2010.sln
index 1c9627756..733ced60f 100644
--- a/src/apps/asf2mkv/asf2mkv_2010.sln
+++ b/src/apps/asf2mkv/asf2mkv_2010.sln
@@ -2,9 +2,9 @@ Microsoft Visual Studio Solution File, Format Version 11.00
# Visual Studio 2010
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "asf2mkv", "asf2mkv.vcxproj", "{B4E3D650-306F-4F9B-A7DD-2F70C2F69007}"
EndProject
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "CmdUI", "..\..\ui\CmdUI\CmdUI.vcxproj", "{03208025-D5C2-426A-B0FA-251D4338F30C}"
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "CmdUI", "..\..\CmdUI\CmdUI.vcxproj", "{03208025-D5C2-426A-B0FA-251D4338F30C}"
EndProject
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "ResizableLib", "..\..\ui\ResizableLib\ResizableLib.vcxproj", "{4CC7AE86-3E0A-430A-BFF4-BF00204CAFB0}"
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "ResizableLib", "..\..\thirdparty\ui\ResizableLib\ResizableLib.vcxproj", "{4CC7AE86-3E0A-430A-BFF4-BF00204CAFB0}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DSUtil", "..\..\DSUtil\DSUtil.vcxproj", "{FC70988B-1AE5-4381-866D-4F405E28AC42}"
EndProject
diff --git a/src/apps/asf2mkv/stdafx.h b/src/apps/asf2mkv/stdafx.h
index 4a3ab7abd..27dd75cff 100644
--- a/src/apps/asf2mkv/stdafx.h
+++ b/src/apps/asf2mkv/stdafx.h
@@ -38,8 +38,8 @@
// turns off MFC's hiding of some common and often safely ignored warning messages
#define _AFX_ALL_WARNINGS
-#include <afxwin.h> // MFC core and standard components
-#include <afxext.h> // MFC extensions
+#include <afxwin.h> // MFC core and standard components
+#include <afxext.h> // MFC extensions
#include <afxdtctl.h> // MFC support for Internet Explorer 4 Common Controls
#ifndef _AFX_NO_AFXCMN_SUPPORT
#include <afxcmn.h> // MFC support for Windows Common Controls
@@ -52,7 +52,13 @@
#include <streams.h>
#include <dvdmedia.h>
-#include "../../ui/ui.h"
+#include "../../CmdUI/CmdUI.h"
+#include "../../thirdparty/ui/ResizableLib/ResizableDialog.h"
+#include "../../thirdparty/ui/ResizableLib/ResizablePage.h"
+#include "../../thirdparty/ui/ResizableLib/ResizableSheet.h"
+#include "../../thirdparty/ui/sizecbar/sizecbar.h"
+#include "../../thirdparty/ui/sizecbar/scbarcf.h"
+#include "../../thirdparty/ui/sizecbar/scbarg.h"
#include "../../DSUtil/DSUtil.h"
#include "../../DSUtil/SharedInclude.h"
#include "../../filters/Filters.h"
diff --git a/src/apps/mpcinfo/stdafx.h b/src/apps/mpcinfo/stdafx.h
index 9e5f785f9..4b5caf984 100644
--- a/src/apps/mpcinfo/stdafx.h
+++ b/src/apps/mpcinfo/stdafx.h
@@ -37,20 +37,6 @@
#include <afxwin.h> // MFC core and standard components
#include <afxext.h> // MFC extensions
-#ifndef _AFX_NO_OLE_SUPPORT
-#include <afxole.h> // MFC OLE classes
-#include <afxodlgs.h> // MFC OLE dialog classes
-#include <afxdisp.h> // MFC Automation classes
-#endif // _AFX_NO_OLE_SUPPORT
-
-#ifndef _AFX_NO_DB_SUPPORT
-#include <afxdb.h> // MFC ODBC database classes
-#endif // _AFX_NO_DB_SUPPORT
-
-#ifndef _AFX_NO_DAO_SUPPORT
-#include <afxdao.h> // MFC DAO database classes
-#endif // _AFX_NO_DAO_SUPPORT
-
#ifndef _AFX_NO_AFXCMN_SUPPORT
#include <afxcmn.h> // MFC support for Windows Common Controls
#endif // _AFX_NO_AFXCMN_SUPPORT
diff --git a/src/apps/mplayerc/AppSettings.cpp b/src/apps/mplayerc/AppSettings.cpp
index b20fe1cec..8cd8f839e 100644
--- a/src/apps/mplayerc/AppSettings.cpp
+++ b/src/apps/mplayerc/AppSettings.cpp
@@ -82,17 +82,17 @@ void CAppSettings::CreateCommands()
ADDCMD((ID_PLAY_SEEKFORWARDSMALL, 0, FVIRTKEY|FNOINVERT, IDS_MPLAYERC_23));
ADDCMD((ID_PLAY_SEEKBACKWARDSMALL, 0, FVIRTKEY|FNOINVERT, IDS_MPLAYERC_24));
ADDCMD((ID_PLAY_SEEKFORWARDMED, VK_RIGHT, FVIRTKEY|FCONTROL|FNOINVERT, IDS_MPLAYERC_25));
- ADDCMD((ID_PLAY_SEEKBACKWARDMED, VK_LEFT, FVIRTKEY|FCONTROL|FNOINVERT, IDS_MPLAYERC_26));
- ADDCMD((ID_PLAY_SEEKFORWARDLARGE, 0, FVIRTKEY|FNOINVERT, IDS_MPLAYERC_27));
- ADDCMD((ID_PLAY_SEEKBACKWARDLARGE, 0, FVIRTKEY|FNOINVERT, IDS_MPLAYERC_28));
+ ADDCMD((ID_PLAY_SEEKBACKWARDMED, VK_LEFT, FVIRTKEY|FCONTROL|FNOINVERT, IDS_MPLAYERC_26));
+ ADDCMD((ID_PLAY_SEEKFORWARDLARGE, 0, FVIRTKEY|FNOINVERT, IDS_MPLAYERC_27));
+ ADDCMD((ID_PLAY_SEEKBACKWARDLARGE, 0, FVIRTKEY|FNOINVERT, IDS_MPLAYERC_28));
ADDCMD((ID_PLAY_SEEKKEYFORWARD, VK_RIGHT, FVIRTKEY|FSHIFT|FNOINVERT, IDS_MPLAYERC_29));
- ADDCMD((ID_PLAY_SEEKKEYBACKWARD, VK_LEFT, FVIRTKEY|FSHIFT|FNOINVERT, IDS_MPLAYERC_30));
- ADDCMD((ID_NAVIGATE_SKIPFORWARD, VK_NEXT, FVIRTKEY|FNOINVERT, IDS_AG_NEXT, APPCOMMAND_MEDIA_NEXTTRACK, wmcmd::X2DOWN));
+ ADDCMD((ID_PLAY_SEEKKEYBACKWARD, VK_LEFT, FVIRTKEY|FSHIFT|FNOINVERT, IDS_MPLAYERC_30));
+ ADDCMD((ID_NAVIGATE_SKIPFORWARD, VK_NEXT, FVIRTKEY|FNOINVERT, IDS_AG_NEXT, APPCOMMAND_MEDIA_NEXTTRACK, wmcmd::X2DOWN));
ADDCMD((ID_NAVIGATE_SKIPBACK, VK_PRIOR, FVIRTKEY|FNOINVERT, IDS_AG_PREVIOUS, APPCOMMAND_MEDIA_PREVIOUSTRACK, wmcmd::X1DOWN));
ADDCMD((ID_NAVIGATE_SKIPFORWARDPLITEM, VK_NEXT, FVIRTKEY|FCONTROL|FNOINVERT, IDS_MPLAYERC_33));
ADDCMD((ID_NAVIGATE_SKIPBACKPLITEM, VK_PRIOR, FVIRTKEY|FCONTROL|FNOINVERT, IDS_MPLAYERC_34));
- ADDCMD((ID_NAVIGATE_TUNERSCAN, 'T', FVIRTKEY|FSHIFT|FNOINVERT, IDS_NAVIGATE_TUNERSCAN));
- ADDCMD((ID_FAVORITES_QUICKADDFAVORITE, 'Q', FVIRTKEY|FSHIFT|FNOINVERT, IDS_FAVORITES_QUICKADDFAVORITE));
+ ADDCMD((ID_NAVIGATE_TUNERSCAN, 'T', FVIRTKEY|FSHIFT|FNOINVERT, IDS_NAVIGATE_TUNERSCAN));
+ ADDCMD((ID_FAVORITES_QUICKADDFAVORITE, 'Q', FVIRTKEY|FSHIFT|FNOINVERT, IDS_FAVORITES_QUICKADDFAVORITE));
ADDCMD((ID_VIEW_CAPTIONMENU, '0', FVIRTKEY|FCONTROL|FNOINVERT, IDS_AG_TOGGLE_CAPTION));
ADDCMD((ID_VIEW_SEEKER, '1', FVIRTKEY|FCONTROL|FNOINVERT, IDS_AG_TOGGLE_SEEKER));
ADDCMD((ID_VIEW_CONTROLS, '2', FVIRTKEY|FCONTROL|FNOINVERT, IDS_AG_TOGGLE_CONTROLS));
@@ -118,8 +118,8 @@ void CAppSettings::CreateCommands()
ADDCMD((ID_VIEW_VF_DOUBLE, 0, FVIRTKEY|FNOINVERT, IDS_AG_VIDFRM_DOUBLE));
ADDCMD((ID_VIEW_VF_STRETCH, 0, FVIRTKEY|FNOINVERT, IDS_AG_VIDFRM_STRETCH));
ADDCMD((ID_VIEW_VF_FROMINSIDE, 0, FVIRTKEY|FNOINVERT, IDS_AG_VIDFRM_INSIDE));
- ADDCMD((ID_VIEW_VF_ZOOM1, 0, FVIRTKEY|FNOINVERT, IDS_AG_VIDFRM_ZOOM1));
- ADDCMD((ID_VIEW_VF_ZOOM2, 0, FVIRTKEY|FNOINVERT, IDS_AG_VIDFRM_ZOOM2));
+ ADDCMD((ID_VIEW_VF_ZOOM1, 0, FVIRTKEY|FNOINVERT, IDS_AG_VIDFRM_ZOOM1));
+ ADDCMD((ID_VIEW_VF_ZOOM2, 0, FVIRTKEY|FNOINVERT, IDS_AG_VIDFRM_ZOOM2));
ADDCMD((ID_VIEW_VF_FROMOUTSIDE, 0, FVIRTKEY|FNOINVERT, IDS_AG_VIDFRM_OUTSIDE));
ADDCMD((ID_VIEW_VF_SWITCHZOOM, 'P', FVIRTKEY|FNOINVERT, IDS_AG_VIDFRM_SWITCHZOOM));
ADDCMD((ID_ONTOP_ALWAYS, 'A', FVIRTKEY|FCONTROL|FNOINVERT, IDS_AG_ALWAYS_ON_TOP));
@@ -145,8 +145,8 @@ void CAppSettings::CreateCommands()
ADDCMD((ID_PANSCAN_ROTATEYM, VK_NUMPAD6, FVIRTKEY|FALT|FNOINVERT, IDS_AG_PNS_ROTATEY_M));
ADDCMD((ID_PANSCAN_ROTATEZP, VK_NUMPAD1, FVIRTKEY|FALT|FNOINVERT, IDS_AG_PNS_ROTATEZ_P));
ADDCMD((ID_PANSCAN_ROTATEZM, VK_NUMPAD3, FVIRTKEY|FALT|FNOINVERT, IDS_AG_PNS_ROTATEZ_M));
- ADDCMD((ID_VOLUME_UP, VK_UP, FVIRTKEY|FNOINVERT, IDS_AG_VOLUME_UP, APPCOMMAND_VOLUME_UP, wmcmd::WUP));
- ADDCMD((ID_VOLUME_DOWN, VK_DOWN, FVIRTKEY|FNOINVERT, IDS_AG_VOLUME_DOWN, APPCOMMAND_VOLUME_DOWN, wmcmd::WDOWN));
+ ADDCMD((ID_VOLUME_UP, VK_UP, FVIRTKEY|FNOINVERT, IDS_AG_VOLUME_UP, APPCOMMAND_VOLUME_UP, wmcmd::WUP));
+ ADDCMD((ID_VOLUME_DOWN, VK_DOWN, FVIRTKEY|FNOINVERT, IDS_AG_VOLUME_DOWN, APPCOMMAND_VOLUME_DOWN, wmcmd::WDOWN));
ADDCMD((ID_VOLUME_MUTE, 'M', FVIRTKEY|FCONTROL|FNOINVERT, IDS_AG_VOLUME_MUTE, APPCOMMAND_VOLUME_MUTE));
ADDCMD((ID_VOLUME_BOOST_INC, 0, FVIRTKEY|FNOINVERT, IDS_VOLUME_BOOST_INC));
ADDCMD((ID_VOLUME_BOOST_DEC, 0, FVIRTKEY|FNOINVERT, IDS_VOLUME_BOOST_DEC));
@@ -158,10 +158,10 @@ void CAppSettings::CreateCommands()
ADDCMD((ID_NAVIGATE_AUDIOMENU, 0, FVIRTKEY|FNOINVERT, IDS_MPLAYERC_66));
ADDCMD((ID_NAVIGATE_ANGLEMENU, 0, FVIRTKEY|FNOINVERT, IDS_MPLAYERC_67));
ADDCMD((ID_NAVIGATE_CHAPTERMENU, 0, FVIRTKEY|FNOINVERT, IDS_MPLAYERC_68));
- ADDCMD((ID_NAVIGATE_MENU_LEFT, VK_LEFT, FVIRTKEY|FALT|FNOINVERT, IDS_AG_DVD_MENU_LEFT));
+ ADDCMD((ID_NAVIGATE_MENU_LEFT, VK_LEFT, FVIRTKEY|FALT|FNOINVERT, IDS_AG_DVD_MENU_LEFT));
ADDCMD((ID_NAVIGATE_MENU_RIGHT, VK_RIGHT, FVIRTKEY|FALT|FNOINVERT, IDS_MPLAYERC_70));
ADDCMD((ID_NAVIGATE_MENU_UP, VK_UP, FVIRTKEY|FALT|FNOINVERT, IDS_AG_DVD_MENU_UP));
- ADDCMD((ID_NAVIGATE_MENU_DOWN, VK_DOWN, FVIRTKEY|FALT|FNOINVERT, IDS_AG_DVD_MENU_DOWN));
+ ADDCMD((ID_NAVIGATE_MENU_DOWN, VK_DOWN, FVIRTKEY|FALT|FNOINVERT, IDS_AG_DVD_MENU_DOWN));
ADDCMD((ID_NAVIGATE_MENU_ACTIVATE, VK_SPACE, FVIRTKEY|FALT|FNOINVERT, IDS_MPLAYERC_73));
ADDCMD((ID_NAVIGATE_MENU_BACK, 0, FVIRTKEY|FNOINVERT, IDS_AG_DVD_MENU_BACK));
ADDCMD((ID_NAVIGATE_MENU_LEAVE, 0, FVIRTKEY|FNOINVERT, IDS_MPLAYERC_75));
@@ -200,8 +200,8 @@ void CAppSettings::CreateCommands()
ADDCMD((ID_VIEW_RESETSTATS, 'R', FVIRTKEY|FCONTROL|FALT|FNOINVERT, IDS_AG_RESET_STATS));
ADDCMD((ID_VIEW_VSYNC, 'V', FVIRTKEY|FNOINVERT, IDS_AG_VSYNC));
ADDCMD((ID_VIEW_ENABLEFRAMETIMECORRECTION, 'C', FVIRTKEY|FNOINVERT, IDS_AG_ENABLEFRAMETIMECORRECTION));
- ADDCMD((ID_VIEW_VSYNCACCURATE, 'V', FVIRTKEY|FCONTROL|FALT|FNOINVERT, IDS_AG_VSYNCACCURATE));
- ADDCMD((ID_VIEW_VSYNCOFFSET_DECREASE, VK_UP, FVIRTKEY|FCONTROL|FALT|FNOINVERT, IDS_AG_VSYNCOFFSET_DECREASE));
+ ADDCMD((ID_VIEW_VSYNCACCURATE, 'V', FVIRTKEY|FCONTROL|FALT|FNOINVERT, IDS_AG_VSYNCACCURATE));
+ ADDCMD((ID_VIEW_VSYNCOFFSET_DECREASE, VK_UP, FVIRTKEY|FCONTROL|FALT|FNOINVERT, IDS_AG_VSYNCOFFSET_DECREASE));
ADDCMD((ID_VIEW_VSYNCOFFSET_INCREASE, VK_DOWN, FVIRTKEY|FCONTROL|FALT|FNOINVERT, IDS_AG_VSYNCOFFSET_INCREASE));
ADDCMD((ID_SUB_DELAY_DOWN, VK_F1, FVIRTKEY|FNOINVERT, IDS_MPLAYERC_104));
ADDCMD((ID_SUB_DELAY_UP, VK_F2, FVIRTKEY|FNOINVERT, IDS_MPLAYERC_105));
@@ -1138,12 +1138,12 @@ void CAppSettings::UpdateData(bool fSave)
CRegKey key;
// grrrrr
- // if(!SHGetSpecialFolderPath(NULL, MyPictures.GetBufferSetLength(MAX_PATH), CSIDL_MYPICTURES, TRUE)) MyPictures.Empty();
+ // if(!SHGetSpecialFolderPath(NULL, MyPictures.GetBufferSetLength(_MAX_PATH), CSIDL_MYPICTURES, TRUE)) MyPictures.Empty();
// else MyPictures.ReleaseBuffer();
if(ERROR_SUCCESS == key.Open(HKEY_CURRENT_USER, _T("Software\\Microsoft\\Windows\\CurrentVersion\\Explorer\\Shell Folders"), KEY_READ))
{
- ULONG len = MAX_PATH;
- if(ERROR_SUCCESS == key.QueryStringValue(_T("My Pictures"), MyPictures.GetBuffer(MAX_PATH), &len)) MyPictures.ReleaseBufferSetLength(len);
+ ULONG len = _MAX_PATH;
+ if(ERROR_SUCCESS == key.QueryStringValue(_T("My Pictures"), MyPictures.GetBuffer(_MAX_PATH), &len)) MyPictures.ReleaseBufferSetLength(len);
else MyPictures.Empty();
}
SnapShotPath = pApp->GetProfileString(IDS_R_SETTINGS, IDS_RS_SNAPSHOTPATH, MyPictures);
@@ -1662,7 +1662,7 @@ void CAppSettings::CRecentFileAndURLList::Add(LPCTSTR lpszPathName)
{
if((fURL && !_tcscmp(m_arrNames[iMRU], szTemp))
|| AfxComparePath(m_arrNames[iMRU], szTemp))
- break; // iMRU will point to matching entry
+ break; // iMRU will point to matching entry
}
// move MRU strings before this one down
for (; iMRU > 0; iMRU--)
diff --git a/src/apps/mplayerc/AppSettings.h b/src/apps/mplayerc/AppSettings.h
index b10d8107e..5742dfed4 100644
--- a/src/apps/mplayerc/AppSettings.h
+++ b/src/apps/mplayerc/AppSettings.h
@@ -23,7 +23,7 @@
#pragma once
-#include "resource.h" // main symbols
+#include "resource.h" // main symbols
#include <afxadv.h>
#include <atlsync.h>
#include "RenderersSettings.h"
@@ -348,8 +348,6 @@ public:
class CAppSettings
{
- friend class CMPlayerCApp;
-
bool fInitialized;
class CRecentFileAndURLList : public CRecentFileList
@@ -379,25 +377,25 @@ public:
{
return fixedWindowSize.cx > 0 || fixedWindowSize.cy > 0;
}
- // int iFixedWidth, iFixedHeight;
- int iMonitor;
+ //int iFixedWidth, iFixedHeight;
+ int iMonitor;
- CString sPnSPreset;
+ CString sPnSPreset;
- void ParseCommandLine(CAtlList<CString>& cmdln);
+ void ParseCommandLine(CAtlList<CString>& cmdln);
// Added a Debug display to the screen (/debug option)
- bool ShowDebugInfo;
+ bool ShowDebugInfo;
- int iDXVer;
- int iAdminOption;
+ int iDXVer;
+ int iAdminOption;
- int nCS;
- bool fHideCaptionMenu;
- bool fHideNavigation;
- int iDefaultVideoSize;
- bool fKeepAspectRatio;
- bool fCompMonDeskARDiff;
+ int nCS;
+ bool fHideCaptionMenu;
+ bool fHideNavigation;
+ int iDefaultVideoSize;
+ bool fKeepAspectRatio;
+ bool fCompMonDeskARDiff;
CRecentFileAndURLList MRU;
CRecentFileAndURLList MRUDub;
@@ -406,136 +404,136 @@ public:
CRenderersSettings m_RenderersSettings;
- int iDSVideoRendererType;
- int iRMVideoRendererType;
- int iQTVideoRendererType;
-
- int nVolume;
- int nBalance;
- bool fMute;
- int nLoops;
- bool fLoopForever;
- bool fRewind;
- int iZoomLevel;
- // int iVideoRendererType;
- CStringW AudioRendererDisplayName;
- bool fAutoloadAudio;
- bool fAutoloadSubtitles;
- bool fBlockVSFilter;
- bool fEnableWorkerThreadForOpening;
- bool fReportFailedPins;
-
- CStringW f_hmonitor;
- bool fAssociatedWithIcons;
- CStringW f_lastOpenDir;
-
- bool fAllowMultipleInst;
- int iTitleBarTextStyle;
- bool fTitleBarTextTitle;
- int iOnTop;
- bool fTrayIcon;
- bool fRememberZoomLevel;
- bool fShowBarsWhenFullScreen;
- int nShowBarsWhenFullScreenTimeOut;
- AChFR AutoChangeFullscrRes;
- bool fExitFullScreenAtTheEnd;
- bool fRestoreResAfterExit;
- bool fRememberWindowPos;
- bool fRememberWindowSize;
- bool fSnapToDesktopEdges;
- CRect rcLastWindowPos;
- UINT lastWindowType;
- CSize AspectRatio;
- bool fKeepHistory;
-
- CString sDVDPath;
- bool fUseDVDPath;
- LCID idMenuLang, idAudioLang, idSubtitlesLang;
- bool fAutoSpeakerConf;
-
- STSStyle subdefstyle;
- bool fOverridePlacement;
- int nHorPos, nVerPos;
- int nSubDelayInterval;
- bool fEnableSubtitles;
- bool fUseDefaultSubtitlesStyle;
- bool fPrioritizeExternalSubtitles;
- bool fDisableInternalSubtitles;
- CString szSubtitlePaths;
-
- bool fDisableXPToolbars;
- bool fUseWMASFReader;
- int nJumpDistS;
- int nJumpDistM;
- int nJumpDistL;
- bool fLimitWindowProportions;
- bool fNotifyMSN;
- bool fNotifyGTSdll;
-
- bool fEnableAudioSwitcher;
- bool fDownSampleTo441;
- bool fAudioTimeShift;
- int tAudioTimeShift;
- bool fCustomChannelMapping;
- DWORD pSpeakerToChannelMap[18][18];
- bool fAudioNormalize;
- bool fAudioNormalizeRecover;
- float AudioBoost;
-
- bool fIntRealMedia;
- //bool fRealMediaRenderless;
- int iQuickTimeRenderer;
- float RealMediaQuickTimeFPS;
-
- CStringArray m_pnspresets;
-
- CList<wmcmd> wmcmds;
- HACCEL hAccel;
-
- bool fWinLirc;
- CString WinLircAddr;
- CWinLircClient WinLircClient;
- bool fUIce;
- CString UIceAddr;
- CUIceClient UIceClient;
- bool fGlobalMedia;
-
- CMediaFormats Formats;
-
- UINT SrcFilters, TraFilters, DXVAFilters, FFmpegFilters;
-
- CString logofn;
- UINT logoid;
- bool logoext;
-
- bool fHideCDROMsSubMenu;
-
- DWORD priority;
- bool launchfullscreen;
-
- BOOL fEnableWebServer;
- int nWebServerPort;
- int nCmdlnWebServerPort;
- bool fWebServerPrintDebugInfo;
- bool fWebServerUseCompression;
- bool fWebServerLocalhostOnly;
- CString WebRoot, WebDefIndex;
- CString WebServerCGI;
-
- CString SnapShotPath, SnapShotExt;
- int ThumbRows, ThumbCols, ThumbWidth;
-
- CString ISDb;
+ int iDSVideoRendererType;
+ int iRMVideoRendererType;
+ int iQTVideoRendererType;
+
+ int nVolume;
+ int nBalance;
+ bool fMute;
+ int nLoops;
+ bool fLoopForever;
+ bool fRewind;
+ int iZoomLevel;
+ //int iVideoRendererType;
+ CStringW AudioRendererDisplayName;
+ bool fAutoloadAudio;
+ bool fAutoloadSubtitles;
+ bool fBlockVSFilter;
+ bool fEnableWorkerThreadForOpening;
+ bool fReportFailedPins;
+
+ CStringW f_hmonitor;
+ bool fAssociatedWithIcons;
+ CStringW f_lastOpenDir;
+
+ bool fAllowMultipleInst;
+ int iTitleBarTextStyle;
+ bool fTitleBarTextTitle;
+ int iOnTop;
+ bool fTrayIcon;
+ bool fRememberZoomLevel;
+ bool fShowBarsWhenFullScreen;
+ int nShowBarsWhenFullScreenTimeOut;
+ AChFR AutoChangeFullscrRes;
+ bool fExitFullScreenAtTheEnd;
+ bool fRestoreResAfterExit;
+ bool fRememberWindowPos;
+ bool fRememberWindowSize;
+ bool fSnapToDesktopEdges;
+ CRect rcLastWindowPos;
+ UINT lastWindowType;
+ CSize AspectRatio;
+ bool fKeepHistory;
+
+ CString sDVDPath;
+ bool fUseDVDPath;
+ LCID idMenuLang, idAudioLang, idSubtitlesLang;
+ bool fAutoSpeakerConf;
+
+ STSStyle subdefstyle;
+ bool fOverridePlacement;
+ int nHorPos, nVerPos;
+ int nSubDelayInterval;
+ bool fEnableSubtitles;
+ bool fUseDefaultSubtitlesStyle;
+ bool fPrioritizeExternalSubtitles;
+ bool fDisableInternalSubtitles;
+ CString szSubtitlePaths;
+
+ bool fDisableXPToolbars;
+ bool fUseWMASFReader;
+ int nJumpDistS;
+ int nJumpDistM;
+ int nJumpDistL;
+ bool fLimitWindowProportions;
+ bool fNotifyMSN;
+ bool fNotifyGTSdll;
+
+ bool fEnableAudioSwitcher;
+ bool fDownSampleTo441;
+ bool fAudioTimeShift;
+ int tAudioTimeShift;
+ bool fCustomChannelMapping;
+ DWORD pSpeakerToChannelMap[18][18];
+ bool fAudioNormalize;
+ bool fAudioNormalizeRecover;
+ float AudioBoost;
+
+ bool fIntRealMedia;
+ //bool fRealMediaRenderless;
+ int iQuickTimeRenderer;
+ float RealMediaQuickTimeFPS;
+
+ CStringArray m_pnspresets;
+
+ CList<wmcmd> wmcmds;
+ HACCEL hAccel;
+
+ bool fWinLirc;
+ CString WinLircAddr;
+ CWinLircClient WinLircClient;
+ bool fUIce;
+ CString UIceAddr;
+ CUIceClient UIceClient;
+ bool fGlobalMedia;
+
+ CMediaFormats Formats;
+
+ UINT SrcFilters, TraFilters, DXVAFilters, FFmpegFilters;
+
+ CString logofn;
+ UINT logoid;
+ bool logoext;
+
+ bool fHideCDROMsSubMenu;
+
+ DWORD priority;
+ bool launchfullscreen;
+
+ BOOL fEnableWebServer;
+ int nWebServerPort;
+ int nCmdlnWebServerPort;
+ bool fWebServerPrintDebugInfo;
+ bool fWebServerUseCompression;
+ bool fWebServerLocalhostOnly;
+ CString WebRoot, WebDefIndex;
+ CString WebServerCGI;
+
+ CString SnapShotPath, SnapShotExt;
+ int ThumbRows, ThumbCols, ThumbWidth;
+
+ CString ISDb;
struct Shader
{
- CString label;
- CString target;
- CString srcdata;
+ CString label;
+ CString target;
+ CString srcdata;
};
CAtlList<Shader> m_shaders;
- CString m_shadercombine;
- CString m_shadercombineScreenSpace;
+ CString m_shadercombine;
+ CString m_shadercombineScreenSpace;
// Casimir666 : new settings
bool fD3DFullscreen;
@@ -597,25 +595,24 @@ private :
public:
CAppSettings();
virtual ~CAppSettings();
- void UpdateData(bool fSave);
-
- void GetFav(favtype ft, CAtlList<CString>& sl);
- void SetFav(favtype ft, CAtlList<CString>& sl);
- void AddFav(favtype ft, CString s);
- CDVBChannel* FindChannelByPref(int nPrefNumber);
-
- bool m_fPreventMinimize;
- bool m_fUseWin7TaskBar;
- bool m_fExitAfterPlayback;
- bool m_fNextInDirAfterPlayback;
- bool m_fDontUseSearchInFolder;
- int nOSD_Size;
- CString m_OSD_Font;
- CStringW m_subtitlesLanguageOrder;
- CStringW m_audiosLanguageOrder;
-
- int fnChannels;
-
- CString D3D9RenderDevice;
+ void UpdateData(bool fSave);
+
+ void GetFav(favtype ft, CAtlList<CString>& sl);
+ void SetFav(favtype ft, CAtlList<CString>& sl);
+ void AddFav(favtype ft, CString s);
+ CDVBChannel* FindChannelByPref(int nPrefNumber);
+
+ bool m_fPreventMinimize;
+ bool m_fUseWin7TaskBar;
+ bool m_fExitAfterPlayback;
+ bool m_fNextInDirAfterPlayback;
+ bool m_fDontUseSearchInFolder;
+ int nOSD_Size;
+ CString m_OSD_Font;
+ CStringW m_subtitlesLanguageOrder;
+ CStringW m_audiosLanguageOrder;
+
+ int fnChannels;
+
+ CString D3D9RenderDevice;
};
-
diff --git a/src/apps/mplayerc/Changelog.txt b/src/apps/mplayerc/Changelog.txt
index 0dd240185..6979c6c4b 100644
--- a/src/apps/mplayerc/Changelog.txt
+++ b/src/apps/mplayerc/Changelog.txt
@@ -9,12 +9,19 @@ v1.5.xxxx.0 - unreleased
NEW : Added support for 'IMA4' audio
NEW : Added support for 'NONE' audio (old QuickTime PCM)
NEW : Added channel encryption detection for DVB-t during scan
+ NEW : Ticket #784, Enable ctrl+A in the MediaInfo window
CHANGED: Updated FFmpeg
CHANGED: Updated MediaInfoLib to v0.7.36 Beta
CHANGED: Updated ZenLib to v0.4.16 Beta
CHANGED: Updated Little CMS to v2.1(alpha1) - 09172010
+ CHANGED: Updated libpng to v1.4.4
CHANGED: Cleaned up and optimized code for QT PCM, small corrections in MP4Splitter
+ FIXED : Ticket #52, [playlist] shuffle is broken
FIXED : Ticket #564, EVR Sync enabled when it shouldn't be
+ FIXED : Ticket #627, Don't create the "AppData\Roaming\Media Player Classic"
+ folder if the "Remember items" in playlist is disabled
+ FIXED : Ticket #628, Enable ctrl+A in Player-->Keys page
+ FIXED : Ticket #647, Weird "keys" listed
FIXED : Ticket #651, Make EVR CP stats graph smaller
FIXED : Ticket #652, Escape key on certain form causes form to collapse
FIXED : Ticket #698, VMR-9 (Renderless) + pixel shaders crashes
@@ -23,6 +30,7 @@ v1.5.xxxx.0 - unreleased
not taken into account when doing a scan
FIXED : Ticket #753, DVB-T, internal MPEG-2 filter & wrong aspect ratio
FIXED : Ticket #782, VMR-7 & 9 filter names misspelled
+ FIXED : Ticket #791, Change the cursor behavior
v1.4.2499.0 - 7 September 2010
diff --git a/src/apps/mplayerc/ChildView.cpp b/src/apps/mplayerc/ChildView.cpp
index a9f90e468..8a93b9e20 100644
--- a/src/apps/mplayerc/ChildView.cpp
+++ b/src/apps/mplayerc/ChildView.cpp
@@ -66,32 +66,32 @@ BOOL CChildView::PreTranslateMessage(MSG* pMsg)
bool fDblClick = false;
bool fInteractiveVideo = ((CMainFrame*)AfxGetMainWnd())->IsInteractiveVideo();
- /*
- if(fInteractiveVideo)
+/*
+ if(fInteractiveVideo)
+ {
+ if(pMsg->message == WM_LBUTTONDOWN)
{
- if(pMsg->message == WM_LBUTTONDOWN)
+ if((pMsg->time - m_lastlmdowntime) <= GetDoubleClickTime()
+ && abs(pMsg->pt.x - m_lastlmdownpoint.x) <= GetSystemMetrics(SM_CXDOUBLECLK)
+ && abs(pMsg->pt.y - m_lastlmdownpoint.y) <= GetSystemMetrics(SM_CYDOUBLECLK))
{
- if((pMsg->time - m_lastlmdowntime) <= GetDoubleClickTime()
- && abs(pMsg->pt.x - m_lastlmdownpoint.x) <= GetSystemMetrics(SM_CXDOUBLECLK)
- && abs(pMsg->pt.y - m_lastlmdownpoint.y) <= GetSystemMetrics(SM_CYDOUBLECLK))
- {
- fDblClick = true;
- m_lastlmdowntime = 0;
- m_lastlmdownpoint.SetPoint(0, 0);
- }
- else
- {
- m_lastlmdowntime = pMsg->time;
- m_lastlmdownpoint = pMsg->pt;
- }
+ fDblClick = true;
+ m_lastlmdowntime = 0;
+ m_lastlmdownpoint.SetPoint(0, 0);
}
- else if(pMsg->message == WM_LBUTTONDBLCLK)
+ else
{
m_lastlmdowntime = pMsg->time;
m_lastlmdownpoint = pMsg->pt;
}
}
- */
+ else if(pMsg->message == WM_LBUTTONDBLCLK)
+ {
+ m_lastlmdowntime = pMsg->time;
+ m_lastlmdownpoint = pMsg->pt;
+ }
+ }
+*/
if((pMsg->message == WM_LBUTTONDOWN || pMsg->message == WM_LBUTTONUP || pMsg->message == WM_MOUSEMOVE)
&& fInteractiveVideo)
{
@@ -254,6 +254,11 @@ BOOL CChildView::OnSetCursor(CWnd* pWnd, UINT nHitTest, UINT message)
SetCursor(NULL);
return TRUE;
}
+ if(((CMainFrame*)GetParentFrame())->IsSomethingLoaded())
+ {
+ ::SetCursor(AfxGetApp()->LoadStandardCursor(IDC_HAND));
+ return TRUE;
+ }
return CWnd::OnSetCursor(pWnd, nHitTest, message);
}
diff --git a/src/apps/mplayerc/FGManagerBDA.cpp b/src/apps/mplayerc/FGManagerBDA.cpp
index 3c2424b1f..72157b1c7 100644
--- a/src/apps/mplayerc/FGManagerBDA.cpp
+++ b/src/apps/mplayerc/FGManagerBDA.cpp
@@ -864,32 +864,32 @@ HRESULT CFGManagerBDA::ChangeState(FILTER_STATE nRequested)
switch (nRequested)
{
case State_Stopped :
- {
- if (SUCCEEDED(hr = pMC->Stop()))
- ((CMainFrame*)AfxGetMainWnd())->KillTimersStop();
- LOG (_T("IMediaControl stop: %d."),hr);
- return hr;
- }
+ {
+ if (SUCCEEDED(hr = pMC->Stop()))
+ ((CMainFrame*)AfxGetMainWnd())->KillTimersStop();
+ LOG (_T("IMediaControl stop: %d."),hr);
+ return hr;
+ }
case State_Paused :
- {
- LOG (_T("IMediaControl pause."));
- return pMC->Pause();
- }
+ {
+ LOG (_T("IMediaControl pause."));
+ return pMC->Pause();
+ }
case State_Running :
+ {
+ int iCount = 0;
+ hr = S_FALSE;
+ while ((hr == S_FALSE) && (iCount++ < 10))
{
- int iCount = 0;
- hr = S_FALSE;
- while ((hr == S_FALSE) && (iCount++ < 10))
- {
- hr = pMC->Run();
- if (hr == S_FALSE)
- Sleep(50);
- }
- if (SUCCEEDED(hr))
- ((CMainFrame*)AfxGetMainWnd())->SetTimersPlay();
- LOG (_T("IMediaControl play: %d."),hr);
- return hr;
+ hr = pMC->Run();
+ if (hr == S_FALSE)
+ Sleep(50);
}
+ if (SUCCEEDED(hr))
+ ((CMainFrame*)AfxGetMainWnd())->SetTimersPlay();
+ LOG (_T("IMediaControl play: %d."),hr);
+ return hr;
+ }
}
}
return hr;
diff --git a/src/apps/mplayerc/MainFrm.cpp b/src/apps/mplayerc/MainFrm.cpp
index cf7dfdc26..a4fe9dd60 100644
--- a/src/apps/mplayerc/MainFrm.cpp
+++ b/src/apps/mplayerc/MainFrm.cpp
@@ -1561,7 +1561,7 @@ void CMainFrame::OnActivateApp(BOOL bActive, DWORD dwThreadID)
if(GetVersion()&0x80000000)
{
- module.ReleaseBufferSetLength(GetWindowModuleFileName(pWnd->m_hWnd, module.GetBuffer(MAX_PATH), MAX_PATH));
+ module.ReleaseBufferSetLength(GetWindowModuleFileName(pWnd->m_hWnd, module.GetBuffer(_MAX_PATH), _MAX_PATH));
}
else
{
@@ -1575,7 +1575,7 @@ void CMainFrame::OnActivateApp(BOOL bActive, DWORD dwThreadID)
if(EnumProcessModules(hProcess, &hMod, sizeof(hMod), &cbNeeded))
{
- module.ReleaseBufferSetLength(GetModuleFileNameEx(hProcess, hMod, module.GetBuffer(MAX_PATH), MAX_PATH));
+ module.ReleaseBufferSetLength(GetModuleFileNameEx(hProcess, hMod, module.GetBuffer(_MAX_PATH), _MAX_PATH));
}
CloseHandle(hProcess);
@@ -4264,7 +4264,7 @@ BOOL CMainFrame::OnCopyData(CWnd* pWnd, COPYDATASTRUCT* pCDS)
else
{
CString dir;
- dir.ReleaseBufferSetLength(GetCurrentDirectory(MAX_PATH, dir.GetBuffer(MAX_PATH)));
+ dir.ReleaseBufferSetLength(GetCurrentDirectory(_MAX_PATH, dir.GetBuffer(_MAX_PATH)));
GetCDROMType(dir[0], sl);
@@ -4525,7 +4525,7 @@ void CMainFrame::OnDropFiles(HDROP hDropInfo)
for(UINT iFile = 0; iFile < nFiles; iFile++)
{
CString fn;
- fn.ReleaseBuffer(::DragQueryFile(hDropInfo, iFile, fn.GetBuffer(MAX_PATH), MAX_PATH));
+ fn.ReleaseBuffer(::DragQueryFile(hDropInfo, iFile, fn.GetBuffer(_MAX_PATH), _MAX_PATH));
sl.AddTail(fn);
WIN32_FIND_DATA fd = {0};
@@ -8856,7 +8856,7 @@ void CMainFrame::OnFavoritesAdd()
{
WCHAR path[_MAX_PATH];
ULONG len = 0;
- pDVDI->GetDVDDirectory(path, MAX_PATH, &len);
+ pDVDI->GetDVDDirectory(path, _MAX_PATH, &len);
CString fn = path;
fn.TrimRight(_T("/\\"));
@@ -8967,7 +8967,7 @@ void CMainFrame::OnFavoritesQuickAddFavorite()
{
WCHAR path[_MAX_PATH];
ULONG len = 0;
- pDVDI->GetDVDDirectory(path, MAX_PATH, &len);
+ pDVDI->GetDVDDirectory(path, _MAX_PATH, &len);
CString fn = path;
fn.TrimRight(_T("/\\"));
@@ -9075,7 +9075,7 @@ void CMainFrame::OnFavoritesFile(UINT nID)
{
// Get the drive mpc-hc is on and apply it to the path list
CString exePath;
- DWORD dwLength = GetModuleFileName( AfxGetInstanceHandle(), exePath.GetBuffer(MAX_PATH), MAX_PATH );
+ DWORD dwLength = GetModuleFileName( AfxGetInstanceHandle(), exePath.GetBuffer(_MAX_PATH), _MAX_PATH );
exePath.ReleaseBuffer( dwLength );
CPath exeDrive( exePath );
diff --git a/src/apps/mplayerc/OpenCapDeviceDlg.cpp b/src/apps/mplayerc/OpenCapDeviceDlg.cpp
index 76123c63e..6d901e592 100644
--- a/src/apps/mplayerc/OpenCapDeviceDlg.cpp
+++ b/src/apps/mplayerc/OpenCapDeviceDlg.cpp
@@ -35,36 +35,36 @@ static struct cc_t
} s_countrycodes[] =
{
{1, AnalogVideo_NTSC_M, _T("USA")},
- /* {1, AnalogVideo_NTSC_M, _T("Anguilla")},
- {1, AnalogVideo_NTSC_M, _T("Antigua")},
- {1, AnalogVideo_NTSC_M, _T("Bahamas")},
- {1, AnalogVideo_NTSC_M, _T("Barbados")},
- {1, AnalogVideo_NTSC_M, _T("Bermuda")},
- {1, AnalogVideo_NTSC_M, _T("British Virgin Islands")},
- {1, AnalogVideo_NTSC_M, _T("Canada")},
- {1, AnalogVideo_NTSC_M, _T("Cayman Islands")},
- {1, AnalogVideo_NTSC_M, _T("Dominica")},
- {1, AnalogVideo_NTSC_M, _T("Dominican Republic")},
- {1, AnalogVideo_NTSC_M, _T("Grenada")},
- {1, AnalogVideo_NTSC_M, _T("Jamaica")},
- {1, AnalogVideo_NTSC_M, _T("Montserrat")},
- {1, AnalogVideo_NTSC_M, _T("Nevis")},
- {1, AnalogVideo_NTSC_M, _T("St. Kitts")},
- {1, AnalogVideo_NTSC_M, _T("St. Vincent and the Grenadines")},
- {1, AnalogVideo_NTSC_M, _T("Trinidad and Tobago")},
- {1, AnalogVideo_NTSC_M, _T("Turks and Caicos Islands")},
- {1, AnalogVideo_NTSC_M, _T("Barbuda")},
- {1, AnalogVideo_NTSC_M, _T("Puerto Rico")},
- {1, AnalogVideo_NTSC_M, _T("Saint Lucia")},
- {1, AnalogVideo_NTSC_M, _T("United States Virgin Islands")},
- */ {2, AnalogVideo_NTSC_M, _T("Canada")},
+/* {1, AnalogVideo_NTSC_M, _T("Anguilla")},
+ {1, AnalogVideo_NTSC_M, _T("Antigua")},
+ {1, AnalogVideo_NTSC_M, _T("Bahamas")},
+ {1, AnalogVideo_NTSC_M, _T("Barbados")},
+ {1, AnalogVideo_NTSC_M, _T("Bermuda")},
+ {1, AnalogVideo_NTSC_M, _T("British Virgin Islands")},
+ {1, AnalogVideo_NTSC_M, _T("Canada")},
+ {1, AnalogVideo_NTSC_M, _T("Cayman Islands")},
+ {1, AnalogVideo_NTSC_M, _T("Dominica")},
+ {1, AnalogVideo_NTSC_M, _T("Dominican Republic")},
+ {1, AnalogVideo_NTSC_M, _T("Grenada")},
+ {1, AnalogVideo_NTSC_M, _T("Jamaica")},
+ {1, AnalogVideo_NTSC_M, _T("Montserrat")},
+ {1, AnalogVideo_NTSC_M, _T("Nevis")},
+ {1, AnalogVideo_NTSC_M, _T("St. Kitts")},
+ {1, AnalogVideo_NTSC_M, _T("St. Vincent and the Grenadines")},
+ {1, AnalogVideo_NTSC_M, _T("Trinidad and Tobago")},
+ {1, AnalogVideo_NTSC_M, _T("Turks and Caicos Islands")},
+ {1, AnalogVideo_NTSC_M, _T("Barbuda")},
+ {1, AnalogVideo_NTSC_M, _T("Puerto Rico")},
+ {1, AnalogVideo_NTSC_M, _T("Saint Lucia")},
+ {1, AnalogVideo_NTSC_M, _T("United States Virgin Islands")},
+*/ {2, AnalogVideo_NTSC_M, _T("Canada")},
{7, AnalogVideo_SECAM_D, _T("Russia")},
- /* {7, AnalogVideo_SECAM_D, _T("Kazakhstan")},
- {7, AnalogVideo_SECAM_D, _T("Kyrgyzstan")},
- {7, AnalogVideo_SECAM_D, _T("Tajikistan")},
- {7, AnalogVideo_SECAM_D, _T("Turkmenistan")},
- {7, AnalogVideo_SECAM_D, _T("Uzbekistan")},
- */ {20, AnalogVideo_SECAM_B, _T("Egypt")},
+/* {7, AnalogVideo_SECAM_D, _T("Kazakhstan")},
+ {7, AnalogVideo_SECAM_D, _T("Kyrgyzstan")},
+ {7, AnalogVideo_SECAM_D, _T("Tajikistan")},
+ {7, AnalogVideo_SECAM_D, _T("Turkmenistan")},
+ {7, AnalogVideo_SECAM_D, _T("Uzbekistan")},
+*/ {20, AnalogVideo_SECAM_B, _T("Egypt")},
{27, AnalogVideo_PAL_I, _T("South Africa")},
{30, AnalogVideo_SECAM_B, _T("Greece")},
{31, AnalogVideo_PAL_B, _T("Netherlands")},
@@ -95,7 +95,7 @@ static struct cc_t
{58, AnalogVideo_NTSC_M, _T("Bolivarian Republic of Venezuela")},
{60, AnalogVideo_PAL_B, _T("Malaysia")},
{61, AnalogVideo_PAL_B, _T("Australia")},
- // {61, AnalogVideo_NTSC_M, _T("Cocos-Keeling Islands")},
+// {61, AnalogVideo_NTSC_M, _T("Cocos-Keeling Islands")},
{62, AnalogVideo_PAL_B, _T("Indonesia")},
{63, AnalogVideo_NTSC_M, _T("Philippines")},
{64, AnalogVideo_PAL_B, _T("New Zealand")},
@@ -225,7 +225,7 @@ static struct cc_t
{671, AnalogVideo_NTSC_M, _T("Guam")},
{672, AnalogVideo_NTSC_M, _T("Christmas Island")},
{672, AnalogVideo_NTSC_M, _T("Australian Antarctic Territory")},
- //{672, AnalogVideo_PAL_B, _T("Norfolk Island")},
+// {672, AnalogVideo_PAL_B, _T("Norfolk Island")},
{673, AnalogVideo_PAL_B, _T("Brunei")},
{674, AnalogVideo_NTSC_M, _T("Nauru")},
{675, AnalogVideo_PAL_B, _T("Papua New Guinea")},
diff --git a/src/apps/mplayerc/OpenFileDlg.cpp b/src/apps/mplayerc/OpenFileDlg.cpp
index e9f37ad3d..d0d39ef31 100644
--- a/src/apps/mplayerc/OpenFileDlg.cpp
+++ b/src/apps/mplayerc/OpenFileDlg.cpp
@@ -67,9 +67,9 @@ LRESULT CALLBACK COpenFileDlg::WindowProcNew(HWND hwnd, UINT message, WPARAM wPa
&& m_fAllowDirSelection)
{
CAutoVectorPtr<TCHAR> path;
- path.Allocate(MAX_PATH+1); // MAX_PATH should be bigger for multiple selection, but we are only interested if it's zero length
- // note: allocating MAX_PATH only will cause a buffer overrun for too long strings, and will result in a silent app disappearing crash, 100% reproducable
- if(::GetDlgItemText(hwnd, cmb13, (TCHAR*)path, MAX_PATH) == 0)
+ path.Allocate(_MAX_PATH+1); // _MAX_PATH should be bigger for multiple selection, but we are only interested if it's zero length
+ // note: allocating _MAX_PATH only will cause a buffer overrun for too long strings, and will result in a silent app disappearing crash, 100% reproducable
+ if(::GetDlgItemText(hwnd, cmb13, (TCHAR*)path, _MAX_PATH) == 0)
::SendMessage(hwnd, CDM_SETCONTROLTEXT, edt1, (LPARAM)__DUMMY__);
}
diff --git a/src/apps/mplayerc/PPageAccelTbl.cpp b/src/apps/mplayerc/PPageAccelTbl.cpp
index 351bf61c2..b93a64c02 100644
--- a/src/apps/mplayerc/PPageAccelTbl.cpp
+++ b/src/apps/mplayerc/PPageAccelTbl.cpp
@@ -199,493 +199,558 @@ CString CPPageAccelTbl::MakeAccelModLabel(BYTE fVirt)
CString CPPageAccelTbl::MakeAccelVkeyLabel(WORD key, bool fVirtKey)
{
+// Reference page for Virtual-Key Codes: http://msdn.microsoft.com/en-us/library/ms645540
CString str;
- if(fVirtKey)
- switch(key)
- {
- case VK_LBUTTON:
- str = _T("VK_LBUTTON");
- break;
- case VK_RBUTTON:
- str = _T("VK_RBUTTON");
- break;
- case VK_CANCEL:
- str = _T("VK_CANCEL");
- break;
- case VK_MBUTTON:
- str = _T("VK_MBUTTON");
- break;
- case VK_XBUTTON1:
- str = _T("VK_XBUTTON1");
- break;
- case VK_XBUTTON2:
- str = _T("VK_XBUTTON2");
- break;
- case VK_BACK:
- str = _T("VK_BACK");
- break;
- case VK_TAB:
- str = _T("VK_TAB");
- break;
- case VK_CLEAR:
- str = _T("VK_CLEAR");
- break;
- case VK_RETURN:
- str = _T("VK_RETURN");
- break;
- case VK_SHIFT:
- str = _T("VK_SHIFT");
- break;
- case VK_CONTROL:
- str = _T("VK_CONTROL");
- break;
- case VK_MENU:
- str = _T("VK_MENU");
- break;
- case VK_PAUSE:
- str = _T("VK_PAUSE");
- break;
- case VK_CAPITAL:
- str = _T("VK_CAPITAL");
- break;
+ switch(key)
+ {
+ case VK_LBUTTON:
+ str = _T("VK_LBUTTON");
+ break;
+ case VK_RBUTTON:
+ str = _T("VK_RBUTTON");
+ break;
+ case VK_CANCEL:
+ str = _T("VK_CANCEL");
+ break;
+ case VK_MBUTTON:
+ str = _T("VK_MBUTTON");
+ break;
+ case VK_XBUTTON1:
+ str = _T("VK_XBUTTON1");
+ break;
+ case VK_XBUTTON2:
+ str = _T("VK_XBUTTON2");
+ break;
+ case VK_BACK:
+ str = _T("VK_BACK");
+ break;
+ case VK_TAB:
+ str = _T("VK_TAB");
+ break;
+ case VK_CLEAR:
+ str = _T("VK_CLEAR");
+ break;
+ case VK_RETURN:
+ str = _T("VK_RETURN");
+ break;
+ case VK_SHIFT:
+ str = _T("VK_SHIFT");
+ break;
+ case VK_CONTROL:
+ str = _T("VK_CONTROL");
+ break;
+ case VK_MENU:
+ str = _T("VK_MENU");
+ break;
+ case VK_PAUSE:
+ str = _T("VK_PAUSE");
+ break;
+ case VK_CAPITAL:
+ str = _T("VK_CAPITAL");
+ break;
// case VK_KANA: str = _T("VK_KANA"); break;
// case VK_HANGEUL: str = _T("VK_HANGEUL"); break;
- case VK_HANGUL:
- str = _T("VK_HANGUL");
- break;
- case VK_JUNJA:
- str = _T("VK_JUNJA");
- break;
- case VK_FINAL:
- str = _T("VK_FINAL");
- break;
+ case VK_HANGUL:
+ str = _T("VK_HANGUL");
+ break;
+ case VK_JUNJA:
+ str = _T("VK_JUNJA");
+ break;
+ case VK_FINAL:
+ str = _T("VK_FINAL");
+ break;
// case VK_HANJA: str = _T("VK_HANJA"); break;
- case VK_KANJI:
- str = _T("VK_KANJI");
- break;
- case VK_ESCAPE:
- str = _T("VK_ESCAPE");
- break;
- case VK_CONVERT:
- str = _T("VK_CONVERT");
- break;
- case VK_NONCONVERT:
- str = _T("VK_NONCONVERT");
- break;
- case VK_ACCEPT:
- str = _T("VK_ACCEPT");
- break;
- case VK_MODECHANGE:
- str = _T("VK_MODECHANGE");
- break;
- case VK_SPACE:
- str = _T("VK_SPACE");
- break;
- case VK_PRIOR:
- str = _T("VK_PRIOR");
- break;
- case VK_NEXT:
- str = _T("VK_NEXT");
- break;
- case VK_END:
- str = _T("VK_END");
- break;
- case VK_HOME:
- str = _T("VK_HOME");
- break;
- case VK_LEFT:
- str = _T("VK_LEFT");
- break;
- case VK_UP:
- str = _T("VK_UP");
- break;
- case VK_RIGHT:
- str = _T("VK_RIGHT");
- break;
- case VK_DOWN:
- str = _T("VK_DOWN");
- break;
- case VK_SELECT:
- str = _T("VK_SELECT");
- break;
- case VK_PRINT:
- str = _T("VK_PRINT");
- break;
- case VK_EXECUTE:
- str = _T("VK_EXECUTE");
- break;
- case VK_SNAPSHOT:
- str = _T("VK_SNAPSHOT");
- break;
- case VK_INSERT:
- str = _T("VK_INSERT");
- break;
- case VK_DELETE:
- str = _T("VK_DELETE");
- break;
- case VK_HELP:
- str = _T("VK_HELP");
- break;
- case VK_LWIN:
- str = _T("VK_LWIN");
- break;
- case VK_RWIN:
- str = _T("VK_RWIN");
- break;
- case VK_APPS:
- str = _T("VK_APPS");
- break;
- case VK_SLEEP:
- str = _T("VK_SLEEP");
- break;
- case VK_NUMPAD0:
- str = _T("VK_NUMPAD0");
- break;
- case VK_NUMPAD1:
- str = _T("VK_NUMPAD1");
- break;
- case VK_NUMPAD2:
- str = _T("VK_NUMPAD2");
- break;
- case VK_NUMPAD3:
- str = _T("VK_NUMPAD3");
- break;
- case VK_NUMPAD4:
- str = _T("VK_NUMPAD4");
- break;
- case VK_NUMPAD5:
- str = _T("VK_NUMPAD5");
- break;
- case VK_NUMPAD6:
- str = _T("VK_NUMPAD6");
- break;
- case VK_NUMPAD7:
- str = _T("VK_NUMPAD7");
- break;
- case VK_NUMPAD8:
- str = _T("VK_NUMPAD8");
- break;
- case VK_NUMPAD9:
- str = _T("VK_NUMPAD9");
- break;
- case VK_MULTIPLY:
- str = _T("VK_MULTIPLY");
- break;
- case VK_ADD:
- str = _T("VK_ADD");
- break;
- case VK_SEPARATOR:
- str = _T("VK_SEPARATOR");
- break;
- case VK_SUBTRACT:
- str = _T("VK_SUBTRACT");
- break;
- case VK_DECIMAL:
- str = _T("VK_DECIMAL");
- break;
- case VK_DIVIDE:
- str = _T("VK_DIVIDE");
- break;
- case VK_F1:
- str = _T("VK_F1");
- break;
- case VK_F2:
- str = _T("VK_F2");
- break;
- case VK_F3:
- str = _T("VK_F3");
- break;
- case VK_F4:
- str = _T("VK_F4");
- break;
- case VK_F5:
- str = _T("VK_F5");
- break;
- case VK_F6:
- str = _T("VK_F6");
- break;
- case VK_F7:
- str = _T("VK_F7");
- break;
- case VK_F8:
- str = _T("VK_F8");
- break;
- case VK_F9:
- str = _T("VK_F9");
- break;
- case VK_F10:
- str = _T("VK_F10");
- break;
- case VK_F11:
- str = _T("VK_F11");
- break;
- case VK_F12:
- str = _T("VK_F12");
- break;
- case VK_F13:
- str = _T("VK_F13");
- break;
- case VK_F14:
- str = _T("VK_F14");
- break;
- case VK_F15:
- str = _T("VK_F15");
- break;
- case VK_F16:
- str = _T("VK_F16");
- break;
- case VK_F17:
- str = _T("VK_F17");
- break;
- case VK_F18:
- str = _T("VK_F18");
- break;
- case VK_F19:
- str = _T("VK_F19");
- break;
- case VK_F20:
- str = _T("VK_F20");
- break;
- case VK_F21:
- str = _T("VK_F21");
- break;
- case VK_F22:
- str = _T("VK_F22");
- break;
- case VK_F23:
- str = _T("VK_F23");
- break;
- case VK_F24:
- str = _T("VK_F24");
- break;
- case VK_NUMLOCK:
- str = _T("VK_NUMLOCK");
- break;
- case VK_SCROLL:
- str = _T("VK_SCROLL");
- break;
+ case VK_KANJI:
+ str = _T("VK_KANJI");
+ break;
+ case VK_ESCAPE:
+ str = _T("VK_ESCAPE");
+ break;
+ case VK_CONVERT:
+ str = _T("VK_CONVERT");
+ break;
+ case VK_NONCONVERT:
+ str = _T("VK_NONCONVERT");
+ break;
+ case VK_ACCEPT:
+ str = _T("VK_ACCEPT");
+ break;
+ case VK_MODECHANGE:
+ str = _T("VK_MODECHANGE");
+ break;
+ case VK_SPACE:
+ str = _T("VK_SPACE");
+ break;
+ case VK_PRIOR:
+ str = _T("VK_PRIOR");
+ break;
+ case VK_NEXT:
+ str = _T("VK_NEXT");
+ break;
+ case VK_END:
+ str = _T("VK_END");
+ break;
+ case VK_HOME:
+ str = _T("VK_HOME");
+ break;
+ case VK_LEFT:
+ str = _T("VK_LEFT");
+ break;
+ case VK_UP:
+ str = _T("VK_UP");
+ break;
+ case VK_RIGHT:
+ str = _T("VK_RIGHT");
+ break;
+ case VK_DOWN:
+ str = _T("VK_DOWN");
+ break;
+ case VK_SELECT:
+ str = _T("VK_SELECT");
+ break;
+ case VK_PRINT:
+ str = _T("VK_PRINT");
+ break;
+ case VK_EXECUTE:
+ str = _T("VK_EXECUTE");
+ break;
+ case VK_SNAPSHOT:
+ str = _T("VK_SNAPSHOT");
+ break;
+ case VK_INSERT:
+ str = _T("VK_INSERT");
+ break;
+ case VK_DELETE:
+ str = _T("VK_DELETE");
+ break;
+ case VK_HELP:
+ str = _T("VK_HELP");
+ break;
+ case VK_LWIN:
+ str = _T("VK_LWIN");
+ break;
+ case VK_RWIN:
+ str = _T("VK_RWIN");
+ break;
+ case VK_APPS:
+ str = _T("VK_APPS");
+ break;
+ case VK_SLEEP:
+ str = _T("VK_SLEEP");
+ break;
+ case VK_NUMPAD0:
+ str = _T("VK_NUMPAD0");
+ break;
+ case VK_NUMPAD1:
+ str = _T("VK_NUMPAD1");
+ break;
+ case VK_NUMPAD2:
+ str = _T("VK_NUMPAD2");
+ break;
+ case VK_NUMPAD3:
+ str = _T("VK_NUMPAD3");
+ break;
+ case VK_NUMPAD4:
+ str = _T("VK_NUMPAD4");
+ break;
+ case VK_NUMPAD5:
+ str = _T("VK_NUMPAD5");
+ break;
+ case VK_NUMPAD6:
+ str = _T("VK_NUMPAD6");
+ break;
+ case VK_NUMPAD7:
+ str = _T("VK_NUMPAD7");
+ break;
+ case VK_NUMPAD8:
+ str = _T("VK_NUMPAD8");
+ break;
+ case VK_NUMPAD9:
+ str = _T("VK_NUMPAD9");
+ break;
+ case VK_MULTIPLY:
+ str = _T("VK_MULTIPLY");
+ break;
+ case VK_ADD:
+ str = _T("VK_ADD");
+ break;
+ case VK_SEPARATOR:
+ str = _T("VK_SEPARATOR");
+ break;
+ case VK_SUBTRACT:
+ str = _T("VK_SUBTRACT");
+ break;
+ case VK_DECIMAL:
+ str = _T("VK_DECIMAL");
+ break;
+ case VK_DIVIDE:
+ str = _T("VK_DIVIDE");
+ break;
+ case VK_F1:
+ str = _T("VK_F1");
+ break;
+ case VK_F2:
+ str = _T("VK_F2");
+ break;
+ case VK_F3:
+ str = _T("VK_F3");
+ break;
+ case VK_F4:
+ str = _T("VK_F4");
+ break;
+ case VK_F5:
+ str = _T("VK_F5");
+ break;
+ case VK_F6:
+ str = _T("VK_F6");
+ break;
+ case VK_F7:
+ str = _T("VK_F7");
+ break;
+ case VK_F8:
+ str = _T("VK_F8");
+ break;
+ case VK_F9:
+ str = _T("VK_F9");
+ break;
+ case VK_F10:
+ str = _T("VK_F10");
+ break;
+ case VK_F11:
+ str = _T("VK_F11");
+ break;
+ case VK_F12:
+ str = _T("VK_F12");
+ break;
+ case VK_F13:
+ str = _T("VK_F13");
+ break;
+ case VK_F14:
+ str = _T("VK_F14");
+ break;
+ case VK_F15:
+ str = _T("VK_F15");
+ break;
+ case VK_F16:
+ str = _T("VK_F16");
+ break;
+ case VK_F17:
+ str = _T("VK_F17");
+ break;
+ case VK_F18:
+ str = _T("VK_F18");
+ break;
+ case VK_F19:
+ str = _T("VK_F19");
+ break;
+ case VK_F20:
+ str = _T("VK_F20");
+ break;
+ case VK_F21:
+ str = _T("VK_F21");
+ break;
+ case VK_F22:
+ str = _T("VK_F22");
+ break;
+ case VK_F23:
+ str = _T("VK_F23");
+ break;
+ case VK_F24:
+ str = _T("VK_F24");
+ break;
+ case VK_NUMLOCK:
+ str = _T("VK_NUMLOCK");
+ break;
+ case VK_SCROLL:
+ str = _T("VK_SCROLL");
+ break;
// case VK_OEM_NEC_EQUAL: str = _T("VK_OEM_NEC_EQUAL"); break;
- case VK_OEM_FJ_JISHO:
- str = _T("VK_OEM_FJ_JISHO");
- break;
- case VK_OEM_FJ_MASSHOU:
- str = _T("VK_OEM_FJ_MASSHOU");
- break;
- case VK_OEM_FJ_TOUROKU:
- str = _T("VK_OEM_FJ_TOUROKU");
- break;
- case VK_OEM_FJ_LOYA:
- str = _T("VK_OEM_FJ_LOYA");
- break;
- case VK_OEM_FJ_ROYA:
- str = _T("VK_OEM_FJ_ROYA");
- break;
- case VK_LSHIFT:
- str = _T("VK_LSHIFT");
- break;
- case VK_RSHIFT:
- str = _T("VK_RSHIFT");
- break;
- case VK_LCONTROL:
- str = _T("VK_LCONTROL");
- break;
- case VK_RCONTROL:
- str = _T("VK_RCONTROL");
- break;
- case VK_LMENU:
- str = _T("VK_LMENU");
- break;
- case VK_RMENU:
- str = _T("VK_RMENU");
- break;
- case VK_BROWSER_BACK:
- str = _T("VK_BROWSER_BACK");
- break;
- case VK_BROWSER_FORWARD:
- str = _T("VK_BROWSER_FORWARD");
- break;
- case VK_BROWSER_REFRESH:
- str = _T("VK_BROWSER_REFRESH");
- break;
- case VK_BROWSER_STOP:
- str = _T("VK_BROWSER_STOP");
- break;
- case VK_BROWSER_SEARCH:
- str = _T("VK_BROWSER_SEARCH");
- break;
- case VK_BROWSER_FAVORITES:
- str = _T("VK_BROWSER_FAVORITES");
- break;
- case VK_BROWSER_HOME:
- str = _T("VK_BROWSER_HOME");
- break;
- case VK_VOLUME_MUTE:
- str = _T("VK_VOLUME_MUTE");
- break;
- case VK_VOLUME_DOWN:
- str = _T("VK_VOLUME_DOWN");
- break;
- case VK_VOLUME_UP:
- str = _T("VK_VOLUME_UP");
- break;
- case VK_MEDIA_NEXT_TRACK:
- str = _T("VK_MEDIA_NEXT_TRACK");
- break;
- case VK_MEDIA_PREV_TRACK:
- str = _T("VK_MEDIA_PREV_TRACK");
- break;
- case VK_MEDIA_STOP:
- str = _T("VK_MEDIA_STOP");
- break;
- case VK_MEDIA_PLAY_PAUSE:
- str = _T("VK_MEDIA_PLAY_PAUSE");
- break;
- case VK_LAUNCH_MAIL:
- str = _T("VK_LAUNCH_MAIL");
- break;
- case VK_LAUNCH_MEDIA_SELECT:
- str = _T("VK_LAUNCH_MEDIA_SELECT");
- break;
- case VK_LAUNCH_APP1:
- str = _T("VK_LAUNCH_APP1");
- break;
- case VK_LAUNCH_APP2:
- str = _T("VK_LAUNCH_APP2");
- break;
- case VK_OEM_1:
- str = _T("VK_OEM_1");
- break;
- case VK_OEM_PLUS:
- str = _T("VK_OEM_PLUS");
- break;
- case VK_OEM_COMMA:
- str = _T("VK_OEM_COMMA");
- break;
- case VK_OEM_MINUS:
- str = _T("VK_OEM_MINUS");
- break;
- case VK_OEM_PERIOD:
- str = _T("VK_OEM_PERIOD");
- break;
- case VK_OEM_2:
- str = _T("VK_OEM_2");
- break;
- case VK_OEM_3:
- str = _T("VK_OEM_3");
- break;
- case VK_OEM_4:
- str = _T("VK_OEM_4");
- break;
- case VK_OEM_5:
- str = _T("VK_OEM_5");
- break;
- case VK_OEM_6:
- str = _T("VK_OEM_6");
- break;
- case VK_OEM_7:
- str = _T("VK_OEM_7");
- break;
- case VK_OEM_8:
- str = _T("VK_OEM_8");
- break;
- case VK_OEM_AX:
- str = _T("VK_OEM_AX");
- break;
- case VK_OEM_102:
- str = _T("VK_OEM_102");
- break;
- case VK_ICO_HELP:
- str = _T("VK_ICO_HELP");
- break;
- case VK_ICO_00:
- str = _T("VK_ICO_00");
- break;
- case VK_PROCESSKEY:
- str = _T("VK_PROCESSKEY");
- break;
- case VK_ICO_CLEAR:
- str = _T("VK_ICO_CLEAR");
- break;
- case VK_PACKET:
- str = _T("VK_PACKET");
- break;
- case VK_OEM_RESET:
- str = _T("VK_OEM_RESET");
- break;
- case VK_OEM_JUMP:
- str = _T("VK_OEM_JUMP");
- break;
- case VK_OEM_PA1:
- str = _T("VK_OEM_PA1");
- break;
- case VK_OEM_PA2:
- str = _T("VK_OEM_PA2");
- break;
- case VK_OEM_PA3:
- str = _T("VK_OEM_PA3");
- break;
- case VK_OEM_WSCTRL:
- str = _T("VK_OEM_WSCTRL");
- break;
- case VK_OEM_CUSEL:
- str = _T("VK_OEM_CUSEL");
- break;
- case VK_OEM_ATTN:
- str = _T("VK_OEM_ATTN");
- break;
- case VK_OEM_FINISH:
- str = _T("VK_OEM_FINISH");
- break;
- case VK_OEM_COPY:
- str = _T("VK_OEM_COPY");
- break;
- case VK_OEM_AUTO:
- str = _T("VK_OEM_AUTO");
- break;
- case VK_OEM_ENLW:
- str = _T("VK_OEM_ENLW");
- break;
- case VK_OEM_BACKTAB:
- str = _T("VK_OEM_BACKTAB");
- break;
- case VK_ATTN:
- str = _T("VK_ATTN");
- break;
- case VK_CRSEL:
- str = _T("VK_CRSEL");
- break;
- case VK_EXSEL:
- str = _T("VK_EXSEL");
- break;
- case VK_EREOF:
- str = _T("VK_EREOF");
- break;
- case VK_PLAY:
- str = _T("VK_PLAY");
- break;
- case VK_ZOOM:
- str = _T("VK_ZOOM");
- break;
- case VK_NONAME:
- str = _T("VK_NONAME");
- break;
- case VK_PA1:
- str = _T("VK_PA1");
- break;
- case VK_OEM_CLEAR:
- str = _T("VK_OEM_CLEAR");
- break;
- default:
- if('0' <= key && key <= '9' || 'A' <= key && key <= 'Z')
- str.Format(_T("%c"), (TCHAR)key);
- break;
- }
-
- if(str.IsEmpty() || !fVirtKey)
- {
- str.Format(_T("%c, 0x%02x"), (TCHAR)key, key);
- return(str);
+ case VK_OEM_FJ_JISHO:
+ str = _T("VK_OEM_FJ_JISHO");
+ break;
+ case VK_OEM_FJ_MASSHOU:
+ str = _T("VK_OEM_FJ_MASSHOU");
+ break;
+ case VK_OEM_FJ_TOUROKU:
+ str = _T("VK_OEM_FJ_TOUROKU");
+ break;
+ case VK_OEM_FJ_LOYA:
+ str = _T("VK_OEM_FJ_LOYA");
+ break;
+ case VK_OEM_FJ_ROYA:
+ str = _T("VK_OEM_FJ_ROYA");
+ break;
+ case VK_LSHIFT:
+ str = _T("VK_LSHIFT");
+ break;
+ case VK_RSHIFT:
+ str = _T("VK_RSHIFT");
+ break;
+ case VK_LCONTROL:
+ str = _T("VK_LCONTROL");
+ break;
+ case VK_RCONTROL:
+ str = _T("VK_RCONTROL");
+ break;
+ case VK_LMENU:
+ str = _T("VK_LMENU");
+ break;
+ case VK_RMENU:
+ str = _T("VK_RMENU");
+ break;
+ case VK_BROWSER_BACK:
+ str = _T("VK_BROWSER_BACK");
+ break;
+ case VK_BROWSER_FORWARD:
+ str = _T("VK_BROWSER_FORWARD");
+ break;
+ case VK_BROWSER_REFRESH:
+ str = _T("VK_BROWSER_REFRESH");
+ break;
+ case VK_BROWSER_STOP:
+ str = _T("VK_BROWSER_STOP");
+ break;
+ case VK_BROWSER_SEARCH:
+ str = _T("VK_BROWSER_SEARCH");
+ break;
+ case VK_BROWSER_FAVORITES:
+ str = _T("VK_BROWSER_FAVORITES");
+ break;
+ case VK_BROWSER_HOME:
+ str = _T("VK_BROWSER_HOME");
+ break;
+ case VK_VOLUME_MUTE:
+ str = _T("VK_VOLUME_MUTE");
+ break;
+ case VK_VOLUME_DOWN:
+ str = _T("VK_VOLUME_DOWN");
+ break;
+ case VK_VOLUME_UP:
+ str = _T("VK_VOLUME_UP");
+ break;
+ case VK_MEDIA_NEXT_TRACK:
+ str = _T("VK_MEDIA_NEXT_TRACK");
+ break;
+ case VK_MEDIA_PREV_TRACK:
+ str = _T("VK_MEDIA_PREV_TRACK");
+ break;
+ case VK_MEDIA_STOP:
+ str = _T("VK_MEDIA_STOP");
+ break;
+ case VK_MEDIA_PLAY_PAUSE:
+ str = _T("VK_MEDIA_PLAY_PAUSE");
+ break;
+ case VK_LAUNCH_MAIL:
+ str = _T("VK_LAUNCH_MAIL");
+ break;
+ case VK_LAUNCH_MEDIA_SELECT:
+ str = _T("VK_LAUNCH_MEDIA_SELECT");
+ break;
+ case VK_LAUNCH_APP1:
+ str = _T("VK_LAUNCH_APP1");
+ break;
+ case VK_LAUNCH_APP2:
+ str = _T("VK_LAUNCH_APP2");
+ break;
+ case VK_OEM_1:
+ str = _T("VK_OEM_1");
+ break;
+ case VK_OEM_PLUS:
+ str = _T("VK_OEM_PLUS");
+ break;
+ case VK_OEM_COMMA:
+ str = _T("VK_OEM_COMMA");
+ break;
+ case VK_OEM_MINUS:
+ str = _T("VK_OEM_MINUS");
+ break;
+ case VK_OEM_PERIOD:
+ str = _T("VK_OEM_PERIOD");
+ break;
+ case VK_OEM_2:
+ str = _T("VK_OEM_2");
+ break;
+ case VK_OEM_3:
+ str = _T("VK_OEM_3");
+ break;
+ case VK_OEM_4:
+ str = _T("VK_OEM_4");
+ break;
+ case VK_OEM_5:
+ str = _T("VK_OEM_5");
+ break;
+ case VK_OEM_6:
+ str = _T("VK_OEM_6");
+ break;
+ case VK_OEM_7:
+ str = _T("VK_OEM_7");
+ break;
+ case VK_OEM_8:
+ str = _T("VK_OEM_8");
+ break;
+ case VK_OEM_AX:
+ str = _T("VK_OEM_AX");
+ break;
+ case VK_OEM_102:
+ str = _T("VK_OEM_102");
+ break;
+ case VK_ICO_HELP:
+ str = _T("VK_ICO_HELP");
+ break;
+ case VK_ICO_00:
+ str = _T("VK_ICO_00");
+ break;
+ case VK_PROCESSKEY:
+ str = _T("VK_PROCESSKEY");
+ break;
+ case VK_ICO_CLEAR:
+ str = _T("VK_ICO_CLEAR");
+ break;
+ case VK_PACKET:
+ str = _T("VK_PACKET");
+ break;
+ case VK_OEM_RESET:
+ str = _T("VK_OEM_RESET");
+ break;
+ case VK_OEM_JUMP:
+ str = _T("VK_OEM_JUMP");
+ break;
+ case VK_OEM_PA1:
+ str = _T("VK_OEM_PA1");
+ break;
+ case VK_OEM_PA2:
+ str = _T("VK_OEM_PA2");
+ break;
+ case VK_OEM_PA3:
+ str = _T("VK_OEM_PA3");
+ break;
+ case VK_OEM_WSCTRL:
+ str = _T("VK_OEM_WSCTRL");
+ break;
+ case VK_OEM_CUSEL:
+ str = _T("VK_OEM_CUSEL");
+ break;
+ case VK_OEM_ATTN:
+ str = _T("VK_OEM_ATTN");
+ break;
+ case VK_OEM_FINISH:
+ str = _T("VK_OEM_FINISH");
+ break;
+ case VK_OEM_COPY:
+ str = _T("VK_OEM_COPY");
+ break;
+ case VK_OEM_AUTO:
+ str = _T("VK_OEM_AUTO");
+ break;
+ case VK_OEM_ENLW:
+ str = _T("VK_OEM_ENLW");
+ break;
+ case VK_OEM_BACKTAB:
+ str = _T("VK_OEM_BACKTAB");
+ break;
+ case VK_ATTN:
+ str = _T("VK_ATTN");
+ break;
+ case VK_CRSEL:
+ str = _T("VK_CRSEL");
+ break;
+ case VK_EXSEL:
+ str = _T("VK_EXSEL");
+ break;
+ case VK_EREOF:
+ str = _T("VK_EREOF");
+ break;
+ case VK_PLAY:
+ str = _T("VK_PLAY");
+ break;
+ case VK_ZOOM:
+ str = _T("VK_ZOOM");
+ break;
+ case VK_NONAME:
+ str = _T("VK_NONAME");
+ break;
+ case VK_PA1:
+ str = _T("VK_PA1");
+ break;
+ case VK_OEM_CLEAR:
+ str = _T("VK_OEM_CLEAR");
+ break;
+ case 0x07:
+ case 0x0E:
+ case 0x0F:
+ case 0x16:
+ case 0x1A:
+ case 0x3A:
+ case 0x3B:
+ case 0x3C:
+ case 0x3D:
+ case 0x3E:
+ case 0x3F:
+ case 0x40:
+ str.Format(_T("Undefined (0x%02x)"), (TCHAR)key);
+ break;
+ case 0x0A:
+ case 0x0B:
+ case 0x5E:
+ case 0xB8:
+ case 0xB9:
+ case 0xC1:
+ case 0xC2:
+ case 0xC3:
+ case 0xC4:
+ case 0xC5:
+ case 0xC6:
+ case 0xC7:
+ case 0xC8:
+ case 0xC9:
+ case 0xCA:
+ case 0xCB:
+ case 0xCC:
+ case 0xCD:
+ case 0xCE:
+ case 0xCF:
+ case 0xD0:
+ case 0xD1:
+ case 0xD2:
+ case 0xD3:
+ case 0xD4:
+ case 0xD5:
+ case 0xD6:
+ case 0xD7:
+ case 0xE0:
+ str.Format(_T("Reserved (0x%02x)"), (TCHAR)key);
+ break;
+ case 0x88:
+ case 0x89:
+ case 0x8A:
+ case 0x8B:
+ case 0x8C:
+ case 0x8D:
+ case 0x8E:
+ case 0x8F:
+ case 0x97:
+ case 0x98:
+ case 0x99:
+ case 0x9A:
+ case 0x9B:
+ case 0x9C:
+ case 0x9D:
+ case 0x9E:
+ case 0x9F:
+ case 0xD8:
+ case 0xD9:
+ case 0xDA:
+ case 0xE8:
+ str.Format(_T("Unassigned (0x%02x)"), (TCHAR)key);
+ break;
+ case 0xFF:
+ str = _T("Multimedia keys");
+ break;
+ default:
+// if('0' <= key && key <= '9' || 'A' <= key && key <= 'Z')
+ str.Format(_T("%c"), (TCHAR)key);
+ break;
}
return(str);
@@ -707,491 +772,559 @@ CString CPPageAccelTbl::MakeAccelShortcutLabel(UINT id)
CString CPPageAccelTbl::MakeAccelShortcutLabel(ACCEL& a)
{
+// Reference page for Virtual-Key Codes: http://msdn.microsoft.com/en-us/library/ms645540
CString str;
- if(a.fVirt&1)
- switch(a.key)
- {
- case VK_LBUTTON:
- str = _T("LBtn");
- break;
- case VK_RBUTTON:
- str = _T("RBtn");
- break;
- case VK_CANCEL:
- str = _T("Cancel");
- break;
- case VK_MBUTTON:
- str = _T("MBtn");
- break;
- case VK_XBUTTON1:
- str = _T("X1Btn");
- break;
- case VK_XBUTTON2:
- str = _T("X2Btn");
- break;
- case VK_BACK:
- str = _T("Back");
- break;
- case VK_TAB:
- str = _T("Tab");
- break;
- case VK_CLEAR:
- str = _T("Clear");
- break;
- case VK_RETURN:
- str = _T("Return");
- break;
- case VK_SHIFT:
- str = _T("Shift");
- break;
- case VK_CONTROL:
- str = _T("Ctrl");
- break;
- case VK_MENU:
- str = _T("Alt");
- break;
- case VK_PAUSE:
- str = _T("Pause");
- break;
- case VK_CAPITAL:
- str = _T("Capital");
- break;
+ switch(a.key)
+ {
+ case VK_LBUTTON:
+ str = _T("LBtn");
+ break;
+ case VK_RBUTTON:
+ str = _T("RBtn");
+ break;
+ case VK_CANCEL:
+ str = _T("Cancel");
+ break;
+ case VK_MBUTTON:
+ str = _T("MBtn");
+ break;
+ case VK_XBUTTON1:
+ str = _T("X1Btn");
+ break;
+ case VK_XBUTTON2:
+ str = _T("X2Btn");
+ break;
+ case VK_BACK:
+ str = _T("Back");
+ break;
+ case VK_TAB:
+ str = _T("Tab");
+ break;
+ case VK_CLEAR:
+ str = _T("Clear");
+ break;
+ case VK_RETURN:
+ str = _T("Return");
+ break;
+ case VK_SHIFT:
+ str = _T("Shift");
+ break;
+ case VK_CONTROL:
+ str = _T("Ctrl");
+ break;
+ case VK_MENU:
+ str = _T("Alt");
+ break;
+ case VK_PAUSE:
+ str = _T("Pause");
+ break;
+ case VK_CAPITAL:
+ str = _T("Capital");
+ break;
// case VK_KANA: str = _T("Kana"); break;
// case VK_HANGEUL: str = _T("Hangeul"); break;
- case VK_HANGUL:
- str = _T("Hangul");
- break;
- case VK_JUNJA:
- str = _T("Junja");
- break;
- case VK_FINAL:
- str = _T("Final");
- break;
+ case VK_HANGUL:
+ str = _T("Hangul");
+ break;
+ case VK_JUNJA:
+ str = _T("Junja");
+ break;
+ case VK_FINAL:
+ str = _T("Final");
+ break;
// case VK_HANJA: str = _T("Hanja"); break;
- case VK_KANJI:
- str = _T("Kanji");
- break;
- case VK_ESCAPE:
- str = _T("Escape");
- break;
- case VK_CONVERT:
- str = _T("Convert");
- break;
- case VK_NONCONVERT:
- str = _T("Non Convert");
- break;
- case VK_ACCEPT:
- str = _T("Accept");
- break;
- case VK_MODECHANGE:
- str = _T("Mode Change");
- break;
- case VK_SPACE:
- str = _T("Space");
- break;
- case VK_PRIOR:
- str = _T("PgUp");
- break;
- case VK_NEXT:
- str = _T("PgDn");
- break;
- case VK_END:
- str = _T("End");
- break;
- case VK_HOME:
- str = _T("Home");
- break;
- case VK_LEFT:
- str = _T("Left");
- break;
- case VK_UP:
- str = _T("Up");
- break;
- case VK_RIGHT:
- str = _T("Right");
- break;
- case VK_DOWN:
- str = _T("Down");
- break;
- case VK_SELECT:
- str = _T("Select");
- break;
- case VK_PRINT:
- str = _T("Print");
- break;
- case VK_EXECUTE:
- str = _T("Execute");
- break;
- case VK_SNAPSHOT:
- str = _T("Snapshot");
- break;
- case VK_INSERT:
- str = _T("Insert");
- break;
- case VK_DELETE:
- str = _T("Delete");
- break;
- case VK_HELP:
- str = _T("Help");
- break;
- case VK_LWIN:
- str = _T("LWin");
- break;
- case VK_RWIN:
- str = _T("RWin");
- break;
- case VK_APPS:
- str = _T("Apps");
- break;
- case VK_SLEEP:
- str = _T("Sleep");
- break;
- case VK_NUMPAD0:
- str = _T("Numpad 0");
- break;
- case VK_NUMPAD1:
- str = _T("Numpad 1");
- break;
- case VK_NUMPAD2:
- str = _T("Numpad 2");
- break;
- case VK_NUMPAD3:
- str = _T("Numpad 3");
- break;
- case VK_NUMPAD4:
- str = _T("Numpad 4");
- break;
- case VK_NUMPAD5:
- str = _T("Numpad 5");
- break;
- case VK_NUMPAD6:
- str = _T("Numpad 6");
- break;
- case VK_NUMPAD7:
- str = _T("Numpad 7");
- break;
- case VK_NUMPAD8:
- str = _T("Numpad 8");
- break;
- case VK_NUMPAD9:
- str = _T("Numpad 9");
- break;
- case VK_MULTIPLY:
- str = _T("Multiply");
- break;
- case VK_ADD:
- str = _T("Add");
- break;
- case VK_SEPARATOR:
- str = _T("Separator");
- break;
- case VK_SUBTRACT:
- str = _T("Subtract");
- break;
- case VK_DECIMAL:
- str = _T("Decimal");
- break;
- case VK_DIVIDE:
- str = _T("Divide");
- break;
- case VK_F1:
- str = _T("F1");
- break;
- case VK_F2:
- str = _T("F2");
- break;
- case VK_F3:
- str = _T("F3");
- break;
- case VK_F4:
- str = _T("F4");
- break;
- case VK_F5:
- str = _T("F5");
- break;
- case VK_F6:
- str = _T("F6");
- break;
- case VK_F7:
- str = _T("F7");
- break;
- case VK_F8:
- str = _T("F8");
- break;
- case VK_F9:
- str = _T("F9");
- break;
- case VK_F10:
- str = _T("F10");
- break;
- case VK_F11:
- str = _T("F11");
- break;
- case VK_F12:
- str = _T("F12");
- break;
- case VK_F13:
- str = _T("F13");
- break;
- case VK_F14:
- str = _T("F14");
- break;
- case VK_F15:
- str = _T("F15");
- break;
- case VK_F16:
- str = _T("F16");
- break;
- case VK_F17:
- str = _T("F17");
- break;
- case VK_F18:
- str = _T("F18");
- break;
- case VK_F19:
- str = _T("F19");
- break;
- case VK_F20:
- str = _T("F20");
- break;
- case VK_F21:
- str = _T("F21");
- break;
- case VK_F22:
- str = _T("F22");
- break;
- case VK_F23:
- str = _T("F23");
- break;
- case VK_F24:
- str = _T("F24");
- break;
- case VK_NUMLOCK:
- str = _T("Numlock");
- break;
- case VK_SCROLL:
- str = _T("Scroll");
- break;
+ case VK_KANJI:
+ str = _T("Kanji");
+ break;
+ case VK_ESCAPE:
+ str = _T("Escape");
+ break;
+ case VK_CONVERT:
+ str = _T("Convert");
+ break;
+ case VK_NONCONVERT:
+ str = _T("Non Convert");
+ break;
+ case VK_ACCEPT:
+ str = _T("Accept");
+ break;
+ case VK_MODECHANGE:
+ str = _T("Mode Change");
+ break;
+ case VK_SPACE:
+ str = _T("Space");
+ break;
+ case VK_PRIOR:
+ str = _T("PgUp");
+ break;
+ case VK_NEXT:
+ str = _T("PgDn");
+ break;
+ case VK_END:
+ str = _T("End");
+ break;
+ case VK_HOME:
+ str = _T("Home");
+ break;
+ case VK_LEFT:
+ str = _T("Left");
+ break;
+ case VK_UP:
+ str = _T("Up");
+ break;
+ case VK_RIGHT:
+ str = _T("Right");
+ break;
+ case VK_DOWN:
+ str = _T("Down");
+ break;
+ case VK_SELECT:
+ str = _T("Select");
+ break;
+ case VK_PRINT:
+ str = _T("Print");
+ break;
+ case VK_EXECUTE:
+ str = _T("Execute");
+ break;
+ case VK_SNAPSHOT:
+ str = _T("Snapshot");
+ break;
+ case VK_INSERT:
+ str = _T("Insert");
+ break;
+ case VK_DELETE:
+ str = _T("Delete");
+ break;
+ case VK_HELP:
+ str = _T("Help");
+ break;
+ case VK_LWIN:
+ str = _T("LWin");
+ break;
+ case VK_RWIN:
+ str = _T("RWin");
+ break;
+ case VK_APPS:
+ str = _T("Apps");
+ break;
+ case VK_SLEEP:
+ str = _T("Sleep");
+ break;
+ case VK_NUMPAD0:
+ str = _T("Numpad 0");
+ break;
+ case VK_NUMPAD1:
+ str = _T("Numpad 1");
+ break;
+ case VK_NUMPAD2:
+ str = _T("Numpad 2");
+ break;
+ case VK_NUMPAD3:
+ str = _T("Numpad 3");
+ break;
+ case VK_NUMPAD4:
+ str = _T("Numpad 4");
+ break;
+ case VK_NUMPAD5:
+ str = _T("Numpad 5");
+ break;
+ case VK_NUMPAD6:
+ str = _T("Numpad 6");
+ break;
+ case VK_NUMPAD7:
+ str = _T("Numpad 7");
+ break;
+ case VK_NUMPAD8:
+ str = _T("Numpad 8");
+ break;
+ case VK_NUMPAD9:
+ str = _T("Numpad 9");
+ break;
+ case VK_MULTIPLY:
+ str = _T("Multiply");
+ break;
+ case VK_ADD:
+ str = _T("Add");
+ break;
+ case VK_SEPARATOR:
+ str = _T("Separator");
+ break;
+ case VK_SUBTRACT:
+ str = _T("Subtract");
+ break;
+ case VK_DECIMAL:
+ str = _T("Decimal");
+ break;
+ case VK_DIVIDE:
+ str = _T("Divide");
+ break;
+ case VK_F1:
+ str = _T("F1");
+ break;
+ case VK_F2:
+ str = _T("F2");
+ break;
+ case VK_F3:
+ str = _T("F3");
+ break;
+ case VK_F4:
+ str = _T("F4");
+ break;
+ case VK_F5:
+ str = _T("F5");
+ break;
+ case VK_F6:
+ str = _T("F6");
+ break;
+ case VK_F7:
+ str = _T("F7");
+ break;
+ case VK_F8:
+ str = _T("F8");
+ break;
+ case VK_F9:
+ str = _T("F9");
+ break;
+ case VK_F10:
+ str = _T("F10");
+ break;
+ case VK_F11:
+ str = _T("F11");
+ break;
+ case VK_F12:
+ str = _T("F12");
+ break;
+ case VK_F13:
+ str = _T("F13");
+ break;
+ case VK_F14:
+ str = _T("F14");
+ break;
+ case VK_F15:
+ str = _T("F15");
+ break;
+ case VK_F16:
+ str = _T("F16");
+ break;
+ case VK_F17:
+ str = _T("F17");
+ break;
+ case VK_F18:
+ str = _T("F18");
+ break;
+ case VK_F19:
+ str = _T("F19");
+ break;
+ case VK_F20:
+ str = _T("F20");
+ break;
+ case VK_F21:
+ str = _T("F21");
+ break;
+ case VK_F22:
+ str = _T("F22");
+ break;
+ case VK_F23:
+ str = _T("F23");
+ break;
+ case VK_F24:
+ str = _T("F24");
+ break;
+ case VK_NUMLOCK:
+ str = _T("Numlock");
+ break;
+ case VK_SCROLL:
+ str = _T("Scroll");
+ break;
// case VK_OEM_NEC_EQUAL: str = _T("OEM NEC Equal"); break;
- case VK_OEM_FJ_JISHO:
- str = _T("OEM FJ Jisho");
- break;
- case VK_OEM_FJ_MASSHOU:
- str = _T("OEM FJ Msshou");
- break;
- case VK_OEM_FJ_TOUROKU:
- str = _T("OEM FJ Touroku");
- break;
- case VK_OEM_FJ_LOYA:
- str = _T("OEM FJ Loya");
- break;
- case VK_OEM_FJ_ROYA:
- str = _T("OEM FJ Roya");
- break;
- case VK_LSHIFT:
- str = _T("LShift");
- break;
- case VK_RSHIFT:
- str = _T("RShift");
- break;
- case VK_LCONTROL:
- str = _T("LCtrl");
- break;
- case VK_RCONTROL:
- str = _T("RCtrl");
- break;
- case VK_LMENU:
- str = _T("LAlt");
- break;
- case VK_RMENU:
- str = _T("RAlt");
- break;
- case VK_BROWSER_BACK:
- str = _T("Browser Back");
- break;
- case VK_BROWSER_FORWARD:
- str = _T("Browser Forward");
- break;
- case VK_BROWSER_REFRESH:
- str = _T("Browser Refresh");
- break;
- case VK_BROWSER_STOP:
- str = _T("Browser Stop");
- break;
- case VK_BROWSER_SEARCH:
- str = _T("Browser Search");
- break;
- case VK_BROWSER_FAVORITES:
- str = _T("Browser Favorites");
- break;
- case VK_BROWSER_HOME:
- str = _T("Browser Home");
- break;
- case VK_VOLUME_MUTE:
- str = _T("Volume Mute");
- break;
- case VK_VOLUME_DOWN:
- str = _T("Volume Down");
- break;
- case VK_VOLUME_UP:
- str = _T("Volume Up");
- break;
- case VK_MEDIA_NEXT_TRACK:
- str = _T("Media Next Track");
- break;
- case VK_MEDIA_PREV_TRACK:
- str = _T("Media Prev Track");
- break;
- case VK_MEDIA_STOP:
- str = _T("Media Stop");
- break;
- case VK_MEDIA_PLAY_PAUSE:
- str = _T("Media Play/Pause");
- break;
- case VK_LAUNCH_MAIL:
- str = _T("Launch Mail");
- break;
- case VK_LAUNCH_MEDIA_SELECT:
- str = _T("Launch Media Select");
- break;
- case VK_LAUNCH_APP1:
- str = _T("Launch App1");
- break;
- case VK_LAUNCH_APP2:
- str = _T("Launch App2");
- break;
- case VK_OEM_1:
- str = _T("OEM 1");
- break;
- case VK_OEM_PLUS:
- str = _T("Plus");
- break;
- case VK_OEM_COMMA:
- str = _T("Comma");
- break;
- case VK_OEM_MINUS:
- str = _T("Minus");
- break;
- case VK_OEM_PERIOD:
- str = _T("Period");
- break;
- case VK_OEM_2:
- str = _T("OEM 2");
- break;
- case VK_OEM_3:
- str = _T("OEM 3");
- break;
- case VK_OEM_4:
- str = _T("OEM 4");
- break;
- case VK_OEM_5:
- str = _T("OEM 5");
- break;
- case VK_OEM_6:
- str = _T("OEM 6");
- break;
- case VK_OEM_7:
- str = _T("OEM 7");
- break;
- case VK_OEM_8:
- str = _T("OEM 8");
- break;
- case VK_OEM_AX:
- str = _T("OEM AX");
- break;
- case VK_OEM_102:
- str = _T("OEM 102");
- break;
- case VK_ICO_HELP:
- str = _T("ICO Help");
- break;
- case VK_ICO_00:
- str = _T("ICO 00");
- break;
- case VK_PROCESSKEY:
- str = _T("Process Key");
- break;
- case VK_ICO_CLEAR:
- str = _T("ICO Clear");
- break;
- case VK_PACKET:
- str = _T("Packet");
- break;
- case VK_OEM_RESET:
- str = _T("OEM Reset");
- break;
- case VK_OEM_JUMP:
- str = _T("OEM Jump");
- break;
- case VK_OEM_PA1:
- str = _T("OEM PA1");
- break;
- case VK_OEM_PA2:
- str = _T("OEM PA2");
- break;
- case VK_OEM_PA3:
- str = _T("OEM PA3");
- break;
- case VK_OEM_WSCTRL:
- str = _T("OEM WSCtrl");
- break;
- case VK_OEM_CUSEL:
- str = _T("OEM CUSEL");
- break;
- case VK_OEM_ATTN:
- str = _T("OEM ATTN");
- break;
- case VK_OEM_FINISH:
- str = _T("OEM Finish");
- break;
- case VK_OEM_COPY:
- str = _T("OEM Copy");
- break;
- case VK_OEM_AUTO:
- str = _T("OEM Auto");
- break;
- case VK_OEM_ENLW:
- str = _T("OEM ENLW");
- break;
- case VK_OEM_BACKTAB:
- str = _T("OEM Backtab");
- break;
- case VK_ATTN:
- str = _T("ATTN");
- break;
- case VK_CRSEL:
- str = _T("CRSEL");
- break;
- case VK_EXSEL:
- str = _T("EXSEL");
- break;
- case VK_EREOF:
- str = _T("EREOF");
- break;
- case VK_PLAY:
- str = _T("Play");
- break;
- case VK_ZOOM:
- str = _T("Zoom");
- break;
- case VK_NONAME:
- str = _T("Noname");
- break;
- case VK_PA1:
- str = _T("PA1");
- break;
- case VK_OEM_CLEAR:
- str = _T("OEM Clear");
- break;
- default:
- if('0' <= a.key && a.key <= '9' || 'A' <= a.key && a.key <= 'Z')
- str.Format(_T("%c"), (TCHAR)a.key);
- break;
- }
-
- if(str.IsEmpty() || !(a.fVirt&1))
+ case VK_OEM_FJ_JISHO:
+ str = _T("OEM FJ Jisho");
+ break;
+ case VK_OEM_FJ_MASSHOU:
+ str = _T("OEM FJ Msshou");
+ break;
+ case VK_OEM_FJ_TOUROKU:
+ str = _T("OEM FJ Touroku");
+ break;
+ case VK_OEM_FJ_LOYA:
+ str = _T("OEM FJ Loya");
+ break;
+ case VK_OEM_FJ_ROYA:
+ str = _T("OEM FJ Roya");
+ break;
+ case VK_LSHIFT:
+ str = _T("LShift");
+ break;
+ case VK_RSHIFT:
+ str = _T("RShift");
+ break;
+ case VK_LCONTROL:
+ str = _T("LCtrl");
+ break;
+ case VK_RCONTROL:
+ str = _T("RCtrl");
+ break;
+ case VK_LMENU:
+ str = _T("LAlt");
+ break;
+ case VK_RMENU:
+ str = _T("RAlt");
+ break;
+ case VK_BROWSER_BACK:
+ str = _T("Browser Back");
+ break;
+ case VK_BROWSER_FORWARD:
+ str = _T("Browser Forward");
+ break;
+ case VK_BROWSER_REFRESH:
+ str = _T("Browser Refresh");
+ break;
+ case VK_BROWSER_STOP:
+ str = _T("Browser Stop");
+ break;
+ case VK_BROWSER_SEARCH:
+ str = _T("Browser Search");
+ break;
+ case VK_BROWSER_FAVORITES:
+ str = _T("Browser Favorites");
+ break;
+ case VK_BROWSER_HOME:
+ str = _T("Browser Home");
+ break;
+ case VK_VOLUME_MUTE:
+ str = _T("Volume Mute");
+ break;
+ case VK_VOLUME_DOWN:
+ str = _T("Volume Down");
+ break;
+ case VK_VOLUME_UP:
+ str = _T("Volume Up");
+ break;
+ case VK_MEDIA_NEXT_TRACK:
+ str = _T("Media Next Track");
+ break;
+ case VK_MEDIA_PREV_TRACK:
+ str = _T("Media Prev Track");
+ break;
+ case VK_MEDIA_STOP:
+ str = _T("Media Stop");
+ break;
+ case VK_MEDIA_PLAY_PAUSE:
+ str = _T("Media Play/Pause");
+ break;
+ case VK_LAUNCH_MAIL:
+ str = _T("Launch Mail");
+ break;
+ case VK_LAUNCH_MEDIA_SELECT:
+ str = _T("Launch Media Select");
+ break;
+ case VK_LAUNCH_APP1:
+ str = _T("Launch App1");
+ break;
+ case VK_LAUNCH_APP2:
+ str = _T("Launch App2");
+ break;
+ case VK_OEM_1:
+ str = _T("OEM 1");
+ break;
+ case VK_OEM_PLUS:
+ str = _T("Plus");
+ break;
+ case VK_OEM_COMMA:
+ str = _T("Comma");
+ break;
+ case VK_OEM_MINUS:
+ str = _T("Minus");
+ break;
+ case VK_OEM_PERIOD:
+ str = _T("Period");
+ break;
+ case VK_OEM_2:
+ str = _T("OEM 2");
+ break;
+ case VK_OEM_3:
+ str = _T("OEM 3");
+ break;
+ case VK_OEM_4:
+ str = _T("OEM 4");
+ break;
+ case VK_OEM_5:
+ str = _T("OEM 5");
+ break;
+ case VK_OEM_6:
+ str = _T("OEM 6");
+ break;
+ case VK_OEM_7:
+ str = _T("OEM 7");
+ break;
+ case VK_OEM_8:
+ str = _T("OEM 8");
+ break;
+ case VK_OEM_AX:
+ str = _T("OEM AX");
+ break;
+ case VK_OEM_102:
+ str = _T("OEM 102");
+ break;
+ case VK_ICO_HELP:
+ str = _T("ICO Help");
+ break;
+ case VK_ICO_00:
+ str = _T("ICO 00");
+ break;
+ case VK_PROCESSKEY:
+ str = _T("Process Key");
+ break;
+ case VK_ICO_CLEAR:
+ str = _T("ICO Clear");
+ break;
+ case VK_PACKET:
+ str = _T("Packet");
+ break;
+ case VK_OEM_RESET:
+ str = _T("OEM Reset");
+ break;
+ case VK_OEM_JUMP:
+ str = _T("OEM Jump");
+ break;
+ case VK_OEM_PA1:
+ str = _T("OEM PA1");
+ break;
+ case VK_OEM_PA2:
+ str = _T("OEM PA2");
+ break;
+ case VK_OEM_PA3:
+ str = _T("OEM PA3");
+ break;
+ case VK_OEM_WSCTRL:
+ str = _T("OEM WSCtrl");
+ break;
+ case VK_OEM_CUSEL:
+ str = _T("OEM CUSEL");
+ break;
+ case VK_OEM_ATTN:
+ str = _T("OEM ATTN");
+ break;
+ case VK_OEM_FINISH:
+ str = _T("OEM Finish");
+ break;
+ case VK_OEM_COPY:
+ str = _T("OEM Copy");
+ break;
+ case VK_OEM_AUTO:
+ str = _T("OEM Auto");
+ break;
+ case VK_OEM_ENLW:
+ str = _T("OEM ENLW");
+ break;
+ case VK_OEM_BACKTAB:
+ str = _T("OEM Backtab");
+ break;
+ case VK_ATTN:
+ str = _T("ATTN");
+ break;
+ case VK_CRSEL:
+ str = _T("CRSEL");
+ break;
+ case VK_EXSEL:
+ str = _T("EXSEL");
+ break;
+ case VK_EREOF:
+ str = _T("EREOF");
+ break;
+ case VK_PLAY:
+ str = _T("Play");
+ break;
+ case VK_ZOOM:
+ str = _T("Zoom");
+ break;
+ case VK_NONAME:
+ str = _T("Noname");
+ break;
+ case VK_PA1:
+ str = _T("PA1");
+ break;
+ case VK_OEM_CLEAR:
+ str = _T("OEM Clear");
+ break;
+ case 0x07:
+ case 0x0E:
+ case 0x0F:
+ case 0x16:
+ case 0x1A:
+ case 0x3A:
+ case 0x3B:
+ case 0x3C:
+ case 0x3D:
+ case 0x3E:
+ case 0x3F:
+ case 0x40:
+ str.Format(_T("Undefined (0x%02x)"), (TCHAR)a.key);
+ break;
+ case 0x0A:
+ case 0x0B:
+ case 0x5E:
+ case 0xB8:
+ case 0xB9:
+ case 0xC1:
+ case 0xC2:
+ case 0xC3:
+ case 0xC4:
+ case 0xC5:
+ case 0xC6:
+ case 0xC7:
+ case 0xC8:
+ case 0xC9:
+ case 0xCA:
+ case 0xCB:
+ case 0xCC:
+ case 0xCD:
+ case 0xCE:
+ case 0xCF:
+ case 0xD0:
+ case 0xD1:
+ case 0xD2:
+ case 0xD3:
+ case 0xD4:
+ case 0xD5:
+ case 0xD6:
+ case 0xD7:
+ case 0xE0:
+ str.Format(_T("Reserved (0x%02x)"), (TCHAR)a.key);
+ break;
+ case 0x88:
+ case 0x89:
+ case 0x8A:
+ case 0x8B:
+ case 0x8C:
+ case 0x8D:
+ case 0x8E:
+ case 0x8F:
+ case 0x97:
+ case 0x98:
+ case 0x99:
+ case 0x9A:
+ case 0x9B:
+ case 0x9C:
+ case 0x9D:
+ case 0x9E:
+ case 0x9F:
+ case 0xD8:
+ case 0xD9:
+ case 0xDA:
+ case 0xE8:
+ str.Format(_T("Unassigned (0x%02x)"), (TCHAR)a.key);
+ break;
+ case 0xFF:
+ str = _T("Multimedia keys");
+ break;
+ default:
+// if('0' <= a.key && a.key <= '9' || 'A' <= a.key && a.key <= 'Z')
str.Format(_T("%c"), (TCHAR)a.key);
+ break;
+ }
if(a.fVirt&(FCONTROL|FALT|FSHIFT))
str = MakeAccelModLabel(a.fVirt) + _T(" + ") + str;
@@ -1300,6 +1433,23 @@ END_MESSAGE_MAP()
// CPPageAccelTbl message handlers
+static WNDPROC OldControlProc;
+static LRESULT CALLBACK ControlProc(HWND control, UINT message, WPARAM wParam, LPARAM lParam)
+{
+ if(message == WM_KEYDOWN) {
+ if ((LOWORD(wParam)== 'A' || LOWORD(wParam) == 'a') &&(GetKeyState(VK_CONTROL) < 0)) {
+ CPlayerListCtrl *pList = (CPlayerListCtrl*)CWnd::FromHandle(control);
+
+ for(int i = 0, j = pList->GetItemCount(); i < j; i++)
+ pList->SetItemState(i, LVIS_SELECTED, LVIS_SELECTED);
+
+ return 0;
+ }
+ }
+
+ return CallWindowProc(OldControlProc, control, message, wParam, lParam); // call control's own windowproc
+}
+
BOOL CPPageAccelTbl::OnInitDialog()
{
__super::OnInitDialog();
@@ -1354,6 +1504,9 @@ BOOL CPPageAccelTbl::OnInitDialog()
m_list.SetColumnWidth(COL_TYPE, LVSCW_AUTOSIZE);
m_list.SetColumnWidth(COL_ID, LVSCW_AUTOSIZE_USEHEADER);
+ // subclass the keylist control
+ OldControlProc = (WNDPROC) SetWindowLongPtr(m_list.m_hWnd, GWLP_WNDPROC, (LONG_PTR) ControlProc);
+
return TRUE; // return TRUE unless you set the focus to a control
// EXCEPTION: OCX Property Pages should return FALSE
}
diff --git a/src/apps/mplayerc/PPageFileMediaInfo.cpp b/src/apps/mplayerc/PPageFileMediaInfo.cpp
index be3b6321d..085a047fe 100644
--- a/src/apps/mplayerc/PPageFileMediaInfo.cpp
+++ b/src/apps/mplayerc/PPageFileMediaInfo.cpp
@@ -65,6 +65,20 @@ BEGIN_MESSAGE_MAP(CPPageFileMediaInfo, CPropertyPage)
END_MESSAGE_MAP()
// CPPageFileMediaInfo message handlers
+static WNDPROC OldControlProc;
+static LRESULT CALLBACK ControlProc(HWND control, UINT message, WPARAM wParam, LPARAM lParam)
+{
+ if(message == WM_KEYDOWN) {
+ if ((LOWORD(wParam)== 'A' || LOWORD(wParam) == 'a')
+ &&(GetKeyState(VK_CONTROL) < 0)) {
+ CEdit *pEdit = (CEdit*)CWnd::FromHandle(control);
+ pEdit->SetSel(0, pEdit->GetWindowTextLength(), TRUE);
+ return 0;
+ }
+ }
+
+ return CallWindowProc(OldControlProc, control, message, wParam, lParam); // call edit control's own windowproc
+}
BOOL CPPageFileMediaInfo::OnInitDialog()
{
@@ -116,6 +130,9 @@ BOOL CPPageFileMediaInfo::OnInitDialog()
m_mediainfo.SetFont( m_pCFont );
m_mediainfo.SetWindowText(MI_Text);
+ // subclass the edit control
+ OldControlProc = (WNDPROC) SetWindowLongPtr(m_mediainfo.m_hWnd, GWLP_WNDPROC, (LONG_PTR) ControlProc);
+
return TRUE; // return TRUE unless you set the focus to a control
// EXCEPTION: OCX Property Pages should return FALSE
}
@@ -136,3 +153,4 @@ bool CPPageFileMediaInfo::HasMediaInfo()
return MI.IsReady();
}
#endif
+
diff --git a/src/apps/mplayerc/PPageFormats.cpp b/src/apps/mplayerc/PPageFormats.cpp
index de9929ec6..15ca29065 100644
--- a/src/apps/mplayerc/PPageFormats.cpp
+++ b/src/apps/mplayerc/PPageFormats.cpp
@@ -110,7 +110,7 @@ CString CPPageFormats::GetEnqueueCommand()
CString path;
TCHAR buff[_MAX_PATH];
- if(::GetModuleFileName(AfxGetInstanceHandle(), buff, MAX_PATH) == 0)
+ if(::GetModuleFileName(AfxGetInstanceHandle(), buff, _MAX_PATH) == 0)
return _T("");
path = buff;
@@ -122,7 +122,7 @@ CString CPPageFormats::GetOpenCommand()
CString path;
TCHAR buff[_MAX_PATH];
- if(::GetModuleFileName(AfxGetInstanceHandle(), buff, MAX_PATH) == 0)
+ if(::GetModuleFileName(AfxGetInstanceHandle(), buff, _MAX_PATH) == 0)
return _T("");
path = buff;
@@ -155,8 +155,8 @@ bool CPPageFormats::IsRegistered(CString ext)
// The 2000/XP way
CRegKey key;
TCHAR buff[256];
- ULONG len = sizeof(buff);
- memset(buff, 0, len);
+ ULONG len = sizeof(buff)/sizeof(buff[0]);
+ memset(buff, 0, sizeof(buff));
if(ERROR_SUCCESS != key.Open(HKEY_CLASSES_ROOT, ext))
return false;
@@ -170,7 +170,7 @@ bool CPPageFormats::IsRegistered(CString ext)
{
CRegKey key;
TCHAR buff[_MAX_PATH];
- ULONG len = sizeof(buff);
+ ULONG len = sizeof(buff)/sizeof(buff[0]);
if(ERROR_SUCCESS == key.Open(HKEY_CLASSES_ROOT, strProgID + _T("\\shell\\open"), KEY_READ))
{
@@ -185,7 +185,7 @@ bool CPPageFormats::IsRegistered(CString ext)
{
CRegKey key;
TCHAR buff[_MAX_PATH];
- ULONG len = sizeof(buff);
+ ULONG len = sizeof(buff)/sizeof(buff[0]);
bIsDefault = FALSE;
if(ERROR_SUCCESS == key.Open(HKEY_CLASSES_ROOT, strProgID + _T("\\shell\\open\\command"), KEY_READ))
@@ -204,7 +204,7 @@ CString GetProgramDir()
{
CString RtnVal;
TCHAR FileName[_MAX_PATH];
- ::GetModuleFileName(AfxGetInstanceHandle(), FileName, MAX_PATH);
+ ::GetModuleFileName(AfxGetInstanceHandle(), FileName, _MAX_PATH);
RtnVal = FileName;
RtnVal = RtnVal.Left(RtnVal.ReverseFind('\\'));
return RtnVal;
@@ -314,7 +314,7 @@ bool CPPageFormats::RegisterExt(CString ext, CString strLabel, bool fRegister)
}
/* no icon was found for the file extension, so use MPC's icon */
- if((AppIcon.IsEmpty()) && (::GetModuleFileName(AfxGetInstanceHandle(), buff, MAX_PATH)))
+ if((AppIcon.IsEmpty()) && (::GetModuleFileName(AfxGetInstanceHandle(), buff, _MAX_PATH)))
{
AppIcon = buff;
AppIcon = "\""+AppIcon+"\"";
@@ -351,7 +351,7 @@ static struct
void CPPageFormats::AddAutoPlayToRegistry(autoplay_t ap, bool fRegister)
{
TCHAR buff[_MAX_PATH];
- if(::GetModuleFileName(AfxGetInstanceHandle(), buff, MAX_PATH) == 0) return;
+ if(::GetModuleFileName(AfxGetInstanceHandle(), buff, _MAX_PATH) == 0) return;
CString exe = buff;
int i = (int)ap;
@@ -396,7 +396,7 @@ bool CPPageFormats::IsAutoPlayRegistered(autoplay_t ap)
{
ULONG len;
TCHAR buff[_MAX_PATH];
- if(::GetModuleFileName(AfxGetInstanceHandle(), buff, MAX_PATH) == 0) return(false);
+ if(::GetModuleFileName(AfxGetInstanceHandle(), buff, _MAX_PATH) == 0) return(false);
CString exe = buff;
int i = (int)ap;
@@ -549,7 +549,7 @@ BOOL CPPageFormats::OnInitDialog()
CRegKey key;
TCHAR buff[_MAX_PATH];
- ULONG len = sizeof(buff);
+ ULONG len = sizeof(buff)/sizeof(buff[0]);
int fContextDir = 0;
if(ERROR_SUCCESS == key.Open(HKEY_CLASSES_ROOT, _T("Directory\\shell\\mplayerc.play\\command"), KEY_READ))
@@ -572,8 +572,8 @@ BOOL CPPageFormats::SetFileAssociation(CString strExt, CString strProgID, bool f
CRegKey key;
HRESULT hr = S_OK;
TCHAR buff[256];
- ULONG len = sizeof(buff);
- memset(buff, 0, len);
+ ULONG len = sizeof(buff)/sizeof(buff[0]);
+ memset(buff, 0, sizeof(buff));
if (m_pAAR == NULL)
{
@@ -643,8 +643,8 @@ BOOL CPPageFormats::SetFileAssociation(CString strExt, CString strProgID, bool f
if(ERROR_SUCCESS != key.Create(HKEY_CLASSES_ROOT, strExt))
return(false);
- len = sizeof(buff);
- memset(buff, 0, len);
+ len = sizeof(buff)/sizeof(buff[0]);
+ memset(buff, 0, sizeof(buff));
if(ERROR_SUCCESS == key.QueryStringValue(NULL, buff, &len) && !CString(buff).Trim().IsEmpty())
extoldreg = buff;
if(ERROR_SUCCESS != key.SetStringValue(NULL, strProgID)) return(false);
@@ -676,8 +676,8 @@ BOOL CPPageFormats::SetFileAssociation(CString strExt, CString strProgID, bool f
else
{
// Get previous association
- len = sizeof(buff);
- memset(buff, 0, len);
+ len = sizeof(buff)/sizeof(buff[0]);
+ memset(buff, 0, sizeof(buff));
if(ERROR_SUCCESS != key.Create(HKEY_CLASSES_ROOT, strProgID))
return(false);
if(ERROR_SUCCESS == key.QueryStringValue(g_strOldAssoc, buff, &len) && !CString(buff).Trim().IsEmpty())
@@ -716,7 +716,7 @@ BOOL CPPageFormats::OnApply()
CString AppIcon = _T("");
TCHAR buff[_MAX_PATH];
- if(::GetModuleFileName(AfxGetInstanceHandle(), buff, MAX_PATH))
+ if(::GetModuleFileName(AfxGetInstanceHandle(), buff, _MAX_PATH))
{
AppIcon = buff;
AppIcon = "\""+AppIcon+"\"";
@@ -975,7 +975,7 @@ void CPPageFormats::OnBnVistaModify()
TCHAR strApp [_MAX_PATH];
strCmd.Format (_T("/adminoption %d"), IDD);
- GetModuleFileNameEx (GetCurrentProcess(), AfxGetMyApp()->m_hInstance, strApp, MAX_PATH);
+ GetModuleFileNameEx (GetCurrentProcess(), AfxGetMyApp()->m_hInstance, strApp, _MAX_PATH);
AfxGetMyApp()->RunAsAdministrator (strApp, strCmd, true);
diff --git a/src/apps/mplayerc/PPageSubtitles.cpp b/src/apps/mplayerc/PPageSubtitles.cpp
index 67b6725fc..f504a1e8c 100644
--- a/src/apps/mplayerc/PPageSubtitles.cpp
+++ b/src/apps/mplayerc/PPageSubtitles.cpp
@@ -167,13 +167,13 @@ BOOL CPPageSubtitles::OnApply()
AppSettings& s = AfxGetAppSettings();
if(s.fOverridePlacement != !!m_fOverridePlacement
- || s.nHorPos != m_nHorPos
- || s.nVerPos != m_nVerPos
- || s.m_RenderersSettings.nSPCSize != m_nSPCSize
- || s.nSubDelayInterval != m_nSubDelayInterval
- || s.m_RenderersSettings.nSPCMaxRes != TranslateResOut(m_spmaxres.GetCurSel())
- || s.m_RenderersSettings.fSPCPow2Tex != !!m_fSPCPow2Tex
- || s.m_RenderersSettings.fSPCAllowAnimationWhenBuffering != !!m_fSPCAllowAnimationWhenBuffering)
+ || s.nHorPos != m_nHorPos
+ || s.nVerPos != m_nVerPos
+ || s.m_RenderersSettings.nSPCSize != m_nSPCSize
+ || s.nSubDelayInterval != m_nSubDelayInterval
+ || s.m_RenderersSettings.nSPCMaxRes != TranslateResOut(m_spmaxres.GetCurSel())
+ || s.m_RenderersSettings.fSPCPow2Tex != !!m_fSPCPow2Tex
+ || s.m_RenderersSettings.fSPCAllowAnimationWhenBuffering != !!m_fSPCAllowAnimationWhenBuffering)
{
s.fOverridePlacement = !!m_fOverridePlacement;
s.nHorPos = m_nHorPos;
diff --git a/src/apps/mplayerc/PPageWebServer.cpp b/src/apps/mplayerc/PPageWebServer.cpp
index 387e6044b..2f0749259 100644
--- a/src/apps/mplayerc/PPageWebServer.cpp
+++ b/src/apps/mplayerc/PPageWebServer.cpp
@@ -154,7 +154,7 @@ BOOL CPPageWebServer::OnApply()
CString CPPageWebServer::GetMPCDir()
{
CString dir;
- GetModuleFileName(AfxGetInstanceHandle(), dir.GetBuffer(MAX_PATH), MAX_PATH);
+ GetModuleFileName(AfxGetInstanceHandle(), dir.GetBuffer(_MAX_PATH), _MAX_PATH);
dir.ReleaseBuffer();
CPath path(dir);
path.RemoveFileSpec();
diff --git a/src/apps/mplayerc/PlayerPlaylistBar.cpp b/src/apps/mplayerc/PlayerPlaylistBar.cpp
index ed78d50fa..9364bbafd 100644
--- a/src/apps/mplayerc/PlayerPlaylistBar.cpp
+++ b/src/apps/mplayerc/PlayerPlaylistBar.cpp
@@ -731,20 +731,23 @@ bool CPlayerPlaylistBar::SelectFileInPlaylist(LPCTSTR filename)
void CPlayerPlaylistBar::LoadPlaylist(LPCTSTR filename)
{
CString base;
+
if(AfxGetMyApp()->GetAppSavePath(base))
{
CPath p;
p.Combine(base, _T("default.mpcpl"));
- if(!AfxGetApp()->GetProfileInt(IDS_R_SETTINGS, _T("RememberPlaylistItems"), TRUE))
- {
- DeleteFile(p);
- }
- else
- {
- ParseMPCPlayList(p);
- Refresh();
- SelectFileInPlaylist(filename);
+ if(p.FileExists()) {
+ if(AfxGetApp()->GetProfileInt(IDS_R_SETTINGS, _T("RememberPlaylistItems"), TRUE))
+ {
+ ParseMPCPlayList(p);
+ Refresh();
+ SelectFileInPlaylist(filename);
+ }
+ else
+ {
+ ::DeleteFile(p);
+ }
}
}
}
@@ -752,19 +755,22 @@ void CPlayerPlaylistBar::LoadPlaylist(LPCTSTR filename)
void CPlayerPlaylistBar::SavePlaylist()
{
CString base;
- if(AfxGetMyApp()->GetAppSavePath(base))
- {
+
+ if(AfxGetMyApp()->GetAppSavePath(base)) {
CPath p;
p.Combine(base, _T("default.mpcpl"));
- if(!AfxGetApp()->GetProfileInt(IDS_R_SETTINGS, _T("RememberPlaylistItems"), TRUE))
- {
- DeleteFile(p);
- }
- else
+ if(AfxGetApp()->GetProfileInt(IDS_R_SETTINGS, _T("RememberPlaylistItems"), TRUE))
{
+ // Only create this folder when needed
+ if(!::PathFileExists(base))
+ ::CreateDirectory(base, NULL);
+
SaveMPCPlayList(p, CTextFile::UTF8, false);
}
+ else if(p.FileExists()) {
+ ::DeleteFile(p);
+ }
}
}
@@ -1119,7 +1125,7 @@ void CPlayerPlaylistBar::DropItemOnList()
lvi.stateMask = LVIS_DROPHILITED | LVIS_FOCUSED | LVIS_SELECTED;
lvi.pszText = szLabel;
lvi.iItem = m_nDragIndex;
- lvi.cchTextMax = MAX_PATH;
+ lvi.cchTextMax = _MAX_PATH;
m_list.GetItem(&lvi);
if(m_nDropIndex < 0) m_nDropIndex = m_list.GetItemCount();
@@ -1432,14 +1438,14 @@ void CPlayerPlaylistBar::OnContextMenu(CWnd* /*pWnd*/, CPoint p)
CString fn = pli.m_fns.GetHead();
- /*
+/*
if(fRemovePath)
{
CPath p(path);
p.StripPath();
fn = (LPCTSTR)p;
}
- */
+*/
switch(idx)
{
diff --git a/src/apps/mplayerc/PlayerSeekBar.cpp b/src/apps/mplayerc/PlayerSeekBar.cpp
index 662a6a2a0..e9adf8e6a 100644
--- a/src/apps/mplayerc/PlayerSeekBar.cpp
+++ b/src/apps/mplayerc/PlayerSeekBar.cpp
@@ -176,6 +176,7 @@ BEGIN_MESSAGE_MAP(CPlayerSeekBar, CDialogBar)
ON_WM_LBUTTONUP()
ON_WM_MOUSEMOVE()
ON_WM_ERASEBKGND()
+ ON_WM_SETCURSOR()
//}}AFX_MSG_MAP
ON_COMMAND_EX(ID_PLAY_STOP, OnPlayStop)
END_MESSAGE_MAP()
@@ -305,6 +306,17 @@ BOOL CPlayerSeekBar::OnEraseBkgnd(CDC* pDC)
return TRUE;
}
+BOOL CPlayerSeekBar::OnSetCursor(CWnd* pWnd, UINT nHitTest, UINT message)
+{
+ bool fEnabled = m_fEnabled && m_start < m_stop;
+
+ if(fEnabled) {
+ ::SetCursor(AfxGetApp()->LoadStandardCursor(IDC_HAND));
+ return TRUE;
+ }
+ return CWnd::OnSetCursor(pWnd, nHitTest, message);
+}
+
BOOL CPlayerSeekBar::OnPlayStop(UINT nID)
{
SetPos(0);
diff --git a/src/apps/mplayerc/PlayerSeekBar.h b/src/apps/mplayerc/PlayerSeekBar.h
index 51153cbaf..c59463b45 100644
--- a/src/apps/mplayerc/PlayerSeekBar.h
+++ b/src/apps/mplayerc/PlayerSeekBar.h
@@ -68,6 +68,7 @@ protected:
afx_msg void OnLButtonUp(UINT nFlags, CPoint point);
afx_msg void OnMouseMove(UINT nFlags, CPoint point);
afx_msg BOOL OnEraseBkgnd(CDC* pDC);
+ afx_msg BOOL OnSetCursor(CWnd* pWnd, UINT nHitTest, UINT message);
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
public:
diff --git a/src/apps/mplayerc/PlayerToolBar.cpp b/src/apps/mplayerc/PlayerToolBar.cpp
index aaa2d08a3..4c6ba5a90 100644
--- a/src/apps/mplayerc/PlayerToolBar.cpp
+++ b/src/apps/mplayerc/PlayerToolBar.cpp
@@ -203,10 +203,10 @@ int CPlayerToolBar::GetMinWidth()
void CPlayerToolBar::SetVolume(int volume)
{
- /*
- volume = (int)pow(10, ((double)volume)/5000+2);
- volume = max(min(volume, 100), 1);
- */
+/*
+ volume = (int)pow(10, ((double)volume)/5000+2);
+ volume = max(min(volume, 100), 1);
+*/
m_volctrl.SetPosInternal(volume);
}
@@ -220,6 +220,7 @@ BEGIN_MESSAGE_MAP(CPlayerToolBar, CToolBar)
ON_COMMAND_EX(ID_VOLUME_DOWN, OnVolumeDown)
ON_WM_NCPAINT()
ON_WM_LBUTTONDOWN()
+ ON_WM_MOUSEMOVE()
END_MESSAGE_MAP()
// CPlayerToolBar message handlers
@@ -296,26 +297,57 @@ void CPlayerToolBar::OnNcPaint() // when using XP styles the NC area isn't drawn
// Do not call CToolBar::OnNcPaint() for painting messages
}
+void CPlayerToolBar::OnMouseMove(UINT nFlags, CPoint point)
+{
+ int i = getHitButtonIdx(point);
+
+ if((i==-1) || (GetButtonStyle(i)&(TBBS_SEPARATOR|TBBS_DISABLED)))
+ ;
+ else
+ {
+ if((i>11) || ((i<10) && ((CMainFrame*)GetParentFrame())->IsSomethingLoaded()))
+ ::SetCursor(AfxGetApp()->LoadStandardCursor(IDC_HAND));
+ }
+ __super::OnMouseMove(nFlags, point);
+}
+
void CPlayerToolBar::OnLButtonDown(UINT nFlags, CPoint point)
{
- for(int i = 0, j = GetToolBarCtrl().GetButtonCount(); i < j; i++)
+ int i = getHitButtonIdx(point);
+ CMainFrame* pFrame = ((CMainFrame*)GetParentFrame());
+
+ if((i==-1) || (GetButtonStyle(i)&(TBBS_SEPARATOR|TBBS_DISABLED)))
+ {
+ if(!pFrame->m_fFullScreen)
+ {
+ MapWindowPoints(pFrame, &point, 1);
+ pFrame->PostMessage(WM_NCLBUTTONDOWN, HTCAPTION, MAKELPARAM(point.x, point.y));
+ }
+ }
+ else
{
- if(GetButtonStyle(i)&(TBBS_SEPARATOR|TBBS_DISABLED))
- continue;
+ if((i>11) || ((i<10) && pFrame->IsSomethingLoaded()))
+ ::SetCursor(AfxGetApp()->LoadStandardCursor(IDC_HAND));
+
+ __super::OnLButtonDown(nFlags, point);
+ }
+}
+
+int CPlayerToolBar::getHitButtonIdx(CPoint point)
+{
+ int hit = -1; // -1 means not on any buttons, mute button is 12/13, others < 10, 11 is empty space between
+ CRect r;
- CRect r;
+ for(int i = 0, j = GetToolBarCtrl().GetButtonCount(); i < j; i++)
+ {
GetItemRect(i, r);
+
if(r.PtInRect(point))
{
- __super::OnLButtonDown(nFlags, point);
- return;
+ hit = i;
+ break;
}
}
- CMainFrame* pFrame = ((CMainFrame*)GetParentFrame());
- if(!pFrame->m_fFullScreen)
- {
- MapWindowPoints(pFrame, &point, 1);
- pFrame->PostMessage(WM_NCLBUTTONDOWN, HTCAPTION, MAKELPARAM(point.x, point.y));
- }
+ return hit;
}
diff --git a/src/apps/mplayerc/PlayerToolBar.h b/src/apps/mplayerc/PlayerToolBar.h
index 54063bbf1..0a41ae84c 100644
--- a/src/apps/mplayerc/PlayerToolBar.h
+++ b/src/apps/mplayerc/PlayerToolBar.h
@@ -35,6 +35,7 @@ class CPlayerToolBar : public CToolBar
private:
bool IsMuted();
void SetMute(bool fMute = true);
+ int getHitButtonIdx(CPoint point);
int m_nButtonHeight;
public:
@@ -69,6 +70,7 @@ protected:
afx_msg BOOL OnVolumeDown(UINT nID);
afx_msg void OnNcPaint();
afx_msg void OnLButtonDown(UINT nFlags, CPoint point);
+ afx_msg void OnMouseMove(UINT nFlags, CPoint point);
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
};
diff --git a/src/apps/mplayerc/Playlist.cpp b/src/apps/mplayerc/Playlist.cpp
index dcc7b07e1..3d49a2863 100644
--- a/src/apps/mplayerc/Playlist.cpp
+++ b/src/apps/mplayerc/Playlist.cpp
@@ -356,22 +356,34 @@ void CPlaylist::SetPos(POSITION pos)
m_pos = pos;
}
-#define Rand(a, b) rand()%(b-a+1)+a
-
POSITION CPlaylist::Shuffle()
{
- CAtlArray<plsort2_t> a;
- a.SetCount(GetCount());
- srand((unsigned)time(NULL));
- POSITION pos = GetHeadPosition();
- for(int i = 0; pos; i++, GetNext(pos))
- a[i].pos = pos;
-
- pos = GetPos();
- int rnd = Rand(0, a.GetCount()-1);
- while(pos == a[rnd].pos) rnd = Rand(0, a.GetCount()-1);
+ static INT_PTR idx = 0;
+ static INT_PTR count = 0;
+ static CAtlArray<plsort_t> a;
+
+ ASSERT(GetCount() > 2);
+ // insert or remove items in playlist, or index out of bounds then recalculate
+ if((count != GetCount()) || (idx >= GetCount())) {
+ a.RemoveAll();
+ idx = 0;
+ a.SetCount(count = GetCount());
+
+ POSITION pos = GetHeadPosition();
+ for(INT_PTR i = 0; pos; i++, GetNext(pos))
+ a[i].pos = pos; // initialize position array
+
+ //Use Fisher-Yates shuffle algorithm
+ srand((unsigned)time(NULL));
+ for (INT_PTR i=0; i<(count-1); i++) {
+ INT_PTR r = i + (rand() % (count-i));
+ POSITION temp = a[i].pos;
+ a[i].pos = a[r].pos;
+ a[r].pos = temp;
+ }
+ }
- return a[rnd].pos;
+ return a[idx++].pos;
}
CPlaylistItem& CPlaylist::GetNextWrap(POSITION& pos)
diff --git a/src/apps/mplayerc/QuicktimeGraph.cpp b/src/apps/mplayerc/QuicktimeGraph.cpp
index 54fd2eed9..5a71fa9e1 100644
--- a/src/apps/mplayerc/QuicktimeGraph.cpp
+++ b/src/apps/mplayerc/QuicktimeGraph.cpp
@@ -366,7 +366,7 @@ CQuicktimeWindow::CQuicktimeWindow(CQuicktimeGraph* pGraph)
void CQuicktimeWindow::ProcessMovieEvent(unsigned int message, unsigned int wParam, long lParam)
{
if(message >= WM_MOUSEFIRST && message <= WM_MOUSELAST
- || message >= WM_KEYFIRST && message <= WM_KEYLAST)
+ || message >= WM_KEYFIRST && message <= WM_KEYLAST)
return;
// Convert the Windows event to a QTML event
@@ -463,7 +463,7 @@ bool CQuicktimeWindow::OpenMovie(CString fn)
CHAR buff[_MAX_PATH] = {0, 0};
#ifdef UNICODE
- WideCharToMultiByte(GetACP(), 0, fn, -1, buff+1, MAX_PATH-1, 0, 0);
+ WideCharToMultiByte(GetACP(), 0, fn, -1, buff+1, _MAX_PATH-1, 0, 0);
#else
strcpy(buff+1, fn);
#endif
diff --git a/src/apps/mplayerc/RealMediaGraph.cpp b/src/apps/mplayerc/RealMediaGraph.cpp
index c5fe2cb7a..022f64e29 100644
--- a/src/apps/mplayerc/RealMediaGraph.cpp
+++ b/src/apps/mplayerc/RealMediaGraph.cpp
@@ -65,7 +65,7 @@ bool CRealMediaPlayer::Init()
return(false);
TCHAR buff[_MAX_PATH];
- ULONG len = sizeof(buff);
+ ULONG len = sizeof(buff)/sizeof(buff[0]);
if(ERROR_SUCCESS != key.QueryStringValue(NULL, buff, &len))
return(false);
@@ -86,14 +86,14 @@ bool CRealMediaPlayer::Init()
{
CString dllpaths;
- len = sizeof(buff);
- for(int i = 0; ERROR_SUCCESS == key.EnumKey(i, buff, &len); i++, len = sizeof(buff))
+ len = sizeof(buff)/sizeof(buff[0]);
+ for(int i = 0; ERROR_SUCCESS == key.EnumKey(i, buff, &len); i++,len = sizeof(buff)/sizeof(buff[0]))
{
CRegKey key2;
TCHAR buff2[_MAX_PATH];
- ULONG len2 = sizeof(buff2);
+ ULONG len2 = sizeof(buff2)/sizeof(buff2[0]);
if(ERROR_SUCCESS != key2.Open(HKEY_CLASSES_ROOT, prefs + _T("\\") + buff, KEY_READ)
- || ERROR_SUCCESS != key2.QueryStringValue(NULL, buff2, &len2))
+ || ERROR_SUCCESS != key2.QueryStringValue(NULL, buff2, &len2))
continue;
dllpaths += CString(buff) + '=' + buff2 + '|';
@@ -641,7 +641,7 @@ STDMETHODIMP CRealMediaGraph::RenderFile(LPCWSTR lpcwstrFile, LPCWSTR lpcwstrPla
m_fn = lpcwstrFile;
CHAR buff[_MAX_PATH] = {0};
- WideCharToMultiByte(GetACP(), 0, lpcwstrFile, -1, buff, MAX_PATH, 0, 0);
+ WideCharToMultiByte(GetACP(), 0, lpcwstrFile, -1, buff, _MAX_PATH, 0, 0);
CStringA fn(buff);
if(fn.Find("://") < 0) fn = "file://" + fn;
diff --git a/src/apps/mplayerc/SaveDlg.cpp b/src/apps/mplayerc/SaveDlg.cpp
index 1bd8047aa..f1b3953e0 100644
--- a/src/apps/mplayerc/SaveDlg.cpp
+++ b/src/apps/mplayerc/SaveDlg.cpp
@@ -77,7 +77,7 @@ BOOL CSaveDlg::OnInitDialog()
m_progress.SetRange(0, 100);
if(FAILED(pGB.CoCreateInstance(CLSID_FilterGraph)) || !(pMC = pGB) || !(pME = pGB) || !(pMS = pGB)
- || FAILED(pME->SetNotifyWindow((OAHWND)m_hWnd, WM_GRAPHNOTIFY, 0)))
+ || FAILED(pME->SetNotifyWindow((OAHWND)m_hWnd, WM_GRAPHNOTIFY, 0)))
{
m_report.SetWindowText(_T("Error"));
return FALSE;
diff --git a/src/apps/mplayerc/StaticLink.cpp b/src/apps/mplayerc/StaticLink.cpp
index d467c7f2f..46a8f697a 100644
--- a/src/apps/mplayerc/StaticLink.cpp
+++ b/src/apps/mplayerc/StaticLink.cpp
@@ -143,7 +143,7 @@ BOOL CStaticLink::OnSetCursor(CWnd* pWnd, UINT nHitTest, UINT message)
if (!bTriedOnce)
{
CString windir;
- GetWindowsDirectory(windir.GetBuffer(MAX_PATH), MAX_PATH);
+ GetWindowsDirectory(windir.GetBuffer(_MAX_PATH), _MAX_PATH);
windir.ReleaseBuffer();
windir += _T("\\winhlp32.exe");
HMODULE hModule = LoadLibrary(windir);
diff --git a/src/apps/mplayerc/VolumeCtrl.cpp b/src/apps/mplayerc/VolumeCtrl.cpp
index 6cd555472..3b0a7d293 100644
--- a/src/apps/mplayerc/VolumeCtrl.cpp
+++ b/src/apps/mplayerc/VolumeCtrl.cpp
@@ -71,6 +71,7 @@ BEGIN_MESSAGE_MAP(CVolumeCtrl, CSliderCtrl)
ON_WM_LBUTTONDOWN()
ON_WM_SETFOCUS()
ON_WM_HSCROLL_REFLECT()
+ ON_WM_SETCURSOR()
END_MESSAGE_MAP()
// CVolumeCtrl message handlers
@@ -181,3 +182,9 @@ void CVolumeCtrl::HScroll(UINT nSBCode, UINT nPos)
if(pFrame && pFrame != GetParent())
pFrame->PostMessage(WM_HSCROLL, MAKEWPARAM((short)nPos, nSBCode), (LPARAM)m_hWnd);
}
+
+BOOL CVolumeCtrl::OnSetCursor(CWnd* pWnd, UINT nHitTest, UINT message)
+{
+ ::SetCursor(AfxGetApp()->LoadStandardCursor(IDC_HAND));
+ return TRUE;
+}
diff --git a/src/apps/mplayerc/VolumeCtrl.h b/src/apps/mplayerc/VolumeCtrl.h
index 76c9b3f9d..a5cd69136 100644
--- a/src/apps/mplayerc/VolumeCtrl.h
+++ b/src/apps/mplayerc/VolumeCtrl.h
@@ -43,6 +43,8 @@ public:
void SetPosInternal(int pos);
protected:
+ afx_msg BOOL OnSetCursor(CWnd* pWnd, UINT nHitTest, UINT message);
+
DECLARE_MESSAGE_MAP()
public:
diff --git a/src/apps/mplayerc/WebServer.cpp b/src/apps/mplayerc/WebServer.cpp
index b60a1de9b..98fc05478 100644
--- a/src/apps/mplayerc/WebServer.cpp
+++ b/src/apps/mplayerc/WebServer.cpp
@@ -115,7 +115,7 @@ CWebServer::CWebServer(CMainFrame* pMainFrame, int nPort)
m_mimes[".jpg"] = "image/jpeg";
m_mimes[".png"] = "image/png";
- GetModuleFileName(AfxGetInstanceHandle(), str.GetBuffer(MAX_PATH), MAX_PATH);
+ GetModuleFileName(AfxGetInstanceHandle(), str.GetBuffer(_MAX_PATH), _MAX_PATH);
str.ReleaseBuffer();
m_webroot = CPath(str);
m_webroot.RemoveFileSpec();
@@ -460,7 +460,7 @@ void CWebServer::OnRequest(CWebClientSocket* pClient, CStringA& hdr, CStringA& b
if(!sl.Find(_T("gzip"))) break;
CHAR path[_MAX_PATH], fn[_MAX_PATH];
- if(!GetTempPathA(MAX_PATH, path) || !GetTempFileNameA(path, "mpc_gz", 0, fn))
+ if(!GetTempPathA(_MAX_PATH, path) || !GetTempFileNameA(path, "mpc_gz", 0, fn))
break;
gzFile gf = gzopen(fn, "wb9");
diff --git a/src/apps/mplayerc/mpcresources/common.pl b/src/apps/mplayerc/mpcresources/common.pl
index 630b19ab1..0df199035 100644
--- a/src/apps/mplayerc/mpcresources/common.pl
+++ b/src/apps/mplayerc/mpcresources/common.pl
@@ -52,7 +52,7 @@ sub analyseData {
my @text=();
foreach (@inputs) {
- s/\s*$//;
+ chop;chop;
$curline=$_;
if(!$bInBlock) {
@@ -188,8 +188,6 @@ sub readStringTable {
my $savekey;
foreach(@{$input}){
- s/\s*$//;
-
if(/^\s+(ID\S+)\s+(".+")/){
my ($key, $value) = ($1, $2);
$strings->{$key} = $value;
@@ -218,7 +216,7 @@ sub skipNonTranslatedStr {
Static|Button|msctls_updown32|SysListView32|msctls_trackbar32 #
|msctls_progress32|SysTreeView32|SysTabControl32|SysAnimate32|SysLink #skip built-in control names
|MS\sShell\sDlg|MS\sSans\sSerif|MS\sUI\sGothic #skip dialog font, but maybe should not because 3 asian languages need change this
- |L|R|F|Q|\\000|\.\.\.|(LANGUAGE.+)?\\r\\n|\+\/- #skip \r\n \000 ... L R F Q etc
+ |\\000|\.\.\.|(LANGUAGE.+)?\\r\\n|\+\/- #skip \r\n \000 ... etc
|<a>http.+<\/a>|http:\/\/ #skip http links
|Media\sPlayer\sClassic\s-?\sHome\sCinema|mpc-hc|MPC-HC\sTeam #skip app names
|Comments|CompanyName|FileDescription|FileVersion|InternalName|VarFileInfo|StringFileInfo|Translation
diff --git a/src/apps/mplayerc/mpcresources/rcfile.pl b/src/apps/mplayerc/mpcresources/rcfile.pl
index fe9f9d62d..48778d000 100644
--- a/src/apps/mplayerc/mpcresources/rcfile.pl
+++ b/src/apps/mplayerc/mpcresources/rcfile.pl
@@ -65,6 +65,7 @@ Options:
First: checkout the head revision of mplayerc.rc using the svn client, give it any other name, for example:
>svn cat -r head ../mplayerc.rc > mplayer.rc.old
Second: >perl rcfile.pl -b mplayerc.rc.old
+ Or better yet use provided batch file: >rcfile.bat
After running this script, you will find all new language rc files under "newrc" subdir, along with
the string text files for translators to translate. These new rc files have all changes copied from your
@@ -221,32 +222,33 @@ sub writeStringTable {
#use new rc file stringtables, try to use as many locale strings as possible
foreach (@{$output}){
- if (/\b(ID\S+)\b\s*(".+")/){
- my($key, $value)=($1, $2);
- my $localeStr = $refs->{$key};
-
- if($localeStr) {
- s/\Q$value\E/$localeStr/;
- }
- else {
- push(@{$patches},["STRINGTABLE",{$key=>$value}]);
- }
+ my ($key, $value);
+
+ if (/\b(ID\S+)\b\s*(".+")/){ #distinguish between key value at same line or not for syntax's sake
+ ($key, $value)= ($1,$2);
}
- elsif (/\b(ID\S+)\b\s*$/){
- my $key = $1;
- my $value = $NewStrings->{$key};
-
- my $localeStr = $refs->{$key};
- if($localeStr) {
- $_ = " $key $localeStr";
- }
- else {
- $_ = " $key $value";
- push(@{$patches}, ["STRINGTABLE",{$key=>$value}]);
- }
+ elsif (/\b(ID\S+)\b\s*$/){ #value too long to fit in one line but we don't care. :)
+ $key = $1;
+ $value = $NewStrings->{$key};
+ $_ = " $key $value";
}
- elsif(/^\s*".+"\s*$/){
+ elsif(/^\s*".+"\s*$/){ #value not same line with key, already dealed with, so just clear it.
$_ = " ";
+ next;
+ }
+ else {
+ next; #other text
+ }
+
+ my $baseStr = $BaseStrings->{$key};
+ my $localeStr = $refs->{$key};
+
+ if((!$localeStr) || (!$baseStr) || ($baseStr ne $value)) {
+ #new string or changed string or not in locale files, use new one
+ push(@{$patches},["STRINGTABLE",{$key=>$value}]);
+ }
+ else {
+ s/\Q$value\E/$localeStr/; #use locale string
}
}
}
@@ -260,10 +262,11 @@ sub writeDialogContent {
my $contentLines = @contents;
if(my $diffData = $DialogDiffs->{$name}) {
- # this menu exists in old file
+ # this dialog exists in old file
my @changes = grep($_->[0] != $_->[1],@$diffData); #anything changed for this dialog?
-
- if(!@changes) { #no change then just use old data
+ my $samelines = @$diffData;
+
+ if((!@changes) && ($samelines == $contentLines)) { #no change then just use old data
@contents = ();
push(@contents, @{$refs->{$name}{"__TEXT__"}});
}
@@ -294,7 +297,9 @@ sub writeDialogContent {
$i;
}@{$NewDialogs->{$name}{"__DATA__"}};
- push(@{$patches}, ["DIALOG", {$name => [@data], "__LINES__" => $contentLines}]);
+ if(@data) {
+ push(@{$patches}, ["DIALOG", {$name => [@data], "__LINES__" => $contentLines}]);
+ }
}
else {
# if locale rc files have different line numbers with original main mplayerc.rc,
@@ -321,8 +326,9 @@ sub writeMenuContent {
if(my $diffData = $MenuDiffs->{$name}) {
# this menu exists in old file
my @changes = grep($_->[0] != $_->[1],@$diffData); #anything changed for this menu?
-
- if(!@changes) { #no change then just use old data
+ my $samelines = @$diffData;
+
+ if((!@changes) && ($samelines == $contentLines)) { #no change then just use old data
@contents = ();
push(@contents, @{$refs->{$name}{"__TEXT__"}});
}
@@ -345,8 +351,10 @@ sub writeMenuContent {
}
$i;
}@{$NewMenus->{$name}{"__DATA__"}};
-
- push(@{$patches}, ["MENU", {$name => [@data], "__LINES__" => $contentLines }]);
+
+ if(@data) {
+ push(@{$patches}, ["MENU", {$name => [@data], "__LINES__" => $contentLines }]);
+ }
}
}
else {
diff --git a/src/apps/mplayerc/mplayerc.cpp b/src/apps/mplayerc/mplayerc.cpp
index bf8bf90e7..7aa362360 100644
--- a/src/apps/mplayerc/mplayerc.cpp
+++ b/src/apps/mplayerc/mplayerc.cpp
@@ -98,8 +98,8 @@ HICON LoadIcon(CString fn, bool fSmall)
if(ERROR_SUCCESS != key.Open(HKEY_CLASSES_ROOT, ext, KEY_READ))
break;
- len = sizeof(buff);
- memset(buff, 0, len);
+ len = sizeof(buff)/sizeof(buff[0]);
+ memset(buff, 0, sizeof(buff));
if(ERROR_SUCCESS != key.QueryStringValue(NULL, buff, &len) || (ext = buff).Trim().IsEmpty())
break;
@@ -109,8 +109,8 @@ HICON LoadIcon(CString fn, bool fSmall)
CString icon;
- len = sizeof(buff);
- memset(buff, 0, len);
+ len = sizeof(buff)/sizeof(buff[0]);
+ memset(buff, 0, sizeof(buff));
if(ERROR_SUCCESS != key.QueryStringValue(NULL, buff, &len) || (icon = buff).Trim().IsEmpty())
break;
@@ -161,8 +161,8 @@ bool LoadType(CString fn, CString& type)
while(ERROR_SUCCESS == key.Open(HKEY_CLASSES_ROOT, tmp))
{
- len = sizeof(buff);
- memset(buff, 0, len);
+ len = sizeof(buff)/sizeof(buff[0]);
+ memset(buff, 0, sizeof(buff));
if(ERROR_SUCCESS != key.QueryStringValue(NULL, buff, &len))
break;
@@ -316,7 +316,7 @@ CMPlayerCApp::CMPlayerCApp()
CFileVersionInfo Version;
TCHAR strApp [_MAX_PATH];
- GetModuleFileNameEx (GetCurrentProcess(), AfxGetMyApp()->m_hInstance, strApp, MAX_PATH);
+ GetModuleFileNameEx (GetCurrentProcess(), AfxGetMyApp()->m_hInstance, strApp, _MAX_PATH);
Version.Create (strApp);
m_strVersion = Version.GetFileVersionEx();
@@ -369,8 +369,7 @@ bool CMPlayerCApp::StoreSettingsToIni()
m_pszRegistryKey = NULL;
free((void*)m_pszProfileName);
m_pszProfileName = _tcsdup(ini);
-
- return(true);
+ return(true);
}
bool CMPlayerCApp::StoreSettingsToRegistry()
@@ -388,7 +387,7 @@ bool CMPlayerCApp::StoreSettingsToRegistry()
CString CMPlayerCApp::GetIniPath()
{
CString path;
- GetModuleFileName(AfxGetInstanceHandle(), path.GetBuffer(MAX_PATH), MAX_PATH);
+ GetModuleFileName(AfxGetInstanceHandle(), path.GetBuffer(_MAX_PATH), _MAX_PATH);
path.ReleaseBuffer();
path = path.Left(path.ReverseFind('.')+1) + _T("ini");
return(path);
@@ -406,7 +405,7 @@ bool CMPlayerCApp::GetAppSavePath(CString& path)
if(IsIniValid()) // If settings ini file found, store stuff in the same folder as the exe file
{
- GetModuleFileName(AfxGetInstanceHandle(), path.GetBuffer(MAX_PATH), MAX_PATH);
+ GetModuleFileName(AfxGetInstanceHandle(), path.GetBuffer(_MAX_PATH), _MAX_PATH);
path.ReleaseBuffer();
path = path.Left(path.ReverseFind('\\'));
}
@@ -415,8 +414,8 @@ bool CMPlayerCApp::GetAppSavePath(CString& path)
CRegKey key;
if(ERROR_SUCCESS == key.Open(HKEY_CURRENT_USER, _T("Software\\Microsoft\\Windows\\CurrentVersion\\Explorer\\Shell Folders"), KEY_READ))
{
- ULONG len = MAX_PATH;
- if(ERROR_SUCCESS == key.QueryStringValue(_T("AppData"), path.GetBuffer(MAX_PATH), &len))
+ ULONG len = _MAX_PATH;
+ if(ERROR_SUCCESS == key.QueryStringValue(_T("AppData"), path.GetBuffer(_MAX_PATH), &len))
path.ReleaseBufferSetLength(len);
}
@@ -425,6 +424,7 @@ bool CMPlayerCApp::GetAppSavePath(CString& path)
CPath p;
p.Combine(path, _T("Media Player Classic"));
+
path = (LPCTSTR)p;
}
@@ -442,7 +442,7 @@ void CMPlayerCApp::PreProcessCommandLine()
{
LPTSTR p = NULL;
CString str2;
- str2.ReleaseBuffer(GetFullPathName(str, MAX_PATH, str2.GetBuffer(MAX_PATH), &p));
+ str2.ReleaseBuffer(GetFullPathName(str, _MAX_PATH, str2.GetBuffer(_MAX_PATH), &p));
CFileStatus fs;
if(!str2.IsEmpty() && CFileGetStatus(str2, fs)) str = str2;
}
@@ -651,7 +651,7 @@ BOOL CreateFakeVideoTS(LPCWSTR strIFOPath, LPWSTR strFakeFile, size_t nFakeFileS
WCHAR strExt[_MAX_EXT];
CIfo Ifo;
- if (!GetTempPathW(MAX_PATH, szTempPath)) return FALSE;
+ if (!GetTempPathW(_MAX_PATH, szTempPath)) return FALSE;
_wsplitpath_s (strIFOPath, NULL, 0, NULL, 0, strFileName, countof(strFileName), strExt, countof(strExt));
_snwprintf_s (strFakeFile, nFakeFileSize, _TRUNCATE, L"%sMPC%s%s", szTempPath, strFileName, strExt);
@@ -897,15 +897,8 @@ BOOL CMPlayerCApp::InitInstance()
if(IsIniValid())
StoreSettingsToIni();
else
- {
StoreSettingsToRegistry();
- // Only create a folder when using registry to store settings
- CString AppSavePath;
- if(GetAppSavePath(AppSavePath))
- CreateDirectory(AppSavePath, NULL);
- }
-
m_s.ParseCommandLine(m_cmdln);
if(m_s.nCLSwitches&(CLSW_HELP|CLSW_UNRECOGNIZEDSWITCH))
@@ -1022,7 +1015,7 @@ BOOL CMPlayerCApp::InitInstance()
if(ERROR_SUCCESS == key.Create(HKEY_LOCAL_MACHINE, _T("Software\\Gabest\\Media Player Classic")))
{
CString path;
- GetModuleFileName(AfxGetInstanceHandle(), path.GetBuffer(MAX_PATH), MAX_PATH);
+ GetModuleFileName(AfxGetInstanceHandle(), path.GetBuffer(_MAX_PATH), _MAX_PATH);
path.ReleaseBuffer();
key.SetStringValue(_T("ExePath"), path);
}
diff --git a/src/apps/mplayerc/mplayerc.h b/src/apps/mplayerc/mplayerc.h
index eb969c1e6..ca58dafdc 100644
--- a/src/apps/mplayerc/mplayerc.h
+++ b/src/apps/mplayerc/mplayerc.h
@@ -40,7 +40,7 @@
#define MPC_WND_CLASS_NAME L"MediaPlayerClassicW"
//define the default logo we use
-#define DEF_LOGO IDF_LOGO1
+#define DEF_LOGO IDF_LOGO3
enum
{
diff --git a/src/apps/subresync/stdafx.cpp b/src/apps/subresync/stdafx.cpp
index dff408efd..dc889a79e 100644
--- a/src/apps/subresync/stdafx.cpp
+++ b/src/apps/subresync/stdafx.cpp
@@ -24,5 +24,3 @@
*/
#include "stdafx.h"
-
-
diff --git a/src/apps/subresync/stdafx.h b/src/apps/subresync/stdafx.h
index a33d16415..05860a9bd 100644
--- a/src/apps/subresync/stdafx.h
+++ b/src/apps/subresync/stdafx.h
@@ -31,20 +31,8 @@
// Modify the following defines if you have to target a platform prior to the ones specified below.
// Refer to MSDN for the latest info on corresponding values for different platforms.
-#ifndef WINVER // Allow use of features specific to Windows 95 and Windows NT 4 or later.
-#define WINVER 0x0400 // Change this to the appropriate value to target Windows 98 and Windows 2000 or later.
-#endif
-
-#ifndef _WIN32_WINNT // Allow use of features specific to Windows NT 4 or later.
-#define _WIN32_WINNT 0x0400 // Change this to the appropriate value to target Windows 98 and Windows 2000 or later.
-#endif
-
-#ifndef _WIN32_WINDOWS // Allow use of features specific to Windows 98 or later.
-#define _WIN32_WINDOWS 0x0410 // Change this to the appropriate value to target Windows Me or later.
-#endif
-
-#ifndef _WIN32_IE // Allow use of features specific to IE 4.0 or later.
-#define _WIN32_IE 0x0400 // Change this to the appropriate value to target IE 5.0 or later.
+#ifndef WINVER // Allow use of features specific to Windows 95 and Windows NT 4 or later.
+#define WINVER 0x0600 // Change this to the appropriate value to target Windows 98 and Windows 2000 or later.
#endif
#define _ATL_CSTRING_EXPLICIT_CONSTRUCTORS // some CString constructors will be explicit
@@ -52,12 +40,12 @@
// turns off MFC's hiding of some common and often safely ignored warning messages
#define _AFX_ALL_WARNINGS
-#include <afxwin.h> // MFC core and standard components
-#include <afxext.h> // MFC extensions
-#include <afxdisp.h> // MFC Automation classes
+#include <afxwin.h> // MFC core and standard components
+#include <afxext.h> // MFC extensions
+#include <afxdisp.h> // MFC Automation classes
+#include <afxdlgs.h>
+#include <atlbase.h>
-#include <afxdtctl.h> // MFC support for Internet Explorer 4 Common Controls
#ifndef _AFX_NO_AFXCMN_SUPPORT
#include <afxcmn.h> // MFC support for Windows Common Controls
#endif // _AFX_NO_AFXCMN_SUPPORT
-
diff --git a/src/apps/subresync/subresync.cpp b/src/apps/subresync/subresync.cpp
index 3192087f8..000484c28 100644
--- a/src/apps/subresync/subresync.cpp
+++ b/src/apps/subresync/subresync.cpp
@@ -24,15 +24,10 @@
#include "subresync.h"
#include "subresyncDlg.h"
-#ifdef _DEBUG
-#define new DEBUG_NEW
-#endif
-
-
// CSubresyncApp
BEGIN_MESSAGE_MAP(CSubresyncApp, CWinApp)
- ON_COMMAND(ID_HELP, CWinApp::OnHelp)
+ ON_COMMAND(ID_HELP, CWinApp::OnHelp)
END_MESSAGE_MAP()
@@ -52,45 +47,45 @@ CSubresyncApp theApp;
BOOL CSubresyncApp::InitInstance()
{
- // InitCommonControls() is required on Windows XP if an application
- // manifest specifies use of ComCtl32.dll version 6 or later to enable
- // visual styles. Otherwise, any window creation will fail.
- InitCommonControls();
+ // InitCommonControls() is required on Windows XP if an application
+ // manifest specifies use of ComCtl32.dll version 6 or later to enable
+ // visual styles. Otherwise, any window creation will fail.
+ InitCommonControls();
- CWinApp::InitInstance();
+ CWinApp::InitInstance();
- AfxEnableControlContainer();
+ AfxEnableControlContainer();
- SetRegistryKey(_T("Gabest"));
+ SetRegistryKey(_T("Gabest"));
- CoInitialize(NULL);
+ CoInitialize(NULL);
- CCommandLineInfo cmdInfo;
- ParseCommandLine(cmdInfo);
+ CCommandLineInfo cmdInfo;
+ ParseCommandLine(cmdInfo);
- CSubresyncDlg dlg(cmdInfo.m_strFileName);
- m_pMainWnd = &dlg;
+ CSubresyncDlg dlg(cmdInfo.m_strFileName);
+ m_pMainWnd = &dlg;
- INT_PTR nResponse = dlg.DoModal();
- if (nResponse == IDOK)
- {
- // TODO: Place code here to handle when the dialog is
- // dismissed with OK
- }
- else if (nResponse == IDCANCEL)
- {
- // TODO: Place code here to handle when the dialog is
- // dismissed with Cancel
- }
+ INT_PTR nResponse = dlg.DoModal();
+ if (nResponse == IDOK)
+ {
+ // TODO: Place code here to handle when the dialog is
+ // dismissed with OK
+ }
+ else if (nResponse == IDCANCEL)
+ {
+ // TODO: Place code here to handle when the dialog is
+ // dismissed with Cancel
+ }
- // Since the dialog has been closed, return FALSE so that we exit the
- // application, rather than start the application's message pump.
- return FALSE;
+ // Since the dialog has been closed, return FALSE so that we exit the
+ // application, rather than start the application's message pump.
+ return FALSE;
}
int CSubresyncApp::ExitInstance()
{
- CoUninitialize();
+ CoUninitialize();
- return CWinApp::ExitInstance();
+ return CWinApp::ExitInstance();
}
diff --git a/src/apps/subresync/subresync.h b/src/apps/subresync/subresync.h
index 4ae374e25..a65478338 100644
--- a/src/apps/subresync/subresync.h
+++ b/src/apps/subresync/subresync.h
@@ -36,16 +36,16 @@
class CSubresyncApp : public CWinApp
{
public:
- CSubresyncApp();
+ CSubresyncApp();
// Overrides
public:
- virtual BOOL InitInstance();
- virtual int ExitInstance();
+ virtual BOOL InitInstance();
+ virtual int ExitInstance();
// Implementation
- DECLARE_MESSAGE_MAP()
+ DECLARE_MESSAGE_MAP()
};
-extern CSubresyncApp theApp; \ No newline at end of file
+extern CSubresyncApp theApp;
diff --git a/src/apps/subresync/subresync.sln b/src/apps/subresync/subresync.sln
new file mode 100644
index 000000000..b523f517d
--- /dev/null
+++ b/src/apps/subresync/subresync.sln
@@ -0,0 +1,36 @@
+Microsoft Visual Studio Solution File, Format Version 10.00
+# Visual Studio 2008
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "subresync", "subresync.vcproj", "{0B232385-29E3-4F64-92F6-1029204A08F3}"
+ ProjectSection(ProjectDependencies) = postProject
+ {5E56335F-0FB1-4EEA-B240-D8DC5E0608E4} = {5E56335F-0FB1-4EEA-B240-D8DC5E0608E4}
+ EndProjectSection
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Subtitles", "..\..\Subtitles\Subtitles.vcproj", "{5E56335F-0FB1-4EEA-B240-D8DC5E0608E4}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Win32 = Debug|Win32
+ Debug|x64 = Debug|x64
+ Release|Win32 = Release|Win32
+ Release|x64 = Release|x64
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {0B232385-29E3-4F64-92F6-1029204A08F3}.Debug|Win32.ActiveCfg = Debug|Win32
+ {0B232385-29E3-4F64-92F6-1029204A08F3}.Debug|Win32.Build.0 = Debug|Win32
+ {0B232385-29E3-4F64-92F6-1029204A08F3}.Debug|x64.ActiveCfg = Debug|Win32
+ {0B232385-29E3-4F64-92F6-1029204A08F3}.Release|Win32.ActiveCfg = Release|Win32
+ {0B232385-29E3-4F64-92F6-1029204A08F3}.Release|Win32.Build.0 = Release|Win32
+ {0B232385-29E3-4F64-92F6-1029204A08F3}.Release|x64.ActiveCfg = Release|Win32
+ {5E56335F-0FB1-4EEA-B240-D8DC5E0608E4}.Debug|Win32.ActiveCfg = Debug|Win32
+ {5E56335F-0FB1-4EEA-B240-D8DC5E0608E4}.Debug|Win32.Build.0 = Debug|Win32
+ {5E56335F-0FB1-4EEA-B240-D8DC5E0608E4}.Debug|x64.ActiveCfg = Debug|x64
+ {5E56335F-0FB1-4EEA-B240-D8DC5E0608E4}.Debug|x64.Build.0 = Debug|x64
+ {5E56335F-0FB1-4EEA-B240-D8DC5E0608E4}.Release|Win32.ActiveCfg = Release|Win32
+ {5E56335F-0FB1-4EEA-B240-D8DC5E0608E4}.Release|Win32.Build.0 = Release|Win32
+ {5E56335F-0FB1-4EEA-B240-D8DC5E0608E4}.Release|x64.ActiveCfg = Release|x64
+ {5E56335F-0FB1-4EEA-B240-D8DC5E0608E4}.Release|x64.Build.0 = Release|x64
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+EndGlobal
diff --git a/src/apps/subresync/subresync.vcproj b/src/apps/subresync/subresync.vcproj
new file mode 100644
index 000000000..4dab723d4
--- /dev/null
+++ b/src/apps/subresync/subresync.vcproj
@@ -0,0 +1,260 @@
+<?xml version="1.0" encoding="windows-1250"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="9,00"
+ Name="subresync"
+ ProjectGUID="{0B232385-29E3-4F64-92F6-1029204A08F3}"
+ RootNamespace="subresync"
+ Keyword="MFCProj"
+ TargetFrameworkVersion="131072"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug|Win32"
+ OutputDirectory="$(SolutionDir)bin\$(ConfigurationName)_$(PlatformName)\"
+ ConfigurationType="1"
+ InheritedPropertySheets="..\..\common.vsprops;..\..\debug.vsprops"
+ UseOfMFC="1"
+ CharacterSet="2"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ PreprocessorDefinitions="_DEBUG"
+ MkTypLibCompatible="false"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories=""
+ PreprocessorDefinitions="WIN32;_WINDOWS;_DEBUG"
+ UsePrecompiledHeader="2"
+ DebugInformationFormat="4"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ PreprocessorDefinitions="_DEBUG"
+ Culture="1033"
+ AdditionalIncludeDirectories="$(IntDir)"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ LinkIncremental="2"
+ GenerateDebugInformation="true"
+ SubSystem="2"
+ RandomizedBaseAddress="1"
+ DataExecutionPrevention="0"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release|Win32"
+ OutputDirectory="$(SolutionDir)bin\$(ConfigurationName)_$(PlatformName)\"
+ ConfigurationType="1"
+ InheritedPropertySheets="..\..\common.vsprops;..\..\release.vsprops"
+ UseOfMFC="1"
+ CharacterSet="2"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ PreprocessorDefinitions="NDEBUG"
+ MkTypLibCompatible="false"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="2"
+ AdditionalIncludeDirectories="../../Subtitles"
+ PreprocessorDefinitions="WIN32;_WINDOWS;NDEBUG"
+ DebugInformationFormat="3"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ PreprocessorDefinitions="NDEBUG"
+ Culture="1033"
+ AdditionalIncludeDirectories="$(IntDir)"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ LinkIncremental="1"
+ GenerateDebugInformation="true"
+ SubSystem="2"
+ RandomizedBaseAddress="2"
+ DataExecutionPrevention="2"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cxx;def;odl;idl;hpj;bat;asm"
+ >
+ <File
+ RelativePath="stdafx.cpp"
+ >
+ <FileConfiguration
+ Name="Debug|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ UsePrecompiledHeader="1"
+ />
+ </FileConfiguration>
+ <FileConfiguration
+ Name="Release|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ UsePrecompiledHeader="1"
+ />
+ </FileConfiguration>
+ </File>
+ <File
+ RelativePath="subresync.cpp"
+ >
+ </File>
+ <File
+ RelativePath="subresyncDlg.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl;inc"
+ >
+ <File
+ RelativePath="Resource.h"
+ >
+ </File>
+ <File
+ RelativePath="stdafx.h"
+ >
+ </File>
+ <File
+ RelativePath="subresync.h"
+ >
+ </File>
+ <File
+ RelativePath="subresyncDlg.h"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;jpg;jpeg;jpe;manifest"
+ >
+ <File
+ RelativePath=".\res\bitmap1.bmp"
+ >
+ </File>
+ <File
+ RelativePath=".\res\bitmap2.bmp"
+ >
+ </File>
+ <File
+ RelativePath="res\subresync.ico"
+ >
+ </File>
+ <File
+ RelativePath="res\subresync.manifest"
+ >
+ </File>
+ <File
+ RelativePath="subresync.rc"
+ >
+ </File>
+ <File
+ RelativePath="res\subresync.rc2"
+ >
+ </File>
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/src/apps/subresync/subresyncDlg.cpp b/src/apps/subresync/subresyncDlg.cpp
index 34212133b..3206b1172 100644
--- a/src/apps/subresync/subresyncDlg.cpp
+++ b/src/apps/subresync/subresyncDlg.cpp
@@ -24,27 +24,22 @@
#include "subresync.h"
#include "subresyncDlg.h"
-#ifdef _DEBUG
-#define new DEBUG_NEW
-#endif
-
-
// CAboutDlg dialog used for App About
class CAboutDlg : public CDialog
{
public:
- CAboutDlg();
+ CAboutDlg();
// Dialog Data
- enum { IDD = IDD_ABOUTBOX };
+ enum { IDD = IDD_ABOUTBOX };
protected:
- virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
+ virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
// Implementation
protected:
- DECLARE_MESSAGE_MAP()
+ DECLARE_MESSAGE_MAP()
};
CAboutDlg::CAboutDlg() : CDialog(CAboutDlg::IDD)
@@ -53,7 +48,7 @@ CAboutDlg::CAboutDlg() : CDialog(CAboutDlg::IDD)
void CAboutDlg::DoDataExchange(CDataExchange* pDX)
{
- CDialog::DoDataExchange(pDX);
+ CDialog::DoDataExchange(pDX);
}
BEGIN_MESSAGE_MAP(CAboutDlg, CDialog)
@@ -61,25 +56,22 @@ END_MESSAGE_MAP()
// CSubresyncDlg dialog
-
-
-
CSubresyncDlg::CSubresyncDlg(CWnd* pParent /*=NULL*/)
- : CDialog(CSubresyncDlg::IDD, pParent)
+ : CDialog(CSubresyncDlg::IDD, pParent)
{
- m_hIcon = AfxGetApp()->LoadIcon(IDR_MAINFRAME);
+ m_hIcon = AfxGetApp()->LoadIcon(IDR_MAINFRAME);
}
void CSubresyncDlg::DoDataExchange(CDataExchange* pDX)
{
- CDialog::DoDataExchange(pDX);
+ CDialog::DoDataExchange(pDX);
}
BEGIN_MESSAGE_MAP(CSubresyncDlg, CDialog)
- ON_WM_SYSCOMMAND()
- ON_WM_PAINT()
- ON_WM_QUERYDRAGICON()
- //}}AFX_MSG_MAP
+ ON_WM_SYSCOMMAND()
+ ON_WM_PAINT()
+ ON_WM_QUERYDRAGICON()
+ //}}AFX_MSG_MAP
END_MESSAGE_MAP()
@@ -87,81 +79,81 @@ END_MESSAGE_MAP()
BOOL CSubresyncDlg::OnInitDialog()
{
- CDialog::OnInitDialog();
-
- // Add "About..." menu item to system menu.
-
- // IDM_ABOUTBOX must be in the system command range.
- ASSERT((IDM_ABOUTBOX & 0xFFF0) == IDM_ABOUTBOX);
- ASSERT(IDM_ABOUTBOX < 0xF000);
-
- CMenu* pSysMenu = GetSystemMenu(FALSE);
- if (pSysMenu != NULL)
- {
- CString strAboutMenu;
- strAboutMenu.LoadString(IDS_ABOUTBOX);
- if (!strAboutMenu.IsEmpty())
- {
- pSysMenu->AppendMenu(MF_SEPARATOR);
- pSysMenu->AppendMenu(MF_STRING, IDM_ABOUTBOX, strAboutMenu);
- }
- }
-
- // Set the icon for this dialog. The framework does this automatically
- // when the application's main window is not a dialog
- SetIcon(m_hIcon, TRUE); // Set big icon
- SetIcon(m_hIcon, FALSE); // Set small icon
-
- // TODO: Add extra initialization here
-
- return TRUE; // return TRUE unless you set the focus to a control
+ CDialog::OnInitDialog();
+
+ // Add "About..." menu item to system menu.
+
+ // IDM_ABOUTBOX must be in the system command range.
+ ASSERT((IDM_ABOUTBOX & 0xFFF0) == IDM_ABOUTBOX);
+ ASSERT(IDM_ABOUTBOX < 0xF000);
+
+ CMenu* pSysMenu = GetSystemMenu(FALSE);
+ if (pSysMenu != NULL)
+ {
+ CString strAboutMenu;
+ strAboutMenu.LoadString(IDS_ABOUTBOX);
+ if (!strAboutMenu.IsEmpty())
+ {
+ pSysMenu->AppendMenu(MF_SEPARATOR);
+ pSysMenu->AppendMenu(MF_STRING, IDM_ABOUTBOX, strAboutMenu);
+ }
+ }
+
+ // Set the icon for this dialog. The framework does this automatically
+ // when the application's main window is not a dialog
+ SetIcon(m_hIcon, TRUE); // Set big icon
+ SetIcon(m_hIcon, FALSE); // Set small icon
+
+ // TODO: Add extra initialization here
+
+ return TRUE; // return TRUE unless you set the focus to a control
}
void CSubresyncDlg::OnSysCommand(UINT nID, LPARAM lParam)
{
- if ((nID & 0xFFF0) == IDM_ABOUTBOX)
- {
- CAboutDlg dlgAbout;
- dlgAbout.DoModal();
- }
- else
- {
- CDialog::OnSysCommand(nID, lParam);
- }
+ if ((nID & 0xFFF0) == IDM_ABOUTBOX)
+ {
+ CAboutDlg dlgAbout;
+ dlgAbout.DoModal();
+ }
+ else
+ {
+ CDialog::OnSysCommand(nID, lParam);
+ }
}
// If you add a minimize button to your dialog, you will need the code below
-// to draw the icon. For MFC applications using the document/view model,
-// this is automatically done for you by the framework.
+// to draw the icon. For MFC applications using the document/view model,
+// this is automatically done for you by the framework.
void CSubresyncDlg::OnPaint()
{
- if (IsIconic())
- {
- CPaintDC dc(this); // device context for painting
-
- SendMessage(WM_ICONERASEBKGND, reinterpret_cast<WPARAM>(dc.GetSafeHdc()), 0);
-
- // Center icon in client rectangle
- int cxIcon = GetSystemMetrics(SM_CXICON);
- int cyIcon = GetSystemMetrics(SM_CYICON);
- CRect rect;
- GetClientRect(&rect);
- int x = (rect.Width() - cxIcon + 1) / 2;
- int y = (rect.Height() - cyIcon + 1) / 2;
-
- // Draw the icon
- dc.DrawIcon(x, y, m_hIcon);
- }
- else
- {
- CDialog::OnPaint();
- }
+ if (IsIconic())
+ {
+ CPaintDC dc(this); // device context for painting
+
+ SendMessage(WM_ICONERASEBKGND, reinterpret_cast<WPARAM>(dc.GetSafeHdc()), 0);
+
+ // Center icon in client rectangle
+ int cxIcon = GetSystemMetrics(SM_CXICON);
+ int cyIcon = GetSystemMetrics(SM_CYICON);
+ CRect rect;
+ GetClientRect(&rect);
+ int x = (rect.Width() - cxIcon + 1) / 2;
+ int y = (rect.Height() - cyIcon + 1) / 2;
+
+ // Draw the icon
+ dc.DrawIcon(x, y, m_hIcon);
+ }
+ else
+ {
+ CDialog::OnPaint();
+ }
}
// The system calls this function to obtain the cursor to display while the user drags
-// the minimized window.
+// the minimized window.
HCURSOR CSubresyncDlg::OnQueryDragIcon()
{
- return static_cast<HCURSOR>(m_hIcon);
+ return static_cast<HCURSOR>(m_hIcon);
}
diff --git a/src/apps/subresync/subresyncDlg.h b/src/apps/subresync/subresyncDlg.h
index cabffc113..1b6f9edf0 100644
--- a/src/apps/subresync/subresyncDlg.h
+++ b/src/apps/subresync/subresyncDlg.h
@@ -22,36 +22,40 @@
#pragma once
+#include "stdafx.h"
+#include <GFN.h>
+#include <TextFile.h>
+
class CharImg
{
public:
- CString m_str;
+ CString m_str;
- CSize m_size;
- CAutoVectorPtr<BYTE> m_p;
+ CSize m_size;
+ CAutoVectorPtr<BYTE> m_p;
- // feature list
- int m_topbottom;
+ // feature list
+ int m_topbottom;
- CharImg(DWORD* p, int pitch, CRect r, int* left, int* right, int topbottom, CString str = _T(""));
- CharImg(FILE* f);
- ~CharImg();
+ CharImg(DWORD* p, int pitch, CRect r, int* left, int* right, int topbottom, CString str = _T(""));
+ CharImg(FILE* f);
+ ~CharImg();
- bool Match(CharImg* img);
+ bool Match(CharImg* img);
- bool Write(FILE* f);
- bool Read(FILE* f);
+ bool Write(FILE* f);
+ bool Read(FILE* f);
};
class CharSegment
{
public:
- int* left;
- int* right;
- int h, srow, erow;
+ int* left;
+ int* right;
+ int h, srow, erow;
- CharSegment(int* left, int* right, int h, int srow, int erow);
- ~CharSegment();
+ CharSegment(int* left, int* right, int h, int srow, int erow);
+ ~CharSegment();
};
// CSubresyncDlg dialog
@@ -59,37 +63,37 @@ class CSubresyncDlg : public CDialog
{
// Construction
public:
- CSubresyncDlg(CString fn, CWnd* pParent = NULL); // standard constructor
- virtual ~CSubresyncDlg();
+ CSubresyncDlg(CString fn, CWnd* pParent = NULL); // standard constructor
+ virtual ~CSubresyncDlg();
- bool Open(CString fn, int CharSet = DEFAULT_CHARSET, bool fAppend = false, int timeoff = 0);
- bool Save(CString fn, exttype et, CTextFile::enc e, bool fClearImgLetterDb = false, bool fOcrDll = false);
+ bool Open(CString fn, int CharSet = DEFAULT_CHARSET, bool fAppend = false, int timeoff = 0);
+ bool Save(CString fn, exttype et, CTextFile::enc e, bool fClearImgLetterDb = false, bool fOcrDll = false);
// Dialog Data
- enum { IDD = IDD_SUBRESYNC_DIALOG };
- CListCtrl m_list;
- CButton m_saveasbtn;
- CButton m_resetbtn;
- CButton m_editbtn;
- CButton m_exitbtn;
- BOOL m_fRender;
- CButton m_previewchk;
- BOOL m_fUnlink;
- CButton m_unlinkchk;
- CComboBox m_vslangs;
+ enum { IDD = IDD_SUBRESYNC_DIALOG };
+ CListCtrl m_list;
+ CButton m_saveasbtn;
+ CButton m_resetbtn;
+ CButton m_editbtn;
+ CButton m_exitbtn;
+ BOOL m_fRender;
+ CButton m_previewchk;
+ BOOL m_fUnlink;
+ CButton m_unlinkchk;
+ CComboBox m_vslangs;
protected:
- virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
+ virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
// Implementation
protected:
- HICON m_hIcon;
-
- // Generated message map functions
- virtual BOOL OnInitDialog();
- afx_msg void OnSysCommand(UINT nID, LPARAM lParam);
- afx_msg void OnPaint();
- afx_msg HCURSOR OnQueryDragIcon();
- DECLARE_MESSAGE_MAP()
+ HICON m_hIcon;
+
+ // Generated message map functions
+ virtual BOOL OnInitDialog();
+ afx_msg void OnSysCommand(UINT nID, LPARAM lParam);
+ afx_msg void OnPaint();
+ afx_msg HCURSOR OnQueryDragIcon();
+ DECLARE_MESSAGE_MAP()
};
diff --git a/src/apps/vsconv/stdafx.cpp b/src/apps/vsconv/stdafx.cpp
index 2e7f789a5..b40a03cf9 100644
--- a/src/apps/vsconv/stdafx.cpp
+++ b/src/apps/vsconv/stdafx.cpp
@@ -1,8 +1,5 @@
/*
* $Id$
- * stdafx.cpp : source file that includes just the standard includes
- * vsconv.pch will be the pre-compiled header
- * stdafx.obj will contain the pre-compiled type information
*
* (C) 2003-2005 Gabest
*
@@ -24,5 +21,3 @@
*/
#include "stdafx.h"
-
-
diff --git a/src/apps/vsconv/stdafx.h b/src/apps/vsconv/stdafx.h
index 024ca36dd..1b6626a8c 100644
--- a/src/apps/vsconv/stdafx.h
+++ b/src/apps/vsconv/stdafx.h
@@ -1,8 +1,5 @@
/*
* $Id$
- * stdafx.h : include file for standard system include files,
- * or project specific include files that are used frequently,
- * but are changed infrequently
*
* (C) 2003-2005 Gabest
*
@@ -32,19 +29,7 @@
// Modify the following defines if you have to target a platform prior to the ones specified below.
// Refer to MSDN for the latest info on corresponding values for different platforms.
#ifndef WINVER // Allow use of features specific to Windows 95 and Windows NT 4 or later.
-#define WINVER 0x0400 // Change this to the appropriate value to target Windows 98 and Windows 2000 or later.
-#endif
-
-#ifndef _WIN32_WINNT // Allow use of features specific to Windows NT 4 or later.
-#define _WIN32_WINNT 0x0400 // Change this to the appropriate value to target Windows 98 and Windows 2000 or later.
-#endif
-
-#ifndef _WIN32_WINDOWS // Allow use of features specific to Windows 98 or later.
-#define _WIN32_WINDOWS 0x0410 // Change this to the appropriate value to target Windows Me or later.
-#endif
-
-#ifndef _WIN32_IE // Allow use of features specific to IE 4.0 or later.
-#define _WIN32_IE 0x0400 // Change this to the appropriate value to target IE 5.0 or later.
+#define WINVER 0x0600 // Change this to the appropriate value to target Windows 98 and Windows 2000 or later.
#endif
#define _ATL_CSTRING_EXPLICIT_CONSTRUCTORS // some CString constructors will be explicit
@@ -52,11 +37,12 @@
// turns off MFC's hiding of some common and often safely ignored warning messages
#define _AFX_ALL_WARNINGS
-#include <afxwin.h> // MFC core and standard components
-#include <afxext.h> // MFC extensions
-#include <afxdisp.h> // MFC Automation classes
+#include <afxwin.h> // MFC core and standard components
+#include <afxext.h> // MFC extensions
+#include <afxdisp.h> // MFC Automation classes
+#include <afxdlgs.h>
+#include <atlbase.h>
-#include <afxdtctl.h> // MFC support for Internet Explorer 4 Common Controls
#ifndef _AFX_NO_AFXCMN_SUPPORT
#include <afxcmn.h> // MFC support for Windows Common Controls
#endif // _AFX_NO_AFXCMN_SUPPORT
diff --git a/src/apps/vsconv/vsconv.cpp b/src/apps/vsconv/vsconv.cpp
index e239e22c0..58e0b5586 100644
--- a/src/apps/vsconv/vsconv.cpp
+++ b/src/apps/vsconv/vsconv.cpp
@@ -25,15 +25,10 @@
#include "vsconvDlg.h"
#include "../../subtitles/VobSubFile.h"
-#ifdef _DEBUG
-#define new DEBUG_NEW
-#endif
-
-
// CvsconvApp
BEGIN_MESSAGE_MAP(CvsconvApp, CWinApp)
- ON_COMMAND(ID_HELP, CWinApp::OnHelp)
+ ON_COMMAND(ID_HELP, CWinApp::OnHelp)
END_MESSAGE_MAP()
@@ -41,8 +36,8 @@ END_MESSAGE_MAP()
CvsconvApp::CvsconvApp()
{
- // TODO: add construction code here,
- // Place all significant initialization in InitInstance
+ // TODO: add construction code here,
+ // Place all significant initialization in InitInstance
}
@@ -55,141 +50,141 @@ CvsconvApp theApp;
BOOL CvsconvApp::InitInstance()
{
- // InitCommonControls() is required on Windows XP if an application
- // manifest specifies use of ComCtl32.dll version 6 or later to enable
- // visual styles. Otherwise, any window creation will fail.
- InitCommonControls();
+ // InitCommonControls() is required on Windows XP if an application
+ // manifest specifies use of ComCtl32.dll version 6 or later to enable
+ // visual styles. Otherwise, any window creation will fail.
+ InitCommonControls();
- CWinApp::InitInstance();
+ CWinApp::InitInstance();
- AfxEnableControlContainer();
+ AfxEnableControlContainer();
- // TODO
+ // TODO
// if(__argc > 1)
- {
- CString in, out;
- CVobSubFile::SubFormat sf = CVobSubFile::None;
- int iLang = -1;
- bool fIgnoreForcedOnly = false;
- bool fForcedOnly = false;
-
- try
- {
- for(int i = 1; i < __argc; i++)
- {
- if(__targv[i][0] == '-' || __targv[i][0] == '/')
- {
- CString sw(&__targv[i][1]);
-
- if(sw == _T("f"))
- {
- if(++i < __argc && __targv[i][0] != '-' && __targv[i][0] != '/')
- {
- CString fmt = CString(__targv[i]).MakeLower();
-
- if(fmt == _T("winsubmux"))
- sf = CVobSubFile::WinSubMux;
- else if(fmt == _T("scenarist"))
- sf = CVobSubFile::Scenarist;
- else if(fmt == _T("maestro"))
- sf = CVobSubFile::Maestro;
- else
- throw _T("Unrecognized conversion format");
- }
- else
- throw _T("No conversion format given");
- }
- else if(sw == _T("i"))
- {
- if(++i < __argc && __targv[i][0] != '-' && __targv[i][0] != '/')
- in = __targv[i];
- else
- throw _T("Missing input file");
- }
- else if(sw == _T("o"))
- {
- if(++i < __argc && __targv[i][0] != '-' && __targv[i][0] != '/')
- out = __targv[i];
- else
- throw _T("Missing output file");
- }
- else if(sw == _T("id"))
- {
- if(++i < __argc && __targv[i][0] != '-' && __targv[i][0] != '/')
- iLang = _tcstol(__targv[i], NULL, 10);
- else
- throw _T("Missing stream id");
- }
- else if(sw == _T("ignoreforcedonly"))
- {
- fIgnoreForcedOnly = true;
- }
- else if(sw == _T("forcedonly"))
- {
- fForcedOnly = true;
- }
- }
- }
-
- if(!in.IsEmpty() && !out.IsEmpty() && sf != CVobSubFile::None)
- {
- CVobSubFile vsf(NULL);
-
- if(!vsf.Open(in))
- throw _T("Can't open input");
-
- if(iLang >= 0 && iLang < 32)
- vsf.m_iLang = iLang;
-
- if(fForcedOnly)
- vsf.m_fOnlyShowForcedSubs = true;
-
- if(fIgnoreForcedOnly)
- vsf.m_fOnlyShowForcedSubs = false;
-
- if(!vsf.Save(out, sf))
- throw _T("Can't save output");
-
- return FALSE;
- }
- }
- catch(LPCTSTR msg)
- {
- AfxMessageBox(CString(_T("Error: ")) + msg);
- }
-
- AfxMessageBox(
- _T("Usage: vsconv.exe <switches>\n\n")
- _T("-f \"format\" (winsubmux, scenarist, maestro)\n")
- _T("-i \"input\"\n")
- _T("-o \"output\"\n")
- _T("-id 0-31 (optional)\n")
- _T("-ignoreforcedonly (optional)\n")
- _T("-forcedonly (optional)\n")
- );
-
- return FALSE;
- }
-
- // TODO
- return FALSE;
-
-
- CvsconvDlg dlg;
- m_pMainWnd = &dlg;
- INT_PTR nResponse = dlg.DoModal();
- if (nResponse == IDOK)
- {
- // TODO: Place code here to handle when the dialog is
- // dismissed with OK
- }
- else if (nResponse == IDCANCEL)
- {
- // TODO: Place code here to handle when the dialog is
- // dismissed with Cancel
- }
-
- // Since the dialog has been closed, return FALSE so that we exit the
- // application, rather than start the application's message pump.
- return FALSE;
+ {
+ CString in, out;
+ CVobSubFile::SubFormat sf = CVobSubFile::None;
+ int iLang = -1;
+ bool fIgnoreForcedOnly = false;
+ bool fForcedOnly = false;
+
+ try
+ {
+ for(int i = 1; i < __argc; i++)
+ {
+ if(__targv[i][0] == '-' || __targv[i][0] == '/')
+ {
+ CString sw(&__targv[i][1]);
+
+ if(sw == _T("f"))
+ {
+ if(++i < __argc && __targv[i][0] != '-' && __targv[i][0] != '/')
+ {
+ CString fmt = CString(__targv[i]).MakeLower();
+
+ if(fmt == _T("winsubmux"))
+ sf = CVobSubFile::WinSubMux;
+ else if(fmt == _T("scenarist"))
+ sf = CVobSubFile::Scenarist;
+ else if(fmt == _T("maestro"))
+ sf = CVobSubFile::Maestro;
+ else
+ throw _T("Unrecognized conversion format");
+ }
+ else
+ throw _T("No conversion format given");
+ }
+ else if(sw == _T("i"))
+ {
+ if(++i < __argc && __targv[i][0] != '-' && __targv[i][0] != '/')
+ in = __targv[i];
+ else
+ throw _T("Missing input file");
+ }
+ else if(sw == _T("o"))
+ {
+ if(++i < __argc && __targv[i][0] != '-' && __targv[i][0] != '/')
+ out = __targv[i];
+ else
+ throw _T("Missing output file");
+ }
+ else if(sw == _T("id"))
+ {
+ if(++i < __argc && __targv[i][0] != '-' && __targv[i][0] != '/')
+ iLang = _tcstol(__targv[i], NULL, 10);
+ else
+ throw _T("Missing stream id");
+ }
+ else if(sw == _T("ignoreforcedonly"))
+ {
+ fIgnoreForcedOnly = true;
+ }
+ else if(sw == _T("forcedonly"))
+ {
+ fForcedOnly = true;
+ }
+ }
+ }
+
+ if(!in.IsEmpty() && !out.IsEmpty() && sf != CVobSubFile::None)
+ {
+ CVobSubFile vsf(NULL);
+
+ if(!vsf.Open(in))
+ throw _T("Can't open input");
+
+ if(iLang >= 0 && iLang < 32)
+ vsf.m_iLang = iLang;
+
+ if(fForcedOnly)
+ vsf.m_fOnlyShowForcedSubs = true;
+
+ if(fIgnoreForcedOnly)
+ vsf.m_fOnlyShowForcedSubs = false;
+
+ if(!vsf.Save(out, sf))
+ throw _T("Can't save output");
+
+ return FALSE;
+ }
+ }
+ catch(LPCTSTR msg)
+ {
+ AfxMessageBox(CString(_T("Error: ")) + msg);
+ }
+
+ AfxMessageBox(
+ _T("Usage: vsconv.exe <switches>\n\n")
+ _T("-f \"format\" (winsubmux, scenarist, maestro)\n")
+ _T("-i \"input\"\n")
+ _T("-o \"output\"\n")
+ _T("-id 0-31 (optional)\n")
+ _T("-ignoreforcedonly (optional)\n")
+ _T("-forcedonly (optional)\n")
+ );
+
+ return FALSE;
+ }
+
+ // TODO
+ return FALSE;
+
+
+ CvsconvDlg dlg;
+ m_pMainWnd = &dlg;
+ INT_PTR nResponse = dlg.DoModal();
+ if (nResponse == IDOK)
+ {
+ // TODO: Place code here to handle when the dialog is
+ // dismissed with OK
+ }
+ else if (nResponse == IDCANCEL)
+ {
+ // TODO: Place code here to handle when the dialog is
+ // dismissed with Cancel
+ }
+
+ // Since the dialog has been closed, return FALSE so that we exit the
+ // application, rather than start the application's message pump.
+ return FALSE;
}
diff --git a/src/apps/vsconv/vsconv.h b/src/apps/vsconv/vsconv.h
index f41a3ac40..5c5b5e9a5 100644
--- a/src/apps/vsconv/vsconv.h
+++ b/src/apps/vsconv/vsconv.h
@@ -36,15 +36,15 @@
class CvsconvApp : public CWinApp
{
public:
- CvsconvApp();
+ CvsconvApp();
// Overrides
public:
- virtual BOOL InitInstance();
+ virtual BOOL InitInstance();
// Implementation
- DECLARE_MESSAGE_MAP()
+ DECLARE_MESSAGE_MAP()
};
extern CvsconvApp theApp; \ No newline at end of file
diff --git a/src/apps/vsconv/vsconv.sln b/src/apps/vsconv/vsconv.sln
new file mode 100644
index 000000000..6b83d7821
--- /dev/null
+++ b/src/apps/vsconv/vsconv.sln
@@ -0,0 +1,58 @@
+Microsoft Visual Studio Solution File, Format Version 10.00
+# Visual Studio 2008
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "vsconv", "vsconv.vcproj", "{F655A8A5-A73E-4EE0-89B4-2758055B3768}"
+ ProjectSection(ProjectDependencies) = postProject
+ {D514EA4D-EAFB-47A9-A437-A582CA571251} = {D514EA4D-EAFB-47A9-A437-A582CA571251}
+ {5E56335F-0FB1-4EEA-B240-D8DC5E0608E4} = {5E56335F-0FB1-4EEA-B240-D8DC5E0608E4}
+ {E8A3F6FA-AE1C-4C8E-A0B6-9C8480324EAA} = {E8A3F6FA-AE1C-4C8E-A0B6-9C8480324EAA}
+ EndProjectSection
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Subtitles", "..\..\subtitles\subtitles.vcproj", "{5E56335F-0FB1-4EEA-B240-D8DC5E0608E4}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "BaseClasses", "..\..\filters\BaseClasses\BaseClasses.vcproj", "{E8A3F6FA-AE1C-4C8E-A0B6-9C8480324EAA}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "SubPic", "..\..\SubPic\SubPic.vcproj", "{D514EA4D-EAFB-47A9-A437-A582CA571251}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Win32 = Debug|Win32
+ Debug|x64 = Debug|x64
+ Release|Win32 = Release|Win32
+ Release|x64 = Release|x64
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {F655A8A5-A73E-4EE0-89B4-2758055B3768}.Debug|Win32.ActiveCfg = Debug|Win32
+ {F655A8A5-A73E-4EE0-89B4-2758055B3768}.Debug|Win32.Build.0 = Debug|Win32
+ {F655A8A5-A73E-4EE0-89B4-2758055B3768}.Debug|x64.ActiveCfg = Debug|Win32
+ {F655A8A5-A73E-4EE0-89B4-2758055B3768}.Release|Win32.ActiveCfg = Release|Win32
+ {F655A8A5-A73E-4EE0-89B4-2758055B3768}.Release|Win32.Build.0 = Release|Win32
+ {F655A8A5-A73E-4EE0-89B4-2758055B3768}.Release|x64.ActiveCfg = Release|Win32
+ {5E56335F-0FB1-4EEA-B240-D8DC5E0608E4}.Debug|Win32.ActiveCfg = Debug|Win32
+ {5E56335F-0FB1-4EEA-B240-D8DC5E0608E4}.Debug|Win32.Build.0 = Debug|Win32
+ {5E56335F-0FB1-4EEA-B240-D8DC5E0608E4}.Debug|x64.ActiveCfg = Debug|x64
+ {5E56335F-0FB1-4EEA-B240-D8DC5E0608E4}.Debug|x64.Build.0 = Debug|x64
+ {5E56335F-0FB1-4EEA-B240-D8DC5E0608E4}.Release|Win32.ActiveCfg = Release|Win32
+ {5E56335F-0FB1-4EEA-B240-D8DC5E0608E4}.Release|Win32.Build.0 = Release|Win32
+ {5E56335F-0FB1-4EEA-B240-D8DC5E0608E4}.Release|x64.ActiveCfg = Release|x64
+ {5E56335F-0FB1-4EEA-B240-D8DC5E0608E4}.Release|x64.Build.0 = Release|x64
+ {E8A3F6FA-AE1C-4C8E-A0B6-9C8480324EAA}.Debug|Win32.ActiveCfg = Debug|Win32
+ {E8A3F6FA-AE1C-4C8E-A0B6-9C8480324EAA}.Debug|Win32.Build.0 = Debug|Win32
+ {E8A3F6FA-AE1C-4C8E-A0B6-9C8480324EAA}.Debug|x64.ActiveCfg = Debug|x64
+ {E8A3F6FA-AE1C-4C8E-A0B6-9C8480324EAA}.Debug|x64.Build.0 = Debug|x64
+ {E8A3F6FA-AE1C-4C8E-A0B6-9C8480324EAA}.Release|Win32.ActiveCfg = Release|Win32
+ {E8A3F6FA-AE1C-4C8E-A0B6-9C8480324EAA}.Release|Win32.Build.0 = Release|Win32
+ {E8A3F6FA-AE1C-4C8E-A0B6-9C8480324EAA}.Release|x64.ActiveCfg = Release|x64
+ {E8A3F6FA-AE1C-4C8E-A0B6-9C8480324EAA}.Release|x64.Build.0 = Release|x64
+ {D514EA4D-EAFB-47A9-A437-A582CA571251}.Debug|Win32.ActiveCfg = Debug|Win32
+ {D514EA4D-EAFB-47A9-A437-A582CA571251}.Debug|Win32.Build.0 = Debug|Win32
+ {D514EA4D-EAFB-47A9-A437-A582CA571251}.Debug|x64.ActiveCfg = Debug|x64
+ {D514EA4D-EAFB-47A9-A437-A582CA571251}.Debug|x64.Build.0 = Debug|x64
+ {D514EA4D-EAFB-47A9-A437-A582CA571251}.Release|Win32.ActiveCfg = Release|Win32
+ {D514EA4D-EAFB-47A9-A437-A582CA571251}.Release|Win32.Build.0 = Release|Win32
+ {D514EA4D-EAFB-47A9-A437-A582CA571251}.Release|x64.ActiveCfg = Release|x64
+ {D514EA4D-EAFB-47A9-A437-A582CA571251}.Release|x64.Build.0 = Release|x64
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+EndGlobal
diff --git a/src/apps/vsconv/vsconv.vcproj b/src/apps/vsconv/vsconv.vcproj
new file mode 100644
index 000000000..b60a7f82f
--- /dev/null
+++ b/src/apps/vsconv/vsconv.vcproj
@@ -0,0 +1,271 @@
+<?xml version="1.0" encoding="windows-1250"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="9,00"
+ Name="vsconv"
+ ProjectGUID="{F655A8A5-A73E-4EE0-89B4-2758055B3768}"
+ RootNamespace="vsconv"
+ Keyword="MFCProj"
+ TargetFrameworkVersion="131072"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug|Win32"
+ OutputDirectory="$(ConfigurationName)"
+ ConfigurationType="1"
+ InheritedPropertySheets="..\..\common.vsprops;..\..\debug.vsprops"
+ UseOfMFC="2"
+ CharacterSet="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ PreprocessorDefinitions="_DEBUG"
+ MkTypLibCompatible="false"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="..\..\..\include\atl;..\..\filters\BaseClasses"
+ PreprocessorDefinitions="WIN32;_WINDOWS;_DEBUG"
+ MinimalRebuild="true"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ TreatWChar_tAsBuiltInType="false"
+ UsePrecompiledHeader="2"
+ DebugInformationFormat="4"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ PreprocessorDefinitions="_DEBUG"
+ Culture="1033"
+ AdditionalIncludeDirectories="$(IntDir)"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="Winmm.lib"
+ LinkIncremental="2"
+ AdditionalLibraryDirectories=""
+ GenerateDebugInformation="true"
+ SubSystem="2"
+ RandomizedBaseAddress="1"
+ DataExecutionPrevention="0"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release|Win32"
+ OutputDirectory="$(ConfigurationName)"
+ ConfigurationType="1"
+ InheritedPropertySheets="..\..\common.vsprops;..\..\release.vsprops"
+ UseOfMFC="1"
+ CharacterSet="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ PreprocessorDefinitions="NDEBUG"
+ MkTypLibCompatible="false"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="2"
+ InlineFunctionExpansion="1"
+ OmitFramePointers="true"
+ AdditionalIncludeDirectories="..\..\..\include\atl;..\..\filters\BaseClasses"
+ PreprocessorDefinitions="WIN32;_WINDOWS;NDEBUG"
+ StringPooling="true"
+ MinimalRebuild="false"
+ RuntimeLibrary="0"
+ EnableFunctionLevelLinking="true"
+ TreatWChar_tAsBuiltInType="false"
+ UsePrecompiledHeader="2"
+ DebugInformationFormat="3"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ PreprocessorDefinitions="NDEBUG"
+ Culture="1033"
+ AdditionalIncludeDirectories="$(IntDir)"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ AdditionalDependencies="Winmm.lib"
+ LinkIncremental="1"
+ AdditionalLibraryDirectories=""
+ GenerateDebugInformation="true"
+ SubSystem="2"
+ OptimizeReferences="2"
+ EnableCOMDATFolding="2"
+ RandomizedBaseAddress="1"
+ DataExecutionPrevention="0"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ CommandLine="..\..\..\bin\upx.exe --best --compress-icons=0 &quot;$(TargetPath)&quot;"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cxx;def;odl;idl;hpj;bat;asm"
+ >
+ <File
+ RelativePath="stdafx.cpp"
+ >
+ <FileConfiguration
+ Name="Debug|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ UsePrecompiledHeader="1"
+ />
+ </FileConfiguration>
+ <FileConfiguration
+ Name="Release|Win32"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ UsePrecompiledHeader="1"
+ />
+ </FileConfiguration>
+ </File>
+ <File
+ RelativePath="vsconv.cpp"
+ >
+ </File>
+ <File
+ RelativePath="vsconvDlg.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl;inc"
+ >
+ <File
+ RelativePath="Resource.h"
+ >
+ </File>
+ <File
+ RelativePath="stdafx.h"
+ >
+ </File>
+ <File
+ RelativePath="vsconv.h"
+ >
+ </File>
+ <File
+ RelativePath="vsconvDlg.h"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;jpg;jpeg;jpe;manifest"
+ >
+ <File
+ RelativePath="res\vsconv.ico"
+ >
+ </File>
+ <File
+ RelativePath="res\vsconv.manifest"
+ >
+ </File>
+ <File
+ RelativePath="vsconv.rc"
+ >
+ </File>
+ <File
+ RelativePath="res\vsconv.rc2"
+ >
+ </File>
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff --git a/src/apps/vsconv/vsconvDlg.cpp b/src/apps/vsconv/vsconvDlg.cpp
index 5c1aaa78b..d3c4ea703 100644
--- a/src/apps/vsconv/vsconvDlg.cpp
+++ b/src/apps/vsconv/vsconvDlg.cpp
@@ -24,27 +24,22 @@
#include "vsconv.h"
#include "vsconvDlg.h"
-#ifdef _DEBUG
-#define new DEBUG_NEW
-#endif
-
-
// CAboutDlg dialog used for App About
class CAboutDlg : public CDialog
{
public:
- CAboutDlg();
+ CAboutDlg();
// Dialog Data
- enum { IDD = IDD_ABOUTBOX };
+ enum { IDD = IDS_ABOUTBOX };
protected:
- virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
+ virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
// Implementation
protected:
- DECLARE_MESSAGE_MAP()
+ DECLARE_MESSAGE_MAP()
};
CAboutDlg::CAboutDlg() : CDialog(CAboutDlg::IDD)
@@ -53,7 +48,7 @@ CAboutDlg::CAboutDlg() : CDialog(CAboutDlg::IDD)
void CAboutDlg::DoDataExchange(CDataExchange* pDX)
{
- CDialog::DoDataExchange(pDX);
+ CDialog::DoDataExchange(pDX);
}
BEGIN_MESSAGE_MAP(CAboutDlg, CDialog)
@@ -65,21 +60,21 @@ END_MESSAGE_MAP()
CvsconvDlg::CvsconvDlg(CWnd* pParent /*=NULL*/)
- : CDialog(CvsconvDlg::IDD, pParent)
+ : CDialog(CvsconvDlg::IDD, pParent)
{
- m_hIcon = AfxGetApp()->LoadIcon(IDR_MAINFRAME);
+ m_hIcon = AfxGetApp()->LoadIcon(IDR_MAINFRAME);
}
void CvsconvDlg::DoDataExchange(CDataExchange* pDX)
{
- CDialog::DoDataExchange(pDX);
+ CDialog::DoDataExchange(pDX);
}
BEGIN_MESSAGE_MAP(CvsconvDlg, CDialog)
- ON_WM_SYSCOMMAND()
- ON_WM_PAINT()
- ON_WM_QUERYDRAGICON()
- //}}AFX_MSG_MAP
+ ON_WM_SYSCOMMAND()
+ ON_WM_PAINT()
+ ON_WM_QUERYDRAGICON()
+ //}}AFX_MSG_MAP
END_MESSAGE_MAP()
@@ -87,47 +82,47 @@ END_MESSAGE_MAP()
BOOL CvsconvDlg::OnInitDialog()
{
- CDialog::OnInitDialog();
-
- // Add "About..." menu item to system menu.
-
- // IDM_ABOUTBOX must be in the system command range.
- ASSERT((IDM_ABOUTBOX & 0xFFF0) == IDM_ABOUTBOX);
- ASSERT(IDM_ABOUTBOX < 0xF000);
-
- CMenu* pSysMenu = GetSystemMenu(FALSE);
- if (pSysMenu != NULL)
- {
- CString strAboutMenu;
- strAboutMenu.LoadString(IDS_ABOUTBOX);
- if (!strAboutMenu.IsEmpty())
- {
- pSysMenu->AppendMenu(MF_SEPARATOR);
- pSysMenu->AppendMenu(MF_STRING, IDM_ABOUTBOX, strAboutMenu);
- }
- }
-
- // Set the icon for this dialog. The framework does this automatically
- // when the application's main window is not a dialog
- SetIcon(m_hIcon, TRUE); // Set big icon
- SetIcon(m_hIcon, FALSE); // Set small icon
-
- // TODO: Add extra initialization here
-
- return TRUE; // return TRUE unless you set the focus to a control
+ CDialog::OnInitDialog();
+
+ // Add "About..." menu item to system menu.
+
+ // IDM_ABOUTBOX must be in the system command range.
+ ASSERT((IDM_ABOUTBOX & 0xFFF0) == IDM_ABOUTBOX);
+ ASSERT(IDM_ABOUTBOX < 0xF000);
+
+ CMenu* pSysMenu = GetSystemMenu(FALSE);
+ if (pSysMenu != NULL)
+ {
+ CString strAboutMenu;
+ strAboutMenu.LoadString(IDS_ABOUTBOX);
+ if (!strAboutMenu.IsEmpty())
+ {
+ pSysMenu->AppendMenu(MF_SEPARATOR);
+ pSysMenu->AppendMenu(MF_STRING, IDM_ABOUTBOX, strAboutMenu);
+ }
+ }
+
+ // Set the icon for this dialog. The framework does this automatically
+ // when the application's main window is not a dialog
+ SetIcon(m_hIcon, TRUE); // Set big icon
+ SetIcon(m_hIcon, FALSE); // Set small icon
+
+ // TODO: Add extra initialization here
+
+ return TRUE; // return TRUE unless you set the focus to a control
}
void CvsconvDlg::OnSysCommand(UINT nID, LPARAM lParam)
{
- if ((nID & 0xFFF0) == IDM_ABOUTBOX)
- {
- CAboutDlg dlgAbout;
- dlgAbout.DoModal();
- }
- else
- {
- CDialog::OnSysCommand(nID, lParam);
- }
+ if ((nID & 0xFFF0) == IDM_ABOUTBOX)
+ {
+ CAboutDlg dlgAbout;
+ dlgAbout.DoModal();
+ }
+ else
+ {
+ CDialog::OnSysCommand(nID, lParam);
+ }
}
// If you add a minimize button to your dialog, you will need the code below
@@ -136,32 +131,32 @@ void CvsconvDlg::OnSysCommand(UINT nID, LPARAM lParam)
void CvsconvDlg::OnPaint()
{
- if (IsIconic())
- {
- CPaintDC dc(this); // device context for painting
-
- SendMessage(WM_ICONERASEBKGND, reinterpret_cast<WPARAM>(dc.GetSafeHdc()), 0);
-
- // Center icon in client rectangle
- int cxIcon = GetSystemMetrics(SM_CXICON);
- int cyIcon = GetSystemMetrics(SM_CYICON);
- CRect rect;
- GetClientRect(&rect);
- int x = (rect.Width() - cxIcon + 1) / 2;
- int y = (rect.Height() - cyIcon + 1) / 2;
-
- // Draw the icon
- dc.DrawIcon(x, y, m_hIcon);
- }
- else
- {
- CDialog::OnPaint();
- }
+ if (IsIconic())
+ {
+ CPaintDC dc(this); // device context for painting
+
+ SendMessage(WM_ICONERASEBKGND, reinterpret_cast<WPARAM>(dc.GetSafeHdc()), 0);
+
+ // Center icon in client rectangle
+ int cxIcon = GetSystemMetrics(SM_CXICON);
+ int cyIcon = GetSystemMetrics(SM_CYICON);
+ CRect rect;
+ GetClientRect(&rect);
+ int x = (rect.Width() - cxIcon + 1) / 2;
+ int y = (rect.Height() - cyIcon + 1) / 2;
+
+ // Draw the icon
+ dc.DrawIcon(x, y, m_hIcon);
+ }
+ else
+ {
+ CDialog::OnPaint();
+ }
}
// The system calls this function to obtain the cursor to display while the user drags
// the minimized window.
HCURSOR CvsconvDlg::OnQueryDragIcon()
{
- return static_cast<HCURSOR>(m_hIcon);
+ return static_cast<HCURSOR>(m_hIcon);
}
diff --git a/src/apps/vsconv/vsconvDlg.h b/src/apps/vsconv/vsconvDlg.h
index 227f3ac77..beb2c6b1a 100644
--- a/src/apps/vsconv/vsconvDlg.h
+++ b/src/apps/vsconv/vsconvDlg.h
@@ -28,23 +28,23 @@ class CvsconvDlg : public CDialog
{
// Construction
public:
- CvsconvDlg(CWnd* pParent = NULL); // standard constructor
+ CvsconvDlg(CWnd* pParent = NULL); // standard constructor
// Dialog Data
- enum { IDD = IDD_VSCONV_DIALOG };
+ enum { IDD = IDD_VSCONV_DIALOG };
protected:
- virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
+ virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
// Implementation
protected:
- HICON m_hIcon;
-
- // Generated message map functions
- virtual BOOL OnInitDialog();
- afx_msg void OnSysCommand(UINT nID, LPARAM lParam);
- afx_msg void OnPaint();
- afx_msg HCURSOR OnQueryDragIcon();
- DECLARE_MESSAGE_MAP()
+ HICON m_hIcon;
+
+ // Generated message map functions
+ virtual BOOL OnInitDialog();
+ afx_msg void OnSysCommand(UINT nID, LPARAM lParam);
+ afx_msg void OnPaint();
+ afx_msg HCURSOR OnQueryDragIcon();
+ DECLARE_MESSAGE_MAP()
};
diff --git a/src/filters/PinInfoWnd.cpp b/src/filters/PinInfoWnd.cpp
index ca2acf929..9c652e448 100644
--- a/src/filters/PinInfoWnd.cpp
+++ b/src/filters/PinInfoWnd.cpp
@@ -55,10 +55,18 @@ void CPinInfoWnd::OnDisconnect()
static WNDPROC OldControlProc;
static LRESULT CALLBACK ControlProc(HWND control, UINT message, WPARAM wParam, LPARAM lParam)
{
- if(message == WM_KEYDOWN && LOWORD(wParam)==VK_ESCAPE)
- return 0; // just ignore ESCAPE in edit control
- else
- return CallWindowProc(OldControlProc, control, message, wParam, lParam); // call edit control's own windowproc
+ if(message == WM_KEYDOWN) {
+ if (LOWORD(wParam)==VK_ESCAPE)
+ return 0; // just ignore ESCAPE in edit control
+ if ((LOWORD(wParam)== 'A' || LOWORD(wParam) == 'a')
+ &&(GetKeyState(VK_CONTROL) < 0)) {
+ CEdit *pEdit = (CEdit*)CWnd::FromHandle(control);
+ pEdit->SetSel(0, pEdit->GetWindowTextLength(),TRUE);
+ return 0;
+ }
+ }
+
+ return CallWindowProc(OldControlProc, control, message, wParam, lParam); // call edit control's own windowproc
}
bool CPinInfoWnd::OnActivate()
diff --git a/src/filters/renderer/SyncClock/SyncClock.vcproj b/src/filters/renderer/SyncClock/SyncClock.vcproj
index 0012a5de4..2c5f90f57 100644
--- a/src/filters/renderer/SyncClock/SyncClock.vcproj
+++ b/src/filters/renderer/SyncClock/SyncClock.vcproj
@@ -20,290 +20,6 @@
</ToolFiles>
<Configurations>
<Configuration
- Name="Debug Filter|Win32"
- OutputDirectory="$(SolutionDir)bin\Filters_x86_Debug\"
- ConfigurationType="2"
- InheritedPropertySheets="..\..\..\common.vsprops;..\..\..\debug.vsprops"
- UseOfMFC="1"
- CharacterSet="1"
- >
- <Tool
- Name="VCPreBuildEventTool"
- />
- <Tool
- Name="VCCustomBuildTool"
- />
- <Tool
- Name="VCXMLDataGeneratorTool"
- />
- <Tool
- Name="VCWebServiceProxyGeneratorTool"
- />
- <Tool
- Name="VCMIDLTool"
- />
- <Tool
- Name="VCCLCompilerTool"
- Optimization="0"
- AdditionalIncludeDirectories="..\..\..\..\include;..\..\BaseClasses"
- PreprocessorDefinitions="WIN32;_DEBUG;_USRDLL"
- DebugInformationFormat="4"
- />
- <Tool
- Name="VCManagedResourceCompilerTool"
- />
- <Tool
- Name="VCResourceCompilerTool"
- />
- <Tool
- Name="VCPreLinkEventTool"
- />
- <Tool
- Name="VCLinkerTool"
- AdditionalDependencies="BaseClasses.lib Winmm.lib"
- AdditionalLibraryDirectories="$(SolutionDir)bin\lib\Release_$(PlatformName)"
- ModuleDefinitionFile="SyncClock.def"
- SubSystem="2"
- TargetMachine="1"
- />
- <Tool
- Name="VCALinkTool"
- />
- <Tool
- Name="VCManifestTool"
- />
- <Tool
- Name="VCXDCMakeTool"
- />
- <Tool
- Name="VCBscMakeTool"
- />
- <Tool
- Name="VCFxCopTool"
- />
- <Tool
- Name="VCAppVerifierTool"
- />
- <Tool
- Name="VCPostBuildEventTool"
- />
- </Configuration>
- <Configuration
- Name="Debug Filter|x64"
- OutputDirectory="$(SolutionDir)bin\Filters_x64_Debug\"
- ConfigurationType="2"
- InheritedPropertySheets="..\..\..\common.vsprops;..\..\..\debug.vsprops"
- CharacterSet="1"
- >
- <Tool
- Name="VCPreBuildEventTool"
- />
- <Tool
- Name="VCCustomBuildTool"
- />
- <Tool
- Name="VCXMLDataGeneratorTool"
- />
- <Tool
- Name="VCWebServiceProxyGeneratorTool"
- />
- <Tool
- Name="VCMIDLTool"
- TargetEnvironment="3"
- />
- <Tool
- Name="VCCLCompilerTool"
- AdditionalIncludeDirectories="..\..\..\..\include;..\..\BaseClasses"
- PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;_USRDLL;METRONOME_EXPORTS"
- DebugInformationFormat="3"
- />
- <Tool
- Name="VCManagedResourceCompilerTool"
- />
- <Tool
- Name="VCResourceCompilerTool"
- />
- <Tool
- Name="VCPreLinkEventTool"
- />
- <Tool
- Name="VCLinkerTool"
- AdditionalDependencies="BaseClasses.lib Winmm.lib"
- OutputFile="$(OutDir)\$(ProjectName).ax"
- LinkIncremental="2"
- AdditionalLibraryDirectories="$(SolutionDir)bin\lib\Release_$(PlatformName)"
- ModuleDefinitionFile="SyncClock.def"
- GenerateDebugInformation="true"
- SubSystem="2"
- TargetMachine="17"
- />
- <Tool
- Name="VCALinkTool"
- />
- <Tool
- Name="VCManifestTool"
- />
- <Tool
- Name="VCXDCMakeTool"
- />
- <Tool
- Name="VCBscMakeTool"
- />
- <Tool
- Name="VCFxCopTool"
- />
- <Tool
- Name="VCAppVerifierTool"
- />
- <Tool
- Name="VCPostBuildEventTool"
- />
- </Configuration>
- <Configuration
- Name="Release Filter|Win32"
- OutputDirectory="$(SolutionDir)bin\Filters_x86\"
- ConfigurationType="2"
- InheritedPropertySheets="..\..\..\common.vsprops;..\..\..\release.vsprops"
- UseOfMFC="1"
- CharacterSet="1"
- >
- <Tool
- Name="VCPreBuildEventTool"
- />
- <Tool
- Name="VCCustomBuildTool"
- />
- <Tool
- Name="VCXMLDataGeneratorTool"
- />
- <Tool
- Name="VCWebServiceProxyGeneratorTool"
- />
- <Tool
- Name="VCMIDLTool"
- />
- <Tool
- Name="VCCLCompilerTool"
- AdditionalIncludeDirectories="..\..\..\..\include;..\..\BaseClasses"
- PreprocessorDefinitions="WIN32;NDEBUG;_USRDLL"
- DebugInformationFormat="3"
- />
- <Tool
- Name="VCManagedResourceCompilerTool"
- />
- <Tool
- Name="VCResourceCompilerTool"
- />
- <Tool
- Name="VCPreLinkEventTool"
- />
- <Tool
- Name="VCLinkerTool"
- AdditionalDependencies="BaseClasses.lib Winmm.lib"
- AdditionalLibraryDirectories="$(SolutionDir)bin\lib\Release_$(PlatformName)"
- ModuleDefinitionFile="SyncClock.def"
- SubSystem="2"
- TargetMachine="1"
- />
- <Tool
- Name="VCALinkTool"
- />
- <Tool
- Name="VCManifestTool"
- />
- <Tool
- Name="VCXDCMakeTool"
- />
- <Tool
- Name="VCBscMakeTool"
- />
- <Tool
- Name="VCFxCopTool"
- />
- <Tool
- Name="VCAppVerifierTool"
- />
- <Tool
- Name="VCPostBuildEventTool"
- />
- </Configuration>
- <Configuration
- Name="Release Filter|x64"
- OutputDirectory="$(SolutionDir)bin\Filters_x64\"
- ConfigurationType="2"
- InheritedPropertySheets="..\..\..\common.vsprops;..\..\..\release.vsprops"
- UseOfMFC="1"
- CharacterSet="1"
- >
- <Tool
- Name="VCPreBuildEventTool"
- />
- <Tool
- Name="VCCustomBuildTool"
- />
- <Tool
- Name="VCXMLDataGeneratorTool"
- />
- <Tool
- Name="VCWebServiceProxyGeneratorTool"
- />
- <Tool
- Name="VCMIDLTool"
- TargetEnvironment="3"
- />
- <Tool
- Name="VCCLCompilerTool"
- Optimization="2"
- AdditionalIncludeDirectories="..\..\..\..\include;..\..\BaseClasses"
- PreprocessorDefinitions="REGISTER_FILTER;WIN32;NDEBUG;_USRDLL"
- EnableEnhancedInstructionSet="0"
- UsePrecompiledHeader="0"
- WarningLevel="3"
- DebugInformationFormat="3"
- CallingConvention="2"
- />
- <Tool
- Name="VCManagedResourceCompilerTool"
- />
- <Tool
- Name="VCResourceCompilerTool"
- />
- <Tool
- Name="VCPreLinkEventTool"
- />
- <Tool
- Name="VCLinkerTool"
- AdditionalDependencies="BaseClasses.lib Winmm.lib"
- OutputFile="$(OutDir)\$(ProjectName).ax"
- AdditionalLibraryDirectories="$(SolutionDir)bin\lib\Release_$(PlatformName)"
- ModuleDefinitionFile="SyncClock.def"
- GenerateDebugInformation="true"
- SubSystem="2"
- TargetMachine="17"
- />
- <Tool
- Name="VCALinkTool"
- />
- <Tool
- Name="VCManifestTool"
- />
- <Tool
- Name="VCXDCMakeTool"
- />
- <Tool
- Name="VCBscMakeTool"
- />
- <Tool
- Name="VCFxCopTool"
- />
- <Tool
- Name="VCAppVerifierTool"
- />
- <Tool
- Name="VCPostBuildEventTool"
- />
- </Configuration>
- <Configuration
Name="Release|Win32"
ConfigurationType="4"
InheritedPropertySheets="..\..\..\common.vsprops;..\..\..\release.vsprops"
diff --git a/src/filters/renderer/SyncClock/SyncClock.vcxproj b/src/filters/renderer/SyncClock/SyncClock.vcxproj
index 0026fac57..d4f749c83 100644
--- a/src/filters/renderer/SyncClock/SyncClock.vcxproj
+++ b/src/filters/renderer/SyncClock/SyncClock.vcxproj
@@ -1,14 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
- <ProjectConfiguration Include="Debug Filter|Win32">
- <Configuration>Debug Filter</Configuration>
- <Platform>Win32</Platform>
- </ProjectConfiguration>
- <ProjectConfiguration Include="Debug Filter|x64">
- <Configuration>Debug Filter</Configuration>
- <Platform>x64</Platform>
- </ProjectConfiguration>
<ProjectConfiguration Include="Debug|Win32">
<Configuration>Debug</Configuration>
<Platform>Win32</Platform>
@@ -17,14 +9,6 @@
<Configuration>Debug</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
- <ProjectConfiguration Include="Release Filter|Win32">
- <Configuration>Release Filter</Configuration>
- <Platform>Win32</Platform>
- </ProjectConfiguration>
- <ProjectConfiguration Include="Release Filter|x64">
- <Configuration>Release Filter</Configuration>
- <Platform>x64</Platform>
- </ProjectConfiguration>
<ProjectConfiguration Include="Release|Win32">
<Configuration>Release</Configuration>
<Platform>Win32</Platform>
@@ -50,16 +34,6 @@
<UseOfMfc>Static</UseOfMfc>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
- <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Filter|Win32'" Label="Configuration">
- <ConfigurationType>DynamicLibrary</ConfigurationType>
- <UseOfMfc>Static</UseOfMfc>
- <CharacterSet>Unicode</CharacterSet>
- </PropertyGroup>
- <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Filter|Win32'" Label="Configuration">
- <ConfigurationType>DynamicLibrary</ConfigurationType>
- <UseOfMfc>Static</UseOfMfc>
- <CharacterSet>Unicode</CharacterSet>
- </PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseOfMfc>Static</UseOfMfc>
@@ -70,15 +44,6 @@
<UseOfMfc>Static</UseOfMfc>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
- <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Filter|x64'" Label="Configuration">
- <ConfigurationType>DynamicLibrary</ConfigurationType>
- <UseOfMfc>Static</UseOfMfc>
- <CharacterSet>Unicode</CharacterSet>
- </PropertyGroup>
- <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Filter|x64'" Label="Configuration">
- <ConfigurationType>DynamicLibrary</ConfigurationType>
- <CharacterSet>Unicode</CharacterSet>
- </PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings">
</ImportGroup>
@@ -92,16 +57,6 @@
<Import Project="..\..\..\common.props" />
<Import Project="..\..\..\release.props" />
</ImportGroup>
- <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release Filter|Win32'" Label="PropertySheets">
- <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
- <Import Project="..\..\..\common.props" />
- <Import Project="..\..\..\release.props" />
- </ImportGroup>
- <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug Filter|Win32'" Label="PropertySheets">
- <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
- <Import Project="..\..\..\common.props" />
- <Import Project="..\..\..\debug.props" />
- </ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
<Import Project="..\..\..\common.props" />
@@ -112,119 +67,10 @@
<Import Project="..\..\..\common.props" />
<Import Project="..\..\..\release.props" />
</ImportGroup>
- <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release Filter|x64'" Label="PropertySheets">
- <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
- <Import Project="..\..\..\common.props" />
- <Import Project="..\..\..\release.props" />
- </ImportGroup>
- <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug Filter|x64'" Label="PropertySheets">
- <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
- <Import Project="..\..\..\common.props" />
- <Import Project="..\..\..\debug.props" />
- </ImportGroup>
<PropertyGroup Label="UserMacros" />
<PropertyGroup>
<_ProjectFileVersion>10.0.30319.1</_ProjectFileVersion>
- <OutDir Condition="'$(Configuration)|$(Platform)'=='Debug Filter|Win32'">$(SolutionDir)bin\Filters_x86_Debug\</OutDir>
- <OutDir Condition="'$(Configuration)|$(Platform)'=='Debug Filter|x64'">$(SolutionDir)bin\Filters_x64_Debug\</OutDir>
- <LinkIncremental Condition="'$(Configuration)|$(Platform)'=='Debug Filter|x64'">true</LinkIncremental>
- <OutDir Condition="'$(Configuration)|$(Platform)'=='Release Filter|Win32'">$(SolutionDir)bin\Filters_x86\</OutDir>
- <OutDir Condition="'$(Configuration)|$(Platform)'=='Release Filter|x64'">$(SolutionDir)bin\Filters_x64\</OutDir>
- <TargetExt Condition="'$(Configuration)|$(Platform)'=='Release Filter|Win32'">.ax</TargetExt>
- <TargetExt Condition="'$(Configuration)|$(Platform)'=='Release Filter|x64'">.ax</TargetExt>
- <TargetExt Condition="'$(Configuration)|$(Platform)'=='Debug Filter|Win32'">.ax</TargetExt>
- <TargetExt Condition="'$(Configuration)|$(Platform)'=='Debug Filter|x64'">.ax</TargetExt>
</PropertyGroup>
- <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug Filter|Win32'">
- <ClCompile>
- <AdditionalIncludeDirectories>..\..\..\..\include;..\..\BaseClasses;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
- <PreprocessorDefinitions>WIN32;_DEBUG;_USRDLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
- <PrecompiledHeader>
- </PrecompiledHeader>
- <DebugInformationFormat>EditAndContinue</DebugInformationFormat>
- </ClCompile>
- <Lib>
- <OutputFile>$(OutDir)$(ProjectName).ax</OutputFile>
- <TargetMachine>MachineX86</TargetMachine>
- </Lib>
- <Link>
- <AdditionalLibraryDirectories>$(SolutionDir)bin10\lib\Release_$(Platform)</AdditionalLibraryDirectories>
- <OutputFile>$(OutDir)$(TargetName)$(TargetExt)</OutputFile>
- <AdditionalDependencies>BaseClasses.lib;Winmm.lib;%(AdditionalDependencies)</AdditionalDependencies>
- <ModuleDefinitionFile>SyncClock.def</ModuleDefinitionFile>
- <SubSystem>Windows</SubSystem>
- </Link>
- </ItemDefinitionGroup>
- <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug Filter|x64'">
- <Midl>
- <TargetEnvironment>X64</TargetEnvironment>
- </Midl>
- <ClCompile>
- <AdditionalIncludeDirectories>..\..\..\..\include;..\..\BaseClasses;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
- <PreprocessorDefinitions>WIN32;_DEBUG;_WINDOWS;_USRDLL;METRONOME_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
- <PrecompiledHeader>
- </PrecompiledHeader>
- <DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
- </ClCompile>
- <Link>
- <AdditionalDependencies>BaseClasses.lib;Winmm.lib;%(AdditionalDependencies)</AdditionalDependencies>
- <OutputFile>$(OutDir)$(TargetName)$(TargetExt)</OutputFile>
- <AdditionalLibraryDirectories>$(SolutionDir)bin10\lib\Release_$(Platform)</AdditionalLibraryDirectories>
- <ModuleDefinitionFile>SyncClock.def</ModuleDefinitionFile>
- <GenerateDebugInformation>true</GenerateDebugInformation>
- <SubSystem>Windows</SubSystem>
- <RandomizedBaseAddress>false</RandomizedBaseAddress>
- <DataExecutionPrevention>
- </DataExecutionPrevention>
- <TargetMachine>MachineX64</TargetMachine>
- </Link>
- </ItemDefinitionGroup>
- <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release Filter|Win32'">
- <ClCompile>
- <AdditionalIncludeDirectories>..\..\..\..\include;..\..\BaseClasses;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
- <PreprocessorDefinitions>WIN32;NDEBUG;_USRDLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
- <PrecompiledHeader>
- </PrecompiledHeader>
- <DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
- <MultiProcessorCompilation>true</MultiProcessorCompilation>
- </ClCompile>
- <Lib>
- <AdditionalOptions>/IGNORE:4221 %(AdditionalOptions)</AdditionalOptions>
- <OutputFile>$(OutDir)$(ProjectName).ax</OutputFile>
- <TargetMachine>MachineX86</TargetMachine>
- </Lib>
- <Link>
- <AdditionalLibraryDirectories>$(SolutionDir)bin10\lib\Release_$(Platform)</AdditionalLibraryDirectories>
- <OutputFile>$(OutDir)$(TargetName)$(TargetExt)</OutputFile>
- <AdditionalDependencies>BaseClasses.lib;Winmm.lib;%(AdditionalDependencies)</AdditionalDependencies>
- <ModuleDefinitionFile>SyncClock.def</ModuleDefinitionFile>
- <SubSystem>Windows</SubSystem>
- </Link>
- </ItemDefinitionGroup>
- <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release Filter|x64'">
- <Midl>
- <TargetEnvironment>X64</TargetEnvironment>
- </Midl>
- <ClCompile>
- <AdditionalIncludeDirectories>..\..\..\..\include;..\..\BaseClasses;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
- <PreprocessorDefinitions>REGISTER_FILTER;WIN32;NDEBUG;_USRDLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
- <EnableEnhancedInstructionSet>NotSet</EnableEnhancedInstructionSet>
- <PrecompiledHeader>
- </PrecompiledHeader>
- <DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
- <MultiProcessorCompilation>true</MultiProcessorCompilation>
- </ClCompile>
- <Link>
- <AdditionalDependencies>BaseClasses.lib;Winmm.lib;%(AdditionalDependencies)</AdditionalDependencies>
- <OutputFile>$(OutDir)$(TargetName)$(TargetExt)</OutputFile>
- <AdditionalLibraryDirectories>$(SolutionDir)bin10\lib\Release_$(Platform)</AdditionalLibraryDirectories>
- <IgnoreAllDefaultLibraries>true</IgnoreAllDefaultLibraries>
- <ModuleDefinitionFile>SyncClock.def</ModuleDefinitionFile>
- <GenerateDebugInformation>true</GenerateDebugInformation>
- <SubSystem>Windows</SubSystem>
- <TargetMachine>MachineX64</TargetMachine>
- </Link>
- </ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<ClCompile>
<Optimization>MaxSpeed</Optimization>
diff --git a/src/thirdparty/libpng/CHANGES b/src/thirdparty/libpng/CHANGES
index be63e4084..67c7b7fa9 100644
--- a/src/thirdparty/libpng/CHANGES
+++ b/src/thirdparty/libpng/CHANGES
@@ -2610,6 +2610,76 @@ version 1.4.3rc03 [June 23, 2010]
version 1.4.3 [June 26, 2010]
Updated some of the "last changed" dates.
+version 1.4.4beta01 [July 12, 2010]
+ Removed extraneous new_push_process_row.c file.
+ Revised the "SEE ALSO" style of libpng.3, libpngpf.3, and png.5
+ Removed some newly-added TAB characters from pngpread.c.
+ Fixed some indentation in pngpread.c and pngrutil.c
+ Changed "extern PNG_EXPORT" to "PNG_EXPORT" in png.h (Jan Nijtmans)
+ Changed "extern" to "PNG_EXTERN" in pngpriv.h (except for the 'extern "C" {')
+ Put "#ifndef PNG_EXTERN, #endif" around "#define PNG_EXTERN" in pngpriv.h
+
+version 1.4.4beta02 [July 24, 2010]
+ Added -DNO_PNG_SNPRINTF to CFLAGS in scripts/makefile.dj2
+ Moved the definition of png_snprintf() outside of the enclosing
+ #ifdef blocks in pngconf.h
+ Added a special case typedef of png_longjmp_ptr for WATCOM.
+
+version 1.4.4beta03 [July 24, 2010]
+ Removed reference to cbuilder5/* from Makefile.in and Makefile.am
+ Eliminated the new special case typedef of png_longjmp_ptr for WATCOM
+ and made a special case "#define PNGAPI" in pngconf.h instead.
+
+version 1.4.4beta04 [July 31, 2010]
+ Updated the read macros and functions from 1.5.0beta38.
+
+version 1.4.4beta05 [August 6, 2010]
+ Updated projects/visualc71 so it can find scripts/pnglibconf.h
+ Removed unused png_mem_* defines from pngconf.h.
+ Correct use of _WINDOWS_ in pngconf.h
+
+version 1.4.4beta06 [August 11, 2010]
+ Don't try to use version-script with cygwin/mingw.
+ Revised contrib/gregbook to work under cygwin/mingw.
+
+version 1.4.4beta07 [August 26, 2010]
+ Updated prebuilt aclocal.m4 and ltmain.sh
+ Add .dll.a to the list of extensions to be symlinked by Makefile.am (Yaakov)
+ Updated CMakeLists.txt to use CMAKE_INSTALL_LIBDIR variable; useful for
+ installing libpng in /usr/lib64 (Funda Wang).
+ Revised CMakeLists.txt to put the man pages in share/man/man* not man/man*
+ Revised CMakeLists.txt to make symlinks instead of copies when installing.
+ Changed PNG_LIB_NAME from pngNN to libpngNN in CMakeLists.txt (Philip Lowman)
+ Moved "#include pngusr.h" ahead of PNG_USER_PRIVATEBUILD test in pngconf.h
+ Eliminated a deprecated reference to png_ptr->io_ptr in pngtest.c
+ Eliminated new unnecessary #if tests regarding the sCAL chunk from pngrutil.c
+
+version 1.4.4beta08 [September 2, 2010]
+ Updated the xcode project to work with libpng-1.4.x and added iOS targets
+ for simulator and device (Philippe Hausler).
+
+version 1.4.4rc01 [September 10, 2010]
+ No changes.
+
+version 1.4.4rc02 [September 13, 2010]
+ Revised CMakeLists.txt (Philip Lowman).
+
+version 1.4.4rc03 [September 14, 2010]
+ Removed an extraneous close-double-quote from CMakeLists.txt
+ Eliminated another deprecated reference to png_ptr->io_ptr in pngtest.c
+
+version 1.4.4rc04 [September 16, 2010]
+ Fixed indentation and removed debugging message from CMakeLists.txt
+ Revised autogen.sh to recognize and use $AUTOCONF, $AUTOMAKE, $AUTOHEADER,
+ $AUTOPOINT, $ACLOCAL and $LIBTOOLIZE
+
+version 1.4.4rc05 [September 20, 2010]
+ Rebuilt configure scripts with automake-1.11.1 instead of automake-1.11.
+ Removed unused mkinstalldirs file.
+
+version 1.4.4 [September 23, 2010]
+ No changes.
+
Send comments/corrections/commendations to glennrp at users.sourceforge.net
or to png-mng-implement at lists.sf.net (subscription required; visit
https://lists.sourceforge.net/lists/listinfo/png-mng-implement).
diff --git a/src/thirdparty/libpng/LICENSE b/src/thirdparty/libpng/LICENSE
index 06ce0301a..4766a8746 100644
--- a/src/thirdparty/libpng/LICENSE
+++ b/src/thirdparty/libpng/LICENSE
@@ -10,8 +10,8 @@ this sentence.
This code is released under the libpng license.
-libpng versions 1.2.6, August 15, 2004, through 1.4.3, June 26, 2010, are
-Copyright (c) 2004, 2006-2007 Glenn Randers-Pehrson, and are
+libpng versions 1.2.6, August 15, 2004, through 1.4.4, September 23, 2010, are
+Copyright (c) 2004, 2006-2010 Glenn Randers-Pehrson, and are
distributed according to the same disclaimer and license as libpng-1.2.5
with the following individual added to the list of Contributing Authors
@@ -108,4 +108,4 @@ certification mark of the Open Source Initiative.
Glenn Randers-Pehrson
glennrp at users.sourceforge.net
-June 26, 2010
+September 23, 2010
diff --git a/src/thirdparty/libpng/README b/src/thirdparty/libpng/README
index 4cf825fd0..5d3555197 100644
--- a/src/thirdparty/libpng/README
+++ b/src/thirdparty/libpng/README
@@ -1,4 +1,4 @@
-README for libpng version 1.4.3 - June 26, 2010 (shared library 14.0)
+README for libpng version 1.4.4 - September 23, 2010 (shared library 14.0)
See the note about version numbers near the top of png.h
See INSTALL for instructions on how to install libpng.
@@ -185,9 +185,9 @@ Files in this distribution:
makefile.std => Generic UNIX makefile (cc, creates static
libpng.a)
makefile.elf => Linux/ELF makefile symbol versioning,
- gcc, creates libpng14.so.14.1.4.3)
+ (gcc, creates libpng14.so.14.1.4.4)
makefile.linux => Linux/ELF makefile
- (gcc, creates libpng14.so.14.1.4.3)
+ (gcc, creates libpng14.so.14.1.4.4)
makefile.gcc => Generic makefile (gcc, creates static libpng.a)
makefile.knr => Archaic UNIX Makefile that converts files with
ansi2knr (Requires ansi2knr.c from
@@ -209,12 +209,12 @@ Files in this distribution:
makefile.openbsd => OpenBSD makefile
makefile.sgi => Silicon Graphics IRIX (cc, creates static lib)
makefile.sggcc => Silicon Graphics
- (gcc, creates libpng14.so.14.1.4.3)
+ (gcc, creates libpng14.so.14.1.4.4)
makefile.sunos => Sun makefile
makefile.solaris => Solaris 2.X makefile
- (gcc, creates libpng14.so.14.1.4.3)
+ (gcc, creates libpng14.so.14.1.4.4)
makefile.so9 => Solaris 9 makefile
- (gcc, creates libpng14.so.14.1.4.3)
+ (gcc, creates libpng14.so.14.1.4.4)
makefile.32sunu => Sun Ultra 32-bit makefile
makefile.64sunu => Sun Ultra 64-bit makefile
makefile.sco => For SCO OSr5 ELF and Unixware 7 with Native cc
diff --git a/src/thirdparty/libpng/png.c b/src/thirdparty/libpng/png.c
index 239615dab..4b027649f 100644
--- a/src/thirdparty/libpng/png.c
+++ b/src/thirdparty/libpng/png.c
@@ -17,7 +17,7 @@
#include "pngpriv.h"
/* Generate a compiler error if there is an old png.h in the search path. */
-typedef version_1_4_3 Your_png_h_is_not_version_1_4_3;
+typedef version_1_4_4 Your_png_h_is_not_version_1_4_4;
/* Version information for C files. This had better match the version
* string defined in png.h.
@@ -551,13 +551,13 @@ png_get_copyright(png_structp png_ptr)
#else
#ifdef __STDC__
return ((png_charp) PNG_STRING_NEWLINE \
- "libpng version 1.4.3 - June 26, 2010" PNG_STRING_NEWLINE \
+ "libpng version 1.4.4 - September 23, 2010" PNG_STRING_NEWLINE \
"Copyright (c) 1998-2010 Glenn Randers-Pehrson" PNG_STRING_NEWLINE \
"Copyright (c) 1996-1997 Andreas Dilger" PNG_STRING_NEWLINE \
"Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc." \
PNG_STRING_NEWLINE);
#else
- return ((png_charp) "libpng version 1.4.3 - June 26, 2010\
+ return ((png_charp) "libpng version 1.4.4 - September 23, 2010\
Copyright (c) 1998-2010 Glenn Randers-Pehrson\
Copyright (c) 1996-1997 Andreas Dilger\
Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc.");
diff --git a/src/thirdparty/libpng/png.h b/src/thirdparty/libpng/png.h
index ef6dc8e45..f46e97ce1 100644
--- a/src/thirdparty/libpng/png.h
+++ b/src/thirdparty/libpng/png.h
@@ -1,7 +1,7 @@
/* png.h - header file for PNG reference library
*
- * libpng version 1.4.3 - June 26, 2010
+ * libpng version 1.4.4 - September 23, 2010
* Copyright (c) 1998-2010 Glenn Randers-Pehrson
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
* (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.)
@@ -11,7 +11,7 @@
* Authors and maintainers:
* libpng versions 0.71, May 1995, through 0.88, January 1996: Guy Schalnat
* libpng versions 0.89c, June 1996, through 0.96, May 1997: Andreas Dilger
- * libpng versions 0.97, January 1998, through 1.4.3 - June 26, 2010: Glenn
+ * libpng versions 0.97, January 1998, through 1.4.4 - September 23, 2010: Glenn
* See also "Contributing Authors", below.
*
* Note about libpng version numbers:
@@ -145,6 +145,8 @@
* 1.4.3beta01-05 14 10403 14.so.14.3[.0]
* 1.4.3rc01-03 14 10403 14.so.14.3[.0]
* 1.4.3 14 10403 14.so.14.3[.0]
+ * 1.4.4beta01-08 14 10404 14.so.14.4[.0]
+ * 1.4.4rc01-06 14 10404 14.so.14.4[.0]
*
* Henceforth the source version will match the shared-library major
* and minor numbers; the shared-library major version number will be
@@ -176,7 +178,7 @@
*
* This code is released under the libpng license.
*
- * libpng versions 1.2.6, August 15, 2004, through 1.4.3, June 26, 2010, are
+ * libpng versions 1.2.6, August 15, 2004, through 1.4.4, September 23, 2010, are
* Copyright (c) 2004, 2006-2010 Glenn Randers-Pehrson, and are
* distributed according to the same disclaimer and license as libpng-1.2.5
* with the following individual added to the list of Contributing Authors:
@@ -288,13 +290,13 @@
* Y2K compliance in libpng:
* =========================
*
- * June 26, 2010
+ * September 23, 2010
*
* Since the PNG Development group is an ad-hoc body, we can't make
* an official declaration.
*
* This is your unofficial assurance that libpng from version 0.71 and
- * upward through 1.4.3 are Y2K compliant. It is my belief that earlier
+ * upward through 1.4.4 are Y2K compliant. It is my belief that earlier
* versions were also Y2K compliant.
*
* Libpng only has three year fields. One is a 2-byte unsigned integer
@@ -350,9 +352,9 @@
*/
/* Version information for png.h - this should match the version in png.c */
-#define PNG_LIBPNG_VER_STRING "1.4.3"
+#define PNG_LIBPNG_VER_STRING "1.4.4"
#define PNG_HEADER_VERSION_STRING \
- " libpng version 1.4.3 - June 26, 2010\n"
+ " libpng version 1.4.4 - September 23, 2010\n"
#define PNG_LIBPNG_VER_SONUM 14
#define PNG_LIBPNG_VER_DLLNUM 14
@@ -360,7 +362,7 @@
/* These should match the first 3 components of PNG_LIBPNG_VER_STRING: */
#define PNG_LIBPNG_VER_MAJOR 1
#define PNG_LIBPNG_VER_MINOR 4
-#define PNG_LIBPNG_VER_RELEASE 3
+#define PNG_LIBPNG_VER_RELEASE 4
/* This should match the numeric part of the final component of
* PNG_LIBPNG_VER_STRING, omitting any leading zero:
*/
@@ -390,7 +392,7 @@
* version 1.0.0 was mis-numbered 100 instead of 10000). From
* version 1.0.1 it's xxyyzz, where x=major, y=minor, z=release
*/
-#define PNG_LIBPNG_VER 10403 /* 1.4.3 */
+#define PNG_LIBPNG_VER 10404 /* 1.4.4 */
#ifndef PNG_VERSION_INFO_ONLY
/* Include the compression library's header */
@@ -1474,7 +1476,7 @@ struct png_struct_def
/* This triggers a compiler error in png.c, if png.c and png.h
* do not agree upon the version number.
*/
-typedef png_structp version_1_4_3;
+typedef png_structp version_1_4_4;
typedef png_struct FAR * FAR * png_structpp;
@@ -1485,12 +1487,12 @@ typedef png_struct FAR * FAR * png_structpp;
*/
/* Returns the version number of the library */
-extern PNG_EXPORT(png_uint_32,png_access_version_number) PNGARG((void));
+PNG_EXPORT(png_uint_32,png_access_version_number) PNGARG((void));
/* Tell lib we have already handled the first <num_bytes> magic bytes.
* Handling more than 8 bytes from the beginning of the file is an error.
*/
-extern PNG_EXPORT(void,png_set_sig_bytes) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_sig_bytes) PNGARG((png_structp png_ptr,
int num_bytes));
/* Check sig[start] through sig[start + num_to_check - 1] to see if it's a
@@ -1498,7 +1500,7 @@ extern PNG_EXPORT(void,png_set_sig_bytes) PNGARG((png_structp png_ptr,
* signature, and non-zero otherwise. Having num_to_check == 0 or
* start > 7 will always fail (ie return non-zero).
*/
-extern PNG_EXPORT(int,png_sig_cmp) PNGARG((png_bytep sig, png_size_t start,
+PNG_EXPORT(int,png_sig_cmp) PNGARG((png_bytep sig, png_size_t start,
png_size_t num_to_check));
/* Simple signature checking function. This is the same as calling
@@ -1507,19 +1509,19 @@ extern PNG_EXPORT(int,png_sig_cmp) PNGARG((png_bytep sig, png_size_t start,
#define png_check_sig(sig,n) !png_sig_cmp((sig), 0, (n))
/* Allocate and initialize png_ptr struct for reading, and any other memory. */
-extern PNG_EXPORT(png_structp,png_create_read_struct)
+PNG_EXPORT(png_structp,png_create_read_struct)
PNGARG((png_const_charp user_png_ver, png_voidp error_ptr,
png_error_ptr error_fn, png_error_ptr warn_fn)) PNG_ALLOCATED;
/* Allocate and initialize png_ptr struct for writing, and any other memory */
-extern PNG_EXPORT(png_structp,png_create_write_struct)
+PNG_EXPORT(png_structp,png_create_write_struct)
PNGARG((png_const_charp user_png_ver, png_voidp error_ptr,
png_error_ptr error_fn, png_error_ptr warn_fn)) PNG_ALLOCATED;
-extern PNG_EXPORT(png_size_t,png_get_compression_buffer_size)
+PNG_EXPORT(png_size_t,png_get_compression_buffer_size)
PNGARG((png_structp png_ptr));
-extern PNG_EXPORT(void,png_set_compression_buffer_size)
+PNG_EXPORT(void,png_set_compression_buffer_size)
PNGARG((png_structp png_ptr, png_size_t size));
/* Moved from pngconf.h in 1.4.0 and modified to ensure setjmp/longjmp
@@ -1533,7 +1535,7 @@ extern PNG_EXPORT(void,png_set_compression_buffer_size)
* allocated by the library - the call will return NULL on a mismatch
* indicating an ABI mismatch.
*/
-extern PNG_EXPORT(jmp_buf*, png_set_longjmp_fn)
+PNG_EXPORT(jmp_buf*, png_set_longjmp_fn)
PNGARG((png_structp png_ptr, png_longjmp_ptr longjmp_fn, size_t
jmp_buf_size));
# define png_jmpbuf(png_ptr) \
@@ -1545,170 +1547,170 @@ extern PNG_EXPORT(jmp_buf*, png_set_longjmp_fn)
#ifdef PNG_READ_SUPPORTED
/* Reset the compression stream */
-extern PNG_EXPORT(int,png_reset_zstream) PNGARG((png_structp png_ptr));
+PNG_EXPORT(int,png_reset_zstream) PNGARG((png_structp png_ptr));
#endif
/* New functions added in libpng-1.0.2 (not enabled by default until 1.2.0) */
#ifdef PNG_USER_MEM_SUPPORTED
-extern PNG_EXPORT(png_structp,png_create_read_struct_2)
+PNG_EXPORT(png_structp,png_create_read_struct_2)
PNGARG((png_const_charp user_png_ver, png_voidp error_ptr,
png_error_ptr error_fn, png_error_ptr warn_fn, png_voidp mem_ptr,
png_malloc_ptr malloc_fn, png_free_ptr free_fn)) PNG_ALLOCATED;
-extern PNG_EXPORT(png_structp,png_create_write_struct_2)
+PNG_EXPORT(png_structp,png_create_write_struct_2)
PNGARG((png_const_charp user_png_ver, png_voidp error_ptr,
png_error_ptr error_fn, png_error_ptr warn_fn, png_voidp mem_ptr,
png_malloc_ptr malloc_fn, png_free_ptr free_fn)) PNG_ALLOCATED;
#endif
/* Write the PNG file signature. */
-extern PNG_EXPORT(void,png_write_sig) PNGARG((png_structp png_ptr));
+PNG_EXPORT(void,png_write_sig) PNGARG((png_structp png_ptr));
/* Write a PNG chunk - size, type, (optional) data, CRC. */
-extern PNG_EXPORT(void,png_write_chunk) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_write_chunk) PNGARG((png_structp png_ptr,
png_bytep chunk_name, png_bytep data, png_size_t length));
/* Write the start of a PNG chunk - length and chunk name. */
-extern PNG_EXPORT(void,png_write_chunk_start) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_write_chunk_start) PNGARG((png_structp png_ptr,
png_bytep chunk_name, png_uint_32 length));
/* Write the data of a PNG chunk started with png_write_chunk_start(). */
-extern PNG_EXPORT(void,png_write_chunk_data) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_write_chunk_data) PNGARG((png_structp png_ptr,
png_bytep data, png_size_t length));
/* Finish a chunk started with png_write_chunk_start() (includes CRC). */
-extern PNG_EXPORT(void,png_write_chunk_end) PNGARG((png_structp png_ptr));
+PNG_EXPORT(void,png_write_chunk_end) PNGARG((png_structp png_ptr));
/* Allocate and initialize the info structure */
-extern PNG_EXPORT(png_infop,png_create_info_struct)
+PNG_EXPORT(png_infop,png_create_info_struct)
PNGARG((png_structp png_ptr)) PNG_ALLOCATED;
-extern PNG_EXPORT(void,png_info_init_3) PNGARG((png_infopp info_ptr,
+PNG_EXPORT(void,png_info_init_3) PNGARG((png_infopp info_ptr,
png_size_t png_info_struct_size));
/* Writes all the PNG information before the image. */
-extern PNG_EXPORT(void,png_write_info_before_PLTE) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_write_info_before_PLTE) PNGARG((png_structp png_ptr,
png_infop info_ptr));
-extern PNG_EXPORT(void,png_write_info) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_write_info) PNGARG((png_structp png_ptr,
png_infop info_ptr));
#ifdef PNG_SEQUENTIAL_READ_SUPPORTED
/* Read the information before the actual image data. */
-extern PNG_EXPORT(void,png_read_info) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_read_info) PNGARG((png_structp png_ptr,
png_infop info_ptr));
#endif
#ifdef PNG_TIME_RFC1123_SUPPORTED
-extern PNG_EXPORT(png_charp,png_convert_to_rfc1123)
+PNG_EXPORT(png_charp,png_convert_to_rfc1123)
PNGARG((png_structp png_ptr, png_timep ptime));
#endif
#ifdef PNG_CONVERT_tIME_SUPPORTED
/* Convert from a struct tm to png_time */
-extern PNG_EXPORT(void,png_convert_from_struct_tm) PNGARG((png_timep ptime,
+PNG_EXPORT(void,png_convert_from_struct_tm) PNGARG((png_timep ptime,
struct tm FAR * ttime));
/* Convert from time_t to png_time. Uses gmtime() */
-extern PNG_EXPORT(void,png_convert_from_time_t) PNGARG((png_timep ptime,
+PNG_EXPORT(void,png_convert_from_time_t) PNGARG((png_timep ptime,
time_t ttime));
#endif /* PNG_CONVERT_tIME_SUPPORTED */
#ifdef PNG_READ_EXPAND_SUPPORTED
/* Expand data to 24-bit RGB, or 8-bit grayscale, with alpha if available. */
-extern PNG_EXPORT(void,png_set_expand) PNGARG((png_structp png_ptr));
-extern PNG_EXPORT(void,png_set_expand_gray_1_2_4_to_8) PNGARG((png_structp
+PNG_EXPORT(void,png_set_expand) PNGARG((png_structp png_ptr));
+PNG_EXPORT(void,png_set_expand_gray_1_2_4_to_8) PNGARG((png_structp
png_ptr));
-extern PNG_EXPORT(void,png_set_palette_to_rgb) PNGARG((png_structp png_ptr));
-extern PNG_EXPORT(void,png_set_tRNS_to_alpha) PNGARG((png_structp png_ptr));
+PNG_EXPORT(void,png_set_palette_to_rgb) PNGARG((png_structp png_ptr));
+PNG_EXPORT(void,png_set_tRNS_to_alpha) PNGARG((png_structp png_ptr));
#endif
#if defined(PNG_READ_BGR_SUPPORTED) || defined(PNG_WRITE_BGR_SUPPORTED)
/* Use blue, green, red order for pixels. */
-extern PNG_EXPORT(void,png_set_bgr) PNGARG((png_structp png_ptr));
+PNG_EXPORT(void,png_set_bgr) PNGARG((png_structp png_ptr));
#endif
#ifdef PNG_READ_GRAY_TO_RGB_SUPPORTED
/* Expand the grayscale to 24-bit RGB if necessary. */
-extern PNG_EXPORT(void,png_set_gray_to_rgb) PNGARG((png_structp png_ptr));
+PNG_EXPORT(void,png_set_gray_to_rgb) PNGARG((png_structp png_ptr));
#endif
#ifdef PNG_READ_RGB_TO_GRAY_SUPPORTED
/* Reduce RGB to grayscale. */
#ifdef PNG_FLOATING_POINT_SUPPORTED
-extern PNG_EXPORT(void,png_set_rgb_to_gray) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_rgb_to_gray) PNGARG((png_structp png_ptr,
int error_action, double red, double green ));
#endif
-extern PNG_EXPORT(void,png_set_rgb_to_gray_fixed) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_rgb_to_gray_fixed) PNGARG((png_structp png_ptr,
int error_action, png_fixed_point red, png_fixed_point green ));
-extern PNG_EXPORT(png_byte,png_get_rgb_to_gray_status) PNGARG((png_structp
+PNG_EXPORT(png_byte,png_get_rgb_to_gray_status) PNGARG((png_structp
png_ptr));
#endif
-extern PNG_EXPORT(void,png_build_grayscale_palette) PNGARG((int bit_depth,
+PNG_EXPORT(void,png_build_grayscale_palette) PNGARG((int bit_depth,
png_colorp palette));
#ifdef PNG_READ_STRIP_ALPHA_SUPPORTED
-extern PNG_EXPORT(void,png_set_strip_alpha) PNGARG((png_structp png_ptr));
+PNG_EXPORT(void,png_set_strip_alpha) PNGARG((png_structp png_ptr));
#endif
#if defined(PNG_READ_SWAP_ALPHA_SUPPORTED) || \
defined(PNG_WRITE_SWAP_ALPHA_SUPPORTED)
-extern PNG_EXPORT(void,png_set_swap_alpha) PNGARG((png_structp png_ptr));
+PNG_EXPORT(void,png_set_swap_alpha) PNGARG((png_structp png_ptr));
#endif
#if defined(PNG_READ_INVERT_ALPHA_SUPPORTED) || \
defined(PNG_WRITE_INVERT_ALPHA_SUPPORTED)
-extern PNG_EXPORT(void,png_set_invert_alpha) PNGARG((png_structp png_ptr));
+PNG_EXPORT(void,png_set_invert_alpha) PNGARG((png_structp png_ptr));
#endif
#if defined(PNG_READ_FILLER_SUPPORTED) || defined(PNG_WRITE_FILLER_SUPPORTED)
/* Add a filler byte to 8-bit Gray or 24-bit RGB images. */
-extern PNG_EXPORT(void,png_set_filler) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_filler) PNGARG((png_structp png_ptr,
png_uint_32 filler, int flags));
/* The values of the PNG_FILLER_ defines should NOT be changed */
#define PNG_FILLER_BEFORE 0
#define PNG_FILLER_AFTER 1
/* Add an alpha byte to 8-bit Gray or 24-bit RGB images. */
-extern PNG_EXPORT(void,png_set_add_alpha) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_add_alpha) PNGARG((png_structp png_ptr,
png_uint_32 filler, int flags));
#endif /* PNG_READ_FILLER_SUPPORTED || PNG_WRITE_FILLER_SUPPORTED */
#if defined(PNG_READ_SWAP_SUPPORTED) || defined(PNG_WRITE_SWAP_SUPPORTED)
/* Swap bytes in 16-bit depth files. */
-extern PNG_EXPORT(void,png_set_swap) PNGARG((png_structp png_ptr));
+PNG_EXPORT(void,png_set_swap) PNGARG((png_structp png_ptr));
#endif
#if defined(PNG_READ_PACK_SUPPORTED) || defined(PNG_WRITE_PACK_SUPPORTED)
/* Use 1 byte per pixel in 1, 2, or 4-bit depth files. */
-extern PNG_EXPORT(void,png_set_packing) PNGARG((png_structp png_ptr));
+PNG_EXPORT(void,png_set_packing) PNGARG((png_structp png_ptr));
#endif
#if defined(PNG_READ_PACKSWAP_SUPPORTED) || \
defined(PNG_WRITE_PACKSWAP_SUPPORTED)
/* Swap packing order of pixels in bytes. */
-extern PNG_EXPORT(void,png_set_packswap) PNGARG((png_structp png_ptr));
+PNG_EXPORT(void,png_set_packswap) PNGARG((png_structp png_ptr));
#endif
#if defined(PNG_READ_SHIFT_SUPPORTED) || defined(PNG_WRITE_SHIFT_SUPPORTED)
/* Converts files to legal bit depths. */
-extern PNG_EXPORT(void,png_set_shift) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_shift) PNGARG((png_structp png_ptr,
png_color_8p true_bits));
#endif
#if defined(PNG_READ_INTERLACING_SUPPORTED) || \
defined(PNG_WRITE_INTERLACING_SUPPORTED)
/* Have the code handle the interlacing. Returns the number of passes. */
-extern PNG_EXPORT(int,png_set_interlace_handling) PNGARG((png_structp png_ptr));
+PNG_EXPORT(int,png_set_interlace_handling) PNGARG((png_structp png_ptr));
#endif
#if defined(PNG_READ_INVERT_SUPPORTED) || defined(PNG_WRITE_INVERT_SUPPORTED)
/* Invert monochrome files */
-extern PNG_EXPORT(void,png_set_invert_mono) PNGARG((png_structp png_ptr));
+PNG_EXPORT(void,png_set_invert_mono) PNGARG((png_structp png_ptr));
#endif
#ifdef PNG_READ_BACKGROUND_SUPPORTED
/* Handle alpha and tRNS by replacing with a background color. */
#ifdef PNG_FLOATING_POINT_SUPPORTED
-extern PNG_EXPORT(void,png_set_background) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_background) PNGARG((png_structp png_ptr,
png_color_16p background_color, int background_gamma_code,
int need_expand, double background_gamma));
#endif
@@ -1720,14 +1722,14 @@ extern PNG_EXPORT(void,png_set_background) PNGARG((png_structp png_ptr,
#ifdef PNG_READ_16_TO_8_SUPPORTED
/* Strip the second byte of information from a 16-bit depth file. */
-extern PNG_EXPORT(void,png_set_strip_16) PNGARG((png_structp png_ptr));
+PNG_EXPORT(void,png_set_strip_16) PNGARG((png_structp png_ptr));
#endif
#ifdef PNG_READ_QUANTIZE_SUPPORTED
/* Turn on quantizing, and reduce the palette to the number of colors
* available. Prior to libpng-1.4.2, this was png_set_dither().
*/
-extern PNG_EXPORT(void,png_set_quantize) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_quantize) PNGARG((png_structp png_ptr,
png_colorp palette, int num_palette, int maximum_colors,
png_uint_16p histogram, int full_quantize));
#endif
@@ -1737,7 +1739,7 @@ extern PNG_EXPORT(void,png_set_quantize) PNGARG((png_structp png_ptr,
#ifdef PNG_READ_GAMMA_SUPPORTED
/* Handle gamma correction. Screen_gamma=(display_exponent) */
#ifdef PNG_FLOATING_POINT_SUPPORTED
-extern PNG_EXPORT(void,png_set_gamma) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_gamma) PNGARG((png_structp png_ptr,
double screen_gamma, double default_file_gamma));
#endif
#endif
@@ -1745,73 +1747,73 @@ extern PNG_EXPORT(void,png_set_gamma) PNGARG((png_structp png_ptr,
#ifdef PNG_WRITE_FLUSH_SUPPORTED
/* Set how many lines between output flushes - 0 for no flushing */
-extern PNG_EXPORT(void,png_set_flush) PNGARG((png_structp png_ptr, int nrows));
+PNG_EXPORT(void,png_set_flush) PNGARG((png_structp png_ptr, int nrows));
/* Flush the current PNG output buffer */
-extern PNG_EXPORT(void,png_write_flush) PNGARG((png_structp png_ptr));
+PNG_EXPORT(void,png_write_flush) PNGARG((png_structp png_ptr));
#endif
/* Optional update palette with requested transformations */
-extern PNG_EXPORT(void,png_start_read_image) PNGARG((png_structp png_ptr));
+PNG_EXPORT(void,png_start_read_image) PNGARG((png_structp png_ptr));
/* Optional call to update the users info structure */
-extern PNG_EXPORT(void,png_read_update_info) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_read_update_info) PNGARG((png_structp png_ptr,
png_infop info_ptr));
#ifdef PNG_SEQUENTIAL_READ_SUPPORTED
/* Read one or more rows of image data. */
-extern PNG_EXPORT(void,png_read_rows) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_read_rows) PNGARG((png_structp png_ptr,
png_bytepp row, png_bytepp display_row, png_uint_32 num_rows));
#endif
#ifdef PNG_SEQUENTIAL_READ_SUPPORTED
/* Read a row of data. */
-extern PNG_EXPORT(void,png_read_row) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_read_row) PNGARG((png_structp png_ptr,
png_bytep row,
png_bytep display_row));
#endif
#ifdef PNG_SEQUENTIAL_READ_SUPPORTED
/* Read the whole image into memory at once. */
-extern PNG_EXPORT(void,png_read_image) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_read_image) PNGARG((png_structp png_ptr,
png_bytepp image));
#endif
/* Write a row of image data */
-extern PNG_EXPORT(void,png_write_row) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_write_row) PNGARG((png_structp png_ptr,
png_bytep row));
/* Write a few rows of image data */
-extern PNG_EXPORT(void,png_write_rows) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_write_rows) PNGARG((png_structp png_ptr,
png_bytepp row, png_uint_32 num_rows));
/* Write the image data */
-extern PNG_EXPORT(void,png_write_image) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_write_image) PNGARG((png_structp png_ptr,
png_bytepp image));
/* Write the end of the PNG file. */
-extern PNG_EXPORT(void,png_write_end) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_write_end) PNGARG((png_structp png_ptr,
png_infop info_ptr));
#ifdef PNG_SEQUENTIAL_READ_SUPPORTED
/* Read the end of the PNG file. */
-extern PNG_EXPORT(void,png_read_end) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_read_end) PNGARG((png_structp png_ptr,
png_infop info_ptr));
#endif
/* Free any memory associated with the png_info_struct */
-extern PNG_EXPORT(void,png_destroy_info_struct) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_destroy_info_struct) PNGARG((png_structp png_ptr,
png_infopp info_ptr_ptr));
/* Free any memory associated with the png_struct and the png_info_structs */
-extern PNG_EXPORT(void,png_destroy_read_struct) PNGARG((png_structpp
+PNG_EXPORT(void,png_destroy_read_struct) PNGARG((png_structpp
png_ptr_ptr, png_infopp info_ptr_ptr, png_infopp end_info_ptr_ptr));
/* Free any memory associated with the png_struct and the png_info_structs */
-extern PNG_EXPORT(void,png_destroy_write_struct)
+PNG_EXPORT(void,png_destroy_write_struct)
PNGARG((png_structpp png_ptr_ptr, png_infopp info_ptr_ptr));
/* Set the libpng method of handling chunk CRC errors */
-extern PNG_EXPORT(void,png_set_crc_action) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_crc_action) PNGARG((png_structp png_ptr,
int crit_action, int ancil_action));
/* Values for png_set_crc_action() to say how to handle CRC errors in
@@ -1841,7 +1843,7 @@ extern PNG_EXPORT(void,png_set_crc_action) PNGARG((png_structp png_ptr,
/* Set the filtering method(s) used by libpng. Currently, the only valid
* value for "method" is 0.
*/
-extern PNG_EXPORT(void,png_set_filter) PNGARG((png_structp png_ptr, int method,
+PNG_EXPORT(void,png_set_filter) PNGARG((png_structp png_ptr, int method,
int filters));
/* Flags for png_set_filter() to say which filters to use. The flags
@@ -1898,7 +1900,7 @@ extern PNG_EXPORT(void,png_set_filter) PNGARG((png_structp png_ptr, int method,
* to the UNWEIGHTED method, but with added encoding time/computation.
*/
#ifdef PNG_FLOATING_POINT_SUPPORTED
-extern PNG_EXPORT(void,png_set_filter_heuristics) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_filter_heuristics) PNGARG((png_structp png_ptr,
int heuristic_method, int num_weights, png_doublep filter_weights,
png_doublep filter_costs));
#endif
@@ -1919,19 +1921,19 @@ extern PNG_EXPORT(void,png_set_filter_heuristics) PNGARG((png_structp png_ptr,
* for PNG images, and do considerably fewer caclulations. In the future,
* these values may not correspond directly to the zlib compression levels.
*/
-extern PNG_EXPORT(void,png_set_compression_level) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_compression_level) PNGARG((png_structp png_ptr,
int level));
-extern PNG_EXPORT(void,png_set_compression_mem_level)
+PNG_EXPORT(void,png_set_compression_mem_level)
PNGARG((png_structp png_ptr, int mem_level));
-extern PNG_EXPORT(void,png_set_compression_strategy)
+PNG_EXPORT(void,png_set_compression_strategy)
PNGARG((png_structp png_ptr, int strategy));
-extern PNG_EXPORT(void,png_set_compression_window_bits)
+PNG_EXPORT(void,png_set_compression_window_bits)
PNGARG((png_structp png_ptr, int window_bits));
-extern PNG_EXPORT(void,png_set_compression_method) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_compression_method) PNGARG((png_structp png_ptr,
int method));
/* These next functions are called for input/output, memory, and error
@@ -1945,7 +1947,7 @@ extern PNG_EXPORT(void,png_set_compression_method) PNGARG((png_structp png_ptr,
#ifdef PNG_STDIO_SUPPORTED
/* Initialize the input/output for the PNG file to the default functions. */
-extern PNG_EXPORT(void,png_init_io) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_init_io) PNGARG((png_structp png_ptr,
png_FILE_p fp));
#endif
@@ -1957,11 +1959,11 @@ extern PNG_EXPORT(void,png_init_io) PNGARG((png_structp png_ptr,
* default function will be used.
*/
-extern PNG_EXPORT(void,png_set_error_fn) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_error_fn) PNGARG((png_structp png_ptr,
png_voidp error_ptr, png_error_ptr error_fn, png_error_ptr warning_fn));
/* Return the user pointer associated with the error functions */
-extern PNG_EXPORT(png_voidp,png_get_error_ptr) PNGARG((png_structp png_ptr));
+PNG_EXPORT(png_voidp,png_get_error_ptr) PNGARG((png_structp png_ptr));
/* Replace the default data output functions with a user supplied one(s).
* If buffered output is not used, then output_flush_fn can be set to NULL.
@@ -1973,54 +1975,54 @@ extern PNG_EXPORT(png_voidp,png_get_error_ptr) PNGARG((png_structp png_ptr));
* default flush function, which uses the standard *FILE structure, will
* be used.
*/
-extern PNG_EXPORT(void,png_set_write_fn) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_write_fn) PNGARG((png_structp png_ptr,
png_voidp io_ptr, png_rw_ptr write_data_fn, png_flush_ptr output_flush_fn));
/* Replace the default data input function with a user supplied one. */
-extern PNG_EXPORT(void,png_set_read_fn) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_read_fn) PNGARG((png_structp png_ptr,
png_voidp io_ptr, png_rw_ptr read_data_fn));
/* Return the user pointer associated with the I/O functions */
-extern PNG_EXPORT(png_voidp,png_get_io_ptr) PNGARG((png_structp png_ptr));
+PNG_EXPORT(png_voidp,png_get_io_ptr) PNGARG((png_structp png_ptr));
-extern PNG_EXPORT(void,png_set_read_status_fn) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_read_status_fn) PNGARG((png_structp png_ptr,
png_read_status_ptr read_row_fn));
-extern PNG_EXPORT(void,png_set_write_status_fn) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_write_status_fn) PNGARG((png_structp png_ptr,
png_write_status_ptr write_row_fn));
#ifdef PNG_USER_MEM_SUPPORTED
/* Replace the default memory allocation functions with user supplied one(s). */
-extern PNG_EXPORT(void,png_set_mem_fn) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_mem_fn) PNGARG((png_structp png_ptr,
png_voidp mem_ptr, png_malloc_ptr malloc_fn, png_free_ptr free_fn));
/* Return the user pointer associated with the memory functions */
-extern PNG_EXPORT(png_voidp,png_get_mem_ptr) PNGARG((png_structp png_ptr));
+PNG_EXPORT(png_voidp,png_get_mem_ptr) PNGARG((png_structp png_ptr));
#endif
#ifdef PNG_READ_USER_TRANSFORM_SUPPORTED
-extern PNG_EXPORT(void,png_set_read_user_transform_fn) PNGARG((png_structp
+PNG_EXPORT(void,png_set_read_user_transform_fn) PNGARG((png_structp
png_ptr, png_user_transform_ptr read_user_transform_fn));
#endif
#ifdef PNG_WRITE_USER_TRANSFORM_SUPPORTED
-extern PNG_EXPORT(void,png_set_write_user_transform_fn) PNGARG((png_structp
+PNG_EXPORT(void,png_set_write_user_transform_fn) PNGARG((png_structp
png_ptr, png_user_transform_ptr write_user_transform_fn));
#endif
#if defined(PNG_READ_USER_TRANSFORM_SUPPORTED) || \
defined(PNG_WRITE_USER_TRANSFORM_SUPPORTED)
-extern PNG_EXPORT(void,png_set_user_transform_info) PNGARG((png_structp
+PNG_EXPORT(void,png_set_user_transform_info) PNGARG((png_structp
png_ptr, png_voidp user_transform_ptr, int user_transform_depth,
int user_transform_channels));
/* Return the user pointer associated with the user transform functions */
-extern PNG_EXPORT(png_voidp,png_get_user_transform_ptr)
+PNG_EXPORT(png_voidp,png_get_user_transform_ptr)
PNGARG((png_structp png_ptr));
#endif
#ifdef PNG_USER_CHUNKS_SUPPORTED
-extern PNG_EXPORT(void,png_set_read_user_chunk_fn) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_read_user_chunk_fn) PNGARG((png_structp png_ptr,
png_voidp user_chunk_ptr, png_user_chunk_ptr read_user_chunk_fn));
-extern PNG_EXPORT(png_voidp,png_get_user_chunk_ptr) PNGARG((png_structp
+PNG_EXPORT(png_voidp,png_get_user_chunk_ptr) PNGARG((png_structp
png_ptr));
#endif
@@ -2028,45 +2030,45 @@ extern PNG_EXPORT(png_voidp,png_get_user_chunk_ptr) PNGARG((png_structp
/* Sets the function callbacks for the push reader, and a pointer to a
* user-defined structure available to the callback functions.
*/
-extern PNG_EXPORT(void,png_set_progressive_read_fn) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_progressive_read_fn) PNGARG((png_structp png_ptr,
png_voidp progressive_ptr,
png_progressive_info_ptr info_fn, png_progressive_row_ptr row_fn,
png_progressive_end_ptr end_fn));
/* Returns the user pointer associated with the push read functions */
-extern PNG_EXPORT(png_voidp,png_get_progressive_ptr)
+PNG_EXPORT(png_voidp,png_get_progressive_ptr)
PNGARG((png_structp png_ptr));
/* Function to be called when data becomes available */
-extern PNG_EXPORT(void,png_process_data) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_process_data) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_bytep buffer, png_size_t buffer_size));
/* Function that combines rows. Not very much different than the
* png_combine_row() call. Is this even used?????
*/
-extern PNG_EXPORT(void,png_progressive_combine_row) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_progressive_combine_row) PNGARG((png_structp png_ptr,
png_bytep old_row, png_bytep new_row));
#endif /* PNG_PROGRESSIVE_READ_SUPPORTED */
-extern PNG_EXPORT(png_voidp,png_malloc) PNGARG((png_structp png_ptr,
+PNG_EXPORT(png_voidp,png_malloc) PNGARG((png_structp png_ptr,
png_alloc_size_t size)) PNG_ALLOCATED;
/* Added at libpng version 1.4.0 */
-extern PNG_EXPORT(png_voidp,png_calloc) PNGARG((png_structp png_ptr,
+PNG_EXPORT(png_voidp,png_calloc) PNGARG((png_structp png_ptr,
png_alloc_size_t size)) PNG_ALLOCATED;
/* Added at libpng version 1.2.4 */
-extern PNG_EXPORT(png_voidp,png_malloc_warn) PNGARG((png_structp png_ptr,
+PNG_EXPORT(png_voidp,png_malloc_warn) PNGARG((png_structp png_ptr,
png_alloc_size_t size)) PNG_ALLOCATED;
/* Frees a pointer allocated by png_malloc() */
-extern PNG_EXPORT(void,png_free) PNGARG((png_structp png_ptr, png_voidp ptr));
+PNG_EXPORT(void,png_free) PNGARG((png_structp png_ptr, png_voidp ptr));
/* Free data that was allocated internally */
-extern PNG_EXPORT(void,png_free_data) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_free_data) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_uint_32 free_me, int num));
/* Reassign responsibility for freeing existing data, whether allocated
* by libpng or by the application */
-extern PNG_EXPORT(void,png_data_freer) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_data_freer) PNGARG((png_structp png_ptr,
png_infop info_ptr, int freer, png_uint_32 mask));
/* Assignments for png_data_freer */
#define PNG_DESTROY_WILL_FREE_DATA 1
@@ -2088,45 +2090,45 @@ extern PNG_EXPORT(void,png_data_freer) PNGARG((png_structp png_ptr,
#define PNG_FREE_MUL 0x4220 /* PNG_FREE_SPLT|PNG_FREE_TEXT|PNG_FREE_UNKN */
#ifdef PNG_USER_MEM_SUPPORTED
-extern PNG_EXPORT(png_voidp,png_malloc_default) PNGARG((png_structp png_ptr,
+PNG_EXPORT(png_voidp,png_malloc_default) PNGARG((png_structp png_ptr,
png_alloc_size_t size)) PNG_ALLOCATED;
-extern PNG_EXPORT(void,png_free_default) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_free_default) PNGARG((png_structp png_ptr,
png_voidp ptr));
#endif
#ifndef PNG_NO_ERROR_TEXT
/* Fatal error in PNG image of libpng - can't continue */
-extern PNG_EXPORT(void,png_error) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_error) PNGARG((png_structp png_ptr,
png_const_charp error_message)) PNG_NORETURN;
/* The same, but the chunk name is prepended to the error string. */
-extern PNG_EXPORT(void,png_chunk_error) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_chunk_error) PNGARG((png_structp png_ptr,
png_const_charp error_message)) PNG_NORETURN;
#else
/* Fatal error in PNG image of libpng - can't continue */
-extern PNG_EXPORT(void,png_err) PNGARG((png_structp png_ptr)) PNG_NORETURN;
+PNG_EXPORT(void,png_err) PNGARG((png_structp png_ptr)) PNG_NORETURN;
#endif
/* Non-fatal error in libpng. Can continue, but may have a problem. */
-extern PNG_EXPORT(void,png_warning) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_warning) PNGARG((png_structp png_ptr,
png_const_charp warning_message));
/* Non-fatal error in libpng, chunk name is prepended to message. */
-extern PNG_EXPORT(void,png_chunk_warning) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_chunk_warning) PNGARG((png_structp png_ptr,
png_const_charp warning_message));
#ifdef PNG_BENIGN_ERRORS_SUPPORTED
/* Benign error in libpng. Can continue, but may have a problem.
* User can choose whether to handle as a fatal error or as a warning. */
-extern PNG_EXPORT(void,png_benign_error) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_benign_error) PNGARG((png_structp png_ptr,
png_const_charp warning_message));
/* Same, chunk name is prepended to message. */
-extern PNG_EXPORT(void,png_chunk_benign_error) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_chunk_benign_error) PNGARG((png_structp png_ptr,
png_const_charp warning_message));
-extern PNG_EXPORT(void,png_set_benign_errors) PNGARG((png_structp
+PNG_EXPORT(void,png_set_benign_errors) PNGARG((png_structp
png_ptr, int allowed));
#endif
@@ -2143,108 +2145,108 @@ extern PNG_EXPORT(void,png_set_benign_errors) PNGARG((png_structp
* png_info_struct.
*/
/* Returns "flag" if chunk data is valid in info_ptr. */
-extern PNG_EXPORT(png_uint_32,png_get_valid) PNGARG((png_structp png_ptr,
+PNG_EXPORT(png_uint_32,png_get_valid) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_uint_32 flag));
/* Returns number of bytes needed to hold a transformed row. */
-extern PNG_EXPORT(png_size_t,png_get_rowbytes) PNGARG((png_structp png_ptr,
+PNG_EXPORT(png_size_t,png_get_rowbytes) PNGARG((png_structp png_ptr,
png_infop info_ptr));
#ifdef PNG_INFO_IMAGE_SUPPORTED
/* Returns row_pointers, which is an array of pointers to scanlines that was
* returned from png_read_png().
*/
-extern PNG_EXPORT(png_bytepp,png_get_rows) PNGARG((png_structp png_ptr,
+PNG_EXPORT(png_bytepp,png_get_rows) PNGARG((png_structp png_ptr,
png_infop info_ptr));
/* Set row_pointers, which is an array of pointers to scanlines for use
* by png_write_png().
*/
-extern PNG_EXPORT(void,png_set_rows) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_rows) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_bytepp row_pointers));
#endif
/* Returns number of color channels in image. */
-extern PNG_EXPORT(png_byte,png_get_channels) PNGARG((png_structp png_ptr,
+PNG_EXPORT(png_byte,png_get_channels) PNGARG((png_structp png_ptr,
png_infop info_ptr));
#ifdef PNG_EASY_ACCESS_SUPPORTED
/* Returns image width in pixels. */
-extern PNG_EXPORT(png_uint_32, png_get_image_width) PNGARG((png_structp
+PNG_EXPORT(png_uint_32, png_get_image_width) PNGARG((png_structp
png_ptr, png_infop info_ptr));
/* Returns image height in pixels. */
-extern PNG_EXPORT(png_uint_32, png_get_image_height) PNGARG((png_structp
+PNG_EXPORT(png_uint_32, png_get_image_height) PNGARG((png_structp
png_ptr, png_infop info_ptr));
/* Returns image bit_depth. */
-extern PNG_EXPORT(png_byte, png_get_bit_depth) PNGARG((png_structp
+PNG_EXPORT(png_byte, png_get_bit_depth) PNGARG((png_structp
png_ptr, png_infop info_ptr));
/* Returns image color_type. */
-extern PNG_EXPORT(png_byte, png_get_color_type) PNGARG((png_structp
+PNG_EXPORT(png_byte, png_get_color_type) PNGARG((png_structp
png_ptr, png_infop info_ptr));
/* Returns image filter_type. */
-extern PNG_EXPORT(png_byte, png_get_filter_type) PNGARG((png_structp
+PNG_EXPORT(png_byte, png_get_filter_type) PNGARG((png_structp
png_ptr, png_infop info_ptr));
/* Returns image interlace_type. */
-extern PNG_EXPORT(png_byte, png_get_interlace_type) PNGARG((png_structp
+PNG_EXPORT(png_byte, png_get_interlace_type) PNGARG((png_structp
png_ptr, png_infop info_ptr));
/* Returns image compression_type. */
-extern PNG_EXPORT(png_byte, png_get_compression_type) PNGARG((png_structp
+PNG_EXPORT(png_byte, png_get_compression_type) PNGARG((png_structp
png_ptr, png_infop info_ptr));
/* Returns image resolution in pixels per meter, from pHYs chunk data. */
-extern PNG_EXPORT(png_uint_32, png_get_pixels_per_meter) PNGARG((png_structp
+PNG_EXPORT(png_uint_32, png_get_pixels_per_meter) PNGARG((png_structp
png_ptr, png_infop info_ptr));
-extern PNG_EXPORT(png_uint_32, png_get_x_pixels_per_meter) PNGARG((png_structp
+PNG_EXPORT(png_uint_32, png_get_x_pixels_per_meter) PNGARG((png_structp
png_ptr, png_infop info_ptr));
-extern PNG_EXPORT(png_uint_32, png_get_y_pixels_per_meter) PNGARG((png_structp
+PNG_EXPORT(png_uint_32, png_get_y_pixels_per_meter) PNGARG((png_structp
png_ptr, png_infop info_ptr));
/* Returns pixel aspect ratio, computed from pHYs chunk data. */
#ifdef PNG_FLOATING_POINT_SUPPORTED
-extern PNG_EXPORT(float, png_get_pixel_aspect_ratio) PNGARG((png_structp
+PNG_EXPORT(float, png_get_pixel_aspect_ratio) PNGARG((png_structp
png_ptr, png_infop info_ptr));
#endif
/* Returns image x, y offset in pixels or microns, from oFFs chunk data. */
-extern PNG_EXPORT(png_int_32, png_get_x_offset_pixels) PNGARG((png_structp
+PNG_EXPORT(png_int_32, png_get_x_offset_pixels) PNGARG((png_structp
png_ptr, png_infop info_ptr));
-extern PNG_EXPORT(png_int_32, png_get_y_offset_pixels) PNGARG((png_structp
+PNG_EXPORT(png_int_32, png_get_y_offset_pixels) PNGARG((png_structp
png_ptr, png_infop info_ptr));
-extern PNG_EXPORT(png_int_32, png_get_x_offset_microns) PNGARG((png_structp
+PNG_EXPORT(png_int_32, png_get_x_offset_microns) PNGARG((png_structp
png_ptr, png_infop info_ptr));
-extern PNG_EXPORT(png_int_32, png_get_y_offset_microns) PNGARG((png_structp
+PNG_EXPORT(png_int_32, png_get_y_offset_microns) PNGARG((png_structp
png_ptr, png_infop info_ptr));
#endif /* PNG_EASY_ACCESS_SUPPORTED */
/* Returns pointer to signature string read from PNG header */
-extern PNG_EXPORT(png_bytep,png_get_signature) PNGARG((png_structp png_ptr,
+PNG_EXPORT(png_bytep,png_get_signature) PNGARG((png_structp png_ptr,
png_infop info_ptr));
#ifdef PNG_bKGD_SUPPORTED
-extern PNG_EXPORT(png_uint_32,png_get_bKGD) PNGARG((png_structp png_ptr,
+PNG_EXPORT(png_uint_32,png_get_bKGD) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_color_16p *background));
#endif
#ifdef PNG_bKGD_SUPPORTED
-extern PNG_EXPORT(void,png_set_bKGD) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_bKGD) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_color_16p background));
#endif
#ifdef PNG_cHRM_SUPPORTED
#ifdef PNG_FLOATING_POINT_SUPPORTED
-extern PNG_EXPORT(png_uint_32,png_get_cHRM) PNGARG((png_structp png_ptr,
+PNG_EXPORT(png_uint_32,png_get_cHRM) PNGARG((png_structp png_ptr,
png_infop info_ptr, double *white_x, double *white_y, double *red_x,
double *red_y, double *green_x, double *green_y, double *blue_x,
double *blue_y));
#endif
#ifdef PNG_FIXED_POINT_SUPPORTED
-extern PNG_EXPORT(png_uint_32,png_get_cHRM_fixed) PNGARG((png_structp png_ptr,
+PNG_EXPORT(png_uint_32,png_get_cHRM_fixed) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_fixed_point *int_white_x, png_fixed_point
*int_white_y, png_fixed_point *int_red_x, png_fixed_point *int_red_y,
png_fixed_point *int_green_x, png_fixed_point *int_green_y, png_fixed_point
@@ -2254,12 +2256,12 @@ extern PNG_EXPORT(png_uint_32,png_get_cHRM_fixed) PNGARG((png_structp png_ptr,
#ifdef PNG_cHRM_SUPPORTED
#ifdef PNG_FLOATING_POINT_SUPPORTED
-extern PNG_EXPORT(void,png_set_cHRM) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_cHRM) PNGARG((png_structp png_ptr,
png_infop info_ptr, double white_x, double white_y, double red_x,
double red_y, double green_x, double green_y, double blue_x, double blue_y));
#endif
#ifdef PNG_FIXED_POINT_SUPPORTED
-extern PNG_EXPORT(void,png_set_cHRM_fixed) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_cHRM_fixed) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_fixed_point int_white_x, png_fixed_point int_white_y,
png_fixed_point int_red_x, png_fixed_point int_red_y, png_fixed_point
int_green_x, png_fixed_point int_green_y, png_fixed_point int_blue_x,
@@ -2269,131 +2271,131 @@ extern PNG_EXPORT(void,png_set_cHRM_fixed) PNGARG((png_structp png_ptr,
#ifdef PNG_gAMA_SUPPORTED
#ifdef PNG_FLOATING_POINT_SUPPORTED
-extern PNG_EXPORT(png_uint_32,png_get_gAMA) PNGARG((png_structp png_ptr,
+PNG_EXPORT(png_uint_32,png_get_gAMA) PNGARG((png_structp png_ptr,
png_infop info_ptr, double *file_gamma));
#endif
-extern PNG_EXPORT(png_uint_32,png_get_gAMA_fixed) PNGARG((png_structp png_ptr,
+PNG_EXPORT(png_uint_32,png_get_gAMA_fixed) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_fixed_point *int_file_gamma));
#endif
#ifdef PNG_gAMA_SUPPORTED
#ifdef PNG_FLOATING_POINT_SUPPORTED
-extern PNG_EXPORT(void,png_set_gAMA) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_gAMA) PNGARG((png_structp png_ptr,
png_infop info_ptr, double file_gamma));
#endif
-extern PNG_EXPORT(void,png_set_gAMA_fixed) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_gAMA_fixed) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_fixed_point int_file_gamma));
#endif
#ifdef PNG_hIST_SUPPORTED
-extern PNG_EXPORT(png_uint_32,png_get_hIST) PNGARG((png_structp png_ptr,
+PNG_EXPORT(png_uint_32,png_get_hIST) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_uint_16p *hist));
#endif
#ifdef PNG_hIST_SUPPORTED
-extern PNG_EXPORT(void,png_set_hIST) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_hIST) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_uint_16p hist));
#endif
-extern PNG_EXPORT(png_uint_32,png_get_IHDR) PNGARG((png_structp png_ptr,
+PNG_EXPORT(png_uint_32,png_get_IHDR) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_uint_32 *width, png_uint_32 *height,
int *bit_depth, int *color_type, int *interlace_method,
int *compression_method, int *filter_method));
-extern PNG_EXPORT(void,png_set_IHDR) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_IHDR) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_uint_32 width, png_uint_32 height, int bit_depth,
int color_type, int interlace_method, int compression_method,
int filter_method));
#ifdef PNG_oFFs_SUPPORTED
-extern PNG_EXPORT(png_uint_32,png_get_oFFs) PNGARG((png_structp png_ptr,
+PNG_EXPORT(png_uint_32,png_get_oFFs) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_int_32 *offset_x, png_int_32 *offset_y,
int *unit_type));
#endif
#ifdef PNG_oFFs_SUPPORTED
-extern PNG_EXPORT(void,png_set_oFFs) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_oFFs) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_int_32 offset_x, png_int_32 offset_y,
int unit_type));
#endif
#ifdef PNG_pCAL_SUPPORTED
-extern PNG_EXPORT(png_uint_32,png_get_pCAL) PNGARG((png_structp png_ptr,
+PNG_EXPORT(png_uint_32,png_get_pCAL) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_charp *purpose, png_int_32 *X0, png_int_32 *X1,
int *type, int *nparams, png_charp *units, png_charpp *params));
#endif
#ifdef PNG_pCAL_SUPPORTED
-extern PNG_EXPORT(void,png_set_pCAL) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_pCAL) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_charp purpose, png_int_32 X0, png_int_32 X1,
int type, int nparams, png_charp units, png_charpp params));
#endif
#ifdef PNG_pHYs_SUPPORTED
-extern PNG_EXPORT(png_uint_32,png_get_pHYs) PNGARG((png_structp png_ptr,
+PNG_EXPORT(png_uint_32,png_get_pHYs) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_uint_32 *res_x, png_uint_32 *res_y, int *unit_type));
#endif
#ifdef PNG_pHYs_SUPPORTED
-extern PNG_EXPORT(void,png_set_pHYs) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_pHYs) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_uint_32 res_x, png_uint_32 res_y, int unit_type));
#endif
-extern PNG_EXPORT(png_uint_32,png_get_PLTE) PNGARG((png_structp png_ptr,
+PNG_EXPORT(png_uint_32,png_get_PLTE) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_colorp *palette, int *num_palette));
-extern PNG_EXPORT(void,png_set_PLTE) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_PLTE) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_colorp palette, int num_palette));
#ifdef PNG_sBIT_SUPPORTED
-extern PNG_EXPORT(png_uint_32,png_get_sBIT) PNGARG((png_structp png_ptr,
+PNG_EXPORT(png_uint_32,png_get_sBIT) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_color_8p *sig_bit));
#endif
#ifdef PNG_sBIT_SUPPORTED
-extern PNG_EXPORT(void,png_set_sBIT) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_sBIT) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_color_8p sig_bit));
#endif
#ifdef PNG_sRGB_SUPPORTED
-extern PNG_EXPORT(png_uint_32,png_get_sRGB) PNGARG((png_structp png_ptr,
+PNG_EXPORT(png_uint_32,png_get_sRGB) PNGARG((png_structp png_ptr,
png_infop info_ptr, int *intent));
#endif
#ifdef PNG_sRGB_SUPPORTED
-extern PNG_EXPORT(void,png_set_sRGB) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_sRGB) PNGARG((png_structp png_ptr,
png_infop info_ptr, int intent));
-extern PNG_EXPORT(void,png_set_sRGB_gAMA_and_cHRM) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_sRGB_gAMA_and_cHRM) PNGARG((png_structp png_ptr,
png_infop info_ptr, int intent));
#endif
#ifdef PNG_iCCP_SUPPORTED
-extern PNG_EXPORT(png_uint_32,png_get_iCCP) PNGARG((png_structp png_ptr,
+PNG_EXPORT(png_uint_32,png_get_iCCP) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_charpp name, int *compression_type,
png_charpp profile, png_uint_32 *proflen));
/* Note to maintainer: profile should be png_bytepp */
#endif
#ifdef PNG_iCCP_SUPPORTED
-extern PNG_EXPORT(void,png_set_iCCP) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_iCCP) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_charp name, int compression_type,
png_charp profile, png_uint_32 proflen));
/* Note to maintainer: profile should be png_bytep */
#endif
#ifdef PNG_sPLT_SUPPORTED
-extern PNG_EXPORT(png_uint_32,png_get_sPLT) PNGARG((png_structp png_ptr,
+PNG_EXPORT(png_uint_32,png_get_sPLT) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_sPLT_tpp entries));
#endif
#ifdef PNG_sPLT_SUPPORTED
-extern PNG_EXPORT(void,png_set_sPLT) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_sPLT) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_sPLT_tp entries, int nentries));
#endif
#ifdef PNG_TEXT_SUPPORTED
/* png_get_text also returns the number of text chunks in *num_text */
-extern PNG_EXPORT(png_uint_32,png_get_text) PNGARG((png_structp png_ptr,
+PNG_EXPORT(png_uint_32,png_get_text) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_textp *text_ptr, int *num_text));
#endif
@@ -2405,28 +2407,28 @@ extern PNG_EXPORT(png_uint_32,png_get_text) PNGARG((png_structp png_ptr,
*/
#ifdef PNG_TEXT_SUPPORTED
-extern PNG_EXPORT(void,png_set_text) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_text) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_textp text_ptr, int num_text));
#endif
#ifdef PNG_tIME_SUPPORTED
-extern PNG_EXPORT(png_uint_32,png_get_tIME) PNGARG((png_structp png_ptr,
+PNG_EXPORT(png_uint_32,png_get_tIME) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_timep *mod_time));
#endif
#ifdef PNG_tIME_SUPPORTED
-extern PNG_EXPORT(void,png_set_tIME) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_tIME) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_timep mod_time));
#endif
#ifdef PNG_tRNS_SUPPORTED
-extern PNG_EXPORT(png_uint_32,png_get_tRNS) PNGARG((png_structp png_ptr,
+PNG_EXPORT(png_uint_32,png_get_tRNS) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_bytep *trans_alpha, int *num_trans,
png_color_16p *trans_color));
#endif
#ifdef PNG_tRNS_SUPPORTED
-extern PNG_EXPORT(void,png_set_tRNS) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_tRNS) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_bytep trans_alpha, int num_trans,
png_color_16p trans_color));
#endif
@@ -2436,11 +2438,11 @@ extern PNG_EXPORT(void,png_set_tRNS) PNGARG((png_structp png_ptr,
#ifdef PNG_sCAL_SUPPORTED
#ifdef PNG_FLOATING_POINT_SUPPORTED
-extern PNG_EXPORT(png_uint_32,png_get_sCAL) PNGARG((png_structp png_ptr,
+PNG_EXPORT(png_uint_32,png_get_sCAL) PNGARG((png_structp png_ptr,
png_infop info_ptr, int *unit, double *width, double *height));
#else
#ifdef PNG_FIXED_POINT_SUPPORTED
-extern PNG_EXPORT(png_uint_32,png_get_sCAL_s) PNGARG((png_structp png_ptr,
+PNG_EXPORT(png_uint_32,png_get_sCAL_s) PNGARG((png_structp png_ptr,
png_infop info_ptr, int *unit, png_charpp swidth, png_charpp sheight));
#endif
#endif
@@ -2448,11 +2450,11 @@ extern PNG_EXPORT(png_uint_32,png_get_sCAL_s) PNGARG((png_structp png_ptr,
#ifdef PNG_sCAL_SUPPORTED
#ifdef PNG_FLOATING_POINT_SUPPORTED
-extern PNG_EXPORT(void,png_set_sCAL) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_sCAL) PNGARG((png_structp png_ptr,
png_infop info_ptr, int unit, double width, double height));
#else
#ifdef PNG_FIXED_POINT_SUPPORTED
-extern PNG_EXPORT(void,png_set_sCAL_s) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void,png_set_sCAL_s) PNGARG((png_structp png_ptr,
png_infop info_ptr, int unit, png_charp swidth, png_charp sheight));
#endif
#endif
@@ -2468,17 +2470,17 @@ extern PNG_EXPORT(void,png_set_sCAL_s) PNGARG((png_structp png_ptr,
= 2: keep only if safe-to-copy
= 3: keep even if unsafe-to-copy
*/
-extern PNG_EXPORT(void, png_set_keep_unknown_chunks) PNGARG((png_structp
+PNG_EXPORT(void, png_set_keep_unknown_chunks) PNGARG((png_structp
png_ptr, int keep, png_bytep chunk_list, int num_chunks));
PNG_EXPORT(int,png_handle_as_unknown) PNGARG((png_structp png_ptr, png_bytep
chunk_name));
#endif
#ifdef PNG_UNKNOWN_CHUNKS_SUPPORTED
-extern PNG_EXPORT(void, png_set_unknown_chunks) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void, png_set_unknown_chunks) PNGARG((png_structp png_ptr,
png_infop info_ptr, png_unknown_chunkp unknowns, int num_unknowns));
-extern PNG_EXPORT(void, png_set_unknown_chunk_location)
+PNG_EXPORT(void, png_set_unknown_chunk_location)
PNGARG((png_structp png_ptr, png_infop info_ptr, int chunk, int location));
-extern PNG_EXPORT(png_uint_32,png_get_unknown_chunks) PNGARG((png_structp
+PNG_EXPORT(png_uint_32,png_get_unknown_chunks) PNGARG((png_structp
png_ptr, png_infop info_ptr, png_unknown_chunkpp entries));
#endif
@@ -2486,29 +2488,29 @@ extern PNG_EXPORT(png_uint_32,png_get_unknown_chunks) PNGARG((png_structp
* If you need to turn it off for a chunk that your application has freed,
* you can use png_set_invalid(png_ptr, info_ptr, PNG_INFO_CHNK);
*/
-extern PNG_EXPORT(void, png_set_invalid) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void, png_set_invalid) PNGARG((png_structp png_ptr,
png_infop info_ptr, int mask));
#ifdef PNG_INFO_IMAGE_SUPPORTED
/* The "params" pointer is currently not used and is for future expansion. */
-extern PNG_EXPORT(void, png_read_png) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void, png_read_png) PNGARG((png_structp png_ptr,
png_infop info_ptr,
int transforms,
png_voidp params));
-extern PNG_EXPORT(void, png_write_png) PNGARG((png_structp png_ptr,
+PNG_EXPORT(void, png_write_png) PNGARG((png_structp png_ptr,
png_infop info_ptr,
int transforms,
png_voidp params));
#endif
-extern PNG_EXPORT(png_charp,png_get_copyright) PNGARG((png_structp png_ptr));
-extern PNG_EXPORT(png_charp,png_get_header_ver) PNGARG((png_structp png_ptr));
-extern PNG_EXPORT(png_charp,png_get_header_version) PNGARG((png_structp
+PNG_EXPORT(png_charp,png_get_copyright) PNGARG((png_structp png_ptr));
+PNG_EXPORT(png_charp,png_get_header_ver) PNGARG((png_structp png_ptr));
+PNG_EXPORT(png_charp,png_get_header_version) PNGARG((png_structp
png_ptr));
-extern PNG_EXPORT(png_charp,png_get_libpng_ver) PNGARG((png_structp png_ptr));
+PNG_EXPORT(png_charp,png_get_libpng_ver) PNGARG((png_structp png_ptr));
#ifdef PNG_MNG_FEATURES_SUPPORTED
-extern PNG_EXPORT(png_uint_32,png_permit_mng_features) PNGARG((png_structp
+PNG_EXPORT(png_uint_32,png_permit_mng_features) PNGARG((png_structp
png_ptr, png_uint_32 mng_features_permitted));
#endif
@@ -2522,27 +2524,27 @@ extern PNG_EXPORT(png_uint_32,png_permit_mng_features) PNGARG((png_structp
* messages before passing them to the error or warning handler.
*/
#ifdef PNG_ERROR_NUMBERS_SUPPORTED
-extern PNG_EXPORT(void,png_set_strip_error_numbers) PNGARG((png_structp
+PNG_EXPORT(void,png_set_strip_error_numbers) PNGARG((png_structp
png_ptr, png_uint_32 strip_mode));
#endif
/* Added in libpng-1.2.6 */
#ifdef PNG_SET_USER_LIMITS_SUPPORTED
-extern PNG_EXPORT(void,png_set_user_limits) PNGARG((png_structp
+PNG_EXPORT(void,png_set_user_limits) PNGARG((png_structp
png_ptr, png_uint_32 user_width_max, png_uint_32 user_height_max));
-extern PNG_EXPORT(png_uint_32,png_get_user_width_max) PNGARG((png_structp
+PNG_EXPORT(png_uint_32,png_get_user_width_max) PNGARG((png_structp
png_ptr));
-extern PNG_EXPORT(png_uint_32,png_get_user_height_max) PNGARG((png_structp
+PNG_EXPORT(png_uint_32,png_get_user_height_max) PNGARG((png_structp
png_ptr));
/* Added in libpng-1.4.0 */
-extern PNG_EXPORT(void,png_set_chunk_cache_max) PNGARG((png_structp
+PNG_EXPORT(void,png_set_chunk_cache_max) PNGARG((png_structp
png_ptr, png_uint_32 user_chunk_cache_max));
-extern PNG_EXPORT(png_uint_32,png_get_chunk_cache_max)
+PNG_EXPORT(png_uint_32,png_get_chunk_cache_max)
PNGARG((png_structp png_ptr));
/* Added in libpng-1.4.1 */
-extern PNG_EXPORT(void,png_set_chunk_malloc_max) PNGARG((png_structp
+PNG_EXPORT(void,png_set_chunk_malloc_max) PNGARG((png_structp
png_ptr, png_alloc_size_t user_chunk_cache_max));
-extern PNG_EXPORT(png_alloc_size_t,png_get_chunk_malloc_max)
+PNG_EXPORT(png_alloc_size_t,png_get_chunk_malloc_max)
PNGARG((png_structp png_ptr));
#endif
@@ -2570,9 +2572,9 @@ png_infop info_ptr, png_uint_32 *res_x, png_uint_32 *res_y, int *unit_type));
/* Added in libpng-1.4.0 */
#ifdef PNG_IO_STATE_SUPPORTED
-extern PNG_EXPORT(png_uint_32,png_get_io_state) PNGARG((png_structp png_ptr));
+PNG_EXPORT(png_uint_32,png_get_io_state) PNGARG((png_structp png_ptr));
-extern PNG_EXPORT(png_bytep,png_get_io_chunk_name)
+PNG_EXPORT(png_bytep,png_get_io_chunk_name)
PNGARG((png_structp png_ptr));
/* The flags returned by png_get_io_state() are the following: */
@@ -2638,7 +2640,6 @@ extern PNG_EXPORT(png_bytep,png_get_io_chunk_name)
* The png_get_int_32() routine assumes we are using two's complement
* format for negative values, which is almost certainly true.
*/
-/* We could make special-case BIG_ENDIAN macros that do direct reads here */
# define png_get_uint_32(buf) \
(((png_uint_32)(*(buf)) << 24) + \
((png_uint_32)(*((buf) + 1)) << 16) + \
@@ -2647,35 +2648,32 @@ extern PNG_EXPORT(png_bytep,png_get_io_chunk_name)
# define png_get_uint_16(buf) \
(((png_uint_32)(*(buf)) << 8) + \
((png_uint_32)(*((buf) + 1))))
-#ifdef PNG_GET_INT_32_SUPPORTED
# define png_get_int_32(buf) \
- (((png_int_32)(*(buf)) << 24) + \
- ((png_int_32)(*((buf) + 1)) << 16) + \
- ((png_int_32)(*((buf) + 2)) << 8) + \
- ((png_int_32)(*((buf) + 3))))
-#endif
+ ((png_int_32)((*(buf) & 0x80) \
+ ? -((png_int_32)((png_get_uint_32(buf) ^ 0xffffffff)+1)) \
+ : (png_int_32)png_get_uint_32(buf)))
#else
-extern PNG_EXPORT(png_uint_32,png_get_uint_32) PNGARG((png_bytep buf));
-extern PNG_EXPORT(png_uint_16,png_get_uint_16) PNGARG((png_bytep buf));
+PNG_EXPORT(png_uint_32,png_get_uint_32) PNGARG((png_bytep buf));
+PNG_EXPORT(png_uint_16,png_get_uint_16) PNGARG((png_bytep buf));
#ifdef PNG_GET_INT_32_SUPPORTED
-extern PNG_EXPORT(png_int_32,png_get_int_32) PNGARG((png_bytep buf));
+PNG_EXPORT(png_int_32,png_get_int_32) PNGARG((png_bytep buf));
#endif
#endif
-extern PNG_EXPORT(png_uint_32,png_get_uint_31)
+PNG_EXPORT(png_uint_32,png_get_uint_31)
PNGARG((png_structp png_ptr, png_bytep buf));
/* No png_get_int_16 -- may be added if there's a real need for it. */
/* Place a 32-bit number into a buffer in PNG byte order (big-endian). */
-extern PNG_EXPORT(void,png_save_uint_32)
+PNG_EXPORT(void,png_save_uint_32)
PNGARG((png_bytep buf, png_uint_32 i));
-extern PNG_EXPORT(void,png_save_int_32)
+PNG_EXPORT(void,png_save_int_32)
PNGARG((png_bytep buf, png_int_32 i));
/* Place a 16-bit number into a buffer in PNG byte order.
* The parameter is declared unsigned int, not png_uint_16,
* just to avoid potential problems on pre-ANSI C compilers.
*/
-extern PNG_EXPORT(void,png_save_uint_16)
+PNG_EXPORT(void,png_save_uint_16)
PNGARG((png_bytep buf, unsigned int i));
/* No png_save_int_16 -- may be added if there's a real need for it. */
diff --git a/src/thirdparty/libpng/pngconf.h b/src/thirdparty/libpng/pngconf.h
index 2ebe72d0e..7d1780246 100644
--- a/src/thirdparty/libpng/pngconf.h
+++ b/src/thirdparty/libpng/pngconf.h
@@ -1,7 +1,7 @@
/* pngconf.h - machine configurable file for libpng
*
- * libpng version 1.4.3 - June 26, 2010
+ * libpng version 1.4.4 - September 23, 2010
* For conditions of distribution and use, see copyright notice in png.h
* Copyright (c) 1998-2010 Glenn Randers-Pehrson
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
@@ -44,14 +44,14 @@
* includes the resource compiler for Windows DLL configurations.
*/
#ifdef PNG_USER_CONFIG
+# include "pngusr.h"
# ifndef PNG_USER_PRIVATEBUILD
# define PNG_USER_PRIVATEBUILD
# endif
-# include "pngusr.h"
#endif
/*
- * If you create a private DLL you need to define in "pngusr.h" the followings:
+ * If you create a private DLL you should define in "pngusr.h" the following:
* #define PNG_USER_PRIVATEBUILD <Describes by whom and why this version of
* the DLL was built>
* e.g. #define PNG_USER_PRIVATEBUILD "Build by MyCompany for xyz reasons."
@@ -59,7 +59,7 @@
* distinguish your DLL from those of the official release. These
* correspond to the trailing letters that come after the version
* number and must match your private DLL name>
- * e.g. // private DLL "libpng13gx.dll"
+ * e.g. // private DLL "libpng14gx.dll"
* #define PNG_USER_DLLFNAME_POSTFIX "gx"
*
* The following macros are also at your disposal if you want to complete the
@@ -269,11 +269,19 @@
* #define PNG_NO_STDIO
*/
+#ifdef _WIN32_WCE
+# define PNG_NO_CONSOLE_IO
+# define PNG_NO_STDIO
+# define PNG_NO_TIME_RFC1123
+# ifdef PNG_DEBUG
+# undef PNG_DEBUG
+# endif
+#endif
+
#if !defined(PNG_NO_STDIO) && !defined(PNG_STDIO_SUPPORTED)
# define PNG_STDIO_SUPPORTED
#endif
-
#ifdef PNG_BUILD_DLL
# if !defined(PNG_CONSOLE_IO_SUPPORTED) && !defined(PNG_NO_CONSOLE_IO)
# define PNG_NO_CONSOLE_IO
@@ -439,7 +447,7 @@
/* The following uses const char * instead of char * for error
* and warning message functions, so some compilers won't complain.
- * If you do not want to use const, define PNG_NO_CONST here.
+ * If you do not want to use const, define PNG_NO_CONST.
*/
#ifndef PNG_CONST
@@ -454,8 +462,10 @@
* library that you will not be using. I wish I could figure out how to
* automate this, but I can't do that without making it seriously hard
* on the users. So if you are not using an ability, change the #define
- * to and #undef, and that part of the library will not be compiled. If
- * your linker can't find a function, you may want to make sure the
+ * to an #undef, or pass in PNG_NO_feature and that part of the library
+ * will not be compiled.
+
+ * If your linker can't find a function, you may want to make sure the
* ability is defined here. Some of these depend upon some others being
* defined. I haven't figured out all the interactions here, so you may
* have to experiment awhile to get everything to compile. If you are
@@ -1114,7 +1124,7 @@ typedef unsigned char png_byte;
#else
typedef size_t png_size_t;
#endif
-#define png_sizeof(x) sizeof(x)
+#define png_sizeof(x) (sizeof (x))
/* The following is needed for medium model support. It cannot be in the
* pngpriv.h header. Needs modification for other compilers besides
@@ -1236,6 +1246,13 @@ typedef char FAR * FAR * FAR * png_charppp;
# define PNG_DLL
#endif
+/* If you define PNGAPI, e.g., with compiler option "-DPNGAPI=__stdcall",
+ * you may get warnings regarding the linkage of png_zalloc and png_zfree.
+ * Don't ignore those warnings; you must also reset the default calling
+ * convention in your compiler to match your PNGAPI, and you must build
+ * zlib and your applications the same way you build libpng.
+ */
+
#ifdef __CYGWIN__
# undef PNGAPI
# define PNGAPI __cdecl
@@ -1243,14 +1260,11 @@ typedef char FAR * FAR * FAR * png_charppp;
# define PNG_IMPEXP
#endif
-#define PNG_USE_LOCAL_ARRAYS /* Not used in libpng, defined for legacy apps */
-
-/* If you define PNGAPI, e.g., with compiler option "-DPNGAPI=__stdcall",
- * you may get warnings regarding the linkage of png_zalloc and png_zfree.
- * Don't ignore those warnings; you must also reset the default calling
- * convention in your compiler to match your PNGAPI, and you must build
- * zlib and your applications the same way you build libpng.
- */
+#ifdef __WATCOMC__
+# ifndef PNGAPI
+# define PNGAPI
+# endif
+#endif
#if defined(__MINGW32__) && !defined(PNG_MODULEDEF)
# ifndef PNG_NO_MODULEDEF
@@ -1335,6 +1349,8 @@ typedef char FAR * FAR * FAR * png_charppp;
# define PNG_EXPORT(type,symbol) PNG_IMPEXP type PNGAPI symbol
#endif
+#define PNG_USE_LOCAL_ARRAYS /* Not used in libpng, defined for legacy apps */
+
/* Support for compiler specific function attributes. These are used
* so that where compiler support is available incorrect use of API
* functions in png.h will generate compiler warnings.
@@ -1412,7 +1428,7 @@ typedef char FAR * FAR * FAR * png_charppp;
/* memory model/platform independent fns */
#ifndef PNG_ABORT
-# ifdef _WINDOWS_
+# if (defined(_Windows) || defined(_WINDOWS) || defined(_WINDOWS_))
# define PNG_ABORT() ExitProcess(0)
# else
# define PNG_ABORT() abort()
@@ -1433,7 +1449,8 @@ typedef char FAR * FAR * FAR * png_charppp;
# define png_memset _fmemset
# define png_sprintf sprintf
#else
-# ifdef _WINDOWS_ /* Favor Windows over C runtime fns */
+# if (defined(_Windows) || defined(_WINDOWS) || defined(_WINDOWS_))
+# /* Favor Windows over C runtime fns */
# define CVT_PTR(ptr) (ptr)
# define CVT_PTR_NOCHECK(ptr) (ptr)
# define png_strcpy lstrcpyA
@@ -1453,31 +1470,32 @@ typedef char FAR * FAR * FAR * png_charppp;
# define png_memcpy memcpy
# define png_memset memset
# define png_sprintf sprintf
-# ifndef PNG_NO_SNPRINTF
-# ifdef _MSC_VER
-# define png_snprintf _snprintf /* Added to v 1.2.19 */
-# define png_snprintf2 _snprintf
-# define png_snprintf6 _snprintf
-# else
-# define png_snprintf snprintf /* Added to v 1.2.19 */
-# define png_snprintf2 snprintf
-# define png_snprintf6 snprintf
-# endif
-# else
- /* You don't have or don't want to use snprintf(). Caution: Using
- * sprintf instead of snprintf exposes your application to accidental
- * or malevolent buffer overflows. If you don't have snprintf()
- * as a general rule you should provide one (you can get one from
- * Portable OpenSSH).
- */
-# define png_snprintf(s1,n,fmt,x1) sprintf(s1,fmt,x1)
-# define png_snprintf2(s1,n,fmt,x1,x2) sprintf(s1,fmt,x1,x2)
-# define png_snprintf6(s1,n,fmt,x1,x2,x3,x4,x5,x6) \
- sprintf(s1,fmt,x1,x2,x3,x4,x5,x6)
-# endif
# endif
#endif
+#ifndef PNG_NO_SNPRINTF
+# ifdef _MSC_VER
+# define png_snprintf _snprintf /* Added to v 1.2.19 */
+# define png_snprintf2 _snprintf
+# define png_snprintf6 _snprintf
+# else
+# define png_snprintf snprintf /* Added to v 1.2.19 */
+# define png_snprintf2 snprintf
+# define png_snprintf6 snprintf
+# endif
+#else
+ /* You don't have or don't want to use snprintf(). Caution: Using
+ * sprintf instead of snprintf exposes your application to accidental
+ * or malevolent buffer overflows. If you don't have snprintf()
+ * as a general rule you should provide one (you can get one from
+ * Portable OpenSSH).
+ */
+# define png_snprintf(s1,n,fmt,x1) png_sprintf(s1,fmt,x1)
+# define png_snprintf2(s1,n,fmt,x1,x2) png_sprintf(s1,fmt,x1,x2)
+# define png_snprintf6(s1,n,fmt,x1,x2,x3,x4,x5,x6) \
+ png_sprintf(s1,fmt,x1,x2,x3,x4,x5,x6)
+#endif
+
/* png_alloc_size_t is guaranteed to be no smaller than png_size_t,
* and no smaller than png_uint_32. Casts from png_size_t or png_uint_32
* to png_alloc_size_t are not necessary; in fact, it is recommended
@@ -1488,22 +1506,19 @@ typedef char FAR * FAR * FAR * png_charppp;
* to encounter practical situations that require such conversions.
*/
#if defined(__TURBOC__) && !defined(__FLAT__)
-# define png_mem_alloc farmalloc
-# define png_mem_free farfree
typedef unsigned long png_alloc_size_t;
#else
# if defined(_MSC_VER) && defined(MAXSEG_64K)
-# define png_mem_alloc(s) halloc(s, 1)
-# define png_mem_free hfree
typedef unsigned long png_alloc_size_t;
# else
-# if defined(_WINDOWS_) && (!defined(INT_MAX) || INT_MAX <= 0x7ffffffeL)
-# define png_mem_alloc(s) HeapAlloc(GetProcessHeap(), 0, s)
-# define png_mem_free(p) HeapFree(GetProcessHeap(), 0, p)
- typedef DWORD png_alloc_size_t;
+ /* This is an attempt to detect an old Windows system where (int) is
+ * actually 16 bits, in that case png_malloc must have an argument with a
+ * bigger size to accomodate the requirements of the library.
+ */
+# if (defined(_Windows) || defined(_WINDOWS) || defined(_WINDOWS_)) && \
+ (!defined(INT_MAX) || INT_MAX <= 0x7ffffffeL)
+ typedef DWORD png_alloc_size_t;
# else
-# define png_mem_alloc malloc
-# define png_mem_free free
typedef png_size_t png_alloc_size_t;
# endif
# endif
diff --git a/src/thirdparty/libpng/pngpread.c b/src/thirdparty/libpng/pngpread.c
index ed5d82c63..61683cc78 100644
--- a/src/thirdparty/libpng/pngpread.c
+++ b/src/thirdparty/libpng/pngpread.c
@@ -843,7 +843,7 @@ png_process_IDAT_data(png_structp png_ptr, png_bytep buffer,
* or the stream marked as finished.
*/
while (png_ptr->zstream.avail_in > 0 &&
- !(png_ptr->flags & PNG_FLAG_ZLIB_FINISHED))
+ !(png_ptr->flags & PNG_FLAG_ZLIB_FINISHED))
{
int ret;
@@ -872,49 +872,49 @@ png_process_IDAT_data(png_structp png_ptr, png_bytep buffer,
/* Check for any failure before proceeding. */
if (ret != Z_OK && ret != Z_STREAM_END)
{
- /* Terminate the decompression. */
- png_ptr->flags |= PNG_FLAG_ZLIB_FINISHED;
+ /* Terminate the decompression. */
+ png_ptr->flags |= PNG_FLAG_ZLIB_FINISHED;
/* This may be a truncated stream (missing or
- * damaged end code). Treat that as a warning.
- */
+ * damaged end code). Treat that as a warning.
+ */
if (png_ptr->row_number >= png_ptr->num_rows ||
- png_ptr->pass > 6)
- png_warning(png_ptr, "Truncated compressed data in IDAT");
- else
- png_error(png_ptr, "Decompression error in IDAT");
+ png_ptr->pass > 6)
+ png_warning(png_ptr, "Truncated compressed data in IDAT");
+ else
+ png_error(png_ptr, "Decompression error in IDAT");
- /* Skip the check on unprocessed input */
+ /* Skip the check on unprocessed input */
return;
}
/* Did inflate output any data? */
if (png_ptr->zstream.next_out != png_ptr->row_buf)
{
- /* Is this unexpected data after the last row?
- * If it is, artificially terminate the LZ output
- * here.
- */
+ /* Is this unexpected data after the last row?
+ * If it is, artificially terminate the LZ output
+ * here.
+ */
if (png_ptr->row_number >= png_ptr->num_rows ||
- png_ptr->pass > 6)
+ png_ptr->pass > 6)
{
- /* Extra data. */
- png_warning(png_ptr, "Extra compressed data in IDAT");
+ /* Extra data. */
+ png_warning(png_ptr, "Extra compressed data in IDAT");
png_ptr->flags |= PNG_FLAG_ZLIB_FINISHED;
- /* Do no more processing; skip the unprocessed
- * input check below.
- */
+ /* Do no more processing; skip the unprocessed
+ * input check below.
+ */
return;
- }
+ }
- /* Do we have a complete row? */
- if (png_ptr->zstream.avail_out == 0)
- png_push_process_row(png_ptr);
+ /* Do we have a complete row? */
+ if (png_ptr->zstream.avail_out == 0)
+ png_push_process_row(png_ptr);
}
/* And check for the end of the stream. */
if (ret == Z_STREAM_END)
- png_ptr->flags |= PNG_FLAG_ZLIB_FINISHED;
+ png_ptr->flags |= PNG_FLAG_ZLIB_FINISHED;
}
/* All the data should have been processed, if anything
@@ -988,7 +988,7 @@ png_push_process_row(png_structp png_ptr)
if (png_ptr->pass == 6 && png_ptr->height <= 4)
{
- png_push_have_row(png_ptr, NULL);
+ png_push_have_row(png_ptr, NULL);
png_read_push_finish_row(png_ptr);
}
@@ -1028,7 +1028,7 @@ png_push_process_row(png_structp png_ptr)
for (i = 0; i < 4 && png_ptr->pass == 2; i++)
{
- png_push_have_row(png_ptr, NULL);
+ png_push_have_row(png_ptr, NULL);
png_read_push_finish_row(png_ptr);
}
@@ -1078,13 +1078,13 @@ png_push_process_row(png_structp png_ptr)
for (i = 0; i < 2 && png_ptr->pass == 4; i++)
{
- png_push_have_row(png_ptr, NULL);
+ png_push_have_row(png_ptr, NULL);
png_read_push_finish_row(png_ptr);
}
if (png_ptr->pass == 6) /* Pass 5 might be empty */
{
- png_push_have_row(png_ptr, NULL);
+ png_push_have_row(png_ptr, NULL);
png_read_push_finish_row(png_ptr);
}
@@ -1103,7 +1103,7 @@ png_push_process_row(png_structp png_ptr)
if (png_ptr->pass == 6) /* Skip top generated row */
{
- png_push_have_row(png_ptr, NULL);
+ png_push_have_row(png_ptr, NULL);
png_read_push_finish_row(png_ptr);
}
@@ -1117,7 +1117,7 @@ png_push_process_row(png_structp png_ptr)
if (png_ptr->pass != 6)
break;
- png_push_have_row(png_ptr, NULL);
+ png_push_have_row(png_ptr, NULL);
png_read_push_finish_row(png_ptr);
}
}
diff --git a/src/thirdparty/libpng/pngpriv.h b/src/thirdparty/libpng/pngpriv.h
index b1b6a99b1..ebf8e5301 100644
--- a/src/thirdparty/libpng/pngpriv.h
+++ b/src/thirdparty/libpng/pngpriv.h
@@ -1,7 +1,7 @@
/* pngpriv.h - private declarations for use inside libpng
*
- * libpng version 1.4.3 - June 26, 2010
+ * libpng version 1.4.4 - September 23, 2010
* For conditions of distribution and use, see copyright notice in png.h
* Copyright (c) 1998-2010 Glenn Randers-Pehrson
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
@@ -28,14 +28,16 @@
#include <stdlib.h>
+#ifndef PNG_EXTERN
/* The functions exported by PNG_EXTERN are internal functions, which
* aren't usually used outside the library (as far as I know), so it is
* debatable if they should be exported at all. In the future, when it
* is possible to have run-time registry of chunk-handling functions,
* some of these will be made available again.
-#define PNG_EXTERN extern
+# define PNG_EXTERN extern
*/
-#define PNG_EXTERN
+# define PNG_EXTERN
+#endif
/* Other defines specific to compilers can go here. Try to keep
* them inside an appropriate ifdef/endif pair for portability.
@@ -75,10 +77,6 @@
#if defined(WIN32) || defined(_Windows) || defined(_WINDOWS) || \
defined(_WIN32) || defined(__WIN32__)
# include <windows.h> /* defines _WINDOWS_ macro */
-/* I have no idea why is this necessary... */
-# ifdef _MSC_VER
-# include <malloc.h>
-# endif
#endif
/* Various modes of operation. Note that after an init, mode is set to
@@ -672,7 +670,7 @@ PNG_EXTERN void png_handle_hIST PNGARG((png_structp png_ptr, png_infop info_ptr,
#endif
#ifdef PNG_READ_iCCP_SUPPORTED
-extern void png_handle_iCCP PNGARG((png_structp png_ptr, png_infop info_ptr,
+PNG_EXTERN void png_handle_iCCP PNGARG((png_structp png_ptr, png_infop info_ptr,
png_uint_32 length));
#endif /* PNG_READ_iCCP_SUPPORTED */
@@ -707,7 +705,7 @@ PNG_EXTERN void png_handle_sCAL PNGARG((png_structp png_ptr, png_infop info_ptr,
#endif
#ifdef PNG_READ_sPLT_SUPPORTED
-extern void png_handle_sPLT PNGARG((png_structp png_ptr, png_infop info_ptr,
+PNG_EXTERN void png_handle_sPLT PNGARG((png_structp png_ptr, png_infop info_ptr,
png_uint_32 length));
#endif /* PNG_READ_sPLT_SUPPORTED */
@@ -828,14 +826,14 @@ PNG_EXTERN void png_check_IHDR PNGARG((png_structp png_ptr,
int filter_type));
/* Free all memory used by the read (old method - NOT DLL EXPORTED) */
-extern void png_read_destroy PNGARG((png_structp png_ptr, png_infop info_ptr,
+PNG_EXTERN void png_read_destroy PNGARG((png_structp png_ptr, png_infop info_ptr,
png_infop end_info_ptr));
/* Free any memory used in png_ptr struct (old method - NOT DLL EXPORTED) */
-extern void png_write_destroy PNGARG((png_structp png_ptr));
+PNG_EXTERN void png_write_destroy PNGARG((png_structp png_ptr));
#ifdef USE_FAR_KEYWORD /* memory model conversion function */
-extern void *png_far_to_near PNGARG((png_structp png_ptr,png_voidp ptr,
+PNG_EXTERN void *png_far_to_near PNGARG((png_structp png_ptr,png_voidp ptr,
int check));
#endif /* USE_FAR_KEYWORD */
diff --git a/src/thirdparty/libpng/pngrutil.c b/src/thirdparty/libpng/pngrutil.c
index db5ec0c3f..6a7437efa 100644
--- a/src/thirdparty/libpng/pngrutil.c
+++ b/src/thirdparty/libpng/pngrutil.c
@@ -1,7 +1,7 @@
/* pngrutil.c - utilities to read a PNG file
*
- * Last changed in libpng 1.4.3 [June 26, 2010]
+ * Last changed in libpng 1.4.4 [August 26, 2010]
* Copyright (c) 1998-2010 Glenn Randers-Pehrson
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
* (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.)
@@ -30,38 +30,41 @@ png_get_uint_31(png_structp png_ptr, png_bytep buf)
}
#ifndef PNG_USE_READ_MACROS
/* Grab an unsigned 32-bit integer from a buffer in big-endian format. */
-png_uint_32 PNGAPI
-png_get_uint_32(png_bytep buf)
+png_uint_32 (PNGAPI
+png_get_uint_32)(png_bytep buf)
{
- png_uint_32 i = ((png_uint_32)(*buf) << 24) +
- ((png_uint_32)(*(buf + 1)) << 16) +
- ((png_uint_32)(*(buf + 2)) << 8) +
- (png_uint_32)(*(buf + 3));
+ png_uint_32 i =
+ ((png_uint_32)(*(buf )) << 24) +
+ ((png_uint_32)(*(buf + 1)) << 16) +
+ ((png_uint_32)(*(buf + 2)) << 8) +
+ ((png_uint_32)(*(buf + 3)) ) ;
return (i);
}
/* Grab a signed 32-bit integer from a buffer in big-endian format. The
- * data is stored in the PNG file in two's complement format, and it is
- * assumed that the machine format for signed integers is the same.
+ * data is stored in the PNG file in two's complement format and there
+ * is no guarantee that a 'png_int_32' is exactly 32 bits, therefore
+ * the following code does a two's complement to native conversion.
*/
-png_int_32 PNGAPI
-png_get_int_32(png_bytep buf)
+png_int_32 (PNGAPI
+png_get_int_32)(png_bytep buf)
{
- png_int_32 i = ((png_int_32)(*buf) << 24) +
- ((png_int_32)(*(buf + 1)) << 16) +
- ((png_int_32)(*(buf + 2)) << 8) +
- (png_int_32)(*(buf + 3));
+ png_uint_32 u = png_get_uint_32(buf);
+ if ((u & 0x80000000) == 0) /* non-negative */
+ return u;
- return (i);
+ u = (u ^ 0xffffffff) + 1; /* 2's complement: -x = ~x+1 */
+ return -(png_int_32)u;
}
/* Grab an unsigned 16-bit integer from a buffer in big-endian format. */
-png_uint_16 PNGAPI
-png_get_uint_16(png_bytep buf)
+png_uint_16 (PNGAPI
+png_get_uint_16)(png_bytep buf)
{
- png_uint_16 i = (png_uint_16)(((png_uint_16)(*buf) << 8) +
- (png_uint_16)(*(buf + 1)));
+ png_uint_16 i =
+ ((png_uint_32)(*buf) << 8) +
+ ((png_uint_32)(*(buf + 1)));
return (i);
}
@@ -1128,20 +1131,20 @@ png_handle_iCCP(png_structp png_ptr, png_infop info_ptr, png_uint_32 length)
if (profile_size > profile_length)
{
+#ifdef PNG_STDIO_SUPPORTED
+ char umsg[50];
+#endif
png_free(png_ptr, png_ptr->chunkdata);
png_ptr->chunkdata = NULL;
png_warning(png_ptr, "Ignoring truncated iCCP profile");
#ifdef PNG_STDIO_SUPPORTED
- {
- char umsg[50];
- png_snprintf(umsg, 50, "declared profile size = %lu",
- (unsigned long)profile_size);
- png_warning(png_ptr, umsg);
- png_snprintf(umsg, 50, "actual profile length = %lu",
- (unsigned long)profile_length);
- png_warning(png_ptr, umsg);
- }
+ png_snprintf(umsg, 50, "declared profile size = %lu",
+ (unsigned long)profile_size);
+ png_warning(png_ptr, umsg);
+ png_snprintf(umsg, 50, "actual profile length = %lu",
+ (unsigned long)profile_length);
+ png_warning(png_ptr, umsg);
#endif
return;
}
@@ -1875,9 +1878,6 @@ png_handle_sCAL(png_structp png_ptr, png_infop info_ptr, png_uint_32 length)
png_warning(png_ptr, "malformed height string in sCAL chunk");
png_free(png_ptr, png_ptr->chunkdata);
png_ptr->chunkdata = NULL;
-#if defined(PNG_FIXED_POINT_SUPPORTED) && !defined(PNG_FLOATING_POINT_SUPPORTED)
- png_free(png_ptr, swidth);
-#endif
return;
}
#else
@@ -1888,9 +1888,7 @@ png_handle_sCAL(png_structp png_ptr, png_infop info_ptr, png_uint_32 length)
png_warning(png_ptr, "Out of memory while processing sCAL chunk height");
png_free(png_ptr, png_ptr->chunkdata);
png_ptr->chunkdata = NULL;
-#if defined(PNG_FIXED_POINT_SUPPORTED) && !defined(PNG_FLOATING_POINT_SUPPORTED)
png_free(png_ptr, swidth);
-#endif
return;
}
png_memcpy(sheight, ep, png_strlen(ep));
diff --git a/src/thirdparty/libpng/pngtest.c b/src/thirdparty/libpng/pngtest.c
index 35a4c7dba..b76de0e9a 100644
--- a/src/thirdparty/libpng/pngtest.c
+++ b/src/thirdparty/libpng/pngtest.c
@@ -302,7 +302,7 @@ pngtest_read_data(png_structp png_ptr, png_bytep data, png_size_t length)
/* Check if data really is near. If so, use usual code. */
n_data = (png_byte *)CVT_PTR_NOCHECK(data);
- io_ptr = (png_FILE_p)CVT_PTR(png_ptr->io_ptr);
+ io_ptr = (png_FILE_p)CVT_PTR(png_get_io_ptr(png_ptr));
if ((png_bytep)n_data == data)
{
check = fread(n_data, 1, length, io_ptr);
@@ -351,8 +351,10 @@ static void
pngtest_write_data(png_structp png_ptr, png_bytep data, png_size_t length)
{
png_size_t check;
+ png_FILE_p io_ptr;
+ io_ptr = (png_FILE_p)CVT_PTR(png_get_io_ptr(png_ptr));
- check = fwrite(data, 1, length, (png_FILE_p)png_ptr->io_ptr);
+ check = fwrite(data, 1, length, io_ptr);
if (check != length)
{
png_error(png_ptr, "Write Error");
@@ -1627,4 +1629,4 @@ main(int argc, char *argv[])
}
/* Generate a compiler error if there is an old png.h in the search path. */
-typedef version_1_4_3 your_png_h_is_not_version_1_4_3;
+typedef version_1_4_4 your_png_h_is_not_version_1_4_4;
diff --git a/src/thirdparty/libpng/pngtrans.c b/src/thirdparty/libpng/pngtrans.c
index d604a7a47..bdc10a261 100644
--- a/src/thirdparty/libpng/pngtrans.c
+++ b/src/thirdparty/libpng/pngtrans.c
@@ -673,5 +673,5 @@ png_get_user_transform_ptr(png_structp png_ptr)
#endif
}
#endif /* PNG_READ_USER_TRANSFORM_SUPPORTED ||
- PNG_WRITE_USER_TRANSFORM_SUPPORTED */
+ PNG_WRITE_USER_TRANSFORM_SUPPORTED */
#endif /* PNG_READ_SUPPORTED || PNG_WRITE_SUPPORTED */