Develop and Download Open Source Software

Browse CVS Repository

Annotation of /gikonavigoeson/gikonavi/Giko.pas

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.175 - (hide annotations) (download) (as text)
Tue Dec 9 14:08:22 2003 UTC (20 years, 4 months ago) by h677
Branch: MAIN
Changes since 1.174: +8 -0 lines
File MIME type: text/x-pascal
バタ44以前の巡回ファイルのコンバーターを作った。 

1 hi_ 1.1 unit Giko;
2    
3     interface
4    
5     uses
6     Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms,
7 yoffy 1.117 OleCtrls, ComCtrls, ExtCtrls, Menus, StdCtrls, MMSystem, DateUtils, Math,
8 hi_ 1.4 {$IF Defined(DELPRO) }
9 yoffy 1.138 SHDocVw,
10 hi_ 1.4 MSHTML,
11     {$ELSE}
12     SHDocVw_TLB,
13     MSHTML_TLB,
14     {$IFEND}
15 yoffy 1.2 IdHTTP, ActiveX, Clipbrd, Buttons, ToolWin, {HTTPApp,} YofUtils, IdComponent,
16 hi_ 1.4 ShellAPI, ImgList, ActnList, UrlMon, Tabs, IdGlobal, StrUtils,
17 h677 1.170 CommCtrl, IniFiles, Dialogs,
18 hi_ 1.1 GikoSystem, GikoUtil, Setting, BoardGroup, ThreadControl, ItemDownload,
19     Editor, RoundData, RoundName, KeySetting, GikoPanel, Favorite, FavoriteAdd,
20     FavoriteArrange, AddressHistory, Preview, HTMLDocumentEvent, Kotehan,
21 h677 1.35 HintWindow, GikoCoolBar, GikoListView, ToolBarSetting, ToolBarUtil,
22 h677 1.170 IndividualAbon, Search, ExternalBoardManager, ExternalBoardPlugInMain,
23 yoffy 1.135 StdActns, GikoXMLDoc;
24 hi_ 1.1
25     type
26 yoffy 1.138 TGikoTreeType = (gttNone, gtt2ch, gttHistory, gttFavorite);
27 hi_ 1.1
28     TGikoForm = class(TForm)
29     StatusBar: TStatusBar;
30     MainPanel: TPanel;
31     ClientPanel: TPanel;
32     TreeSplitter: TSplitter;
33     CabinetPanel: TPanel;
34     TreeView: TTreeView;
35     ThreadMainPanel: TPanel;
36     ListSplitter: TSplitter;
37     ViewPanel: TPanel;
38 yoffy 1.51 ListView: TGikoListView;
39 hi_ 1.1 ThreadPanel: TPanel;
40     Browser: TWebBrowser;
41     MessagePanel: TPanel;
42     MessageBar: TPanel;
43     MessageHideButton: TSpeedButton;
44     MessageListView: TListView;
45     MessageSplitter: TSplitter;
46     Panel3: TPanel;
47     SpeedButton1: TSpeedButton;
48     ToolBar1: TToolBar;
49     CabinetSelectToolButton: TToolButton;
50     HistoryToolBar: TToolBar;
51     ToolButton15: TToolButton;
52     ToolButton18: TToolButton;
53     ItemIcon16: TImageList;
54     ItemIcon32: TImageList;
55 yoffy 1.2 HotToobarImageList: TImageList;
56 yoffy 1.51 ToobarImageList: TImageList;
57 hi_ 1.1 ItemImageList: TImageList;
58 yoffy 1.2 ActionList: TActionList;
59 hi_ 1.1 LogDeleteAction: TAction;
60     KidokuAction: TAction;
61     StdToolBarVisibleAction: TAction;
62     SearchAction: TAction;
63 yoffy 1.51 GikoNaviWebPageAction: TAction;
64 hi_ 1.1 AboutAction: TAction;
65     ExitAction: TAction;
66 yoffy 1.51 MsgBarVisibleAction: TAction;
67 hi_ 1.1 StatusBarVisibleAction: TAction;
68     LargeIconAction: TAction;
69     SmallIconAction: TAction;
70     ListIconAction: TAction;
71 yoffy 1.51 DetailIconAction: TAction;
72 yoffy 1.141 CabinetBBSAction: TAction;
73 hi_ 1.1 CabinetHistoryAction: TAction;
74 yoffy 1.51 CabinetVisibleAction: TAction;
75     MidokuAction: TAction;
76 hi_ 1.1 AllSelectAction: TAction;
77     UpFolderAction: TAction;
78 yoffy 1.51 ListNumberVisibleAction: TAction;
79 hi_ 1.1 AllItemAction: TAction;
80 yoffy 1.51 LogItemAction: TAction;
81     NewItemAction: TAction;
82 hi_ 1.1 SelectItemAction: TAction;
83     ShowThreadAction: TAction;
84     StopAction: TAction;
85     MainMenu: TMainMenu;
86     FileMenu: TMenuItem;
87 yoffy 1.51 DeleteMenu: TMenuItem;
88     ExitMenu: TMenuItem;
89     KidokuMenu: TMenuItem;
90 hi_ 1.1 MidokuMenu: TMenuItem;
91 yoffy 1.51 AllSelectMenu: TMenuItem;
92 hi_ 1.1 ViewMenu: TMenuItem;
93     StdToolBarMenu: TMenuItem;
94     CabinetMenu: TMenuItem;
95 yoffy 1.51 H1: TMenuItem;
96 hi_ 1.1 N4: TMenuItem;
97 yoffy 1.51 CabinetVisibleMenu: TMenuItem;
98 hi_ 1.1 MessageMenu: TMenuItem;
99     StatusBarMenu: TMenuItem;
100     MMSep03: TMenuItem;
101 yoffy 1.51 LargeIconMenu: TMenuItem;
102 hi_ 1.1 SmallIconMenu: TMenuItem;
103     ListMenu: TMenuItem;
104     DetailMenu: TMenuItem;
105 yoffy 1.51 ToolMenu: TMenuItem;
106 hi_ 1.1 Find1: TMenuItem;
107     RoundMenu: TMenuItem;
108     MMSep04: TMenuItem;
109     OptionMenu: TMenuItem;
110     HelpMenu: TMenuItem;
111     G1: TMenuItem;
112 yoffy 1.51 N1: TMenuItem;
113 hi_ 1.1 AboutMenu: TMenuItem;
114 yoffy 1.51 IconStyle: TAction;
115 hi_ 1.1 BrowserPopupMenu: TPopupMenu;
116 yoffy 1.51 ShowThreadMenu: TMenuItem;
117 yoffy 1.2 ShowBoardMenu: TMenuItem;
118 hi_ 1.1 ShowBoardAction: TAction;
119     ListIconPopupMenu: TPopupMenu;
120     LargeIconPMenu: TMenuItem;
121     SmallIconPMenu: TMenuItem;
122     ListPMenu: TMenuItem;
123 yoffy 1.51 DetailPMenu: TMenuItem;
124     CabinetCloseAction: TAction;
125 hi_ 1.1 ClosePopupMenu: TPopupMenu;
126 yoffy 1.51 CloseMenu: TMenuItem;
127     OptionAction: TAction;
128 hi_ 1.1 U1: TMenuItem;
129     N3: TMenuItem;
130     B1: TMenuItem;
131     S1: TMenuItem;
132     N2: TMenuItem;
133     A1: TMenuItem;
134     L1: TMenuItem;
135     N5: TMenuItem;
136     S2: TMenuItem;
137 yoffy 1.51 RoundAction: TAction;
138 hi_ 1.1 ListPopupMenu: TPopupMenu;
139 yoffy 1.51 ListRoundPMenu: TMenuItem;
140 hi_ 1.1 ListReservPMenu: TMenuItem;
141     LPMSep01: TMenuItem;
142 yoffy 1.51 ItemRoundPMenu: TMenuItem;
143 hi_ 1.1 LPMSep02: TMenuItem;
144 yoffy 1.2 KidokuPMenu: TMenuItem;
145 hi_ 1.1 MidokuPMenu: TMenuItem;
146     AllSelectPMenu: TMenuItem;
147     UrlCopyPMenu: TMenuItem;
148     LPMSep05: TMenuItem;
149     DeletePMenu: TMenuItem;
150     LPMSep06: TMenuItem;
151     ViewPMenu: TMenuItem;
152     LargeIconLPMenu: TMenuItem;
153     SmallIconLPMenu: TMenuItem;
154     ListLPMenu: TMenuItem;
155     DetailLPMenu: TMenuItem;
156     T1: TMenuItem;
157     B2: TMenuItem;
158     N8: TMenuItem;
159     URLCopyAction: TAction;
160 yoffy 1.51 URLC1: TMenuItem;
161     N9: TMenuItem;
162 hi_ 1.1 N10: TMenuItem;
163 yoffy 1.51 MsgBarCloseAction: TAction;
164     ScrollTopAction: TAction;
165 hi_ 1.1 ScrollLastAction: TAction;
166     ScrollNewAction: TAction;
167     ScrollKokoAction: TAction;
168 yoffy 1.51 EditorAction: TAction;
169 hi_ 1.1 IEAction: TAction;
170     ItemReloadAction: TAction;
171 yoffy 1.51 BrowserMaxAction: TAction;
172 hi_ 1.1 G2: TMenuItem;
173     N11: TMenuItem;
174     T3: TMenuItem;
175     L2: TMenuItem;
176     N12: TMenuItem;
177     K1: TMenuItem;
178     N13: TMenuItem;
179     N14: TMenuItem;
180     R1: TMenuItem;
181     A2: TMenuItem;
182     N15: TMenuItem;
183 yoffy 1.51 SelectListReloadAction: TAction;
184     SelectThreadReloadAction: TAction;
185 hi_ 1.1 SelectTimer: TTimer;
186     KokoPopupMenu: TPopupMenu;
187     KokomadePMenu: TMenuItem;
188 yoffy 1.2 AllPMenu: TMenuItem;
189 hi_ 1.1 MenuItem1: TMenuItem;
190     MenuItem2: TMenuItem;
191     BrowserTabCloseAction: TAction;
192     BrowserTabPopupMenu: TPopupMenu;
193 yoffy 1.51 Close1: TMenuItem;
194 hi_ 1.1 KokomadeAction: TAction;
195     ZenbuAction: TAction;
196     KokoResAction: TAction;
197     SelectItemURLCopyAction: TAction;
198     SelectReservAction: TAction;
199     NotSelectTabCloseAction: TAction;
200     A3: TMenuItem;
201 yoffy 1.51 N16: TMenuItem;
202 hi_ 1.1 A4: TMenuItem;
203     TreePopupMenu: TPopupMenu;
204     TreeSelectThreadPupupMenu: TMenuItem;
205 yoffy 1.51 TreeSelectBoardPupupMenu: TMenuItem;
206 hi_ 1.1 TPMSep01: TMenuItem;
207     TreeSelectURLPupupMenu: TMenuItem;
208     TreeSelectBoradReload: TAction;
209 yoffy 1.51 TreeSelectThreadReload: TAction;
210 hi_ 1.1 TreeSelectURLCopy: TAction;
211     ListToolBarVisibleAction: TAction;
212     BrowserToolBarVisibleAction: TAction;
213     T2: TMenuItem;
214 yoffy 1.2 L3: TMenuItem;
215 hi_ 1.1 B3: TMenuItem;
216     BrowserBottomPanel: TGikoPanel;
217     CabinetSelectPopupMenu: TPopupMenu;
218     H2: TMenuItem;
219 yoffy 1.51 ItemReservPMenu: TMenuItem;
220     RoundNamePopupMenu: TPopupMenu;
221 hi_ 1.1 SelectNewRoundName: TAction;
222 yoffy 1.51 SelectDeleteRound: TAction;
223     NewBoardAction: TAction;
224 yoffy 1.2 N7: TMenuItem;
225 hi_ 1.1 B4: TMenuItem;
226     LoginAction: TAction;
227     L4: TMenuItem;
228     KeySettingAction: TAction;
229     K2: TMenuItem;
230     AllTabCloseAction: TAction;
231 yoffy 1.51 A5: TMenuItem;
232 hi_ 1.1 A6: TMenuItem;
233 yoffy 1.51 C1: TMenuItem;
234     V1: TMenuItem;
235     N19: TMenuItem;
236 hi_ 1.1 D1: TMenuItem;
237 yoffy 1.51 D2: TMenuItem;
238     MessageImageList: TImageList;
239     ProgressBar: TProgressBar;
240     ArrangeAction: TAction;
241     URL1: TMenuItem;
242     NameURLCopyAction: TAction;
243     SelectItemNameURLCopyAction: TAction;
244 hi_ 1.1 NameUrlCopyPMenu: TMenuItem;
245     URLC2: TMenuItem;
246 yoffy 1.51 URLN1: TMenuItem;
247     N21: TMenuItem;
248     URLC3: TMenuItem;
249 yoffy 1.2 URLN2: TMenuItem;
250 hi_ 1.1 N22: TMenuItem;
251 yoffy 1.51 N23: TMenuItem;
252 yoffy 1.2 ListCoolBar: TGikoCoolBar;
253 hi_ 1.1 ListToolBar: TToolBar;
254     ViewNoButton: TToolButton;
255     IconToolButton: TToolButton;
256 yoffy 1.51 UpFolderButton: TToolButton;
257     Sepa01ToolButton: TToolButton;
258 yoffy 1.2 AllItemToolButton: TToolButton;
259 hi_ 1.1 LogItemToolButton: TToolButton;
260     NewItemToolButton: TToolButton;
261 yoffy 1.51 ListDownloadToolButton: TToolButton;
262 hi_ 1.1 ListThreadDownloadToolButton: TToolButton;
263 yoffy 1.51 ToolButton2: TToolButton;
264     ToolButton1: TToolButton;
265 yoffy 1.2 BrowserCoolBar: TGikoCoolBar;
266 hi_ 1.1 BrowserToolBar: TToolBar;
267 yoffy 1.51 BrowserSizeButton: TToolButton;
268 hi_ 1.1 ToolButton3: TToolButton;
269     TopButton: TToolButton;
270 yoffy 1.2 LastBotton: TToolButton;
271     NewButton: TToolButton;
272 yoffy 1.51 KokoButton: TToolButton;
273     ToolButton9: TToolButton;
274 yoffy 1.2 EditorButton: TToolButton;
275 hi_ 1.1 ToolButton11: TToolButton;
276     IEButton: TToolButton;
277 yoffy 1.51 ToolButton5: TToolButton;
278     ItemReloadButton: TToolButton;
279 hi_ 1.1 ListNameToolBar: TToolBar;
280 yoffy 1.51 ListNameLabel: TLabel;
281 hi_ 1.1 FolderImage: TImage;
282     BrowserNameToolBar: TToolBar;
283     ItemBoardImage: TImage;
284     BrowserBoardNameLabel: TLabel;
285 yoffy 1.51 ItemImage: TImage;
286     BrowserNameLabel: TLabel;
287     ActiveLogDeleteAction: TAction;
288     D3: TMenuItem;
289     N25: TMenuItem;
290 hi_ 1.1 N26: TMenuItem;
291     ListNameBarVisibleAction: TAction;
292     D4: TMenuItem;
293     BrowserNameBarVisibleAction: TAction;
294     S3: TMenuItem;
295 yoffy 1.51 R2: TMenuItem;
296     TreeSelectNameURLCopy: TAction;
297     TreeSelectNameURLPupupMenu: TMenuItem;
298     N27: TMenuItem;
299 hi_ 1.1 H3: TMenuItem;
300     PaneInitAction: TAction;
301 yoffy 1.51 I1: TMenuItem;
302     BrowserTabToolBar: TToolBar;
303     BrowserTab: TTabControl;
304 hi_ 1.1 ToolButton7: TToolButton;
305 yoffy 1.2 BrowserMinAction: TAction;
306 yoffy 1.51 About1: TMenuItem;
307     N28: TMenuItem;
308     SelectTextClearAction: TAction;
309     MailTextClearAction: TAction;
310 hi_ 1.1 NameTextClearAction: TAction;
311 yoffy 1.51 S4: TMenuItem;
312 yoffy 1.2 N29: TMenuItem;
313     N30: TMenuItem;
314 hi_ 1.1 LeftmostTabSelectAction: TAction;
315 yoffy 1.51 LeftTabSelectAction: TAction;
316     RightTabSelectAction: TAction;
317     RightmostTabSelectAction: TAction;
318 yoffy 1.2 N31: TMenuItem;
319 hi_ 1.1 L5: TMenuItem;
320 yoffy 1.51 L6: TMenuItem;
321 hi_ 1.1 A7: TMenuItem;
322 yoffy 1.51 R3: TMenuItem;
323 hi_ 1.1 FavoriteMenu: TMenuItem;
324 yoffy 1.51 FavoriteAddAction: TAction;
325     N32: TMenuItem;
326 hi_ 1.1 BoardFavoriteAddMenu: TMenuItem;
327 yoffy 1.2 BoardFavoriteAddAction: TAction;
328 hi_ 1.1 ThreadFavoriteAddAction: TAction;
329     ThreadFavoriteAddMenu: TMenuItem;
330     TreeSelectFavoriteAddAction: TAction;
331 yoffy 1.2 N33: TMenuItem;
332 hi_ 1.1 TreeSelectFavoriteAddPupupMenu: TMenuItem;
333     FavoriteArrangeAction: TAction;
334     FavoriteTreeView: TTreeView;
335 yoffy 1.51 StateIconImageList: TImageList;
336     TopPanel: TPanel;
337     TopRightPanel: TPanel;
338     AnimePanel: TPanel;
339 hi_ 1.1 Animate: TAnimate;
340     TopCoolPanel: TPanel;
341 yoffy 1.51 MainCoolBar: TGikoCoolBar;
342     MenuToolBar: TToolBar;
343     StdToolBar: TToolBar;
344     RoundToolButton: TToolButton;
345     ToolButton6: TToolButton;
346     ToolButton4: TToolButton;
347 hi_ 1.1 ToolButton13: TToolButton;
348     AbortToolButton: TToolButton;
349     LoginToolButton: TToolButton;
350 yoffy 1.51 AddressToolBar: TToolBar;
351     AddressComboBox: TComboBox;
352     MoveToToolButton: TToolButton;
353 yoffy 1.2 MoveToAction: TAction;
354 yoffy 1.51 AddressImageList: TImageList;
355     AddressBarVisibleAction: TAction;
356     AddressToolBarMenu: TMenuItem;
357     T4: TMenuItem;
358 hi_ 1.1 BrowserTabVisibleAction: TAction;
359 yoffy 1.51 Show1: TMenuItem;
360     N34: TMenuItem;
361     BrowserTabTopAction: TAction;
362 yoffy 1.2 BrowserTabBottomAction: TAction;
363 hi_ 1.1 T5: TMenuItem;
364     B5: TMenuItem;
365 yoffy 1.51 N35: TMenuItem;
366     BrowserTabTabStyleAction: TAction;
367     BrowserTabButtonStyleAction: TAction;
368     BrowserTabFlatStyleAction: TAction;
369     A8: TMenuItem;
370     U2: TMenuItem;
371 hi_ 1.1 F1: TMenuItem;
372     PreviewTimer: TTimer;
373 yoffy 1.51 MonazillaWebPageAction: TAction;
374     MonazillaWebPageAction1: TMenuItem;
375 hi_ 1.1 GikoHelpAction: TAction;
376 yoffy 1.51 N36: TMenuItem;
377     H4: TMenuItem;
378     KotehanAction: TAction;
379     K3: TMenuItem;
380     LinkBarVisibleAction: TAction;
381     L7: TMenuItem;
382     N37: TMenuItem;
383     A9: TMenuItem;
384 yoffy 1.2 ChevronPopupMenu: TPopupMenu;
385 yoffy 1.51 BBS2chWebPageAction: TAction;
386 yoffy 1.2 N2N1: TMenuItem;
387 hi_ 1.1 N38: TMenuItem;
388     GikoFolderOpenAction: TAction;
389 yoffy 1.2 F2: TMenuItem;
390 yoffy 1.51 LinkToolBar: TToolBar;
391     a10: TMenuItem;
392     ToolButton8: TToolButton;
393 yoffy 1.2 ToolButton10: TToolButton;
394 yoffy 1.51 ThreadEditorAction: TAction;
395     N39: TMenuItem;
396     T6: TMenuItem;
397     N40: TMenuItem;
398 yoffy 1.2 LinkBarPopupMenu: TPopupMenu;
399 yoffy 1.51 ToolBarSettingAction: TAction;
400     T7: TMenuItem;
401     ToolButton12: TToolButton;
402     ToolButton14: TToolButton;
403     ThreadPopupMenu: TPopupMenu;
404     MenuItem4: TMenuItem;
405     MenuItem5: TMenuItem;
406     MenuItem6: TMenuItem;
407 yoffy 1.2 T8: TMenuItem;
408 yoffy 1.51 NameCopyAction: TAction;
409     BoardIEAction: TAction;
410     URLN3: TMenuItem;
411     SelectItemNameCopyAction: TAction;
412 yoffy 1.2 SelectItemNameCopyAction1: TMenuItem;
413 yoffy 1.51 B6: TMenuItem;
414     T9: TMenuItem;
415     C2: TMenuItem;
416     SelectComboBox: TComboBox;
417     MainCoolBarPopupMenu: TPopupMenu;
418     StdToolBarVisiblePMenu: TMenuItem;
419     AddressToolBarVisiblePMenu: TMenuItem;
420     LinkToolBarVisiblePMenu: TMenuItem;
421     NG1: TMenuItem;
422     NG2: TMenuItem;
423     N43: TMenuItem;
424     N44: TMenuItem;
425     L9: TMenuItem;
426     I3: TMenuItem;
427     N45: TMenuItem;
428     B9: TMenuItem;
429     R5: TMenuItem;
430     T12: TMenuItem;
431     Show3: TMenuItem;
432     N46: TMenuItem;
433     T13: TMenuItem;
434     B10: TMenuItem;
435     N47: TMenuItem;
436     A12: TMenuItem;
437     U4: TMenuItem;
438     F4: TMenuItem;
439     N48: TMenuItem;
440     T14: TMenuItem;
441     SelectItemToolButton: TToolButton;
442     SelectResToolButton: TToolButton;
443     SelectResAction: TAction;
444     ToolButton16: TToolButton;
445     AllResAction: TAction;
446     AllResToolButton: TToolButton;
447     N50: TMenuItem;
448     A11: TMenuItem;
449     S5: TMenuItem;
450     Reload: TMenuItem;
451     GoBack: TMenuItem;
452     GoFoward: TMenuItem;
453     EditAction: TAction;
454     ReloadAction: TAction;
455     GoFowardAction: TAction;
456     GoBackAction: TAction;
457     SelectComboBoxSplitter: TImage;
458     IndividualAbon1: TMenuItem;
459     N41: TMenuItem;
460     IndividualAbon2: TMenuItem;
461     N42: TMenuItem;
462     CancellIndividualAbon: TAction;
463     AntiIndividualAbon: TMenuItem;
464     N49: TMenuItem;
465     N51: TMenuItem;
466     N52: TMenuItem;
467     N53: TMenuItem;
468     SearchBoardName: TMenuItem;
469     N55: TMenuItem;
470     TreeSelectSearchBoardName: TAction;
471 yoffy 1.100 CabinetFavoriteAction: TAction;
472     N54: TMenuItem;
473     A13: TMenuItem;
474     FavoriteTreePopupMenu: TPopupMenu;
475     FavoriteTreeViewRenameAction: TAction;
476     FavoriteTreeRenamePopupMenu: TMenuItem;
477     FavoriteTreeViewNewFolderAction: TAction;
478     FavoriteTreeNewFolderPopupMenu: TMenuItem;
479     N56: TMenuItem;
480     FavoriteTreeViewDeleteAction: TAction;
481     FavoriteTreeDeletePopupMenu: TMenuItem;
482     FavoriteToolBar: TToolBar;
483     ToolButton17: TToolButton;
484     ToolButton19: TToolButton;
485     FavoriteTreeViewBrowseFolderAction: TAction;
486     FavoriteTreeBrowseFolderPopupMenu: TMenuItem;
487     N57: TMenuItem;
488     FavoriteTreeReloadPopupMenu: TMenuItem;
489     N58: TMenuItem;
490     FavoriteTreeURLCopyPopupMenu: TMenuItem;
491     FavoriteTreeNameCopyPopupMenu: TMenuItem;
492     FavoriteTreeLogDeletePopupMenu: TMenuItem;
493     N59: TMenuItem;
494     FavoriteTreeNameURLCopyPopupMenu: TMenuItem;
495     FavoriteTreeViewReloadAction: TAction;
496     FavoriteTreeViewURLCopyAction: TAction;
497     FavoriteTreeViewNameCopyAction: TAction;
498     FavoriteTreeViewNameURLCopyAction: TAction;
499     FavoriteTreeViewLogDeleteAction: TAction;
500     OnlyAHundredRes: TAction;
501     ToolButton20: TToolButton;
502     AHundredResButton: TToolButton;
503     N60: TMenuItem;
504 yoffy 1.107 N61: TMenuItem;
505     ExportFavoriteFileAction1: TMenuItem;
506     ExportFavoriteFile: TFileSaveAs;
507 yoffy 1.141 ToolButton21: TToolButton;
508     ToolButton22: TToolButton;
509     ToolButton23: TToolButton;
510     ToolButton24: TToolButton;
511 yoffy 1.142 N6: TMenuItem;
512     N17: TMenuItem;
513     FavoriteTreeViewBrowseBoardAction: TAction;
514     FavoriteTreeViewBrowseThreadAction: TAction;
515 yoffy 1.158 UpBoardAction: TAction;
516 h677 1.174 N18: TMenuItem;
517     N20: TMenuItem;
518     N24: TMenuItem;
519     N62: TMenuItem;
520 h677 1.175 N63: TMenuItem;
521     N441: TMenuItem;
522 hi_ 1.1 procedure FormCreate(Sender: TObject);
523     procedure FormDestroy(Sender: TObject);
524     procedure CabinetPanelHide(Sender: TObject);
525     procedure FormClose(Sender: TObject; var Action: TCloseAction);
526     procedure TreeViewChange(Sender: TObject; Node: TTreeNode);
527     procedure ListViewData(Sender: TObject; Item: TListItem);
528     procedure ListViewDataFind(Sender: TObject; Find: TItemFind;
529     const FindString: String; const FindPosition: TPoint;
530     FindData: Pointer; StartIndex: Integer; Direction: TSearchDirection;
531     Wrap: Boolean; var Index: Integer);
532     procedure ListViewDataHint(Sender: TObject; StartIndex,
533     EndIndex: Integer);
534     procedure ListViewDataStateChange(Sender: TObject; StartIndex,
535     EndIndex: Integer; OldState, NewState: TItemStates);
536     procedure BrowserStatusTextChange(Sender: TObject;
537     const Text: WideString);
538     procedure BrowserTitleChange(Sender: TObject; const Text: WideString);
539     procedure FormCloseQuery(Sender: TObject; var CanClose: Boolean);
540     procedure TreeViewChanging(Sender: TObject; Node: TTreeNode;
541     var AllowChange: Boolean);
542     procedure ListViewKeyDown(Sender: TObject; var Key: Word;
543     Shift: TShiftState);
544     procedure ListViewColumnClick(Sender: TObject; Column: TListColumn);
545     procedure MenuToolBarCustomDrawButton(Sender: TToolBar;
546     Button: TToolButton; State: TCustomDrawState;
547     var DefaultDraw: Boolean);
548     procedure BrowserBeforeNavigate2(Sender: TObject;
549     const pDisp: IDispatch; var URL, Flags, TargetFrameName, PostData,
550     Headers: OleVariant; var Cancel: WordBool);
551     procedure ListViewAdvancedCustomDrawItem(Sender: TCustomListView;
552     Item: TListItem; State: TCustomDrawState; Stage: TCustomDrawStage;
553     var DefaultDraw: Boolean);
554     procedure TreeViewCustomDraw(Sender: TCustomTreeView;
555     const ARect: TRect; var DefaultDraw: Boolean);
556     procedure TreeViewCustomDrawItem(Sender: TCustomTreeView;
557     Node: TTreeNode; State: TCustomDrawState; var DefaultDraw: Boolean);
558     procedure TreeViewExpanded(Sender: TObject; Node: TTreeNode);
559     procedure TreeViewDblClick(Sender: TObject);
560 yoffy 1.100 procedure FavoriteTreeViewClick(Sender: TObject);
561 hi_ 1.1 procedure ListViewCustomDraw(Sender: TCustomListView;
562     const ARect: TRect; var DefaultDraw: Boolean);
563     procedure ListViewMouseDown(Sender: TObject; Button: TMouseButton;
564     Shift: TShiftState; X, Y: Integer);
565     procedure TreeViewCollapsed(Sender: TObject; Node: TTreeNode);
566     procedure MessageListViewResize(Sender: TObject);
567     procedure ExitActionExecute(Sender: TObject);
568     procedure AllSelectActionExecute(Sender: TObject);
569     procedure StdToolBarVisibleActionExecute(Sender: TObject);
570     procedure MsgBarVisibleActionExecute(Sender: TObject);
571     procedure StatusBarVisibleActionExecute(Sender: TObject);
572     procedure LargeIconActionExecute(Sender: TObject);
573     procedure SmallIconActionExecute(Sender: TObject);
574     procedure ListIconActionExecute(Sender: TObject);
575     procedure DetailIconActionExecute(Sender: TObject);
576     procedure SearchActionExecute(Sender: TObject);
577     procedure OptionActionExecute(Sender: TObject);
578     procedure GikoNaviWebPageActionExecute(Sender: TObject);
579     procedure AboutActionExecute(Sender: TObject);
580     procedure CabinetHistoryActionExecute(Sender: TObject);
581 yoffy 1.138 procedure CabinetVisible( isVisible : Boolean );
582 hi_ 1.1 procedure CabinetVisibleActionExecute(Sender: TObject);
583     procedure AllItemActionExecute(Sender: TObject);
584     procedure LogItemActionExecute(Sender: TObject);
585     procedure NewItemActionExecute(Sender: TObject);
586     procedure SelectItemActionExecute(Sender: TObject);
587     procedure ListNumberVisibleActionExecute(Sender: TObject);
588     procedure UpFolderActionExecute(Sender: TObject);
589     procedure IconStyleExecute(Sender: TObject);
590     procedure RoundActionExecute(Sender: TObject);
591     procedure StopActionExecute(Sender: TObject);
592     procedure MsgBarCloseActionExecute(Sender: TObject);
593     procedure BrowserMaxActionExecute(Sender: TObject);
594     procedure ScrollTopActionExecute(Sender: TObject);
595     procedure ScrollLastActionExecute(Sender: TObject);
596     procedure ScrollNewActionExecute(Sender: TObject);
597     procedure ScrollKokoActionExecute(Sender: TObject);
598     procedure EditorActionExecute(Sender: TObject);
599     procedure IEActionExecute(Sender: TObject);
600     procedure ShowThreadActionExecute(Sender: TObject);
601     procedure ShowBoardActionExecute(Sender: TObject);
602     procedure URLCopyActionExecute(Sender: TObject);
603     procedure ItemReloadActionExecute(Sender: TObject);
604     procedure SelectListReloadActionExecute(Sender: TObject);
605     procedure SelectThreadReloadActionExecute(Sender: TObject);
606     procedure SelectListReloadActionUpdate(Sender: TObject);
607     procedure AllItemActionUpdate(Sender: TObject);
608     procedure LogItemActionUpdate(Sender: TObject);
609     procedure NewItemActionUpdate(Sender: TObject);
610     procedure SelectItemActionUpdate(Sender: TObject);
611     procedure UpFolderActionUpdate(Sender: TObject);
612     procedure FormResize(Sender: TObject);
613     procedure ScrollTopActionUpdate(Sender: TObject);
614     procedure ScrollLastActionUpdate(Sender: TObject);
615     procedure ScrollNewActionUpdate(Sender: TObject);
616     procedure ScrollKokoActionUpdate(Sender: TObject);
617     procedure EditorActionUpdate(Sender: TObject);
618     procedure IEActionUpdate(Sender: TObject);
619     procedure ShowThreadActionUpdate(Sender: TObject);
620     procedure ShowBoardActionUpdate(Sender: TObject);
621     procedure SelectThreadReloadActionUpdate(Sender: TObject);
622     procedure ListViewSelectItem(Sender: TObject; Item: TListItem;
623     Selected: Boolean);
624     procedure SelectTimerTimer(Sender: TObject);
625 yoffy 1.51 procedure ItemReloadActionUpdate(Sender: TObject);
626 hi_ 1.1 procedure ListViewDblClick(Sender: TObject);
627 yoffy 1.51 procedure LogDeleteActionExecute(Sender: TObject);
628 hi_ 1.1 procedure KokomadeActionExecute(Sender: TObject);
629     procedure ZenbuActionExecute(Sender: TObject);
630 yoffy 1.51 procedure KokoResActionExecute(Sender: TObject);
631 hi_ 1.1 procedure ListPopupMenuPopup(Sender: TObject);
632     procedure SelectItemURLCopyActionExecute(Sender: TObject);
633     procedure SelectItemURLCopyActionUpdate(Sender: TObject);
634     procedure AllSelectActionUpdate(Sender: TObject);
635     procedure LogDeleteActionUpdate(Sender: TObject);
636     procedure BrowserTabCloseActionExecute(Sender: TObject);
637     procedure NotSelectTabCloseActionExecute(Sender: TObject);
638     procedure TreeSelectBoradReloadExecute(Sender: TObject);
639     procedure TreeSelectThreadReloadExecute(Sender: TObject);
640     procedure TreeSelectURLCopyExecute(Sender: TObject);
641     procedure TreePopupMenuPopup(Sender: TObject);
642     procedure ListToolBarVisibleActionExecute(Sender: TObject);
643     procedure BrowserToolBarVisibleActionExecute(Sender: TObject);
644     procedure BrowserNewWindow2(Sender: TObject; var ppDisp: IDispatch;
645     var Cancel: WordBool);
646     procedure ListSplitterCanResize(Sender: TObject; var NewSize: Integer;
647     var Accept: Boolean);
648     procedure ListSplitterMoved(Sender: TObject);
649     procedure BrowserTabChange(Sender: TObject);
650     procedure BrowserTabMouseDown(Sender: TObject; Button: TMouseButton;
651     Shift: TShiftState; X, Y: Integer);
652     procedure BrowserTabDragOver(Sender, Source: TObject; X, Y: Integer;
653     State: TDragState; var Accept: Boolean);
654     procedure BrowserTabDragDrop(Sender, Source: TObject; X, Y: Integer);
655     procedure BrowserTabMouseMove(Sender: TObject; Shift: TShiftState; X,
656     Y: Integer);
657     procedure BrowserDocumentComplete(Sender: TObject;
658     const pDisp: IDispatch; var URL: OleVariant);
659     procedure SelectReservActionUpdate(Sender: TObject);
660     procedure RoundNamePopupMenuPopup(Sender: TObject);
661     procedure SelectNewRoundNameExecute(Sender: TObject);
662     procedure SelectDeleteRoundExecute(Sender: TObject);
663     procedure SelectReservActionExecute(Sender: TObject);
664     procedure NewBoardActionExecute(Sender: TObject);
665     procedure LoginActionExecute(Sender: TObject);
666     procedure KeySettingActionExecute(Sender: TObject);
667     procedure AllTabCloseActionExecute(Sender: TObject);
668 yoffy 1.51 procedure ArrangeActionExecute(Sender: TObject);
669     procedure NameURLCopyActionExecute(Sender: TObject);
670     procedure SelectItemNameURLCopyActionExecute(Sender: TObject);
671 hi_ 1.1 procedure URLCopyActionUpdate(Sender: TObject);
672 yoffy 1.2 procedure NameURLCopyActionUpdate(Sender: TObject);
673 hi_ 1.1 procedure BrowserTabCloseActionUpdate(Sender: TObject);
674 yoffy 1.51 procedure NotSelectTabCloseActionUpdate(Sender: TObject);
675 hi_ 1.1 procedure AllTabCloseActionUpdate(Sender: TObject);
676     procedure SelectItemNameURLCopyActionUpdate(Sender: TObject);
677     procedure ActiveLogDeleteActionExecute(Sender: TObject);
678     procedure ActiveLogDeleteActionUpdate(Sender: TObject);
679 yoffy 1.51 procedure ListNameBarVisibleActionExecute(Sender: TObject);
680 hi_ 1.1 procedure BrowserNameBarVisibleActionExecute(Sender: TObject);
681 yoffy 1.51 procedure TreeSelectNameURLCopyExecute(Sender: TObject);
682     procedure PaneInitActionExecute(Sender: TObject);
683 hi_ 1.1 procedure FormShow(Sender: TObject);
684     procedure BrowserTabToolBarResize(Sender: TObject);
685     procedure BrowserMinActionExecute(Sender: TObject);
686 yoffy 1.51 procedure SelectTextClearActionExecute(Sender: TObject);
687 hi_ 1.1 procedure NameTextClearActionExecute(Sender: TObject);
688 yoffy 1.51 procedure MailTextClearActionExecute(Sender: TObject);
689     procedure LeftmostTabSelectActionExecute(Sender: TObject);
690     procedure LeftTabSelectActionExecute(Sender: TObject);
691 hi_ 1.1 procedure RightTabSelectActionExecute(Sender: TObject);
692     procedure RightmostTabSelectActionExecute(Sender: TObject);
693     procedure LeftmostTabSelectActionUpdate(Sender: TObject);
694     procedure LeftTabSelectActionUpdate(Sender: TObject);
695     procedure RightTabSelectActionUpdate(Sender: TObject);
696     procedure RightmostTabSelectActionUpdate(Sender: TObject);
697     procedure FavoriteMenuClick(Sender: TObject);
698     procedure FavoriteAddActionExecute(Sender: TObject);
699     procedure FavoriteAddActionUpdate(Sender: TObject);
700     procedure BoardFavoriteAddActionExecute(Sender: TObject);
701     procedure BoardFavoriteAddActionUpdate(Sender: TObject);
702 yoffy 1.51 procedure ThreadFavoriteAddActionExecute(Sender: TObject);
703 hi_ 1.1 procedure ThreadFavoriteAddActionUpdate(Sender: TObject);
704 yoffy 1.51 procedure TreeSelectFavoriteAddActionExecute(Sender: TObject);
705 yoffy 1.2 procedure FavoriteArrangeActionExecute(Sender: TObject);
706     procedure MainCoolBarResize(Sender: TObject);
707 hi_ 1.1 procedure MoveToActionExecute(Sender: TObject);
708 yoffy 1.2 procedure AddressToolBarResize(Sender: TObject);
709 hi_ 1.1 procedure AddressComboBoxKeyDown(Sender: TObject; var Key: Word;
710     Shift: TShiftState);
711 yoffy 1.51 procedure AddressBarVisibleActionExecute(Sender: TObject);
712 yoffy 1.2 procedure BrowserEnter(Sender: TObject);
713 hi_ 1.1 procedure FormShortCut(var Msg: TWMKey; var Handled: Boolean);
714 yoffy 1.51 procedure BrowserTabVisibleActionExecute(Sender: TObject);
715     procedure BrowserTabTopActionExecute(Sender: TObject);
716     procedure BrowserTabBottomActionExecute(Sender: TObject);
717     procedure BrowserTabTabStyleActionExecute(Sender: TObject);
718 hi_ 1.1 procedure BrowserTabButtonStyleActionExecute(Sender: TObject);
719 yoffy 1.51 procedure BrowserTabFlatStyleActionExecute(Sender: TObject);
720 hi_ 1.1 procedure PreviewTimerTimer(Sender: TObject);
721     procedure MessageHideButtonClick(Sender: TObject);
722     procedure MonazillaWebPageActionExecute(Sender: TObject);
723     procedure GikoHelpActionExecute(Sender: TObject);
724     procedure ToolButton18Click(Sender: TObject);
725     procedure KotehanActionExecute(Sender: TObject);
726 yoffy 1.51 procedure LinkBarVisibleActionExecute(Sender: TObject);
727     procedure BBS2chWebPageActionExecute(Sender: TObject);
728     procedure GikoFolderOpenActionExecute(Sender: TObject);
729 yoffy 1.2 procedure MainCoolBarBandInfo(Sender: TObject;
730     var BandInfo: PReBarBandInfoA);
731     procedure MainCoolBarChevronClick(Sender: TObject;
732 yoffy 1.51 RebarChevron: PNMRebarChevron);
733     procedure ListCoolBarBandInfo(Sender: TObject;
734     var BandInfo: PReBarBandInfoA);
735     procedure ListCoolBarChevronClick(Sender: TObject;
736     RebarChevron: PNMRebarChevron);
737     procedure BrowserCoolBarBandInfo(Sender: TObject;
738     var BandInfo: PReBarBandInfoA);
739 yoffy 1.2 procedure BrowserCoolBarChevronClick(Sender: TObject;
740 yoffy 1.51 RebarChevron: PNMRebarChevron);
741     procedure ListViewColumnInfo(Sender: TObject; var Column: PLVColumnA);
742     procedure ThreadEditorActionExecute(Sender: TObject);
743 yoffy 1.2 procedure ThreadEditorActionUpdate(Sender: TObject);
744 yoffy 1.51 procedure ToolBarSettingActionExecute(Sender: TObject);
745     procedure NameCopyActionExecute(Sender: TObject);
746     procedure BoardIEActionExecute(Sender: TObject);
747     procedure SelectItemNameCopyActionExecute(Sender: TObject);
748 yoffy 1.2 procedure SelectItemNameCopyActionUpdate(Sender: TObject);
749 yoffy 1.51 procedure BoardIEActionUpdate(Sender: TObject);
750     procedure FormMouseWheel(Sender: TObject; Shift: TShiftState;
751     WheelDelta: Integer; MousePos: TPoint; var Handled: Boolean);
752     procedure NameCopyActionUpdate(Sender: TObject);
753     procedure SelectComboBoxChange(Sender: TObject);
754     procedure SelectComboBoxKeyDown(Sender: TObject; var Key: Word;
755     Shift: TShiftState);
756     procedure SelectComboBoxExit(Sender: TObject);
757     procedure NG1Click(Sender: TObject);
758     procedure SelectResActionExecute(Sender: TObject);
759     procedure SelectResActionUpdate(Sender: TObject);
760     procedure FormKeyDown(Sender: TObject; var Key: Word;
761     Shift: TShiftState);
762     procedure FormKeyUp(Sender: TObject; var Key: Word;
763     Shift: TShiftState);
764     procedure AllResActionExecute(Sender: TObject);
765     procedure AllResActionUpdate(Sender: TObject);
766     procedure ReloadClick(Sender: TObject);
767     procedure GoBackClick(Sender: TObject);
768     procedure GoFowardClick(Sender: TObject);
769     procedure SelectComboBoxSplitterMouseMove(Sender: TObject;
770     Shift: TShiftState; X, Y: Integer);
771     procedure SelectComboBoxSplitterMouseDown(Sender: TObject;
772     Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
773     procedure SelectComboBoxSplitterMouseUp(Sender: TObject;
774     Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
775     procedure StatusBarResize(Sender: TObject);
776     procedure IndividualAbon1Click(Sender: TObject);
777     procedure IndividualAbon2Click(Sender: TObject);
778     procedure N42Click(Sender: TObject);
779     procedure SelectComboBoxEnter(Sender: TObject);
780     procedure AntiIndividualAbonClick(Sender: TObject);
781     procedure N51Click(Sender: TObject);
782     procedure TreeSelectSearchBoardNameExecute(Sender: TObject);
783 yoffy 1.100 procedure CabinetFavoriteActionExecute(Sender: TObject);
784     procedure FavoriteTreeViewDragDrop(Sender, Source: TObject; X,
785     Y: Integer);
786 yoffy 1.71 procedure FavoriteTreeViewDragOver(Sender, Source: TObject; X, Y: Integer; State: TDragState; var Accept: Boolean);
787 yoffy 1.100 procedure FavoriteTreeViewEdited(Sender: TObject; Node: TTreeNode;
788     var S: String);
789     procedure FavoriteTreeViewKeyDown(Sender: TObject; var Key: Word;
790     Shift: TShiftState);
791     procedure FavoriteTreePopupMenuPopup(Sender: TObject);
792     procedure FavoriteTreeViewDeleteActionExecute(Sender: TObject);
793     procedure FavoriteTreeViewRenameActionExecute(Sender: TObject);
794     procedure FavoriteTreeViewNewFolderActionExecute(Sender: TObject);
795     procedure ToolButton19Click(Sender: TObject);
796     procedure FavoriteTreeViewBrowseFolderActionExecute(Sender: TObject);
797     procedure FavoriteTreeViewChange(Sender: TObject; Node: TTreeNode);
798     procedure FavoriteTreeViewDblClick(Sender: TObject);
799     procedure FavoriteTreeViewLogDeleteActionExecute(Sender: TObject);
800     procedure FavoriteTreeViewReloadActionExecute(Sender: TObject);
801     procedure FavoriteTreeViewURLCopyActionExecute(Sender: TObject);
802     procedure FavoriteTreeViewNameCopyActionExecute(Sender: TObject);
803     procedure FavoriteTreeViewNameURLCopyActionExecute(Sender: TObject);
804     procedure LinkToolBarDragDrop(Sender, Source: TObject; X, Y: Integer);
805     procedure BrowserTabMouseUp(Sender: TObject; Button: TMouseButton;
806     Shift: TShiftState; X, Y: Integer);
807     procedure LinkToolBarDragOver(Sender, Source: TObject; X, Y: Integer;
808     State: TDragState; var Accept: Boolean);
809     procedure OnlyAHundredResExecute(Sender: TObject);
810     procedure FavoriteTreeViewEndDrag(Sender, Target: TObject; X,
811     Y: Integer);
812     procedure ListCoolBarContextPopup(Sender: TObject; MousePos: TPoint;
813     var Handled: Boolean);
814     procedure MainCoolBarContextPopup(Sender: TObject; MousePos: TPoint;
815     var Handled: Boolean);
816     procedure BrowserCoolBarContextPopup(Sender: TObject; MousePos: TPoint;
817     var Handled: Boolean);
818 yoffy 1.107 procedure ExportFavoriteFileAccept(Sender: TObject);
819     procedure ExportFavoriteFileBeforeExecute(Sender: TObject);
820 yoffy 1.139 procedure CabinetBBSActionExecute(Sender: TObject);
821 yoffy 1.142 procedure FavoriteTreeViewBrowseThreadActionExecute(Sender: TObject);
822     procedure FavoriteTreeBrowseBoardPopupMenuClick(Sender: TObject);
823 yoffy 1.158 procedure UpBoardActionExecute(Sender: TObject);
824     procedure UpBoardActionUpdate(Sender: TObject);
825 h677 1.174 procedure BrowserTabContextPopup(Sender: TObject; MousePos: TPoint;
826     var Handled: Boolean);
827 h677 1.175 procedure N441Click(Sender: TObject);
828 hi_ 1.1 private
829     { Private 鐃緒申鐃緒申 }
830    
831     FSortIndex: Integer;
832     FSortOrder: Boolean;
833    
834     FEnabledCloseButton: Boolean;
835     // ThreadCreate: TThreadCreate;
836    
837     FClickNode: TTreeNode;
838     FHttpState: Boolean;
839     FHint: TResPopup;
840     FPreviewBrowser: TPreviewBrowser;
841     FPreviewURL: string;
842    
843     FBrowserSizeHeight: Integer;
844     FBrowserSizeWidth: Integer;
845    
846     // FFavorite: TFavorite;
847     FBrowserComplete: Boolean;
848     FTabHintIndex: Integer;
849     FListStyle: TViewStyle; //鐃緒申鐃?鐃?鐃?鐃?鐃?鐃緒申鐃?鐃?鐃?鐃緒申
850     FItemNoVisible: Boolean; //鐃緒申鐃?鐃?鐃緒申鐃緒申鐃?鐃緒申鐃?鐃緒申鐃?
851     FViewType: TGikoViewType; //鐃緒申鐃?鐃?鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃?鐃?鐃?
852 yoffy 1.123 FActiveList: TObject;
853 hi_ 1.1 FActiveContent: TThreadItem; //
854 yoffy 1.133 FActiveBBS : TBBS;
855 hi_ 1.1 FHistoryList: TList; //鐃?鐃?鐃?鐃緒申鐃緒申鐃?鐃?
856     FTreeType: TGikoTreeType;
857     FWorkCount: Integer;
858     FNameCookie: string;
859     FMailCookie: string;
860     // FLastRoundTime: TDateTime;
861     BrowserNullTab: TThreadItem;
862     // DoubleClickOccurred: array [TMouseButton] of Boolean;
863     FDownloadTitle: string; //鐃?鐃?鐃緒申鐃緒申鐃?鐃?鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申鐃緒申
864     FDownloadMax: Integer; //鐃?鐃?鐃緒申鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?
865     FEvent: THTMLDocumentEventSink;//鐃?鐃緒申鐃?鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申鐃?
866 h677 1.14
867 yoffy 1.51 Fkeynum : Integer; //鐃?鐃?鐃?鐃?鐃?鐃緒申鐃?鐃?鐃?鐃?鐃?鐃?鐃?鐃?
868 yoffy 1.29
869 yoffy 1.51 IsDraggingSelectComboBox : Boolean;
870     DraggingSelectComboBoxPosition : TPoint;
871 yoffy 1.29
872 yoffy 1.54 FSearchDialog: TSearchDialog;
873 yoffy 1.49
874 yoffy 1.100 FDropSpaceNode: TTreeNode;
875 yoffy 1.74
876 yoffy 1.107 FDragTime : Cardinal; //鐃緒申鐃緒申鐃?鐃緒申D&D鐃?
877     FDragButton : TToolButton; //鐃緒申鐃緒申鐃?鐃緒申D&D鐃?鐃緒申Drag鐃緒申鐃緒申鐃緒申Button鐃緒申鐃緒申
878     FDragWFirst : Boolean; //WebTab鐃緒申D&D鐃?
879 h677 1.84
880 yoffy 1.143 FListViewBackGroundColor : TColor; //ListView鐃緒申BackGroundColor
881     FUseOddResOddColor : Boolean; //鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃?鐃緒申
882     FOddColor : TColor; //鐃緒申鐃緒申鐃?
883 yoffy 1.152
884     FSelectResWord : string; // 鐃緒申鐃?鐃?鐃緒申鐃緒申鐃?鐃?
885 yoffy 1.123 procedure SetBoardTreeNode( inBBS : TBBS );
886     function SetCategoryListItem(ABBS2ch: TBBS): Integer;
887 hi_ 1.1 function SetBoardListItem(Category: TCategory): Integer;
888     function SetThreadListItem(Board: TBoard): Integer;
889     // function GetRoundName(index: integer): string;
890    
891     procedure DownloadEnd(Sender: TObject; Item: TDownloadItem);
892     procedure DownloadMsg(Sender: TObject; Item: TDownloadItem; Msg: string; Icon: TGikoMessageIcon);
893     procedure WorkBegin(Sender: TObject; AWorkMode: TWorkMode; const AWorkCountMax: Integer; Number: Integer);
894     procedure WorkEnd(Sender: TObject; AWorkMode: TWorkMode; Number: Integer);
895     procedure Work(Sender: TObject; AWorkMode: TWorkMode; const AWorkCount: Integer; Number: Integer);
896    
897     procedure SetActiveList(Obj: TObject);
898     procedure ListClick;
899     procedure ListDoubleClick;
900     procedure BrowserMovement(AName: string);
901     procedure SelectListItem(List: TList);
902     // procedure SetProgressValue(Number: Integer; Value: Integer; Max: Integer = -1);
903     procedure DeleteTab(ThreadItem: TThreadItem);
904     function Hook(var Message: TMessage): Boolean;
905     procedure AddRoundNameMenu(MenuItem: TMenuItem);
906     procedure SetSelectItemRound(RoundFlag: Boolean; RoundName: string);
907     procedure SetSelectRoundName(Sender: TObject);
908     function GetCoolBand(CoolBar: TCoolBar; Control: TWinControl): TCoolBand;
909    
910     procedure SetMenuFont;
911     // procedure CreateFavMenu(Folder: TFavoriteFolder);
912     procedure CreateFavMenu(Node: TTreeNode; MenuItem: TMenuItem);
913 yoffy 1.62 procedure FavoriteClick(Sender: TObject; ActiveTab: Boolean); overload;
914     procedure FavoriteClick(Sender: TObject); overload;
915 yoffy 1.100 procedure FavoriteDragOver(Sender, Source: TObject; X, Y: Integer; State: TDragState; var Accept: Boolean);
916 yoffy 1.2 procedure SelectTreeNode(Item: TObject; CallEvent: Boolean);
917 hi_ 1.1 function OnDocumentContextMenu(Sender: TObject): WordBool;
918     // function GetThreadText(sBoard: string; sThread: string; StNum, ToNum: Integer; Title, First: Boolean): string;
919 yoffy 1.123 procedure SetResPopupText(ThreadItem : TThreadItem; StNum, ToNum: Integer; Title, First: Boolean);
920 hi_ 1.1 procedure ShowTextPopup;
921     //procedure ShowTextPopup(HintData: THintData);
922 yoffy 1.2 // procedure SetStdToolBar;
923     // function GetAction(ActionName: string): TContainedAction;
924 hi_ 1.1 procedure SetLinkBar;
925     function GetWidthAllToolButton(ToolBar: TToolBar): Integer;
926 yoffy 1.2 procedure MenuBarChevronMenu;
927     procedure LinkBarChevronMenu;
928     procedure ToolBarChevronMenu(ToolBar: TToolBar);
929 yoffy 1.51 procedure ModifySelectList;
930 yoffy 1.100 procedure FavoriteBrowseFolder( node: TTreeNode );
931     procedure LinkToolButtonDragDrop(Sender, Source: TObject; X, Y: Integer);
932     procedure LinkToolButtonOnMouseDown(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
933     procedure LinkToolButtonOnMouseMove(Sender: TObject; Shift: TShiftState; X, Y: Integer);
934     procedure LinkToolButtonOnMouseUp(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
935 yoffy 1.85 procedure LinkToolButtonStartDrag(Sender: TObject; var DragObject: TDragObject);
936 yoffy 1.72 function TreeNodeDataFind(Node: TTreeNode; FindPointer: Pointer): TTreeNode;
937 yoffy 1.100 procedure FavoriteMoveTo( SenderNode, SourceNode: TTreeNode );
938     procedure FavoriteAddTo( SenderNode: TTreeNode; Source: TObject );
939 yoffy 1.72 procedure FavoriteDragDrop( SenderNode: TTreeNode; Source: TObject );
940 yoffy 1.100 //
941 yoffy 1.143 procedure BrowserTabClick(Sender: TObject);
942     procedure SetListViewBackGroundColor(value: TColor);
943 yoffy 1.123 procedure BBSMenuItemOnClick( Sender : TObject );
944 hi_ 1.1 protected
945     procedure CreateParams(var Params: TCreateParams); override;
946 yoffy 1.2 procedure WndProc(var Message: TMessage); override;
947 hi_ 1.1 procedure WMSetCursor(var Message: TWMSetCursor); message WM_SETCURSOR;
948     procedure WMSettingChange(var Message: TWMWinIniChange); message WM_SETTINGCHANGE;
949     procedure WMCopyData(var Message: TWMCopyData); message WM_COPYDATA;
950     public
951     { Public 鐃緒申鐃緒申 }
952     // FDownload: TDownload;
953     FControlThread: TThreadControl;
954 yoffy 1.48 procedure MoveToURL(URL: string);
955     procedure InsertBrowserTab(ThreadItem: TThreadItem; ActiveTab: Boolean = True);
956 hi_ 1.1 procedure ReloadBBS;
957     function GetHttpState: Boolean;
958     procedure SetEnabledCloseButton(Enabled: Boolean);
959     function GetTreeNode(Data: TObject): TTreeNode;
960     procedure AppFormDeactivate(Sender: TObject);
961     // procedure CabinetPanelVisible(PanelVisible: Boolean);
962     procedure ListViewAllSelect;
963    
964     property ListStyle: TViewStyle read FListStyle write FListStyle;
965     property ItemNoVisible: Boolean read FItemNoVisible write FItemNoVisible;
966     property ViewType: TGikoViewType read FViewType write FViewType;
967    
968     property NameCookie: string read FNameCookie write FNameCookie;
969     property MailCookie: string read FMailCookie write FMailCookie;
970    
971     procedure SetContent(ThreadItem: TThreadItem);
972     function GetActiveContent: TThreadItem;
973     function GetActiveList: TObject;
974    
975     property ActiveList: TObject read GetActiveList write SetActiveList;
976     // property LastRoundTime: TDateTime read FLastRoundTime write FLastRoundTime;
977    
978     procedure SetListViewType(AViewType: TGikoViewType); overload;
979     procedure SetListViewType(AViewType: TGikoViewType; SelectText: string; KubetsuChk: Boolean); overload;
980     procedure DownloadContent(ThreadItem: TThreadItem);
981     procedure DownloadList(Board: TBoard);
982     procedure PlaySound(SoundEventName: string);
983    
984 yoffy 1.136 function AddHistory( FavItem: TFavoriteThreadItem ): Boolean;
985     procedure DeleteHistory( threadItem: TThreadItem );
986 hi_ 1.1 procedure ClearHistory;
987 yoffy 1.135 procedure SaveHistory;
988     procedure LoadHistory;
989 yoffy 1.123 procedure ShowBBSTree( inBBS : TBBS );
990 hi_ 1.1 procedure ShowHistoryTree;
991     procedure SetHistoryTreeNode;
992     // procedure SelectTreeNode(Item: TObject);
993     procedure AddMessageList(ACaption: string; AObject: TObject; Icon: TGikoMessageIcon);
994     procedure SetBrowserTabState;
995     // property Favorite: TFavorite read FFavorite write FFavorite;
996 yoffy 1.2 procedure SetToolBarPopup;
997 yoffy 1.100 procedure ShowFavoriteAddDialog( Item : TObject );
998 yoffy 1.143 property ListViewBackGroundColor: TColor read FListViewBackGroundColor write SetListViewBackGroundColor;
999     property UseOddResOddColor : Boolean read FUseOddResOddColor write FUseOddResOddColor;
1000     property OddColor : TColor read FOddColor write FOddColor;
1001 h677 1.109
1002 hi_ 1.1 published
1003     property EnabledCloseButton: Boolean read FEnabledCloseButton write SetEnabledCloseButton;
1004     end;
1005    
1006     TFavoriteMenuItem = class(TMenuItem)
1007     private
1008     FData : Pointer;
1009     public
1010     property Data: Pointer read FData write FData;
1011     end;
1012    
1013 yoffy 1.123 TBBSMenuItem = class(TMenuItem)
1014     private
1015     FData : Pointer;
1016     public
1017     property Data: Pointer read FData write FData;
1018     end;
1019    
1020 hi_ 1.1 TLinkToolButton = class(TToolButton)
1021     private
1022     FData : Pointer;
1023     public
1024     property Data: Pointer read FData write FData;
1025     end;
1026    
1027     var
1028     GikoForm: TGikoForm;
1029    
1030     implementation
1031    
1032     uses
1033     About, Option, Round, Splash, Sort, ListSelect,
1034 h677 1.151 NewBoard, MojuUtils;
1035 hi_ 1.1
1036     const
1037     CAPTION_NAME: string = '鐃?鐃?鐃?鐃?';
1038     BLANK_HTML: string = 'about:blank';
1039 yoffy 1.51 SELECTCOMBOBOX_NAME: string = ''; // '鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申';
1040     SELECTCOMBOBOX_COLOR: TColor = clWindow;
1041 yoffy 1.120 //D&D鐃緒申鐃?
1042     DandD_THRESHOLD = 5; //D&D鐃緒申鐃緒申鐃?鐃?pixcel)
1043 yoffy 1.2 //鐃?鐃緒申鐃?鐃?鐃緒申鐃?鐃?鐃?鐃?鐃?鐃緒申
1044     ITEM_ICON_2CH1 = 0; //2ch鐃?鐃?鐃?鐃緒申
1045     ITEM_ICON_2CH2 = 1; //2ch鐃?鐃?鐃?鐃緒申
1046     ITEM_ICON_CATEGORY1 = 2; //鐃?鐃?鐃?鐃緒申鐃?鐃?鐃?鐃緒申
1047     ITEM_ICON_CATEGORY2 = 3; //鐃?鐃?鐃?鐃緒申鐃?鐃?鐃?鐃緒申
1048 yoffy 1.120 ITEM_ICON_BOARD_NOSUBJECT = 3; //鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申
1049 yoffy 1.2 ITEM_ICON_BOARD1 = 4; //鐃緒申鐃?鐃?鐃?鐃緒申
1050     ITEM_ICON_BOARD2 = 5; //鐃緒申鐃?鐃?鐃?鐃緒申
1051     ITEM_ICON_THREADLOG1 = 6; //鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃?
1052     ITEM_ICON_THREADLOG2 = 7; //鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃?
1053     ITEM_ICON_THREAD1 = 8; //鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃?
1054     ITEM_ICON_THREAD2 = 9; //鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃?
1055     ITEM_ICON_THREADNEW1 = 10; //鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃?
1056     ITEM_ICON_THREADNEW2 = 11; //鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃?
1057     ITEM_ICON_SORT1 = 12; //鐃?鐃?鐃?鐃?鐃?鐃?鐃緒申
1058     ITEM_ICON_SORT2 = 13; //鐃?鐃?鐃?鐃?鐃?鐃?鐃緒申
1059 yoffy 1.120 ITEM_ICON_BOARD_LOG = 17; //鐃?鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申
1060     ITEM_ICON_BOARD_NEW = 18; //鐃?鐃緒申鐃?鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申
1061 yoffy 1.2
1062     //鐃?鐃?鐃緒申鐃?鐃?鐃?鐃?鐃?鐃緒申
1063 yoffy 1.48 TOOL_ICON_HEIGHT_MAX = 16; //鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申
1064     TOOL_ICON_HEIGHT_MIN = 17; //鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申
1065     TOOL_ICON_HEIGHT_NORMAL = 18; //鐃緒申鐃緒申鐃?鐃緒申鐃?鐃?鐃?鐃緒申
1066     TOOL_ICON_WIDTH_MAX = 19; //鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申
1067     TOOL_ICON_WIDTH_MIN = 20; //鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申
1068     TOOL_ICON_WIDTH_NORMAL = 21; //鐃緒申鐃?鐃緒申鐃?鐃?鐃?鐃緒申
1069    
1070 yoffy 1.51 TOOL_ICON_FAV_FOLDER = 30; //鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃?鐃?鐃緒申鐃?鐃?鐃?鐃?鐃緒申
1071 yoffy 1.100 TOOL_ICON_FAV_BOARD = 31; //鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申
1072 yoffy 1.51 TOOL_ICON_FAV_THREAD = 32; //鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃?鐃?鐃?鐃緒申
1073 hi_ 1.1
1074     HTML_FILE_NAME = 'temp_preview.html';
1075    
1076     {$R *.DFM}
1077    
1078     procedure TGikoForm.CreateParams(var Params: TCreateParams);
1079     begin
1080     inherited;
1081     if FormStyle in [fsNormal, fsStayOnTop] then begin
1082     if BorderStyle in [bsSingle, bsSizeable] then begin
1083     Params.ExStyle := Params.ExStyle or WS_EX_APPWINDOW;
1084     Params.WndParent := 0;
1085     end;
1086     end;
1087     end;
1088    
1089     procedure TGikoForm.FormCreate(Sender: TObject);
1090     const
1091     TVS_NOTOOLTIPS = $0080;
1092     var
1093     FileName: string;
1094     Style: DWORD;
1095     msg: string;
1096     i: Integer;
1097     wp: TWindowPlacement;
1098 hi_ 1.32 s: string;
1099 yoffy 1.123 item : TBBSMenuItem;
1100 hi_ 1.1 begin
1101     {$IFDEF DEBUG}
1102     AllocConsole;
1103     Writeln('============================================================');
1104     Writeln(' 鐃?鐃?鐃?鐃?鐃?鐃?鐃?鐃? 鐃?鐃緒申鐃?鐃?鐃緒申');
1105     Writeln('');
1106     Writeln(' 鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?');
1107     Writeln(' 鐃?鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃?鐃?鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申');
1108     Writeln('============================================================');
1109     {$ENDIF}
1110     Application.OnDeactivate := AppFormDeactivate;
1111     Self.OnDeactivate := AppFormDeactivate;
1112     Application.HookMainWindow(Hook);
1113    
1114     FTreeType := gttNone;
1115    
1116 yoffy 1.51 FSearchDialog := nil;
1117 yoffy 1.49
1118 hi_ 1.1 //鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申
1119     Screen.Cursors[5] := LoadCursor(HInstance, 'GIKOHAND');
1120    
1121     //鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申
1122     RoundList := TRoundList.Create;
1123     RoundList.LoadRoundFile;
1124    
1125     //鐃?鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1126     AddressHistoryDM.ReadHistory(AddressComboBox.Items, GikoSys.Setting.AddressHistoryCount);
1127    
1128 yoffy 1.135 // 鐃?鐃緒申鐃緒申鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申鐃?鐃?(ReadBoardFile, LoadHistory 鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申)
1129 yoffy 1.107 InitializeBoardPlugIns;
1130 yoffy 1.105
1131 hi_ 1.1 EnabledCloseButton := True;
1132 yoffy 1.123 // 鐃?鐃?鐃?鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申(ReadFavorite 鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申)
1133     GikoSys.ReadBoardFile;
1134 hi_ 1.1 // SetBoardTreeNode; //鐃?鐃緒申鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃緒申
1135 yoffy 1.123 // 鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申
1136     for i := Length( BBSs ) - 1 downto 0 do begin
1137 yoffy 1.126 try
1138     item := TBBSMenuItem.Create( PopupMenu );
1139     item.Caption := BBSs[ i ].Title;
1140     item.Data := BBSs[ i ];
1141     item.OnClick := BBSMenuItemOnClick;
1142     CabinetSelectPopupMenu.Items.Insert( 0, item );
1143     item := TBBSMenuItem.Create( PopupMenu );
1144     item.Caption := BBSs[ i ].Title;
1145     item.Data := BBSs[ i ];
1146     item.OnClick := BBSMenuItemOnClick;
1147     CabinetMenu.Insert( 0, item );
1148     except
1149     end;
1150 yoffy 1.123 end;
1151    
1152 yoffy 1.135 // 鐃?鐃?鐃?鐃緒申鐃緒申鐃?鐃?(LoadHistory 鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申)
1153     FHistoryList := TList.Create;
1154    
1155     // 鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1156     LoadHistory;
1157    
1158 yoffy 1.123 //鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1159     // FFavorite := TFavorite.Create(FavoriteTreeView);
1160     FavoriteDM.SetFavTreeView(FavoriteTreeView);
1161     FavoriteDM.ReadFavorite;
1162 hi_ 1.1
1163     //鐃緒申鐃?鐃?鐃?鐃?鐃?鐃緒申
1164     ListView.ViewStyle := GikoSys.Setting.ListStyle;
1165    
1166     //鐃緒申鐃?鐃緒申鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃?
1167     // MainCoolBar.Top := 0;
1168     // MainCoolBar.Left := 0;
1169    
1170     //鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申鐃?
1171     AnimePanel.Top := 0;
1172     AnimePanel.Left := 0;
1173    
1174     //鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1175    
1176     //鐃?鐃緒申鐃?鐃?鐃?鐃?
1177     CabinetPanel.Width := GikoSys.Setting.CabinetWidth;
1178    
1179     //鐃緒申鐃?鐃?鐃?鐃?鐃?鐃?
1180     MsgBarVisibleAction.Checked := GikoSys.Setting.MessageBarVisible;
1181     MsgBarVisibleActionExecute(nil);
1182     MessagePanel.Height := GikoSys.Setting.MessegeBarHeight;
1183    
1184     //鐃?鐃?鐃?鐃?鐃?鐃?鐃?
1185     StatusBarVisibleAction.Checked := GikoSys.Setting.StatusBarVisible;
1186     StatusBarVisibleActionExecute(nil);
1187    
1188     //鐃?鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃緒申
1189     TreeView.Items.BeginUpdate;
1190 yoffy 1.100 FavoriteTreeView.Items.BeginUpdate;
1191 hi_ 1.1 ListView.Items.BeginUpdate;
1192     try
1193     TreeView.Font.Name := GikoSys.Setting.CabinetFontName;
1194     TreeView.Font.Size := GikoSys.Setting.CabinetFontSize;
1195     TreeView.Font.Color := GikoSys.Setting.CabinetFontColor;
1196     TreeView.Color := GikoSys.Setting.CabinetBackColor;
1197    
1198 yoffy 1.67 FavoriteTreeView.Font.Name := GikoSys.Setting.CabinetFontName;
1199     FavoriteTreeView.Font.Size := GikoSys.Setting.CabinetFontSize;
1200     FavoriteTreeView.Font.Color := GikoSys.Setting.CabinetFontColor;
1201     FavoriteTreeView.Color := GikoSys.Setting.CabinetBackColor;
1202    
1203 hi_ 1.1 ListView.Font.Name := GikoSys.Setting.ListFontName;
1204     ListView.Font.Size := GikoSys.Setting.ListFontSize;
1205     ListView.Font.Color := GikoSys.Setting.ListFontColor;
1206 h677 1.109 //ListView.Color := GikoSys.Setting.ListBackColor;
1207 yoffy 1.123 ListViewBackGroundColor := GikoSys.Setting.ListBackColor;
1208     FUseOddResOddColor := GikoSys.Setting.UseOddColorOddResNum;
1209     FOddColor := GikoSys.Setting.OddColor;
1210 h677 1.109
1211 hi_ 1.1 finally
1212     TreeView.Items.EndUpdate;
1213 yoffy 1.100 FavoriteTreeView.Items.EndUpdate;
1214 hi_ 1.1 ListView.Items.EndUpdate;
1215     end;
1216     //ViewNoButton.Down := GikoSys.Setting.ListViewNo;
1217     ListNumberVisibleAction.Checked := GikoSys.Setting.ListViewNo;
1218    
1219     //鐃?鐃緒申鐃?鐃?鐃?鐃?鐃?鐃?鐃緒申鐃?
1220     BrowserTab.Font.Name := GikoSys.Setting.BrowserTabFontName;
1221     BrowserTab.Font.Size := GikoSys.Setting.BrowserTabFontSize;
1222 yoffy 1.133 FDragWFirst := false;
1223 hi_ 1.1
1224     // TreeView.TopItem.Expanded := True; //鐃?鐃緒申鐃?鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申
1225     // TreeView.Selected := TreeView.Items[0]; //鐃?鐃緒申鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申
1226     SetContent(nil); //鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申鐃?鐃緒申
1227    
1228     //鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃?鐃緒申鐃緒申
1229     wp.length := sizeof(wp);
1230     wp.rcNormalPosition.Top := GikoSys.Setting.WindowTop;
1231     wp.rcNormalPosition.Left := GikoSys.Setting.WindowLeft;
1232     wp.rcNormalPosition.Bottom := GikoSys.Setting.WindowTop + GikoSys.Setting.WindowHeight;
1233     wp.rcNormalPosition.Right := GikoSys.Setting.WindowLeft + GikoSys.Setting.WindowWidth;
1234     wp.showCmd := SW_HIDE;
1235     SetWindowPlacement(Handle, @wp);
1236    
1237     // SetBounds(GikoSys.Setting.WindowLeft, GikoSys.Setting.WindowTop,
1238     // GikoSys.Setting.WindowWidth, GikoSys.Setting.WindowHeight);
1239     if GikoSys.Setting.WindowMax then
1240     WindowState := wsMaximized;
1241    
1242     //鐃?鐃?鐃?鐃?鐃緒申
1243     try
1244     FileName := GikoSys.GetAppDir + 'gikoNavi.avi';
1245     if FileExists(FileName) then
1246     Animate.FileName := FileName;
1247     except
1248     end;
1249    
1250     //鐃?鐃?鐃?鐃?
1251     FNameCookie := '';
1252     FMailCookie := '';
1253    
1254     //鐃?鐃緒申鐃?鐃緒申鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1255     AllItemAction.Checked := True;
1256 yoffy 1.126 AllResAction.Checked := True;
1257 hi_ 1.1
1258     //TreeView鐃緒申鐃緒申鐃緒申鐃?鐃緒申ToolTip鐃緒申鐃緒申鐃?鐃緒申
1259     Style := GetWindowLong(TreeView.Handle, GWL_STYLE);
1260     Style := Style or TVS_NOTOOLTIPS;
1261     SetWindowLong(TreeView.Handle, GWL_STYLE, Style);
1262    
1263     // 鐃?鐃緒申鐃?鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1264     TreeView.Align := alClient;
1265 yoffy 1.57 FavoriteTreeView.Align := alClient;
1266 hi_ 1.1 FavoriteTreeView.Visible := False;
1267    
1268     //鐃?鐃緒申鐃?鐃?鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申
1269     // FBrowserSizeFlag := False;
1270     // FBrowserSizeHeight := ViewPanel.Height;
1271    
1272     FBrowserSizeHeight := GikoSys.Setting.ListHeight;
1273     FBrowserSizeWidth := GikoSys.Setting.ListWidth;
1274    
1275     ArrangeAction.Checked := not (GikoSys.Setting.ListOrientation = gloVertical);
1276     ArrangeAction.Execute;
1277    
1278     if GikoSys.Setting.ListOrientation = gloHorizontal then begin
1279     case GikoSys.Setting.ListWidthState of
1280     glsMax: begin
1281     ViewPanel.Width := 1;
1282 yoffy 1.2 BrowserMaxAction.ImageIndex := TOOL_ICON_WIDTH_NORMAL;
1283     BrowserMinAction.ImageIndex := TOOL_ICON_WIDTH_MIN;
1284 hi_ 1.1 end;
1285     glsMin: begin
1286     ViewPanel.Width := GikoSys.Setting.ListWidth;
1287 yoffy 1.2 BrowserMaxAction.ImageIndex := TOOL_ICON_WIDTH_MAX;
1288     BrowserMinAction.ImageIndex := TOOL_ICON_WIDTH_NORMAL;
1289 hi_ 1.1 end;
1290     else begin
1291     ViewPanel.Width := GikoSys.Setting.ListWidth;
1292 yoffy 1.2 BrowserMaxAction.ImageIndex := TOOL_ICON_WIDTH_MAX;
1293     BrowserMinAction.ImageIndex := TOOL_ICON_WIDTH_MIN;
1294 hi_ 1.1 end;
1295     end;
1296     end else begin
1297     case GikoSys.Setting.ListHeightState of
1298     glsMax: begin
1299     ViewPanel.Height := 1;
1300 yoffy 1.2 BrowserMaxAction.ImageIndex := TOOL_ICON_HEIGHT_NORMAL;
1301     BrowserMinAction.ImageIndex := TOOL_ICON_HEIGHT_MIN;
1302 hi_ 1.1 end;
1303     glsMin: begin
1304     ViewPanel.Height := GikoSys.Setting.ListHeight;
1305 yoffy 1.2 BrowserMaxAction.ImageIndex := TOOL_ICON_HEIGHT_MAX;
1306     BrowserMinAction.ImageIndex := TOOL_ICON_HEIGHT_NORMAL;
1307 hi_ 1.1 end;
1308     else begin
1309     ViewPanel.Height := GikoSys.Setting.ListHeight;
1310 yoffy 1.2 BrowserMaxAction.ImageIndex := TOOL_ICON_HEIGHT_MAX;
1311     BrowserMinAction.ImageIndex := TOOL_ICON_HEIGHT_MIN;
1312 hi_ 1.1 end;
1313     end;
1314     end;
1315    
1316     //鐃?鐃緒申鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申
1317     // ProgressBar.Visible := False;
1318     ProgressBar.Parent := StatusBar;
1319     ProgressBar.Top := 2;
1320     ProgressBar.Left := 0;
1321     ProgressBar.Width := StatusBar.Panels[0].Width;
1322     ProgressBar.Height := StatusBar.Height - 2;
1323     ProgressBar.Position := 0;
1324    
1325     //鐃?鐃?鐃緒申鐃緒申鐃?鐃?鐃?鐃?鐃?鐃?鐃?鐃?
1326     FControlThread := TThreadControl.Create(True);
1327     FControlThread.MaxThreadCount := 1;
1328     FControlThread.Resume;
1329     FControlThread.OnDownloadEnd := DownloadEnd;
1330     FControlThread.OnDownloadMsg := DownloadMsg;
1331     FControlThread.OnWork := Work;
1332     FControlThread.OnWorkBegin := WorkBegin;
1333     FControlThread.OnWorkEnd := WorkEnd;
1334     // ProgressPanel.Width := FControlThread.MaxThreadCount * 12;
1335    
1336 yoffy 1.51 // 鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1337     SelectComboBox.Items.Assign( GikoSys.Setting.SelectTextList );
1338 yoffy 1.2
1339 hi_ 1.1 //鐃?鐃緒申鐃?鐃?鐃?鐃?鐃緒申鐃緒申
1340     SetBrowserTabState;
1341    
1342     BrowserBoardNameLabel.Caption := '';
1343     BrowserNameLabel.Caption := '';
1344     FWorkCount := 0;
1345    
1346     FTabHintIndex := -1;
1347    
1348     //鐃緒申鐃緒申鐃?鐃?鐃?
1349     SetLinkBar;
1350    
1351     //鐃緒申鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?
1352     SetMenuFont;
1353    
1354     //鐃?鐃?鐃緒申鐃?鐃?Wrapable
1355     ListToolBar.Wrapable := GikoSys.Setting.ListToolBarWrapable;
1356     BrowserToolBar.Wrapable := GikoSys.Setting.BrowserToolBarWrapable;
1357    
1358 yoffy 1.2 //鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1359     ReadToolBarSetting(ActionList, StdToolBar);
1360     ReadToolBarSetting(ActionList, ListToolBar);
1361 yoffy 1.51 try
1362     for i := ListToolBar.ControlCount - 1 downto 0 do
1363     begin
1364     if ListToolBar.Controls[ i ].Action = SelectItemAction then
1365     begin
1366     // 鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申
1367     if (i + 1) < ListToolBar.ControlCount then
1368     if ListToolBar.Controls[ i + 1 ] is TToolButton then
1369     if TToolButton( ListToolBar.Controls[ i + 1 ] ).Style = tbsSeparator then
1370     ListToolBar.Controls[ i + 1 ].Visible := False;
1371    
1372     // 鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申鐃?鐃緒申
1373     ListToolBar.Controls[ i ].Visible := False;
1374     // 鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃?鐃緒申
1375     SelectComboBox.Left := ListToolBar.Controls[ i ].Left;
1376     SelectComboBox.Width := GikoSys.Setting.SelectComboBoxWidth;
1377     SelectComboBox.Parent := ListToolBar;
1378     // 鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃緒申鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃?鐃緒申
1379     SelectComboBoxSplitter.Left := SelectComboBox.Left + SelectComboBox.Width;
1380     SelectComboBoxSplitter.Parent := ListToolBar;
1381    
1382     break;
1383     end;
1384     end;
1385     except
1386     end;
1387 yoffy 1.2 ReadToolBarSetting(ActionList, BrowserToolBar);
1388     SetToolBarPopup;
1389 yoffy 1.126 OnlyAHundredRes.Checked := GikoSys.Setting.OnlyAHundredRes;
1390 hi_ 1.1 //鐃?鐃?鐃緒申鐃?鐃?鐃?
1391     AddressComboBox.TabStop := GikoSys.Setting.AddressBarTabStop;
1392    
1393 yoffy 1.2 //鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申FormShow鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1394    
1395     //鐃?鐃?鐃?鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃?鐃?鐃緒申
1396     if not FileExists(GikoSys.GetBoardFileName) then begin
1397     msg := '鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃?鐃緒申鐃?鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申' + #13#10#13#10
1398     + '鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃?鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃?鐃?鐃緒申鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申' + #13#10
1399     + '鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃?鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?';
1400     MsgBox(SplashWindow.Handle, msg, '鐃?鐃?鐃?鐃?', MB_OK or MB_ICONINFORMATION);
1401     NewBoardAction.Execute;
1402     end;
1403    
1404     //鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1405     GikoSys.LoadKeySetting(ActionList);
1406    
1407     //鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申
1408     // FLastRoundTime := 0;
1409    
1410     //ResHint
1411     FHint := TResPopup.Create(Self);
1412    
1413 yoffy 1.100 // 鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃?鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申
1414 yoffy 1.140 CabinetVisible( False );
1415 yoffy 1.141 if GikoSys.Setting.CabinetVisible then begin
1416     i := CabinetSelectPopupMenu.Items.Count - 1;
1417     if GikoSys.Setting.CabinetIndex = i - 1 then
1418     CabinetHistoryAction.Execute
1419     else if GikoSys.Setting.CabinetIndex = i then
1420     CabinetFavoriteAction.Execute
1421     else begin
1422     if GikoSys.Setting.CabinetIndex < Length( BBSs ) then
1423     ShowBBSTree( BBSs[ GikoSys.Setting.CabinetIndex ] );
1424     CabinetBBSAction.Execute;
1425     end;
1426     end else begin
1427     ShowBBSTree( BBSs[ 0 ] );
1428     end;
1429 yoffy 1.67
1430 yoffy 1.2 //鐃?鐃?鐃?鐃緒申鐃?鐃?鐃緒申
1431     if GikoSys.Setting.AutoLogin then
1432     LoginAction.Execute;
1433    
1434     //鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃緒申鐃緒申鐃?鐃?鐃?
1435     for i := 1 to ParamCount do begin
1436     MoveToURL(ParamStr(i));
1437     end;
1438     // SetStdToolBar;
1439     // SetLinkBar;
1440 h677 1.22
1441 hi_ 1.32 s := GikoSys.FAbon.NGwordname;
1442     StatusBar.Panels[2].Text := s;
1443     StatusBar.Panels[2].Width := Max(StatusBar.Canvas.TextWidth(s), 100);
1444     StatusBarResize(Sender);
1445 yoffy 1.2 end;
1446    
1447     //
1448     //
1449     //
1450     procedure TGikoForm.FormShow(Sender: TObject);
1451     var
1452     i: Integer;
1453     CoolSet: TCoolSet;
1454     begin
1455     ShowWindow(Application.Handle, SW_HIDE);
1456    
1457     //FormCreate鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申FormShow鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1458     //鐃?鐃?鐃緒申鐃?鐃?鐃?鐃緒申
1459     StdToolBarVisibleAction.Checked := GikoSys.Setting.StdToolBarVisible;
1460     StdToolBarVisibleActionExecute( nil );
1461     AddressBarVisibleAction.Checked := GikoSys.Setting.AddressBarVisible;
1462     AddressBarVisibleActionExecute( nil );
1463     LinkBarVisibleAction.Checked := GikoSys.Setting.LinkBarVisible;
1464     LinkBarVisibleActionExecute( nil );
1465     ListToolBarVisibleAction.Checked := GikoSys.Setting.ListToolBarVisible;
1466     ListToolBarVisibleActionExecute( nil );
1467     ListNameBarVisibleAction.Checked := GikoSys.Setting.ListNameBarVisible;
1468     ListNameBarVisibleActionExecute( nil );
1469     BrowserToolBarVisibleAction.Checked := GikoSys.Setting.BrowserToolBarVisible;
1470     BrowserToolBarVisibleActionExecute( nil );
1471     BrowserNameBarVisibleAction.Checked := GikoSys.Setting.BrowserNameBarVisible;
1472     BrowserNameBarVisibleActionExecute( nil );
1473    
1474     //鐃?鐃緒申鐃?鐃?鐃?鐃?
1475     BrowserTabVisibleAction.Checked := GikoSys.Setting.BrowserTabVisible;
1476     BrowserTabVisibleActionExecute(nil);
1477    
1478     if GikoSys.Setting.BrowserTabPosition = gtpTop then begin
1479     BrowserTabTopAction.Checked := True;
1480     BrowserTabTopActionExecute(nil);
1481     end else begin
1482     BrowserTabBottomAction.Checked := True;
1483     BrowserTabBottomActionExecute(nil);
1484     end;
1485    
1486     if GikoSys.Setting.BrowserTabStyle = gtsTab then begin
1487     BrowserTabTabStyleAction.Checked := True;
1488     BrowserTabTabStyleActionExecute(nil);
1489     end else if GikoSys.Setting.BrowserTabStyle = gtsButton then begin
1490     BrowserTabButtonStyleAction.Checked := True;
1491     BrowserTabButtonStyleActionExecute(nil);
1492     end else begin
1493     BrowserTabFlatStyleAction.Checked := True;
1494     BrowserTabFlatStyleActionExecute(nil);
1495     end;
1496    
1497    
1498 hi_ 1.1 //鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申(Main)
1499     MainCoolBar.Bands.BeginUpdate;
1500     try
1501     for i := 0 to MainCoolBar.Bands.Count - 1 do begin
1502     CoolSet := GikoSys.Setting.MainCoolSet[i];
1503     if (CoolSet.FCoolID = -1) or (CoolSet.FCoolWidth = -1) then
1504     Continue;
1505     MainCoolBar.Bands.FindItemID(CoolSet.FCoolID).Index := i;
1506     MainCoolBar.Bands[i].Break := CoolSet.FCoolBreak;
1507     MainCoolBar.Bands[i].Width := CoolSet.FCoolWidth;
1508     end;
1509     finally
1510     MainCoolBar.Bands.EndUpdate;
1511     end;
1512    
1513     //鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申(Board)
1514     ListCoolBar.Bands.BeginUpdate;
1515     try
1516     for i := 0 to ListCoolBar.Bands.Count - 1 do begin
1517     CoolSet := GikoSys.Setting.ListCoolSet[i];
1518     if (CoolSet.FCoolID = -1) or (CoolSet.FCoolWidth = -1) then
1519     Continue;
1520     ListCoolBar.Bands.FindItemID(CoolSet.FCoolID).Index := i;
1521     ListCoolBar.Bands[i].Break := CoolSet.FCoolBreak;
1522     ListCoolBar.Bands[i].Width := CoolSet.FCoolWidth;
1523     end;
1524     finally
1525     ListCoolBar.Bands.EndUpdate;
1526     end;
1527    
1528     //鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申(Browser)
1529     BrowserCoolBar.Bands.BeginUpdate;
1530     try
1531     for i := 0 to BrowserCoolBar.Bands.Count - 1 do begin
1532     CoolSet := GikoSys.Setting.BrowserCoolSet[i];
1533     if (CoolSet.FCoolID = -1) or (CoolSet.FCoolWidth = -1) then
1534     Continue;
1535     BrowserCoolBar.Bands.FindItemID(CoolSet.FCoolID).Index := i;
1536     BrowserCoolBar.Bands[i].Break := CoolSet.FCoolBreak;
1537     BrowserCoolBar.Bands[i].Width := CoolSet.FCoolWidth;
1538     end;
1539     finally
1540     BrowserCoolBar.Bands.EndUpdate;
1541     end;
1542    
1543     end;
1544     procedure TGikoForm.FormCloseQuery(Sender: TObject; var CanClose: Boolean);
1545     var
1546     i: Integer;
1547     CoolSet: TCoolSet;
1548     wp: TWindowPlacement;
1549     begin
1550 yoffy 1.100 if ( GikoSys.Setting.ShowDialogForEnd ) and
1551     (MessageDlg('鐃?鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?', mtConfirmation,[mbOk, mbCancel], 0) = mrCancel ) then begin
1552     CanClose := false;
1553     Exit;
1554     end else begin
1555     CanClose := True;
1556     end;
1557 hi_ 1.1 Application.OnDeactivate := nil;
1558     Self.OnDeactivate := nil;
1559    
1560 yoffy 1.2 //column鐃緒申
1561 yoffy 1.123 if GetActiveList is TBBS then begin
1562 yoffy 1.2 for i := 0 to ListView.Columns.Count - 1 do
1563     GikoSys.Setting.BBSColumnWidth[i] := ListView.Column[i].Width;
1564     end else if GetActiveList is TCategory then begin
1565     for i := 0 to ListView.Columns.Count - 1 do
1566     GikoSys.Setting.CategoryColumnWidth[i] := ListView.Column[i].Width;
1567     end else if GetActiveList is TBoard then begin
1568     for i := 0 to ListView.Columns.Count - 1 do
1569     GikoSys.Setting.BoardColumnWidth[i] := ListView.Column[i].Width;
1570     end;
1571    
1572     //鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃?鐃緒申鐃緒申
1573     wp.length := sizeof(wp);
1574     GetWindowPlacement(Handle, @wp);
1575     GikoSys.Setting.WindowTop := wp.rcNormalPosition.Top;
1576     GikoSys.Setting.WindowLeft := wp.rcNormalPosition.Left;
1577     GikoSys.Setting.WindowHeight := wp.rcNormalPosition.Bottom - wp.rcNormalPosition.Top;
1578     GikoSys.Setting.WindowWidth := wp.rcNormalPosition.Right - wp.rcNormalPosition.Left;
1579     GikoSys.Setting.WindowMax := WindowState = wsMaximized;
1580    
1581     GikoSys.Setting.ListStyle := ListView.ViewStyle;
1582     GikoSys.Setting.CabinetVisible := CabinetVisibleAction.Checked;
1583     GikoSys.Setting.CabinetWidth := CabinetPanel.Width;
1584     GikoSys.Setting.ListHeight := FBrowserSizeHeight;
1585     GikoSys.Setting.ListWidth := FBrowserSizeWidth;
1586     if ArrangeAction.Checked then
1587     GikoSys.Setting.ListOrientation := gloVertical
1588     else
1589     GikoSys.Setting.ListOrientation := gloHorizontal;
1590     GikoSys.Setting.MessegeBarHeight := MessagePanel.Height;
1591    
1592     //鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申(Main)
1593     for i := 0 to MAIN_COOLBAND_COUNT - 1 do begin
1594     CoolSet.FCoolID := MainCoolBar.Bands[i].ID;
1595     CoolSet.FCoolWidth := MainCoolBar.Bands[i].Width;
1596     CoolSet.FCoolBreak := MainCoolBar.Bands[i].Break;
1597     GikoSys.Setting.MainCoolSet[i] := CoolSet;
1598     end;
1599     //鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申(Board)
1600     for i := 0 to LIST_COOLBAND_COUNT - 1 do begin
1601     CoolSet.FCoolID := ListCoolBar.Bands[i].ID;
1602     CoolSet.FCoolWidth := ListCoolBar.Bands[i].Width;
1603     CoolSet.FCoolBreak := ListCoolBar.Bands[i].Break;
1604     GikoSys.Setting.ListCoolSet[i] := CoolSet;
1605     end;
1606     //鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申(Browser)
1607     for i := 0 to BROWSER_COOLBAND_COUNT - 1 do begin
1608     CoolSet.FCoolID := BrowserCoolBar.Bands[i].ID;
1609     CoolSet.FCoolWidth := BrowserCoolBar.Bands[i].Width;
1610     CoolSet.FCoolBreak := BrowserCoolBar.Bands[i].Break;
1611     GikoSys.Setting.BrowserCoolSet[i] := CoolSet;
1612 hi_ 1.1 end;
1613    
1614 yoffy 1.2 GikoSys.Setting.WriteWindowSettingFile;
1615     GikoSys.Setting.WriteNameMailSettingFile;
1616    
1617     //鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1618 hi_ 1.1 try
1619 yoffy 1.2 FavoriteDM.WriteFavorite;
1620 hi_ 1.1 except
1621     end;
1622 yoffy 1.2 // Favorite.Free;
1623 hi_ 1.1
1624     try
1625     //鐃?鐃?鐃?鐃緒申鐃?鐃?
1626     NotSelectTabCloseAction.Execute;
1627     if BrowserTab.Tabs.Count >= 1 then begin
1628     DeleteTab(TThreadItem(BrowserTab.Tabs.Objects[0]));
1629     end;
1630     except
1631     end;
1632    
1633     //鐃緒申鐃緒申鐃緒申鐃?鐃?鐃緒申鐃緒申&鐃?鐃緒申
1634     try
1635     RoundList.SaveRoundFile;
1636     except
1637     end;
1638 yoffy 1.125
1639 hi_ 1.1 try
1640     RoundList.Clear;
1641     except
1642     end;
1643     try
1644     RoundList.Free;
1645     except
1646     end;
1647    
1648 yoffy 1.135 //鐃?鐃?鐃?鐃緒申鐃緒申鐃?鐃?鐃緒申鐃緒申
1649     try
1650     SaveHistory;
1651     except
1652     end;
1653    
1654 hi_ 1.1 //鐃?鐃?鐃?鐃緒申鐃緒申鐃?鐃?
1655     try
1656     FHistoryList.Free;
1657     except
1658     end;
1659 yoffy 1.125
1660 hi_ 1.1 //鐃?鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申
1661     try
1662     AddressHistoryDM.WriteHistory(AddressComboBox.Items, GikoSys.Setting.AddressHistoryCount);
1663     except
1664     end;
1665    
1666     try
1667     FControlThread.Terminate;
1668     except
1669     end;
1670    
1671     // FDownload.Free;
1672     try
1673     SetActiveList(nil);
1674     except
1675     end;
1676 yoffy 1.124
1677 hi_ 1.1 //TreeView鐃?鐃緒申鐃?鐃?BBS2ch.Free鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申XP鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃?鐃?鐃緒申鐃?
1678 h677 1.170 //Sleep(10);
1679     Application.ProcessMessages;
1680 hi_ 1.1 try
1681     TreeView.Items.Clear;
1682     except
1683     end;
1684 yoffy 1.125
1685 hi_ 1.1 try
1686     if FavoriteDM <> nil then
1687     FavoriteDM.Free;
1688     FavoriteDM := nil;
1689     if AddressHistoryDM <> nil then
1690     AddressHistoryDM.Free;
1691     AddressHistoryDM := nil;
1692     except
1693     end;
1694 yoffy 1.125
1695 yoffy 1.155 // TBBS 鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申 TCategory, TBoard, TThreadItem 鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申
1696     // TBoard, TThreadItem 鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申
1697     // BoardPluteIns 鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申
1698 yoffy 1.126 try
1699 h677 1.153 for i := 0 to Length( BBSs ) - 1 do begin
1700     if BBSs[ i ] <> nil then
1701     BBSs[ i ].Free;
1702     BBSs[ i ] := nil;
1703     end;
1704     except
1705     end;
1706 yoffy 1.155
1707 h677 1.153 try
1708 yoffy 1.126 for i := 0 to Length( BoardPlugIns ) - 1 do begin
1709     if BoardPlugIns[ i ] <> nil then
1710     BoardPlugIns[ i ].Free;
1711     BoardPlugIns[ i ] := nil;
1712     end;
1713     except
1714     end;
1715 yoffy 1.124
1716 yoffy 1.126 try
1717     for i := CabinetSelectPopupMenu.Items.Count - 1 downto 0 do begin
1718     if CabinetSelectPopupMenu.Items[ i ] is TBBSMenuItem then begin
1719 yoffy 1.155 CabinetSelectPopupMenu.Items[ i ].Free;
1720     CabinetMenu.Items[ i ].Free;
1721 yoffy 1.126 end;
1722     end;
1723     except
1724     end;
1725 yoffy 1.124
1726 yoffy 1.2 try
1727     //Hint鐃?鐃緒申
1728     if FHint <> nil then begin
1729     FHint.ReleaseHandle;
1730     FHint.Free;
1731     FHint := nil;
1732     end;
1733     //Preview鐃?鐃緒申
1734     if TPreviewBrowser <> nil then begin
1735     FPreviewBrowser.Free;
1736     FPreviewBrowser := nil;
1737     end;
1738     except
1739     end;
1740 hi_ 1.1 end;
1741    
1742     procedure TGikoForm.FormDestroy(Sender: TObject);
1743     begin
1744     end;
1745    
1746     //鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃?鐃?
1747     procedure TGikoForm.FormClose(Sender: TObject; var Action: TCloseAction);
1748     begin
1749     Application.Terminate;
1750     Action := caFree;
1751     end;
1752    
1753     //鐃?鐃緒申鐃?鐃?鐃?鐃?鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃?鐃?
1754     procedure TGikoForm.CabinetPanelHide(Sender: TObject);
1755     begin
1756     CabinetVisibleAction.Execute;
1757     // CabinetPanelVisible(false);
1758     end;
1759    
1760     procedure TGikoForm.ReloadBBS;
1761 yoffy 1.123 var
1762     i : Integer;
1763 yoffy 1.149 item : TBBSMenuItem;
1764 hi_ 1.1 begin
1765     //鐃?鐃?鐃?鐃緒申鐃?鐃?
1766     NotSelectTabCloseAction.Execute;
1767     if BrowserTab.Tabs.Count >= 1 then
1768     DeleteTab(TThreadItem(BrowserTab.Tabs.Objects[0]));
1769     //鐃?鐃?鐃?鐃緒申鐃緒申鐃?鐃?
1770 yoffy 1.135 //FHistoryList.Clear;
1771 hi_ 1.1 //TreeView鐃?鐃緒申鐃?鐃?BBS2ch.Free鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申XP鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃?鐃?鐃緒申鐃?
1772     TreeView.Items.Clear;
1773    
1774     //BBS鐃?鐃緒申
1775 yoffy 1.146 try
1776     for i := Length( BBSs ) - 1 downto 0 do begin
1777     if BBSs[ i ] <> nil then
1778     BBSs[ i ].Free;
1779     BBSs[ i ] := nil;
1780     end;
1781     except
1782 yoffy 1.126 end;
1783 hi_ 1.1
1784 yoffy 1.123 ActiveList := nil;
1785 hi_ 1.1
1786     FTreeType := gttNone;
1787    
1788 yoffy 1.123 GikoSys.ReadBoardFile; //鐃?鐃?鐃?鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申
1789 yoffy 1.148 // 鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申
1790     for i := CabinetSelectPopupMenu.Items.Count - 1 downto 0 do begin
1791     try
1792     if CabinetSelectPopupMenu.Items[ i ] is TBBSMenuItem then begin
1793 yoffy 1.155 CabinetSelectPopupMenu.Items[ i ].Free;
1794     CabinetMenu.Items[ i ].Free;
1795 yoffy 1.148 end;
1796     except
1797     end;
1798     end;
1799     // 鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申
1800     for i := Length( BBSs ) - 1 downto 0 do begin
1801     try
1802     item := TBBSMenuItem.Create( PopupMenu );
1803     item.Caption := BBSs[ i ].Title;
1804     item.Data := BBSs[ i ];
1805     item.OnClick := BBSMenuItemOnClick;
1806     CabinetSelectPopupMenu.Items.Insert( 0, item );
1807     item := TBBSMenuItem.Create( PopupMenu );
1808     item.Caption := BBSs[ i ].Title;
1809     item.Data := BBSs[ i ];
1810     item.OnClick := BBSMenuItemOnClick;
1811     CabinetMenu.Insert( 0, item );
1812     except
1813     end;
1814     end;
1815 yoffy 1.123 ShowBBSTree( BBSs[ 0 ] );
1816 yoffy 1.143
1817     // 鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1818 yoffy 1.146 SaveHistory;
1819     try
1820     for i := FHistoryList.Count - 1 downto 0 do
1821     TFavoriteThreadItem( FHistoryList[ i ] ).Free;
1822     except
1823     end;
1824     FHistoryList.Clear;
1825 yoffy 1.143 LoadHistory;
1826    
1827     //鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1828     // FFavorite := TFavorite.Create(FavoriteTreeView);
1829     FavoriteTreeView.Items.Clear;
1830     FavoriteDM.SetFavTreeView(FavoriteTreeView);
1831     FavoriteDM.ReadFavorite;
1832     SetLinkBar;
1833    
1834 hi_ 1.1 end;
1835    
1836     //鐃?鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃緒申
1837 yoffy 1.123 procedure TGikoForm.SetBoardTreeNode(
1838     inBBS : TBBS
1839     );
1840 hi_ 1.1 var
1841 yoffy 1.120 i, j, k: integer;
1842 hi_ 1.1 Root: TTreeNode;
1843     CategoryNode: TTreeNode;
1844     BoardNode: TTreeNode;
1845     Category: TCategory;
1846     Board: TBoard;
1847     begin
1848 yoffy 1.112 // 鐃緒申鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申
1849 yoffy 1.133 FActiveBBS := inBBS;
1850 hi_ 1.1 TreeView.Items.BeginUpdate;
1851     TreeView.Items.Clear;
1852     try
1853 yoffy 1.123 try
1854     if SplashWindow <> nil then
1855     SplashWindow.ProgressBar.Max := BBSs[ 0 ].Count;
1856     except
1857     end;
1858    
1859     Root := TreeView.Items.Add( nil, inBBS.Title );
1860     Root.ImageIndex := ITEM_ICON_2CH1;
1861     Root.SelectedIndex := ITEM_ICON_2CH2;
1862     Root.Data := inBBS;
1863     for i := 0 to inBBS.Count - 1 do begin
1864     Category := TCategory(inBBS.Items[i]);
1865     CategoryNode := TreeView.Items.AddChild(Root, Category.Title);
1866     CategoryNode.Data := Category;
1867     CategoryNode.ImageIndex := ITEM_ICON_CATEGORY1;
1868     CategoryNode.SelectedIndex := ITEM_ICON_CATEGORY2;
1869 hi_ 1.1
1870 yoffy 1.123 for j := 0 to Category.Count - 1 do begin
1871     Board := TBoard(Category.Items[j]);
1872     Board.BeginUpdate;
1873     BoardNode := TreeView.Items.AddChild(CategoryNode, Board.Title);
1874     BoardNode.Data := Board;
1875     //if (Board.LastGetTime = 0) or (Board.LastGetTime = ZERO_DATE) then begin
1876     if not Board.IsLogFile then begin
1877     BoardNode.ImageIndex := ITEM_ICON_BOARD_NOSUBJECT;
1878     BoardNode.SelectedIndex := ITEM_ICON_BOARD_NOSUBJECT;
1879     end else begin
1880     BoardNode.ImageIndex := ITEM_ICON_BOARD1;
1881     BoardNode.SelectedIndex := ITEM_ICON_BOARD2;
1882     for k := 0 to Board.Count - 1 do begin
1883     if Board.Items[ k ].IsLogFile then begin
1884     BoardNode.ImageIndex := ITEM_ICON_BOARD_LOG;
1885     BoardNode.SelectedIndex := ITEM_ICON_BOARD_LOG;
1886 yoffy 1.120
1887 yoffy 1.123 Break;
1888 yoffy 1.120 end;
1889     end;
1890 yoffy 1.112 end;
1891 yoffy 1.123 Board.EndUpdate;
1892     end;
1893 hi_ 1.1
1894 yoffy 1.123 CategoryNode.Expanded := Category.NodeExpand;
1895 hi_ 1.1
1896 yoffy 1.123 if SplashWindow <> nil then begin
1897     SplashWindow.ProgressBar.StepIt;
1898     Application.ProcessMessages;
1899 hi_ 1.1 end;
1900     end;
1901     finally
1902     TreeView.Items.EndUpdate;
1903     end;
1904     end;
1905    
1906 yoffy 1.123 function TGikoForm.SetCategoryListItem(ABBS2ch: TBBS): Integer;
1907 hi_ 1.1 const
1908     COLUMN: array[0..0] of string = ('鐃?鐃?鐃?鐃緒申鐃緒申');
1909     var
1910     ListColumn: TListColumn;
1911     i: Integer;
1912     begin
1913     ListView.Items.BeginUpdate;
1914     try
1915     Screen.Cursor := crHourGlass;
1916    
1917     ListView.Columns.Clear;
1918     for i := 0 to Length(COLUMN) - 1 do begin
1919     ListColumn := ListView.Columns.Add;
1920     ListColumn.Caption := COLUMN[i];
1921     ListColumn.Width := GikoSys.Setting.BBSColumnWidth[i];
1922     end;
1923    
1924     ListView.Items.Count := 0;
1925     ListView.Items.Clear;
1926     ListView.Items.Count := ABBS2ch.Count;
1927    
1928     // UpFolderAction.Enabled := False;
1929     // AllItemAction.Enabled := False;
1930     // LogItemAction.Enabled := False;
1931     // NewItemAction.Enabled := False;
1932     // SelectItemAction.Enabled := False;
1933     // ListDownloadToolButton.Enabled := False;
1934     // BoardReservToolButton.Enabled := False;
1935     // ListThreadDownloadToolButton.Enabled := False;
1936    
1937     ListNameLabel.Caption := ABBS2ch.Title;
1938     FolderImage.Picture := nil;
1939     ItemIcon16.GetBitmap(1, FolderImage.Picture.Bitmap);
1940    
1941 yoffy 1.2 FSortIndex := 0;
1942     FSortOrder := False;
1943     ListViewColumnClick(nil, ListView.Column[0]);
1944    
1945 hi_ 1.1 Result := ABBS2ch.Count;
1946     finally
1947     Screen.Cursor := crDefault;
1948     ListView.Items.EndUpdate;
1949     end;
1950     end;
1951    
1952     function TGikoForm.SetBoardListItem(Category: TCategory): Integer;
1953     const
1954     COLUMN: array[0..2] of string = ('鐃緒申鐃緒申', '鐃緒申鐃緒申鐃?鐃緒申', '鐃緒申鐃緒申鐃緒申鐃緒申');
1955     var
1956     ListColumn: TListColumn;
1957     i: Integer;
1958     begin
1959     ListView.Items.BeginUpdate;
1960     try
1961     Screen.Cursor := crHourGlass;
1962    
1963     ListView.Columns.Clear;
1964     for i := 0 to Length(COLUMN) - 1 do begin
1965     ListColumn := ListView.Columns.Add;
1966     ListColumn.Caption := COLUMN[i];
1967     ListColumn.Width := GikoSys.Setting.CategoryColumnWidth[i];
1968     end;
1969    
1970     ListView.Items.Count := 0;
1971     ListView.Items.Clear;
1972     ListView.Items.Count := Category.Count;
1973    
1974     // UpFolderAction.Enabled := True;
1975     // AllItemAction.Enabled := False;
1976     // LogItemAction.Enabled := False;
1977     // NewItemAction.Enabled := False;
1978     // SelectItemAction.Enabled := False;
1979     // ListDownloadToolButton.Enabled := False;
1980     // BoardReservToolButton.Enabled := False;
1981     // ListThreadDownloadToolButton.Enabled := False;
1982    
1983     ListNameLabel.Caption := Category.Title;
1984     FolderImage.Picture := nil;
1985     ItemIcon16.GetBitmap(3, FolderImage.Picture.Bitmap);
1986    
1987 yoffy 1.2 FSortIndex := 0;
1988     FSortOrder := False;
1989     ListViewColumnClick(nil, ListView.Column[0]);
1990    
1991 hi_ 1.1 Result := Category.Count;
1992     finally
1993     Screen.Cursor := crDefault;
1994     ListView.Items.EndUpdate;
1995     end;
1996     end;
1997    
1998     function TGikoForm.SetThreadListItem(Board: TBoard): Integer;
1999     const
2000     COLUMN: array[0..6] of string = ('鐃?鐃緒申鐃?鐃?鐃緒申', '鐃?鐃?鐃緒申鐃?', '鐃緒申鐃緒申', '鐃?鐃緒申',
2001     '鐃緒申鐃緒申', '鐃緒申鐃緒申鐃?鐃緒申', '鐃緒申鐃緒申鐃緒申鐃緒申');
2002     COLUMN_ALIGNMENT: array[0..6] of TAlignment = (taLeftJustify, taRightJustify,
2003     taRightJustify, taRightJustify,
2004     taRightJustify, taLeftJustify,
2005     taLeftJustify);
2006     //No, 鐃?鐃緒申鐃?鐃?鐃緒申, 鐃?鐃?鐃緒申鐃?, 鐃緒申鐃緒申鐃?鐃緒申, 鐃緒申鐃緒申鐃緒申鐃緒申
2007     var
2008     ListColumn: TListColumn;
2009     i: Integer;
2010     begin
2011     ListView.Items.BeginUpdate;
2012     try
2013     Screen.Cursor := crHourGlass;
2014    
2015 yoffy 1.51 // 鐃?鐃緒申鐃緒申鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
2016     // 鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
2017     if ListView.Columns.Count <> (High( COLUMN ) - Low( COLUMN ) + 1) then
2018     begin
2019     ListView.Columns.Clear;
2020     for i := 0 to Length(COLUMN) - 1 do begin
2021     ListColumn := ListView.Columns.Add;
2022     ListColumn.Caption := COLUMN[i];
2023     ListColumn.Width := GikoSys.Setting.BoardColumnWidth[i];
2024     ListColumn.Alignment := COLUMN_ALIGNMENT[i];
2025     end;
2026     end;
2027 hi_ 1.1
2028     ListView.Items.Count := 0;
2029     ListView.Items.Clear;
2030    
2031     case GikoForm.ViewType of
2032     gvtAll: ListView.Items.Count := Board.Count;
2033     gvtLog: ListView.Items.Count := Board.GetLogThreadCount;
2034     gvtNew: ListView.Items.Count := Board.GetNewThreadCount;
2035     gvtUser: ListView.Items.Count := Board.GetUserThreadCount;
2036     end;
2037    
2038     ListNameLabel.Caption := Board.Title;
2039     FolderImage.Picture := nil;
2040     ItemIcon16.GetBitmap(5, FolderImage.Picture.Bitmap);
2041    
2042 yoffy 1.2 FSortIndex := 0;
2043     FSortOrder := False;
2044     ListViewColumnClick(nil, ListView.Column[0]);
2045 hi_ 1.1
2046     Result := Board.Count;
2047     finally
2048     Screen.Cursor := crDefault;
2049     ListView.Items.EndUpdate;
2050     end;
2051     end;
2052    
2053     procedure TGikoForm.TreeViewChange(Sender: TObject; Node: TTreeNode);
2054     var
2055     i: Integer;
2056     begin
2057     if FTreeType = gttHistory then begin
2058 yoffy 1.145 if GetActiveContent <> TFavoriteThreadItem( Node ).Item then
2059     FavoriteClick( Node );
2060 hi_ 1.1 Exit;
2061     end;
2062    
2063     ListView.Selected := nil;
2064     ListView.Items.Count := 0;
2065     ListView.Items.Clear;
2066     // ListView.Columns.Clear;
2067    
2068     Caption := CAPTION_NAME;
2069     //Application.Title := CAPTION_NAME;
2070    
2071    
2072 yoffy 1.123 if GetActiveList is TBBS then begin
2073 hi_ 1.1 for i := 0 to ListView.Columns.Count - 1 do
2074     GikoSys.Setting.BBSColumnWidth[i] := ListView.Column[i].Width;
2075     end else if GetActiveList is TCategory then begin
2076     for i := 0 to ListView.Columns.Count - 1 do
2077     GikoSys.Setting.CategoryColumnWidth[i] := ListView.Column[i].Width;
2078     end else if GetActiveList is TBoard then begin
2079     for i := 0 to ListView.Columns.Count - 1 do
2080     GikoSys.Setting.BoardColumnWidth[i] := ListView.Column[i].Width;
2081     end;
2082    
2083 yoffy 1.123 if TObject(Node.Data) is TBBS then begin
2084 hi_ 1.1 SetActiveList(Node.data);
2085     end else if TObject(Node.Data) is TCategory then begin
2086     SetActiveList(Node.data);
2087     end else if TObject(Node.Data) is TBoard then begin
2088     if not TBoard(Node.Data).IsThreadDatRead then begin
2089     Screen.Cursor := crHourGlass;
2090     try
2091     GikoSys.ReadSubjectFile(TBoard(Node.Data));
2092     finally
2093     Screen.Cursor := crDefault;
2094     end;
2095     end;
2096     SetActiveList(Node.data);
2097     end;
2098     end;
2099    
2100     procedure TGikoForm.ListViewData(Sender: TObject; Item: TListItem);
2101     var
2102     // FileName: string;
2103     // DateTime: TDateTime;
2104     BoardCnt: Integer;
2105 yoffy 1.123 BBS: TBBS;
2106 hi_ 1.1 Category: TCategory;
2107     Board: TBoard;
2108     ThreadItem: TThreadItem;
2109     RepStr: string;
2110 h677 1.170 ActivListObj : TObject;
2111 hi_ 1.1 begin
2112 h677 1.170 ActivListObj := ActiveList;
2113     if ActivListObj is TBBS then begin
2114     BBS := TBBS(ActivListObj);
2115 yoffy 1.114
2116 hi_ 1.1 ListView.StateImages := nil;
2117    
2118     if BBS = nil then Exit;
2119     if BBS.Count <= 0 then Exit;
2120     if Item = nil then Exit;
2121     if Item.Index > BBS.Count then Exit;
2122     if ListView.Items.Count = 0 then Exit;
2123    
2124 yoffy 1.123 if not (BBS.Items[Item.index] is TCategory) then Exit;
2125     Category := TCategory(BBS.Items[Item.index]);
2126 hi_ 1.1
2127     if Category = nil then Exit;
2128    
2129     if ListNumberVisibleAction.Checked then
2130     Item.Caption := IntToStr(Category.No) + ': ' + Category.Title
2131     else
2132     Item.Caption := Category.Title;
2133    
2134 yoffy 1.2 Item.ImageIndex := ITEM_ICON_CATEGORY1;
2135 hi_ 1.1 Item.Data := Category;
2136 h677 1.170 end else if ActivListObj is TCategory then begin
2137     Category := TCategory(ActivListObj);
2138 hi_ 1.1
2139     ListView.StateImages := nil;
2140    
2141     if Category = nil then Exit;
2142     if Category.Count <= 0 then Exit;
2143     if Item = nil then Exit;
2144     if Item.Index >= Category.Count then Exit;
2145     if ListView.Items.Count = 0 then Exit;
2146    
2147     if not (Category.Items[Item.Index] is TBoard) then Exit;
2148     Board := TBoard(Category.Items[Item.Index]);
2149    
2150     if Board = nil then Exit;
2151    
2152     if ListNumberVisibleAction.Checked then
2153     Item.Caption := IntToStr(Board.No) + ': ' + Board.Title
2154     else
2155     Item.Caption := Board.Title;
2156    
2157     if Item.SubItems.Count <> 2 then begin
2158     Item.SubItems.Clear;
2159     Item.SubItems.Add('');
2160     Item.SubItems.Add('');
2161     end;
2162    
2163 yoffy 1.2 Item.ImageIndex := ITEM_ICON_BOARD1;
2164 hi_ 1.1
2165     if Board.Round then
2166 yoffy 1.51 Item.SubItems[0] := Board.RoundName // '鐃?鐃緒申'
2167 hi_ 1.1 else
2168     Item.SubItems[0] := '';
2169    
2170     if Board.RoundDate = ZERO_DATE then begin
2171     Item.SubItems[1] := '';
2172     end else
2173     Item.SubItems[1] := FormatDateTime('yyyy/mm/dd hh:mm:ss', Board.RoundDate);
2174     Item.Data := Board;
2175 h677 1.170 end else if ActivListObj is TBoard then begin
2176     Board := TBoard(ActivListObj);
2177 hi_ 1.1
2178     if GikoSys.Setting.ListIconVisible then
2179     ListView.StateImages := StateIconImageList
2180     else
2181     ListView.StateImages := nil;
2182    
2183     case GikoForm.ViewType of
2184     gvtAll: BoardCnt := Board.Count;
2185     gvtLog: BoardCnt := Board.GetLogThreadCount;
2186     gvtNew: BoardCnt := Board.GetNewThreadCount;
2187     gvtUser: BoardCnt := Board.GetUserThreadCount;
2188 yoffy 1.2 else
2189     BoardCnt := 0;
2190 hi_ 1.1 end;
2191    
2192     // if Board = nil then Exit;
2193     if BoardCnt <= 0 then Exit;
2194     if Item = nil then Exit;
2195     if Item.Index > BoardCnt then Exit;
2196     if ListView.Items.Count = 0 then Exit;
2197    
2198     // if not (Board.Items[Item.Index] is TThreadItem) then Exit;
2199    
2200     ThreadItem := nil;
2201     case GikoForm.ViewType of
2202     gvtAll: ThreadItem := TThreadItem(Board.Items[Item.Index]);
2203     gvtLog: ThreadItem := Board.GetLogThread(Item.Index);
2204     gvtNew: ThreadItem := Board.GetNewThread(Item.Index);
2205     gvtUser: ThreadItem := Board.GetUserThread(Item.Index);
2206     end;
2207    
2208     if ThreadItem = nil then Exit;
2209    
2210     // if ListNumberVisibleAction.Checked then
2211     // RepStr := IntToStr(ThreadItem.No) + ': ' + ThreadItem.Title
2212     // else
2213     RepStr := ThreadItem.Title;
2214 h677 1.151 RepStr := CustomStringReplace(RepStr, '&lt;', '<' );
2215     RepStr := CustomStringReplace(RepStr, '&gt;', '>' );
2216     RepStr := CustomStringReplace(RepStr, '&quot;', '"' );
2217     RepStr := CustomStringReplace(RepStr, '&amp', '&' );
2218 hi_ 1.1 //RepStr := StringReplace(RepStr, '鐃緒申鐃?', ',', [rfReplaceAll]);
2219    
2220     if Item.SubItems.Count <> 6 then begin
2221     Item.SubItems.Clear;
2222     Item.SubItems.Add('');
2223     Item.SubItems.Add('');
2224     Item.SubItems.Add('');
2225     Item.SubItems.Add('');
2226     Item.SubItems.Add('');
2227     Item.SubItems.Add('');
2228     end;
2229    
2230     if ListNumberVisibleAction.Checked then
2231     Item.Caption := IntToStr(ThreadItem.No) + ': ' + RepStr
2232     else
2233     Item.Caption := RepStr;
2234    
2235     case ThreadItem.AgeSage of
2236     gasNone: Item.StateIndex := -1;
2237 yoffy 1.51 gasNew: Item.StateIndex := 0;
2238     gasAge: Item.StateIndex := 1;
2239 hi_ 1.1 gasSage: Item.StateIndex := 2;
2240     end;
2241    
2242     if ThreadItem.IsLogFile then begin
2243 yoffy 1.2 Item.ImageIndex := ITEM_ICON_THREADLOG1;
2244 hi_ 1.1 Item.SubItems[0] := IntToStr(ThreadItem.AllResCount);
2245     Item.SubItems[1] := IntToStr(ThreadItem.Count);
2246     if ThreadItem.NewResCount = 0 then
2247     Item.SubItems[2] := ''
2248     else
2249     Item.SubItems[2] := IntToStr(ThreadItem.NewResCount);
2250     Item.SubItems[3] := '';
2251     if ThreadItem.Round then
2252     Item.SubItems[4] := ThreadItem.RoundName
2253     else
2254     Item.SubItems[4] := '';
2255     if ThreadItem.RoundDate = ZERO_DATE then begin
2256     Item.SubItems[5] := '';
2257     end else
2258     Item.SubItems[5] := FormatDateTime('yyyy/mm/dd hh:mm:ss', ThreadItem.RoundDate);
2259     if ThreadItem.NewArrival then
2260 yoffy 1.2 Item.ImageIndex := ITEM_ICON_THREADNEW1;
2261 hi_ 1.1 end else begin
2262 yoffy 1.2 Item.ImageIndex := ITEM_ICON_THREAD1;
2263 hi_ 1.1 Item.SubItems[0] := IntToStr(ThreadItem.AllResCount);
2264     Item.SubItems[1] := '';
2265     Item.SubItems[2] := '';
2266     Item.SubItems[3] := '';
2267     Item.SubItems[4] := '';
2268     Item.SubItems[5] := '';
2269     end;
2270     Item.Data := ThreadItem;
2271     end;
2272     end;
2273