mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-09-25 11:19:36 +02:00
implemented loading .lpk on cmd line
git-svn-id: trunk@6612 -
This commit is contained in:
parent
838c199783
commit
e0542e128f
21
ide/main.pp
21
ide/main.pp
@ -1541,16 +1541,20 @@ begin
|
|||||||
|
|
||||||
// load the cmd line files
|
// load the cmd line files
|
||||||
if CmdLineFiles<>nil then begin
|
if CmdLineFiles<>nil then begin
|
||||||
OpenFlags:=[ofAddToRecent,ofRegularFile];
|
|
||||||
for i:=0 to CmdLineFiles.Count-1 do
|
for i:=0 to CmdLineFiles.Count-1 do
|
||||||
Begin
|
Begin
|
||||||
AFilename:=CleanAndExpandFilename(CmdLineFiles.Strings[i]);
|
AFilename:=CleanAndExpandFilename(CmdLineFiles.Strings[i]);
|
||||||
if i<CmdLineFiles.Count then
|
if CompareFileExt(AFilename,'.lpk',false)=0 then begin
|
||||||
Include(OpenFlags,ofMultiOpen)
|
if PkgBoss.DoOpenPackageFile(AFilename,[pofAddToRecent])=mrAbort
|
||||||
else
|
then
|
||||||
Exclude(OpenFlags,ofMultiOpen);
|
break;
|
||||||
if DoOpenEditorFile(AFilename,-1,OpenFlags)=mrAbort then begin
|
end else begin
|
||||||
break;
|
OpenFlags:=[ofAddToRecent,ofRegularFile];
|
||||||
|
if i<CmdLineFiles.Count then
|
||||||
|
Include(OpenFlags,ofMultiOpen);
|
||||||
|
if DoOpenEditorFile(AFilename,-1,OpenFlags)=mrAbort then begin
|
||||||
|
break;
|
||||||
|
end;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
@ -11375,6 +11379,9 @@ end.
|
|||||||
|
|
||||||
{ =============================================================================
|
{ =============================================================================
|
||||||
$Log$
|
$Log$
|
||||||
|
Revision 1.834 2005/01/16 13:34:54 mattias
|
||||||
|
implemented loading .lpk on cmd line
|
||||||
|
|
||||||
Revision 1.833 2005/01/15 13:44:03 vincents
|
Revision 1.833 2005/01/15 13:44:03 vincents
|
||||||
use xml units from fpc, if not compiling with fpc 1.0
|
use xml units from fpc, if not compiling with fpc 1.0
|
||||||
|
|
||||||
|
@ -32,7 +32,7 @@ type
|
|||||||
ofRevert, // reload file if already open
|
ofRevert, // reload file if already open
|
||||||
ofQuiet, // less messages
|
ofQuiet, // less messages
|
||||||
ofAddToRecent, // add file to recent files
|
ofAddToRecent, // add file to recent files
|
||||||
ofRegularFile, // open as regular file (e.g. do not open projects)
|
ofRegularFile, // open as regular file (e.g. do not open projects/packages)
|
||||||
ofVirtualFile, // open the virtual file
|
ofVirtualFile, // open the virtual file
|
||||||
ofConvertMacros, // replace macros in filename
|
ofConvertMacros, // replace macros in filename
|
||||||
ofUseCache, // do not update file from disk
|
ofUseCache, // do not update file from disk
|
||||||
|
Loading…
Reference in New Issue
Block a user