Added: Delphi 6 support
This commit is contained in:
parent
25f0fb41a1
commit
96deb77011
Binary file not shown.
|
@ -30,7 +30,7 @@ type
|
|||
FViewFormAction: TContainedAction;
|
||||
protected
|
||||
function ActiveFileName(): String;
|
||||
{$IFDEF DELPHI7}
|
||||
{$IFDEF DELPHI7ORLOWER}
|
||||
function ActiveGroup(): IOTAProjectGroup;
|
||||
{$ENDIF}
|
||||
function ActiveProject(): IOTAProject;
|
||||
|
@ -58,7 +58,7 @@ begin
|
|||
Assert(Supports(BorlandIDEServices, IOTAModuleServices),
|
||||
'BorlandIDEServices does not support the ' +
|
||||
'IOTAModuleServices interface.');
|
||||
{$IFDEF DELPHI7}
|
||||
{$IFDEF DELPHI7ORLOWER}
|
||||
Assert(Supports(BorlandIDEServices, IOTAActionServices),
|
||||
'BorlandIDEServices does not support the ' +
|
||||
'IOTAActionServices interface.');
|
||||
|
@ -116,7 +116,7 @@ begin
|
|||
end;
|
||||
end;
|
||||
|
||||
{$IFDEF DELPHI7}
|
||||
{$IFDEF DELPHI7ORLOWER}
|
||||
function TUnitSwitcherHook.ActiveGroup(): IOTAProjectGroup;
|
||||
var
|
||||
module: IOTAModule;
|
||||
|
@ -136,7 +136,7 @@ end;
|
|||
{$ENDIF}
|
||||
|
||||
function TUnitSwitcherHook.ActiveProject(): IOTAProject;
|
||||
{$IFDEF DELPHI7}
|
||||
{$IFDEF DELPHI7ORLOWER}
|
||||
var
|
||||
projectGroup: IOTAProjectGroup;
|
||||
module: IOTAModule;
|
||||
|
@ -145,7 +145,7 @@ var
|
|||
{$ENDIF}
|
||||
|
||||
begin
|
||||
{$IFDEF DELPHI7}
|
||||
{$IFDEF DELPHI7ORLOWER}
|
||||
Result := nil;
|
||||
projectGroup := ActiveGroup();
|
||||
if not Assigned(projectGroup) then
|
||||
|
|
|
@ -1,7 +1,16 @@
|
|||
// Lowest supprted version is Delphi 7. It lacks some OTA functionality
|
||||
// Lowest supprted version is Delphi 6. It lacks some OTA functionality
|
||||
// in comparison to Delphi 2006. Note that UnitSwitcher has not been tested
|
||||
// on any other Delphi version!
|
||||
{$UNDEF DELPHI6}
|
||||
{$UNDEF DELPHI7}
|
||||
{$UNDEF DELPHI7ORLOWER}
|
||||
|
||||
{$IFDEF VER140}
|
||||
{$DEFINE DELPHI6}
|
||||
{$DEFINE DELPHI7ORLOWER}
|
||||
{$ENDIF}
|
||||
|
||||
{$IFDEF VER150}
|
||||
{$DEFINE DELPHI7}
|
||||
{$DEFINE DELPHI7ORLOWER}
|
||||
{$ENDIF}
|
||||
|
|
|
@ -145,7 +145,7 @@ type
|
|||
|
||||
implementation
|
||||
uses
|
||||
{$IFDEF DELPHI7}
|
||||
{$IFDEF DELPHI7ORLOWER}
|
||||
ActnList,
|
||||
{$ENDIF}
|
||||
SysUtils;
|
||||
|
@ -271,7 +271,7 @@ begin
|
|||
end;
|
||||
|
||||
procedure TUnSwProjectUnit.Activate(const ASource: Boolean);
|
||||
{$IFDEF DELPHI7}
|
||||
{$IFDEF DELPHI7ORLOWER}
|
||||
var
|
||||
actionIndex: Integer;
|
||||
ntaServices: INTAServices;
|
||||
|
@ -279,7 +279,7 @@ var
|
|||
{$ENDIF}
|
||||
|
||||
begin
|
||||
{$IFDEF DELPHI7}
|
||||
{$IFDEF DELPHI7ORLOWER}
|
||||
// Bit of a hack, but opening the file itself will result in Delphi 7
|
||||
// reloading the project...
|
||||
ntaServices := (BorlandIDEServices as INTAServices);
|
||||
|
|
Loading…
Reference in New Issue