| 38 |
property Count[RoundType: TGikoRoundType]: Integer read GetCount; |
property Count[RoundType: TGikoRoundType]: Integer read GetCount; |
| 39 |
property OldFileRead: Boolean read FOldFileRead; |
property OldFileRead: Boolean read FOldFileRead; |
| 40 |
property Items[Index: integer; RoundType: TGikoRoundType]: TRoundItem read GetRoundItem; |
property Items[Index: integer; RoundType: TGikoRoundType]: TRoundItem read GetRoundItem; |
| 41 |
procedure SetRoundName(Board: TBoard; RoundName: string); overload; |
//procedure SetRoundName(Board: TBoard; RoundName: string); overload; |
| 42 |
procedure SetRoundName(ThreadItem: TThreadItem; RoundName: string); overload; |
//procedure SetRoundName(ThreadItem: TThreadItem; RoundName: string); overload; |
| 43 |
|
|
| 44 |
procedure LoadRoundBoardFile; |
procedure LoadRoundBoardFile; |
| 45 |
procedure LoadRoundThreadFile; |
procedure LoadRoundThreadFile; |
| 163 |
begin |
begin |
| 164 |
Result := -1; |
Result := -1; |
| 165 |
idx := Find(Board); |
idx := Find(Board); |
| 166 |
RoundNameList.Add(Board.RoundName); |
//RoundNameList.Add(Board.RoundName); |
| 167 |
if idx = -1 then begin |
if idx = -1 then begin |
| 168 |
Item := TRoundItem.Create; |
Item := TRoundItem.Create; |
| 169 |
Item.FItem := Board; |
Item.FItem := Board; |
| 186 |
begin |
begin |
| 187 |
Result := -1; |
Result := -1; |
| 188 |
idx := Find(ThreadItem); |
idx := Find(ThreadItem); |
| 189 |
RoundNameList.Add(ThreadItem.RoundName); |
//RoundNameList.Add(ThreadItem.RoundName); |
| 190 |
if idx = -1 then begin |
if idx = -1 then begin |
| 191 |
Item := TRoundItem.Create; |
Item := TRoundItem.Create; |
| 192 |
Item.FItem := ThreadItem; |
Item.FItem := ThreadItem; |
| 337 |
end; |
end; |
| 338 |
end; |
end; |
| 339 |
end; |
end; |
| 340 |
|
{ |
| 341 |
procedure TRoundList.SetRoundName(Board: TBoard; RoundName: string); |
procedure TRoundList.SetRoundName(Board: TBoard; RoundName: string); |
| 342 |
var |
var |
| 343 |
idx: Integer; |
idx: Integer; |
| 349 |
Item.RoundName := RoundName; |
Item.RoundName := RoundName; |
| 350 |
end; |
end; |
| 351 |
end; |
end; |
| 352 |
|
} |
| 353 |
|
{ |
| 354 |
procedure TRoundList.SetRoundName(ThreadItem: TThreadItem; RoundName: string); |
procedure TRoundList.SetRoundName(ThreadItem: TThreadItem; RoundName: string); |
| 355 |
var |
var |
| 356 |
idx: Integer; |
idx: Integer; |
| 362 |
Item.RoundName := RoundName; |
Item.RoundName := RoundName; |
| 363 |
end; |
end; |
| 364 |
end; |
end; |
| 365 |
|
} |
| 366 |
function TRoundList.GetCount(RoundType: TGikoRoundType): Integer; |
function TRoundList.GetCount(RoundType: TGikoRoundType): Integer; |
| 367 |
begin |
begin |
| 368 |
Result := 0; |
Result := 0; |
| 600 |
end; |
end; |
| 601 |
if( board <> nil ) then begin |
if( board <> nil ) then begin |
| 602 |
if not board.Round then begin |
if not board.Round then begin |
| 603 |
board.RoundName := roundname; |
//board.RoundName := roundname; |
| 604 |
|
RoundNameList.Add(roundname); |
| 605 |
|
RoundNameList.Find(roundname, i); |
| 606 |
|
board.RoundName := PChar(RoundNameList[i]); |
| 607 |
board.Round := true; |
board.Round := true; |
| 608 |
end; |
end; |
| 609 |
Result := true; |
Result := true; |
| 647 |
end; |
end; |
| 648 |
if( threadItem <> nil ) then begin |
if( threadItem <> nil ) then begin |
| 649 |
if not threadItem.Round then begin |
if not threadItem.Round then begin |
| 650 |
threadItem.RoundName := roundname; |
//threadItem.RoundName := roundname; |
| 651 |
|
RoundNameList.Add(roundname); |
| 652 |
|
RoundNameList.Find(roundname, i); |
| 653 |
|
threadItem.RoundName := PChar(RoundNameList[i]); |
| 654 |
threadItem.Round := True; |
threadItem.Round := True; |
| 655 |
end; |
end; |
| 656 |
Result := true; |
Result := true; |
| 692 |
end; |
end; |
| 693 |
if( board <> nil ) then begin |
if( board <> nil ) then begin |
| 694 |
if not board.Round then begin |
if not board.Round then begin |
| 695 |
board.RoundName := roundname; |
//board.RoundName := roundname; |
| 696 |
|
RoundNameList.Add(roundname); |
| 697 |
|
RoundNameList.Find(roundname, i); |
| 698 |
|
board.RoundName := PChar(RoundNameList[i]); |
| 699 |
board.Round := true; |
board.Round := true; |
| 700 |
end; |
end; |
| 701 |
Result := true; |
Result := true; |
| 712 |
buf: string; |
buf: string; |
| 713 |
board: TBoard; |
board: TBoard; |
| 714 |
threadItem: TThreadItem; |
threadItem: TThreadItem; |
| 715 |
bbsID: string; |
bbsID: string; |
| 716 |
begin |
begin |
| 717 |
// Result := TRoundItem.Create; |
// Result := TRoundItem.Create; |
| 718 |
// Result.RoundType := grtItem; |
// Result.RoundType := grtItem; |
| 719 |
threadItem := nil; |
threadItem := nil; |
| 720 |
for i := 0 to 4 do begin |
for i := 0 to 4 do begin |
| 721 |
s := GikoSys.GetTokenIndex(Line, #1, i); |
s := GikoSys.GetTokenIndex(Line, #1, i); |
| 722 |
try |
try |
| 723 |
case i of |
case i of |
| 724 |
0: bbsID := s; |
0: bbsID := s; |
| 725 |
//1: Result.BoardTitle := s; |
//1: Result.BoardTitle := s; |
| 726 |
2: |
2: |
| 727 |
begin |
begin |
| 745 |
end; |
end; |
| 746 |
if( threadItem <> nil ) then begin |
if( threadItem <> nil ) then begin |
| 747 |
if not threadItem.Round then begin |
if not threadItem.Round then begin |
| 748 |
threadItem.RoundName := roundname; |
//threadItem.RoundName := roundname; |
| 749 |
|
RoundNameList.Add(roundname); |
| 750 |
|
RoundNameList.Find(roundname, i); |
| 751 |
|
threadItem.RoundName := PChar(RoundNameList[i]); |
| 752 |
threadItem.Round := true; |
threadItem.Round := true; |
| 753 |
end; |
end; |
| 754 |
Result := true; |
Result := true; |