Ignore:
Timestamp:
Jan 16, 2007, 12:35:04 AM (18 years ago)
Author:
alloc
Message:

Rev86 was first after multi-cons

File:
1 edited

Legend:

Unmodified
Added
Removed
  • oup/current/Tools/TxmpReplace.pas

    r86 r92  
    5252begin
    5353  fileid := fileinfo.ID;
    54   OniDataConnection.LoadDatFilePart(fileid, $88, SizeOf(fadingbyte), @fadingbyte);
    55   OniDataConnection.LoadDatFilePart(fileid, $89, SizeOf(depthbyte), @depthbyte);
    56   OniDataConnection.LoadDatFilePart(fileid, $90, SizeOf(storebyte), @storebyte);
     54  Connection.LoadDatFilePart(fileid, $88, SizeOf(fadingbyte), @fadingbyte);
     55  Connection.LoadDatFilePart(fileid, $89, SizeOf(depthbyte), @depthbyte);
     56  Connection.LoadDatFilePart(fileid, $90, SizeOf(storebyte), @storebyte);
    5757  check_fading.Checked := (fadingbyte and $01) > 0;
    5858  check_transparency.Checked := (depthbyte and $04) > 0;
     
    103103  if filelist.ItemIndex >= 0 then
    104104  begin
    105     OniDataConnection.LoadDatFilePart(fileid, $88, 1, @oldfading);
    106     if OniDataConnection.OSisMac then
    107       OniDataConnection.UpdateDatFilePart(fileid, $A0, 4, @old_rawaddr)
     105    Connection.LoadDatFilePart(fileid, $88, 1, @oldfading);
     106    if Connection.OSisMac then
     107      Connection.UpdateDatFilePart(fileid, $A0, 4, @old_rawaddr)
    108108    else
    109       OniDataConnection.LoadDatFilePart(fileid, $9C, 4, @old_rawaddr);
     109      Connection.LoadDatFilePart(fileid, $9C, 4, @old_rawaddr);
    110110
    111111    if (OniImage_Old.Width <> OniImage_New.Width) or
     
    138138    newsize := OniImage_New.GetImageDataSize(check_fading.Checked);
    139139
    140     if (newsize > old_size) and (OniDataConnection.Backend = ODB_Dat) then
    141       new_rawaddr := OniDataConnection.AppendRawFile(
    142         OniDataConnection.OSisMac, Length(tempd), tempd)
     140    if (newsize > old_size) and (Connection.Backend = ODB_Dat) then
     141      new_rawaddr := Connection.AppendRawFile(
     142        Connection.OSisMac, Length(tempd), tempd)
    143143    else
    144144    begin
    145145      new_rawaddr := old_rawaddr;
    146       OniDataConnection.UpdateRawFile(fileid, $9C, Length(tempd), tempd);
     146      Connection.UpdateRawFile(fileid, $9C, Length(tempd), tempd);
    147147    end;
    148148
     
    150150    if check_fading.Checked then
    151151      datbyte := datbyte or $01;
    152     OniDataConnection.UpdateDatFilePart(fileid, $88, 1, @datbyte);
     152    Connection.UpdateDatFilePart(fileid, $88, 1, @datbyte);
    153153    datbyte := $10;
    154154    if check_transparency.Checked then
    155155      datbyte := datbyte or $04;
    156     OniDataConnection.UpdateDatFilePart(fileid, $89, 1, @datbyte);
    157     OniDataConnection.UpdateDatFilePart(fileid, $8C, 2, @OniImage_New.Width);
    158     OniDataConnection.UpdateDatFilePart(fileid, $8E, 2, @OniImage_New.Height);
     156    Connection.UpdateDatFilePart(fileid, $89, 1, @datbyte);
     157    Connection.UpdateDatFilePart(fileid, $8C, 2, @OniImage_New.Width);
     158    Connection.UpdateDatFilePart(fileid, $8E, 2, @OniImage_New.Height);
    159159    datbyte := $08;
    160     OniDataConnection.UpdateDatFilePart(fileid, $90, 1, @datbyte);
    161     if OniDataConnection.OSisMac then
    162       OniDataConnection.UpdateDatFilePart(fileid, $A0, 4, @new_rawaddr)
     160    Connection.UpdateDatFilePart(fileid, $90, 1, @datbyte);
     161    if Connection.OSisMac then
     162      Connection.UpdateDatFilePart(fileid, $A0, 4, @new_rawaddr)
    163163    else
    164       OniDataConnection.UpdateDatFilePart(fileid, $9C, 4, @new_rawaddr);
     164      Connection.UpdateDatFilePart(fileid, $9C, 4, @new_rawaddr);
    165165
    166166    ShowMessage('TXMP-image replaced');
Note: See TracChangeset for help on using the changeset viewer.