mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-09-06 15:00:31 +02:00
ide: move manifest data to the .manifest file since GoRc cannot compile embedded into .rc manifest data (#0012846)
git-svn-id: trunk@17910 -
This commit is contained in:
parent
1be0908482
commit
5604182bbf
@ -2,12 +2,13 @@
|
|||||||
<CONFIG>
|
<CONFIG>
|
||||||
<ProjectOptions>
|
<ProjectOptions>
|
||||||
<PathDelim Value="\"/>
|
<PathDelim Value="\"/>
|
||||||
<Version Value="6"/>
|
<Version Value="7"/>
|
||||||
<General>
|
<General>
|
||||||
<Flags>
|
<Flags>
|
||||||
<MainUnitHasUsesSectionForAllUnits Value="False"/>
|
<MainUnitHasUsesSectionForAllUnits Value="False"/>
|
||||||
<MainUnitHasCreateFormStatements Value="False"/>
|
<MainUnitHasCreateFormStatements Value="False"/>
|
||||||
<MainUnitHasTitleStatement Value="False"/>
|
<MainUnitHasTitleStatement Value="False"/>
|
||||||
|
<LRSInOutputDirectory Value="False"/>
|
||||||
</Flags>
|
</Flags>
|
||||||
<SessionStorage Value="InIDEConfig"/>
|
<SessionStorage Value="InIDEConfig"/>
|
||||||
<MainUnit Value="0"/>
|
<MainUnit Value="0"/>
|
||||||
@ -41,7 +42,7 @@
|
|||||||
<PackageName Value="SynEdit"/>
|
<PackageName Value="SynEdit"/>
|
||||||
</Item4>
|
</Item4>
|
||||||
</RequiredPackages>
|
</RequiredPackages>
|
||||||
<Units Count="28">
|
<Units Count="32">
|
||||||
<Unit0>
|
<Unit0>
|
||||||
<Filename Value="lazarus.pp"/>
|
<Filename Value="lazarus.pp"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
@ -58,7 +59,6 @@
|
|||||||
<HasResources Value="True"/>
|
<HasResources Value="True"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<ResourceBaseClass Value="Frame"/>
|
<ResourceBaseClass Value="Frame"/>
|
||||||
<ResourceFilename Value="frames\options_oi.lrs"/>
|
|
||||||
<UnitName Value="options_OI"/>
|
<UnitName Value="options_OI"/>
|
||||||
</Unit2>
|
</Unit2>
|
||||||
<Unit3>
|
<Unit3>
|
||||||
@ -66,7 +66,6 @@
|
|||||||
<ComponentName Value="FilesOptionsFrame"/>
|
<ComponentName Value="FilesOptionsFrame"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<ResourceBaseClass Value="Frame"/>
|
<ResourceBaseClass Value="Frame"/>
|
||||||
<ResourceFilename Value="frames\options_files.lrs"/>
|
|
||||||
<UnitName Value="options_files"/>
|
<UnitName Value="options_files"/>
|
||||||
</Unit3>
|
</Unit3>
|
||||||
<Unit4>
|
<Unit4>
|
||||||
@ -74,7 +73,6 @@
|
|||||||
<ComponentName Value="DesktopOptionsFrame"/>
|
<ComponentName Value="DesktopOptionsFrame"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<ResourceBaseClass Value="Frame"/>
|
<ResourceBaseClass Value="Frame"/>
|
||||||
<ResourceFilename Value="frames\options_desktop.lrs"/>
|
|
||||||
<UnitName Value="options_desktop"/>
|
<UnitName Value="options_desktop"/>
|
||||||
</Unit4>
|
</Unit4>
|
||||||
<Unit5>
|
<Unit5>
|
||||||
@ -82,7 +80,6 @@
|
|||||||
<ComponentName Value="WindowOptionsFrame"/>
|
<ComponentName Value="WindowOptionsFrame"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<ResourceBaseClass Value="Frame"/>
|
<ResourceBaseClass Value="Frame"/>
|
||||||
<ResourceFilename Value="frames\options_window.lrs"/>
|
|
||||||
<UnitName Value="options_window"/>
|
<UnitName Value="options_window"/>
|
||||||
</Unit5>
|
</Unit5>
|
||||||
<Unit6>
|
<Unit6>
|
||||||
@ -90,7 +87,6 @@
|
|||||||
<ComponentName Value="FormEditorOptionsFrame"/>
|
<ComponentName Value="FormEditorOptionsFrame"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<ResourceBaseClass Value="Frame"/>
|
<ResourceBaseClass Value="Frame"/>
|
||||||
<ResourceFilename Value="frames\options_formed.lrs"/>
|
|
||||||
<UnitName Value="options_formed"/>
|
<UnitName Value="options_formed"/>
|
||||||
</Unit6>
|
</Unit6>
|
||||||
<Unit7>
|
<Unit7>
|
||||||
@ -98,7 +94,6 @@
|
|||||||
<ComponentName Value="BackupOptionsFrame"/>
|
<ComponentName Value="BackupOptionsFrame"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<ResourceBaseClass Value="Frame"/>
|
<ResourceBaseClass Value="Frame"/>
|
||||||
<ResourceFilename Value="frames\options_backup.lrs"/>
|
|
||||||
<UnitName Value="options_backup"/>
|
<UnitName Value="options_backup"/>
|
||||||
</Unit7>
|
</Unit7>
|
||||||
<Unit8>
|
<Unit8>
|
||||||
@ -106,7 +101,6 @@
|
|||||||
<ComponentName Value="NamingOptionsFrame"/>
|
<ComponentName Value="NamingOptionsFrame"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<ResourceBaseClass Value="Frame"/>
|
<ResourceBaseClass Value="Frame"/>
|
||||||
<ResourceFilename Value="frames\options_naming.lrs"/>
|
|
||||||
<UnitName Value="options_naming"/>
|
<UnitName Value="options_naming"/>
|
||||||
</Unit8>
|
</Unit8>
|
||||||
<Unit9>
|
<Unit9>
|
||||||
@ -114,7 +108,6 @@
|
|||||||
<ComponentName Value="FpDocOptionsFrame"/>
|
<ComponentName Value="FpDocOptionsFrame"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<ResourceBaseClass Value="Frame"/>
|
<ResourceBaseClass Value="Frame"/>
|
||||||
<ResourceFilename Value="frames\options_fpdoc.lrs"/>
|
|
||||||
<UnitName Value="options_fpdoc"/>
|
<UnitName Value="options_fpdoc"/>
|
||||||
</Unit9>
|
</Unit9>
|
||||||
<Unit10>
|
<Unit10>
|
||||||
@ -123,7 +116,6 @@
|
|||||||
<HasResources Value="True"/>
|
<HasResources Value="True"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<ResourceBaseClass Value="Frame"/>
|
<ResourceBaseClass Value="Frame"/>
|
||||||
<ResourceFilename Value="..\ideintf\ideoptionsintf.lrs"/>
|
|
||||||
<UnitName Value="IDEOptionsIntf"/>
|
<UnitName Value="IDEOptionsIntf"/>
|
||||||
</Unit10>
|
</Unit10>
|
||||||
<Unit11>
|
<Unit11>
|
||||||
@ -132,7 +124,6 @@
|
|||||||
<HasResources Value="True"/>
|
<HasResources Value="True"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<ResourceBaseClass Value="Frame"/>
|
<ResourceBaseClass Value="Frame"/>
|
||||||
<ResourceFilename Value="frames\options_editor_general.lrs"/>
|
|
||||||
<UnitName Value="options_editor_general"/>
|
<UnitName Value="options_editor_general"/>
|
||||||
</Unit11>
|
</Unit11>
|
||||||
<Unit12>
|
<Unit12>
|
||||||
@ -140,7 +131,6 @@
|
|||||||
<ComponentName Value="EditorDisplayOptionsFrame"/>
|
<ComponentName Value="EditorDisplayOptionsFrame"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<ResourceBaseClass Value="Frame"/>
|
<ResourceBaseClass Value="Frame"/>
|
||||||
<ResourceFilename Value="frames\options_editor_display.lrs"/>
|
|
||||||
<UnitName Value="options_editor_display"/>
|
<UnitName Value="options_editor_display"/>
|
||||||
</Unit12>
|
</Unit12>
|
||||||
<Unit13>
|
<Unit13>
|
||||||
@ -148,7 +138,6 @@
|
|||||||
<ComponentName Value="EditorKeymappingOptionsFrame"/>
|
<ComponentName Value="EditorKeymappingOptionsFrame"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<ResourceBaseClass Value="Frame"/>
|
<ResourceBaseClass Value="Frame"/>
|
||||||
<ResourceFilename Value="frames\options_editor_keymapping.lrs"/>
|
|
||||||
<UnitName Value="options_editor_keymapping"/>
|
<UnitName Value="options_editor_keymapping"/>
|
||||||
</Unit13>
|
</Unit13>
|
||||||
<Unit14>
|
<Unit14>
|
||||||
@ -156,7 +145,6 @@
|
|||||||
<ComponentName Value="EditorColorOptionsFrame"/>
|
<ComponentName Value="EditorColorOptionsFrame"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<ResourceBaseClass Value="Frame"/>
|
<ResourceBaseClass Value="Frame"/>
|
||||||
<ResourceFilename Value="frames\options_editor_color.lrs"/>
|
|
||||||
<UnitName Value="options_editor_color"/>
|
<UnitName Value="options_editor_color"/>
|
||||||
</Unit14>
|
</Unit14>
|
||||||
<Unit15>
|
<Unit15>
|
||||||
@ -164,7 +152,6 @@
|
|||||||
<ComponentName Value="EditorCodetoolsOptionsFrame"/>
|
<ComponentName Value="EditorCodetoolsOptionsFrame"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<ResourceBaseClass Value="Frame"/>
|
<ResourceBaseClass Value="Frame"/>
|
||||||
<ResourceFilename Value="frames\options_editor_codetools.lrs"/>
|
|
||||||
<UnitName Value="options_editor_codetools"/>
|
<UnitName Value="options_editor_codetools"/>
|
||||||
</Unit15>
|
</Unit15>
|
||||||
<Unit16>
|
<Unit16>
|
||||||
@ -172,7 +159,6 @@
|
|||||||
<ComponentName Value="EditorCodefoldingOptionsFrame"/>
|
<ComponentName Value="EditorCodefoldingOptionsFrame"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<ResourceBaseClass Value="Frame"/>
|
<ResourceBaseClass Value="Frame"/>
|
||||||
<ResourceFilename Value="frames\options_editor_codefolding.lrs"/>
|
|
||||||
<UnitName Value="options_editor_codefolding"/>
|
<UnitName Value="options_editor_codefolding"/>
|
||||||
</Unit16>
|
</Unit16>
|
||||||
<Unit17>
|
<Unit17>
|
||||||
@ -180,7 +166,6 @@
|
|||||||
<ComponentName Value="CodetoolsGeneralOptionsFrame"/>
|
<ComponentName Value="CodetoolsGeneralOptionsFrame"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<ResourceBaseClass Value="Frame"/>
|
<ResourceBaseClass Value="Frame"/>
|
||||||
<ResourceFilename Value="frames\options_codetools_general.lrs"/>
|
|
||||||
<UnitName Value="options_codetools_general"/>
|
<UnitName Value="options_codetools_general"/>
|
||||||
</Unit17>
|
</Unit17>
|
||||||
<Unit18>
|
<Unit18>
|
||||||
@ -188,7 +173,6 @@
|
|||||||
<ComponentName Value="CodetoolsCodeCreationOptionsFrame"/>
|
<ComponentName Value="CodetoolsCodeCreationOptionsFrame"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<ResourceBaseClass Value="Frame"/>
|
<ResourceBaseClass Value="Frame"/>
|
||||||
<ResourceFilename Value="frames\options_codetools_codecreation.lrs"/>
|
|
||||||
<UnitName Value="options_codetools_codecreation"/>
|
<UnitName Value="options_codetools_codecreation"/>
|
||||||
</Unit18>
|
</Unit18>
|
||||||
<Unit19>
|
<Unit19>
|
||||||
@ -196,7 +180,6 @@
|
|||||||
<ComponentName Value="CodetoolsWordPolicyOptionsFrame"/>
|
<ComponentName Value="CodetoolsWordPolicyOptionsFrame"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<ResourceBaseClass Value="Frame"/>
|
<ResourceBaseClass Value="Frame"/>
|
||||||
<ResourceFilename Value="frames\options_codetools_wordpolicy.lrs"/>
|
|
||||||
<UnitName Value="options_codetools_wordpolicy"/>
|
<UnitName Value="options_codetools_wordpolicy"/>
|
||||||
</Unit19>
|
</Unit19>
|
||||||
<Unit20>
|
<Unit20>
|
||||||
@ -204,7 +187,6 @@
|
|||||||
<ComponentName Value="CodetoolsLineSplittingOptionsFrame"/>
|
<ComponentName Value="CodetoolsLineSplittingOptionsFrame"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<ResourceBaseClass Value="Frame"/>
|
<ResourceBaseClass Value="Frame"/>
|
||||||
<ResourceFilename Value="frames\options_codetools_linesplitting.lrs"/>
|
|
||||||
<UnitName Value="options_codetools_linesplitting"/>
|
<UnitName Value="options_codetools_linesplitting"/>
|
||||||
</Unit20>
|
</Unit20>
|
||||||
<Unit21>
|
<Unit21>
|
||||||
@ -212,7 +194,6 @@
|
|||||||
<ComponentName Value="CodetoolsSpaceOptionsFrame"/>
|
<ComponentName Value="CodetoolsSpaceOptionsFrame"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<ResourceBaseClass Value="Frame"/>
|
<ResourceBaseClass Value="Frame"/>
|
||||||
<ResourceFilename Value="frames\options_codetools_space.lrs"/>
|
|
||||||
<UnitName Value="options_codetools_space"/>
|
<UnitName Value="options_codetools_space"/>
|
||||||
</Unit21>
|
</Unit21>
|
||||||
<Unit22>
|
<Unit22>
|
||||||
@ -220,7 +201,6 @@
|
|||||||
<ComponentName Value="CodetoolsIndentifierComplietionOptionsFrame"/>
|
<ComponentName Value="CodetoolsIndentifierComplietionOptionsFrame"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<ResourceBaseClass Value="Frame"/>
|
<ResourceBaseClass Value="Frame"/>
|
||||||
<ResourceFilename Value="frames\options_codetools_identifiercompletion.lrs"/>
|
|
||||||
<UnitName Value="options_codetools_identifiercompletion"/>
|
<UnitName Value="options_codetools_identifiercompletion"/>
|
||||||
</Unit22>
|
</Unit22>
|
||||||
<Unit23>
|
<Unit23>
|
||||||
@ -229,7 +209,6 @@
|
|||||||
<HasResources Value="True"/>
|
<HasResources Value="True"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<ResourceBaseClass Value="Frame"/>
|
<ResourceBaseClass Value="Frame"/>
|
||||||
<ResourceFilename Value="frames\options_editor_general_misc.lrs"/>
|
|
||||||
<UnitName Value="options_editor_general_misc"/>
|
<UnitName Value="options_editor_general_misc"/>
|
||||||
</Unit23>
|
</Unit23>
|
||||||
<Unit24>
|
<Unit24>
|
||||||
@ -238,7 +217,6 @@
|
|||||||
<HasResources Value="True"/>
|
<HasResources Value="True"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<ResourceBaseClass Value="Frame"/>
|
<ResourceBaseClass Value="Frame"/>
|
||||||
<ResourceFilename Value="..\debugger\frames\options_debugger_general.lrs"/>
|
|
||||||
<UnitName Value="options_debugger_general"/>
|
<UnitName Value="options_debugger_general"/>
|
||||||
</Unit24>
|
</Unit24>
|
||||||
<Unit25>
|
<Unit25>
|
||||||
@ -246,7 +224,6 @@
|
|||||||
<ComponentName Value="DebuggerEventLogOptionsFrame"/>
|
<ComponentName Value="DebuggerEventLogOptionsFrame"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<ResourceBaseClass Value="Frame"/>
|
<ResourceBaseClass Value="Frame"/>
|
||||||
<ResourceFilename Value="..\debugger\frames\options_debugger_eventlog.lrs"/>
|
|
||||||
<UnitName Value="options_debugger_eventlog"/>
|
<UnitName Value="options_debugger_eventlog"/>
|
||||||
</Unit25>
|
</Unit25>
|
||||||
<Unit26>
|
<Unit26>
|
||||||
@ -254,7 +231,6 @@
|
|||||||
<ComponentName Value="DebuggerLanguageExceptionsOptions"/>
|
<ComponentName Value="DebuggerLanguageExceptionsOptions"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<ResourceBaseClass Value="Frame"/>
|
<ResourceBaseClass Value="Frame"/>
|
||||||
<ResourceFilename Value="..\debugger\frames\options_debugger_language_exceptions.lrs"/>
|
|
||||||
<UnitName Value="options_debugger_language_exceptions"/>
|
<UnitName Value="options_debugger_language_exceptions"/>
|
||||||
</Unit26>
|
</Unit26>
|
||||||
<Unit27>
|
<Unit27>
|
||||||
@ -262,9 +238,28 @@
|
|||||||
<ComponentName Value="DebuggerSignalsOptions"/>
|
<ComponentName Value="DebuggerSignalsOptions"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<ResourceBaseClass Value="Frame"/>
|
<ResourceBaseClass Value="Frame"/>
|
||||||
<ResourceFilename Value="..\debugger\frames\options_debugger_signals.lrs"/>
|
|
||||||
<UnitName Value="options_debugger_signals"/>
|
<UnitName Value="options_debugger_signals"/>
|
||||||
</Unit27>
|
</Unit27>
|
||||||
|
<Unit28>
|
||||||
|
<Filename Value="projectresources.pas"/>
|
||||||
|
<IsPartOfProject Value="True"/>
|
||||||
|
<UnitName Value="ProjectResources"/>
|
||||||
|
</Unit28>
|
||||||
|
<Unit29>
|
||||||
|
<Filename Value="w32manifest.pas"/>
|
||||||
|
<IsPartOfProject Value="True"/>
|
||||||
|
<UnitName Value="W32Manifest"/>
|
||||||
|
</Unit29>
|
||||||
|
<Unit30>
|
||||||
|
<Filename Value="projecticon.pas"/>
|
||||||
|
<IsPartOfProject Value="True"/>
|
||||||
|
<UnitName Value="ProjectIcon"/>
|
||||||
|
</Unit30>
|
||||||
|
<Unit31>
|
||||||
|
<Filename Value="w32versioninfo.pas"/>
|
||||||
|
<IsPartOfProject Value="True"/>
|
||||||
|
<UnitName Value="W32VersionInfo"/>
|
||||||
|
</Unit31>
|
||||||
</Units>
|
</Units>
|
||||||
</ProjectOptions>
|
</ProjectOptions>
|
||||||
<CompilerOptions>
|
<CompilerOptions>
|
||||||
|
@ -155,7 +155,8 @@ end;
|
|||||||
-----------------------------------------------------------------------------}
|
-----------------------------------------------------------------------------}
|
||||||
procedure TProjectIcon.SetFileNames(const MainFilename: string);
|
procedure TProjectIcon.SetFileNames(const MainFilename: string);
|
||||||
begin
|
begin
|
||||||
FicoFileName := ExtractFilePath(MainFilename) + ExtractFileNameWithoutExt(ExtractFileName(MainFileName)) + '.ico';
|
FicoFileName := ExtractFilePath(MainFilename) +
|
||||||
|
ExtractFileNameWithoutExt(ExtractFileName(MainFileName)) + '.ico';
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TProjectIcon.SetIsEmpty(const AValue: Boolean);
|
procedure TProjectIcon.SetIsEmpty(const AValue: Boolean);
|
||||||
|
@ -298,6 +298,8 @@ begin
|
|||||||
with AConfig do
|
with AConfig do
|
||||||
begin
|
begin
|
||||||
ProjectIcon.IcoFileName := ChangeFileExt(FileName, '.ico');
|
ProjectIcon.IcoFileName := ChangeFileExt(FileName, '.ico');
|
||||||
|
XPManifest.ManifestFileName := ChangeFileExt(FileName, '.manifest');
|
||||||
|
|
||||||
ProjectIcon.IsEmpty := StrToBoolDef(GetValue(Path+'General/Icon/Value', '-1'), False);
|
ProjectIcon.IsEmpty := StrToBoolDef(GetValue(Path+'General/Icon/Value', '-1'), False);
|
||||||
XPManifest.UseManifest := GetValue(Path+'General/UseXPManifest/Value', False);
|
XPManifest.UseManifest := GetValue(Path+'General/UseXPManifest/Value', False);
|
||||||
VersionInfo.UseVersionInfo := GetValue(Path+'VersionInfo/UseVersionInfo/Value', False);
|
VersionInfo.UseVersionInfo := GetValue(Path+'VersionInfo/UseVersionInfo/Value', False);
|
||||||
|
@ -43,11 +43,15 @@ type
|
|||||||
TProjectXPManifest = class(TAbstractProjectResource)
|
TProjectXPManifest = class(TAbstractProjectResource)
|
||||||
private
|
private
|
||||||
FUseManifest: boolean;
|
FUseManifest: boolean;
|
||||||
|
FManifestFileName: string;
|
||||||
|
procedure SetFileNames(const MainFilename: string);
|
||||||
procedure SetUseManifest(const AValue: boolean);
|
procedure SetUseManifest(const AValue: boolean);
|
||||||
public
|
public
|
||||||
function UpdateResources(AResources: TAbstractProjectResources; const MainFilename: string): Boolean; override;
|
function UpdateResources(AResources: TAbstractProjectResources; const MainFilename: string): Boolean; override;
|
||||||
|
function CreateManifestFile: Boolean;
|
||||||
|
|
||||||
property UseManifest: boolean read FUseManifest write SetUseManifest;
|
property UseManifest: boolean read FUseManifest write SetUseManifest;
|
||||||
|
property ManifestFileName: String read FManifestFileName write FManifestFileName;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
implementation
|
implementation
|
||||||
@ -58,26 +62,31 @@ const
|
|||||||
'#define CREATEPROCESS_MANIFEST_RESOURCE_ID 1'#$D#$A+
|
'#define CREATEPROCESS_MANIFEST_RESOURCE_ID 1'#$D#$A+
|
||||||
'#define ISOLATIONAWARE_MANIFEST_RESOURCE_ID 2'#$D#$A+
|
'#define ISOLATIONAWARE_MANIFEST_RESOURCE_ID 2'#$D#$A+
|
||||||
'#define ISOLATIONAWARE_NOSTATICIMPORT_MANIFEST_RESOURCE_ID 3'#$D#$A#$D#$A+
|
'#define ISOLATIONAWARE_NOSTATICIMPORT_MANIFEST_RESOURCE_ID 3'#$D#$A#$D#$A+
|
||||||
'CREATEPROCESS_MANIFEST_RESOURCE_ID RT_MANIFEST MOVEABLE PURE'#$D#$A+
|
'CREATEPROCESS_MANIFEST_RESOURCE_ID RT_MANIFEST';
|
||||||
'{'#$D#$A+
|
sManifestFileData: String =
|
||||||
' "<?xml version=""1.0"" encoding=""UTF-8"" standalone=""yes""?>"'#$D#$A+
|
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>'#$D#$A+
|
||||||
' "<assembly xmlns=""urn:schemas-microsoft-com:asm.v1"" manifestVersion=""1.0"">"'#$D#$A+
|
'<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">'#$D#$A+
|
||||||
' "<assemblyIdentity version=""1.0.0.0"" processorArchitecture=""*"" name=""CompanyName.ProductName.YourApp"" type=""win32""/>"'#$D#$A+
|
' <assemblyIdentity version="1.0.0.0" processorArchitecture="*" name="CompanyName.ProductName.YourApp" type="win32"/>'#$D#$A+
|
||||||
' "<description>Your application description here.</description>"'#$D#$A+
|
' <description>Your application description here.</description>'#$D#$A+
|
||||||
' "<dependency>"'#$D#$A+
|
' <dependency>'#$D#$A+
|
||||||
' "<dependentAssembly>"'#$D#$A+
|
' <dependentAssembly>'#$D#$A+
|
||||||
' "<assemblyIdentity type=""win32"" name=""Microsoft.Windows.Common-Controls"" version=""6.0.0.0"" processorArchitecture=""*"" publicKeyToken=""6595b64144ccf1df"" language=""*""/>"'#$D#$A+
|
' <assemblyIdentity type="win32" name="Microsoft.Windows.Common-Controls" version="6.0.0.0" processorArchitecture="*" publicKeyToken="6595b64144ccf1df" language="*"/>'#$D#$A+
|
||||||
' "</dependentAssembly>"'#$D#$A+
|
' </dependentAssembly>'#$D#$A+
|
||||||
' "</dependency>"'#$D#$A+
|
' </dependency>'#$D#$A+
|
||||||
' "<trustInfo xmlns=""urn:schemas-microsoft-com:asm.v3"">"'#$D#$A+
|
' <trustInfo xmlns="urn:schemas-microsoft-com:asm.v3">'#$D#$A+
|
||||||
' "<security>"'#$D#$A+
|
' <security>'#$D#$A+
|
||||||
' "<requestedPrivileges>"'#$D#$A+
|
' <requestedPrivileges>'#$D#$A+
|
||||||
' "<requestedExecutionLevel level=""asInvoker"" uiAccess=""false""/>"'#$D#$A+
|
' <requestedExecutionLevel level="asInvoker" uiAccess="false"/>'#$D#$A+
|
||||||
' "</requestedPrivileges>"'#$D#$A+
|
' </requestedPrivileges>'#$D#$A+
|
||||||
' "</security>"'#$D#$A+
|
' </security>'#$D#$A+
|
||||||
' "</trustInfo>"'#$D#$A+
|
' </trustInfo>'#$D#$A+
|
||||||
' "</assembly>"'#$D#$A+
|
'</assembly>';
|
||||||
'}';
|
|
||||||
|
procedure TProjectXPManifest.SetFileNames(const MainFilename: string);
|
||||||
|
begin
|
||||||
|
FManifestFileName := ExtractFilePath(MainFilename) +
|
||||||
|
ExtractFileNameWithoutExt(ExtractFileName(MainFileName)) + '.manifest';
|
||||||
|
end;
|
||||||
|
|
||||||
procedure TProjectXPManifest.SetUseManifest(const AValue: boolean);
|
procedure TProjectXPManifest.SetUseManifest(const AValue: boolean);
|
||||||
begin
|
begin
|
||||||
@ -88,11 +97,37 @@ end;
|
|||||||
|
|
||||||
function TProjectXPManifest.UpdateResources(AResources: TAbstractProjectResources;
|
function TProjectXPManifest.UpdateResources(AResources: TAbstractProjectResources;
|
||||||
const MainFilename: string): Boolean;
|
const MainFilename: string): Boolean;
|
||||||
|
var
|
||||||
|
ManifestName: String;
|
||||||
begin
|
begin
|
||||||
Result := True;
|
Result := True;
|
||||||
if UseManifest then
|
|
||||||
AResources.AddSystemResource(sManifest);
|
SetFileNames(MainFilename);
|
||||||
|
|
||||||
|
if UseManifest and (not FilenameIsAbsolute(FManifestFileName) or CreateManifestFile) then
|
||||||
|
begin
|
||||||
|
ManifestName := ExtractFileName(FManifestFileName);
|
||||||
|
AResources.AddSystemResource(sManifest + ' "' + ManifestName + '"');
|
||||||
|
end
|
||||||
|
else
|
||||||
|
Result := False;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
function TProjectXPManifest.CreateManifestFile: Boolean;
|
||||||
|
var
|
||||||
|
FileStream: TStream;
|
||||||
|
begin
|
||||||
|
Result := False;
|
||||||
|
FileStream := nil;
|
||||||
|
try
|
||||||
|
FileStream := TFileStream.Create(UTF8ToSys(FManifestFileName), fmCreate);
|
||||||
|
FileStream.Write(sManifestFileData[1], Length(sManifestFileData));
|
||||||
|
Result := True;
|
||||||
|
finally
|
||||||
|
FileStream.Free;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
|
||||||
end.
|
end.
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user