Changeset 61


Ignore:
Timestamp:
Dec 9, 2021, 12:31:17 AM (3 years ago)
Author:
chronos
Message:
  • Fixed: Build with older FPC version.
  • Added: Show also normal phone and work phone in the contact list.
Location:
trunk
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • trunk/Forms/UFormContacts.lfm

    r53 r61  
    1414  object ListView1: TListView
    1515    Left = 0
    16     Height = 801
     16    Height = 810
    1717    Top = 0
    1818    Width = 1210
     
    3636      end   
    3737      item
    38         Caption = 'Cell phone'
     38        Caption = 'Phone'
     39        Width = 150
     40      end   
     41      item
     42        Caption = 'Mobile'
    3943        Width = 150
    4044      end   
    4145      item
    4246        Caption = 'Home phone'
    43         Width = 295
     47        Width = 150
     48      end   
     49      item
     50        Caption = 'Work phone'
     51        Width = 150
    4452      end>
    4553    MultiSelect = True
     
    5866    Left = 0
    5967    Height = 39
    60     Top = 833
     68    Top = 842
    6169    Width = 1210
    6270    Align = alBottom
     
    106114    Left = 0
    107115    Height = 32
    108     Top = 801
     116    Top = 810
    109117    Width = 1210
    110118    OnChange = ListViewFilter1Change
     
    113121  object StatusBar1: TStatusBar
    114122    Left = 0
    115     Height = 36
    116     Top = 872
     123    Height = 27
     124    Top = 881
    117125    Width = 1210
    118126    Panels = <   
  • trunk/Forms/UFormContacts.lrj

    r53 r61  
    55{"hash":36093573,"name":"tformcontacts.listview1.columns[2].caption","sourcebytes":[77,105,100,100,108,101,32,110,97,109,101],"value":"Middle name"},
    66{"hash":174397109,"name":"tformcontacts.listview1.columns[3].caption","sourcebytes":[76,97,115,116,32,78,97,109,101],"value":"Last Name"},
    7 {"hash":242387557,"name":"tformcontacts.listview1.columns[4].caption","sourcebytes":[67,101,108,108,32,112,104,111,110,101],"value":"Cell phone"},
    8 {"hash":124920949,"name":"tformcontacts.listview1.columns[5].caption","sourcebytes":[72,111,109,101,32,112,104,111,110,101],"value":"Home phone"},
     7{"hash":5699141,"name":"tformcontacts.listview1.columns[4].caption","sourcebytes":[80,104,111,110,101],"value":"Phone"},
     8{"hash":88444965,"name":"tformcontacts.listview1.columns[5].caption","sourcebytes":[77,111,98,105,108,101],"value":"Mobile"},
     9{"hash":124920949,"name":"tformcontacts.listview1.columns[6].caption","sourcebytes":[72,111,109,101,32,112,104,111,110,101],"value":"Home phone"},
     10{"hash":225645765,"name":"tformcontacts.listview1.columns[7].caption","sourcebytes":[87,111,114,107,32,112,104,111,110,101],"value":"Work phone"},
    911{"hash":18340,"name":"tformcontacts.aadd.caption","sourcebytes":[65,100,100],"value":"Add"},
    1012{"hash":88453081,"name":"tformcontacts.amodify.caption","sourcebytes":[77,111,100,105,102,121],"value":"Modify"},
  • trunk/Forms/UFormContacts.pas

    r53 r61  
    120120    AddItem(Fields[cfMiddleName]);
    121121    AddItem(Fields[cfLastName]);
     122    AddItem(Fields[cfTel]);
    122123    AddItem(Fields[cfTelCell]);
    123124    AddItem(Fields[cfTelHome]);
     125    AddItem(Fields[cfTelWork]);
    124126    Item.Data := ListViewSort1.List[Item.Index];
    125127  end;
     
    158160      2: Result := CompareString(TContact(Item1).Fields[cfMiddleName], TContact(Item2).Fields[cfMiddleName]);
    159161      3: Result := CompareString(TContact(Item1).Fields[cfLastName], TContact(Item2).Fields[cfLastName]);
    160       4: Result := CompareString(TContact(Item1).Fields[cfTelCell], TContact(Item2).Fields[cfTelCell]);
    161       5: Result := CompareString(TContact(Item1).Fields[cfTelHome], TContact(Item2).Fields[cfTelHome]);
     162      4: Result := CompareString(TContact(Item1).Fields[cfTel], TContact(Item2).Fields[cfTel]);
     163      5: Result := CompareString(TContact(Item1).Fields[cfTelCell], TContact(Item2).Fields[cfTelCell]);
     164      6: Result := CompareString(TContact(Item1).Fields[cfTelHome], TContact(Item2).Fields[cfTelHome]);
     165      7: Result := CompareString(TContact(Item1).Fields[cfTelWork], TContact(Item2).Fields[cfTelWork]);
    162166    end;
    163167    if ListViewSort1.Order = soDown then Result := -Result;
     
    196200             UTF8LowerCase(TContact(List.Items[I]).Fields[cfLastName])) > 0 then Inc(FoundCount);
    197201           if Pos(UTF8LowerCase(StringGrid.Cells[4, 0]),
     202             UTF8LowerCase(TContact(List.Items[I]).Fields[cfTel])) > 0 then Inc(FoundCount);
     203           if Pos(UTF8LowerCase(StringGrid.Cells[5, 0]),
    198204             UTF8LowerCase(TContact(List.Items[I]).Fields[cfTelCell])) > 0 then Inc(FoundCount);
    199            if Pos(UTF8LowerCase(StringGrid.Cells[5, 0]),
     205           if Pos(UTF8LowerCase(StringGrid.Cells[6, 0]),
    200206             UTF8LowerCase(TContact(List.Items[I]).Fields[cfTelHome])) > 0 then Inc(FoundCount);
     207           if Pos(UTF8LowerCase(StringGrid.Cells[7, 0]),
     208             UTF8LowerCase(TContact(List.Items[I]).Fields[cfTelWork])) > 0 then Inc(FoundCount);
    201209           if FoundCount <> EnteredCount then List.Delete(I);
    202210         end;
  • trunk/Languages/vCardStudio.cs.po

    r59 r61  
    508508#: tformcontacts.listview1.columns[4].caption
    509509msgctxt "tformcontacts.listview1.columns[4].caption"
    510 msgid "Cell phone"
    511 msgstr "Mobilní telefon"
     510msgid "Phone"
     511msgstr "Telefon"
    512512
    513513#: tformcontacts.listview1.columns[5].caption
    514514msgctxt "tformcontacts.listview1.columns[5].caption"
     515msgid "Mobile"
     516msgstr "Mobil"
     517
     518#: tformcontacts.listview1.columns[6].caption
     519msgctxt "tformcontacts.listview1.columns[6].caption"
    515520msgid "Home phone"
    516521msgstr "Domácí telefon"
     522
     523#: tformcontacts.listview1.columns[7].caption
     524msgctxt "tformcontacts.listview1.columns[7].caption"
     525msgid "Work phone"
     526msgstr "Pracovní telefon"
    517527
    518528#: tformerror.caption
     
    10311041
    10321042#: ucontact.sworkphone
     1043msgctxt "ucontact.sworkphone"
    10331044msgid "Work phone"
    10341045msgstr "Pracovní telefon"
     
    11281139msgid "Invalid line length for encoded text"
    11291140msgstr "Neplatná délka řádky kódovaného textu"
    1130 
  • trunk/Languages/vCardStudio.po

    r59 r61  
    498498#: tformcontacts.listview1.columns[4].caption
    499499msgctxt "tformcontacts.listview1.columns[4].caption"
    500 msgid "Cell phone"
     500msgid "Phone"
    501501msgstr ""
    502502
    503503#: tformcontacts.listview1.columns[5].caption
    504504msgctxt "tformcontacts.listview1.columns[5].caption"
     505msgid "Mobile"
     506msgstr ""
     507
     508#: tformcontacts.listview1.columns[6].caption
     509msgctxt "tformcontacts.listview1.columns[6].caption"
    505510msgid "Home phone"
     511msgstr ""
     512
     513#: tformcontacts.listview1.columns[7].caption
     514msgctxt "tformcontacts.listview1.columns[7].caption"
     515msgid "Work phone"
    506516msgstr ""
    507517
     
    10191029
    10201030#: ucontact.sworkphone
     1031msgctxt "ucontact.sworkphone"
    10211032msgid "Work phone"
    10221033msgstr ""
  • trunk/UContact.pas

    r60 r61  
    640640var
    641641  I: Integer;
    642   C: Integer;
    643 begin
    644   C := Count;
     642begin
    645643  I := 0;
    646644  while (I < Count) and (Items[I].SysName <> SysName) do Inc(I);
     
    653651var
    654652  I: Integer;
    655   C: Integer;
    656 begin
    657   C := Count;
     653begin
    658654  I := 0;
    659655  while (I < Count) and not Items[I].Match(SysName, Groups) do Inc(I);
     
    951947  try
    952948    Lines.LoadFromFile(FileName);
     949    {$IF FPC_FULLVERSION>=30200}
    953950    if (Length(Lines.Text) > 0) and (Pos(VCardBegin, Lines.Text) = 0) then begin
    954951      Lines.LoadFromFile(FileName, TEncoding.Unicode);
     
    957954      end;
    958955    end;
     956    {$ENDIF}
    959957    LoadFromStrings(Lines);
    960958  finally
     
    11241122  Lines := TStringList.Create;
    11251123  Lines.LoadFromFile(FileName);
     1124  {$IF FPC_FULLVERSION>=30200}
    11261125  if (Length(Lines.Text) > 0) and (Pos(VCardBegin, Lines.Text) = 0) then begin
    11271126    Lines.LoadFromFile(FileName, TEncoding.Unicode);
     
    11301129    end;
    11311130  end;
     1131  {$ENDIF}
    11321132  try
    11331133    I := 0;
  • trunk/UCore.lfm

    r29 r61  
    501501    AppName = 'vCard Studio'
    502502    Description = 'vCard files management tool'
    503     ReleaseDate = 44524
     503    ReleaseDate = 44539
    504504    RegistryKey = '\Software\Chronosoft\vCard Studio'
    505505    RegistryRoot = rrKeyCurrentUser
Note: See TracChangeset for help on using the changeset viewer.