procedure TGikoForm.DeleteHistory( threadItem: TThreadItem );
var
i: Integer;
-begin
+ node: TTreeNode;
+begin
+ // \83L\83\83\83r\83l\83b\83g\82É\97\9a\97ð\82ª\95\\8e¦\82³\82ê\82Ä\82¢\82½\82ç\81A
+ // \83L\83\83\83r\83l\83b\83g\93à\82Ì\83A\83C\83e\83\80\82à\8dí\8f\9c\82·\82é\81B
+ if (FTreeType = gttHistory) then begin
+ node := TreeView.Items.GetFirstNode;
+ while (node <> nil) do begin
+ if ( TFavoriteThreadItem(node.Data).Item = threadItem ) then begin
+ TreeView.Items.Delete(node);
+ TreeView.Refresh;
+ node := nil;
+ end else begin
+ node := node.GetNext;
+ end;
+ end;
+ end;
for i := 0 to FHistoryList.Count - 1 do begin
- if threadItem.URL = TFavoriteThreadItem( FHistoryList.Items[i] ).URL then begin
+ if threadItem = TFavoriteThreadItem( FHistoryList.Items[i] ).Item then begin
TFavoriteThreadItem( FHistoryList.Items[ i ] ).Free;
FHistoryList.Delete(i);
- FHistoryList.Capacity := FHistoryList.Count;
+ FHistoryList.Capacity := FHistoryList.Count;
Break;
end;
end;
end;
procedure TGikoForm.ShowFavoriteAddDialog( Item : TObject );
+const
+ MsgAdd : String = '\8aù\82É\82¨\8bC\82É\93ü\82è\82É\93o\98^\82³\82ê\82Ä\82¢\82Ü\82·\81B\82»\82ê\82Å\82à\92Ç\89Á\82µ\82Ü\82·\82©\81H';
+ TitleAdd: String = '\82¨\8bC\82É\93ü\82è\82Ì\92Ç\89Á';
var
Dlg : TFavoriteAddDialog;
ItemURL : string;
Data := Node.Data;
if TObject( Data ) is TFavoriteBoardItem then begin
if ItemURL = TFavoriteBoardItem( Data ).URL then begin
- if Application.MessageBox( '\8aù\82É\82¨\8bC\82É\93ü\82è\82É\93o\98^\82³\82ê\82Ä\82¢\82Ü\82·\81B\82»\82ê\82Å\82à\92Ç\89Á\82µ\82Ü\82·\82©\81H', '\82¨\8bC\82É\93ü\82è\82Ì\92Ç\89Á', MB_YESNO ) = IDNO then
+ if Application.MessageBox(PChar(MsgAdd) , PChar(TitleAdd), MB_YESNO ) = IDNO then
Exit;
Break;
end;
Data := Node.Data;
if TObject( Data ) is TFavoriteThreadItem then begin
if ItemURL = TFavoriteThreadItem( Data ).URL then begin
- if Application.MessageBox( '\8aù\82É\82¨\8bC\82É\93ü\82è\82É\93o\98^\82³\82ê\82Ä\82¢\82Ü\82·\81B\82»\82ê\82Å\82à\92Ç\89Á\82µ\82Ü\82·\82©\81H', '\82¨\8bC\82É\93ü\82è\82Ì\92Ç\89Á', MB_YESNO ) = IDNO then
+ if Application.MessageBox( PChar(MsgAdd), PChar(TitleAdd), MB_YESNO ) = IDNO then
Exit;
Break;
end;