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.106 - (hide annotations) (download) (as text)
Sat Nov 15 13:01:26 2003 UTC (20 years, 5 months ago) by yoffy
Branch: MAIN
Changes since 1.105: +11 -15 lines
File MIME type: text/x-pascal
・プラグインを使用したスレッドの URL を正しく扱えるようになった。

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