OSDN Git Service

勢いの表示で、ログ有りスレッドのみ生成日時を計算しているときは、
authorh677 <h677>
Sun, 25 Jun 2006 13:54:25 +0000 (13:54 +0000)
committerh677 <h677>
Sun, 25 Jun 2006 13:54:25 +0000 (13:54 +0000)
ログありのみ表示するように変更

ListViewUtils.pas

index dfe415c..a0ad672 100644 (file)
@@ -673,17 +673,20 @@ begin
                                Item.SubItems[ idx ] := FormatDateTime('yyyy/mm/dd hh:mm:ss', Thread.LastModified);
                gbcVigor:
                        begin
-                               if (Thread.AgeSage <> gasArch) then begin
-                                       spanday := DaySpan(Sort.GetSortDate, Thread.CreateDate);
-                               end else begin
-                                       spanday := DaySpan(Thread.LastModified, Thread.CreateDate);
-                               end;
-                               if (spanday > 0) then begin
-                                       Item.SubItems[ idx ] := Format('%f', [Thread.AllResCount / spanday]);
+                               if (Thread.CreateDate <> ZERO_DATE)  then begin
+                                       if (Thread.AgeSage <> gasArch) then begin
+                                               spanday := DaySpan(Sort.GetSortDate, Thread.CreateDate);
+                                       end else begin
+                                               spanday := DaySpan(Thread.LastModified, Thread.CreateDate);
+                                       end;
+                                       if (spanday > 0) then begin
+                                               Item.SubItems[ idx ] := Format('%f', [Thread.AllResCount / spanday]);
+                                       end else begin
+                                               Item.SubItems[ idx ] := '';
+                                       end;
                                end else begin
                                        Item.SubItems[ idx ] := '';
                                end;
-
                        end;
                end;
                Inc( idx );
@@ -719,18 +722,21 @@ begin
                        Item.SubItems[ idx ] := '';
                gbcVigor:
                        begin
-                               if (Thread.AgeSage <> gasArch) then begin
-                                       spanday := DaySpan(Sort.GetSortDate, Thread.CreateDate);
-                               end else begin
-                                       spanday := DaySpan(Thread.LastModified, Thread.CreateDate);
-                               end;
+                               if (Thread.CreateDate <> ZERO_DATE)  then begin
+                                       if (Thread.AgeSage <> gasArch) then begin
+                                               spanday := DaySpan(Sort.GetSortDate, Thread.CreateDate);
+                                       end else begin
+                                               spanday := DaySpan(Thread.LastModified, Thread.CreateDate);
+                                       end;
 
-                               if (spanday > 0) then begin
-                                       Item.SubItems[ idx ] := Format('%f', [Thread.AllResCount / spanday]);
+                                       if (spanday > 0) then begin
+                                               Item.SubItems[ idx ] := Format('%f', [Thread.AllResCount / spanday]);
+                                       end else begin
+                                               Item.SubItems[ idx ] := '';
+                                       end;
                                end else begin
                                        Item.SubItems[ idx ] := '';
                                end;
-
                        end;
                else
                        Item.SubItems[ idx ] := '';