Various Mac OS X fixes for exceptions
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@1724 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
parent
6d72de8412
commit
fb5c2019e9
@ -56,6 +56,7 @@ else
|
|||||||
mkdir $appfolder/Contents
|
mkdir $appfolder/Contents
|
||||||
mkdir $appfolder/Contents/MacOS
|
mkdir $appfolder/Contents/MacOS
|
||||||
mkdir $appfolder/Contents/Resources
|
mkdir $appfolder/Contents/Resources
|
||||||
|
mkdir $appfolder/Contents/Resources/images
|
||||||
|
|
||||||
#
|
#
|
||||||
# For a debug bundle,
|
# For a debug bundle,
|
||||||
@ -69,8 +70,10 @@ else
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# Copy the resource files to the correct place
|
# Copy the resource files to the correct place
|
||||||
# cp *.bmp $appfolder/Contents/Resources
|
cp default.pal $appfolder/Contents/Resources/
|
||||||
# cp icon3.ico $appfolder/Contents/Resources
|
cp images/*.svg $appfolder/Contents/Resources/images
|
||||||
|
cp images/*.png $appfolder/Contents/Resources/images
|
||||||
|
cp images/*.ico $appfolder/Contents/Resources/images
|
||||||
# cp icon3.png $appfolder/Contents/Resources
|
# cp icon3.png $appfolder/Contents/Resources
|
||||||
# cp macicon.icns $appfolder/Contents/Resources
|
# cp macicon.icns $appfolder/Contents/Resources
|
||||||
# cp docs/*.* $appfolder/Contents/Resources
|
# cp docs/*.* $appfolder/Contents/Resources
|
||||||
|
|||||||
@ -16,8 +16,39 @@
|
|||||||
<VersionInfo>
|
<VersionInfo>
|
||||||
<StringTable ProductVersion=""/>
|
<StringTable ProductVersion=""/>
|
||||||
</VersionInfo>
|
</VersionInfo>
|
||||||
<BuildModes Count="1">
|
<BuildModes Count="2">
|
||||||
<Item1 Name="Default" Default="True"/>
|
<Item1 Name="Debug" Default="True"/>
|
||||||
|
<Item2 Name="Release">
|
||||||
|
<CompilerOptions>
|
||||||
|
<Version Value="10"/>
|
||||||
|
<PathDelim Value="\"/>
|
||||||
|
<Target>
|
||||||
|
<Filename Value="lazimageeditor"/>
|
||||||
|
</Target>
|
||||||
|
<SearchPaths>
|
||||||
|
<IncludeFiles Value="$(ProjOutDir)"/>
|
||||||
|
<OtherUnitFiles Value="."/>
|
||||||
|
<UnitOutputDirectory Value="lib\$(TargetCPU)-$(TargetOS)"/>
|
||||||
|
</SearchPaths>
|
||||||
|
<Linking>
|
||||||
|
<Debugging>
|
||||||
|
<UseLineInfoUnit Value="False"/>
|
||||||
|
<StripSymbols Value="True"/>
|
||||||
|
</Debugging>
|
||||||
|
<Options>
|
||||||
|
<Win32>
|
||||||
|
<GraphicApplication Value="True"/>
|
||||||
|
</Win32>
|
||||||
|
</Options>
|
||||||
|
</Linking>
|
||||||
|
<Other>
|
||||||
|
<CompilerMessages>
|
||||||
|
<UseMsgFile Value="True"/>
|
||||||
|
</CompilerMessages>
|
||||||
|
<CompilerPath Value="$(CompPath)"/>
|
||||||
|
</Other>
|
||||||
|
</CompilerOptions>
|
||||||
|
</Item2>
|
||||||
</BuildModes>
|
</BuildModes>
|
||||||
<PublishOptions>
|
<PublishOptions>
|
||||||
<Version Value="2"/>
|
<Version Value="2"/>
|
||||||
@ -154,7 +185,8 @@
|
|||||||
</SearchPaths>
|
</SearchPaths>
|
||||||
<Linking>
|
<Linking>
|
||||||
<Debugging>
|
<Debugging>
|
||||||
<UseLineInfoUnit Value="False"/>
|
<GenerateDebugInfo Value="True"/>
|
||||||
|
<GenerateDwarf Value="True"/>
|
||||||
</Debugging>
|
</Debugging>
|
||||||
<Options>
|
<Options>
|
||||||
<Win32>
|
<Win32>
|
||||||
|
|||||||
@ -31,7 +31,9 @@ begin
|
|||||||
// show new picture dialog
|
// show new picture dialog
|
||||||
MainForm.Show;
|
MainForm.Show;
|
||||||
//MainForm.FileNewExecute(nil);
|
//MainForm.FileNewExecute(nil);
|
||||||
if ParamCount > 0 then
|
|
||||||
|
// With OS X app, ParamStr not meaningful unless launched with --args switch.
|
||||||
|
if (ParamCount > 0) {$IFDEF DARWIN} and (Copy(ParamStr(1), 1, 4) <> '-psn') {$ENDIF} then
|
||||||
MainForm.OpenImageFile(ParamStr(1))
|
MainForm.OpenImageFile(ParamStr(1))
|
||||||
else
|
else
|
||||||
MainForm.FileNewOnStart;
|
MainForm.FileNewOnStart;
|
||||||
|
|||||||
@ -9,6 +9,7 @@ uses
|
|||||||
|
|
||||||
const
|
const
|
||||||
DefaultDirectory = '/usr/share/lazimageeditor/';
|
DefaultDirectory = '/usr/share/lazimageeditor/';
|
||||||
|
BundleResourcesDirectory = '/Contents/Resources/';
|
||||||
|
|
||||||
SectionGeneral = 'General';
|
SectionGeneral = 'General';
|
||||||
IdentLanguage = 'Language';
|
IdentLanguage = 'Language';
|
||||||
|
|||||||
@ -33,7 +33,8 @@ uses
|
|||||||
Classes, SysUtils, LResources, Forms, Controls, Graphics, Dialogs, Menus,
|
Classes, SysUtils, LResources, Forms, Controls, Graphics, Dialogs, Menus,
|
||||||
ExtCtrls, ComCtrls, ActnList, StdActns, ExtDlgs, Buttons, StdCtrls, Spin,
|
ExtCtrls, ComCtrls, ActnList, StdActns, ExtDlgs, Buttons, StdCtrls, Spin,
|
||||||
ColorBox, NewDialog, ResizeDialog, ResizePaperDialog, AboutDialog, DLBitmap,
|
ColorBox, NewDialog, ResizeDialog, ResizePaperDialog, AboutDialog, DLBitmap,
|
||||||
PictureManager, PictureCtrls, ColorPalette;
|
PictureManager, PictureCtrls, ColorPalette,
|
||||||
|
appsettings;
|
||||||
|
|
||||||
type
|
type
|
||||||
|
|
||||||
@ -1017,7 +1018,7 @@ begin
|
|||||||
UpdatePictureToolsEnabled;
|
UpdatePictureToolsEnabled;
|
||||||
UpdateToolSettings;
|
UpdateToolSettings;
|
||||||
|
|
||||||
Palette.LoadPalette('default.pal');
|
Palette.LoadPalette(vConfigurations.MyDirectory + 'default.pal');
|
||||||
|
|
||||||
// Main Form
|
// Main Form
|
||||||
Caption := lieMain;
|
Caption := lieMain;
|
||||||
@ -1182,9 +1183,11 @@ begin
|
|||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TMainForm.FileNewOnStart;
|
procedure TMainForm.FileNewOnStart;
|
||||||
var i: integer;
|
var
|
||||||
|
i: integer;
|
||||||
begin
|
begin
|
||||||
if ParamCount > 0 then
|
// With OS X app, ParamStr not meaningful unless launched with --args switch.
|
||||||
|
if (ParamCount > 0) {$IFDEF DARWIN} and (Copy(ParamStr(1), 1, 4) <> '-psn') {$ENDIF} then
|
||||||
begin
|
begin
|
||||||
for i := 1 to ParamCount - 1 do
|
for i := 1 to ParamCount - 1 do
|
||||||
Pictures.Load(ParamStr(i));
|
Pictures.Load(ParamStr(i));
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user