Advertisement
TLama

Untitled

Jan 14th, 2014
271
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Delphi 0.31 KB | None | 0 0
  1. function GetIndex(const Subs: array of TaDirection; const Item: TaDirection): Integer;
  2. var
  3.   I: Integer;
  4. begin
  5.   Result := -1;
  6.   for I := Low(Subs) to High(Subs) do
  7.   begin
  8.     if CompareMem(@Subs[I], @Item, Length(Item) * SizeOf(TSubRect)) then
  9.     begin
  10.       Result := I;
  11.       Exit;
  12.     end;
  13.   end;
  14. end;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement