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.79 - (hide annotations) (download) (as text)
Wed Oct 1 12:06:08 2003 UTC (20 years, 6 months ago) by h677
Branch: MAIN
Changes since 1.78: +31 -29 lines
File MIME type: text/x-pascal
MouseMoveの二つ目のif文を復活。D&Dの閾値をDandD_THRESHOLDにした。

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     SHDocVw,
10     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 yoffy 1.54 IndividualAbon, Dialogs, Search;
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.57 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 yoffy 1.61 FavoriteTreeViewBrowseFolderAction: TAction;
491     FavoriteTreeBrowseFolderPopupMenu: TMenuItem;
492     N57: TMenuItem;
493 yoffy 1.65 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 h677 1.70 OnlyAHundredRes: TAction;
506 h677 1.76 ToolButton20: TToolButton;
507     ToolButton21: TToolButton;
508 hi_ 1.1 procedure FormCreate(Sender: TObject);
509     procedure FormDestroy(Sender: TObject);
510     procedure CabinetPanelHide(Sender: TObject);
511     procedure FormClose(Sender: TObject; var Action: TCloseAction);
512     procedure TreeViewChange(Sender: TObject; Node: TTreeNode);
513     procedure ListViewData(Sender: TObject; Item: TListItem);
514     procedure ListViewDataFind(Sender: TObject; Find: TItemFind;
515     const FindString: String; const FindPosition: TPoint;
516     FindData: Pointer; StartIndex: Integer; Direction: TSearchDirection;
517     Wrap: Boolean; var Index: Integer);
518     procedure ListViewDataHint(Sender: TObject; StartIndex,
519     EndIndex: Integer);
520     procedure ListViewDataStateChange(Sender: TObject; StartIndex,
521     EndIndex: Integer; OldState, NewState: TItemStates);
522     procedure BrowserStatusTextChange(Sender: TObject;
523     const Text: WideString);
524     procedure BrowserTitleChange(Sender: TObject; const Text: WideString);
525     procedure FormCloseQuery(Sender: TObject; var CanClose: Boolean);
526     procedure TreeViewChanging(Sender: TObject; Node: TTreeNode;
527     var AllowChange: Boolean);
528     procedure ListViewKeyDown(Sender: TObject; var Key: Word;
529     Shift: TShiftState);
530     procedure ListViewColumnClick(Sender: TObject; Column: TListColumn);
531     procedure MenuToolBarCustomDrawButton(Sender: TToolBar;
532     Button: TToolButton; State: TCustomDrawState;
533     var DefaultDraw: Boolean);
534     procedure BrowserBeforeNavigate2(Sender: TObject;
535     const pDisp: IDispatch; var URL, Flags, TargetFrameName, PostData,
536     Headers: OleVariant; var Cancel: WordBool);
537     procedure ListViewAdvancedCustomDrawItem(Sender: TCustomListView;
538     Item: TListItem; State: TCustomDrawState; Stage: TCustomDrawStage;
539     var DefaultDraw: Boolean);
540     procedure TreeViewCustomDraw(Sender: TCustomTreeView;
541     const ARect: TRect; var DefaultDraw: Boolean);
542     procedure TreeViewCustomDrawItem(Sender: TCustomTreeView;
543     Node: TTreeNode; State: TCustomDrawState; var DefaultDraw: Boolean);
544     procedure TreeViewExpanded(Sender: TObject; Node: TTreeNode);
545     procedure TreeViewDblClick(Sender: TObject);
546 yoffy 1.57 procedure FavoriteTreeViewClick(Sender: TObject);
547 hi_ 1.1 procedure ListViewCustomDraw(Sender: TCustomListView;
548     const ARect: TRect; var DefaultDraw: Boolean);
549     procedure ListViewMouseDown(Sender: TObject; Button: TMouseButton;
550     Shift: TShiftState; X, Y: Integer);
551     procedure TreeViewCollapsed(Sender: TObject; Node: TTreeNode);
552     procedure MessageListViewResize(Sender: TObject);
553     procedure ExitActionExecute(Sender: TObject);
554     procedure AllSelectActionExecute(Sender: TObject);
555     procedure StdToolBarVisibleActionExecute(Sender: TObject);
556     procedure MsgBarVisibleActionExecute(Sender: TObject);
557     procedure StatusBarVisibleActionExecute(Sender: TObject);
558     procedure LargeIconActionExecute(Sender: TObject);
559     procedure SmallIconActionExecute(Sender: TObject);
560     procedure ListIconActionExecute(Sender: TObject);
561     procedure DetailIconActionExecute(Sender: TObject);
562     procedure SearchActionExecute(Sender: TObject);
563     procedure OptionActionExecute(Sender: TObject);
564     procedure GikoNaviWebPageActionExecute(Sender: TObject);
565     procedure AboutActionExecute(Sender: TObject);
566     procedure Cabinet2chActionExecute(Sender: TObject);
567     procedure CabinetHistoryActionExecute(Sender: TObject);
568     procedure CabinetVisibleActionExecute(Sender: TObject);
569     procedure AllItemActionExecute(Sender: TObject);
570     procedure LogItemActionExecute(Sender: TObject);
571     procedure NewItemActionExecute(Sender: TObject);
572     procedure SelectItemActionExecute(Sender: TObject);
573     procedure ListNumberVisibleActionExecute(Sender: TObject);
574     procedure UpFolderActionExecute(Sender: TObject);
575     procedure IconStyleExecute(Sender: TObject);
576     procedure RoundActionExecute(Sender: TObject);
577     procedure StopActionExecute(Sender: TObject);
578     procedure MsgBarCloseActionExecute(Sender: TObject);
579     procedure BrowserMaxActionExecute(Sender: TObject);
580     procedure ScrollTopActionExecute(Sender: TObject);
581     procedure ScrollLastActionExecute(Sender: TObject);
582     procedure ScrollNewActionExecute(Sender: TObject);
583     procedure ScrollKokoActionExecute(Sender: TObject);
584     procedure EditorActionExecute(Sender: TObject);
585     procedure IEActionExecute(Sender: TObject);
586     procedure ShowThreadActionExecute(Sender: TObject);
587     procedure ShowBoardActionExecute(Sender: TObject);
588     procedure URLCopyActionExecute(Sender: TObject);
589     procedure ItemReloadActionExecute(Sender: TObject);
590     procedure SelectListReloadActionExecute(Sender: TObject);
591     procedure SelectThreadReloadActionExecute(Sender: TObject);
592     procedure SelectListReloadActionUpdate(Sender: TObject);
593     procedure AllItemActionUpdate(Sender: TObject);
594     procedure LogItemActionUpdate(Sender: TObject);
595     procedure NewItemActionUpdate(Sender: TObject);
596     procedure SelectItemActionUpdate(Sender: TObject);
597     procedure UpFolderActionUpdate(Sender: TObject);
598     procedure FormResize(Sender: TObject);
599     procedure ScrollTopActionUpdate(Sender: TObject);
600     procedure ScrollLastActionUpdate(Sender: TObject);
601     procedure ScrollNewActionUpdate(Sender: TObject);
602     procedure ScrollKokoActionUpdate(Sender: TObject);
603     procedure EditorActionUpdate(Sender: TObject);
604     procedure IEActionUpdate(Sender: TObject);
605     procedure ShowThreadActionUpdate(Sender: TObject);
606     procedure ShowBoardActionUpdate(Sender: TObject);
607     procedure SelectThreadReloadActionUpdate(Sender: TObject);
608     procedure ListViewSelectItem(Sender: TObject; Item: TListItem;
609     Selected: Boolean);
610     procedure SelectTimerTimer(Sender: TObject);
611 yoffy 1.51 procedure ItemReloadActionUpdate(Sender: TObject);
612 hi_ 1.1 procedure ListViewDblClick(Sender: TObject);
613 yoffy 1.51 procedure LogDeleteActionExecute(Sender: TObject);
614 hi_ 1.1 procedure KokomadeActionExecute(Sender: TObject);
615     procedure ZenbuActionExecute(Sender: TObject);
616 yoffy 1.51 procedure KokoResActionExecute(Sender: TObject);
617 hi_ 1.1 procedure ListPopupMenuPopup(Sender: TObject);
618     procedure SelectItemURLCopyActionExecute(Sender: TObject);
619     procedure SelectItemURLCopyActionUpdate(Sender: TObject);
620     procedure AllSelectActionUpdate(Sender: TObject);
621     procedure LogDeleteActionUpdate(Sender: TObject);
622     procedure BrowserTabCloseActionExecute(Sender: TObject);
623     procedure NotSelectTabCloseActionExecute(Sender: TObject);
624     procedure TreeSelectBoradReloadExecute(Sender: TObject);
625     procedure TreeSelectThreadReloadExecute(Sender: TObject);
626     procedure TreeSelectURLCopyExecute(Sender: TObject);
627     procedure TreePopupMenuPopup(Sender: TObject);
628     procedure ListToolBarVisibleActionExecute(Sender: TObject);
629     procedure BrowserToolBarVisibleActionExecute(Sender: TObject);
630     procedure BrowserNewWindow2(Sender: TObject; var ppDisp: IDispatch;
631     var Cancel: WordBool);
632     procedure ListSplitterCanResize(Sender: TObject; var NewSize: Integer;
633     var Accept: Boolean);
634     procedure ListSplitterMoved(Sender: TObject);
635     procedure BrowserTabChange(Sender: TObject);
636     procedure BrowserTabMouseDown(Sender: TObject; Button: TMouseButton;
637     Shift: TShiftState; X, Y: Integer);
638     procedure BrowserTabDragOver(Sender, Source: TObject; X, Y: Integer;
639     State: TDragState; var Accept: Boolean);
640     procedure BrowserTabDragDrop(Sender, Source: TObject; X, Y: Integer);
641     procedure BrowserTabMouseMove(Sender: TObject; Shift: TShiftState; X,
642     Y: Integer);
643     procedure BrowserDocumentComplete(Sender: TObject;
644     const pDisp: IDispatch; var URL: OleVariant);
645     procedure SelectReservActionUpdate(Sender: TObject);
646     procedure RoundNamePopupMenuPopup(Sender: TObject);
647     procedure SelectNewRoundNameExecute(Sender: TObject);
648     procedure SelectDeleteRoundExecute(Sender: TObject);
649     procedure SelectReservActionExecute(Sender: TObject);
650     procedure NewBoardActionExecute(Sender: TObject);
651     procedure LoginActionExecute(Sender: TObject);
652     procedure KeySettingActionExecute(Sender: TObject);
653     procedure AllTabCloseActionExecute(Sender: TObject);
654 yoffy 1.51 procedure ArrangeActionExecute(Sender: TObject);
655     procedure NameURLCopyActionExecute(Sender: TObject);
656     procedure SelectItemNameURLCopyActionExecute(Sender: TObject);
657 hi_ 1.1 procedure URLCopyActionUpdate(Sender: TObject);
658 yoffy 1.2 procedure NameURLCopyActionUpdate(Sender: TObject);
659 hi_ 1.1 procedure BrowserTabCloseActionUpdate(Sender: TObject);
660 yoffy 1.51 procedure NotSelectTabCloseActionUpdate(Sender: TObject);
661 hi_ 1.1 procedure AllTabCloseActionUpdate(Sender: TObject);
662     procedure SelectItemNameURLCopyActionUpdate(Sender: TObject);
663     procedure ActiveLogDeleteActionExecute(Sender: TObject);
664     procedure ActiveLogDeleteActionUpdate(Sender: TObject);
665 yoffy 1.51 procedure ListNameBarVisibleActionExecute(Sender: TObject);
666 hi_ 1.1 procedure BrowserNameBarVisibleActionExecute(Sender: TObject);
667 yoffy 1.51 procedure TreeSelectNameURLCopyExecute(Sender: TObject);
668     procedure PaneInitActionExecute(Sender: TObject);
669 hi_ 1.1 procedure FormShow(Sender: TObject);
670     procedure BrowserTabToolBarResize(Sender: TObject);
671     procedure BrowserMinActionExecute(Sender: TObject);
672 yoffy 1.51 procedure SelectTextClearActionExecute(Sender: TObject);
673 hi_ 1.1 procedure NameTextClearActionExecute(Sender: TObject);
674 yoffy 1.51 procedure MailTextClearActionExecute(Sender: TObject);
675     procedure LeftmostTabSelectActionExecute(Sender: TObject);
676     procedure LeftTabSelectActionExecute(Sender: TObject);
677 hi_ 1.1 procedure RightTabSelectActionExecute(Sender: TObject);
678     procedure RightmostTabSelectActionExecute(Sender: TObject);
679     procedure LeftmostTabSelectActionUpdate(Sender: TObject);
680     procedure LeftTabSelectActionUpdate(Sender: TObject);
681     procedure RightTabSelectActionUpdate(Sender: TObject);
682     procedure RightmostTabSelectActionUpdate(Sender: TObject);
683     procedure FavoriteMenuClick(Sender: TObject);
684     procedure FavoriteAddActionExecute(Sender: TObject);
685     procedure FavoriteAddActionUpdate(Sender: TObject);
686     procedure BoardFavoriteAddActionExecute(Sender: TObject);
687     procedure BoardFavoriteAddActionUpdate(Sender: TObject);
688 yoffy 1.51 procedure ThreadFavoriteAddActionExecute(Sender: TObject);
689 hi_ 1.1 procedure ThreadFavoriteAddActionUpdate(Sender: TObject);
690 yoffy 1.51 procedure TreeSelectFavoriteAddActionExecute(Sender: TObject);
691 yoffy 1.2 procedure FavoriteArrangeActionExecute(Sender: TObject);
692     procedure MainCoolBarResize(Sender: TObject);
693 hi_ 1.1 procedure MoveToActionExecute(Sender: TObject);
694 yoffy 1.2 procedure AddressToolBarResize(Sender: TObject);
695 hi_ 1.1 procedure AddressComboBoxKeyDown(Sender: TObject; var Key: Word;
696     Shift: TShiftState);
697 yoffy 1.51 procedure AddressBarVisibleActionExecute(Sender: TObject);
698 yoffy 1.2 procedure BrowserEnter(Sender: TObject);
699 hi_ 1.1 procedure FormShortCut(var Msg: TWMKey; var Handled: Boolean);
700 yoffy 1.51 procedure BrowserTabVisibleActionExecute(Sender: TObject);
701     procedure BrowserTabTopActionExecute(Sender: TObject);
702     procedure BrowserTabBottomActionExecute(Sender: TObject);
703     procedure BrowserTabTabStyleActionExecute(Sender: TObject);
704 hi_ 1.1 procedure BrowserTabButtonStyleActionExecute(Sender: TObject);
705 yoffy 1.51 procedure BrowserTabFlatStyleActionExecute(Sender: TObject);
706 hi_ 1.1 procedure PreviewTimerTimer(Sender: TObject);
707     procedure MessageHideButtonClick(Sender: TObject);
708     procedure MonazillaWebPageActionExecute(Sender: TObject);
709     procedure GikoHelpActionExecute(Sender: TObject);
710     procedure ToolButton18Click(Sender: TObject);
711     procedure KotehanActionExecute(Sender: TObject);
712 yoffy 1.51 procedure LinkBarVisibleActionExecute(Sender: TObject);
713     procedure BBS2chWebPageActionExecute(Sender: TObject);
714     procedure GikoFolderOpenActionExecute(Sender: TObject);
715 yoffy 1.2 procedure MainCoolBarBandInfo(Sender: TObject;
716     var BandInfo: PReBarBandInfoA);
717     procedure MainCoolBarChevronClick(Sender: TObject;
718 yoffy 1.51 RebarChevron: PNMRebarChevron);
719     procedure ListCoolBarBandInfo(Sender: TObject;
720     var BandInfo: PReBarBandInfoA);
721     procedure ListCoolBarChevronClick(Sender: TObject;
722     RebarChevron: PNMRebarChevron);
723     procedure BrowserCoolBarBandInfo(Sender: TObject;
724     var BandInfo: PReBarBandInfoA);
725 yoffy 1.2 procedure BrowserCoolBarChevronClick(Sender: TObject;
726 yoffy 1.51 RebarChevron: PNMRebarChevron);
727     procedure ListViewColumnInfo(Sender: TObject; var Column: PLVColumnA);
728     procedure ThreadEditorActionExecute(Sender: TObject);
729 yoffy 1.2 procedure ThreadEditorActionUpdate(Sender: TObject);
730 yoffy 1.51 procedure ToolBarSettingActionExecute(Sender: TObject);
731     procedure NameCopyActionExecute(Sender: TObject);
732     procedure BoardIEActionExecute(Sender: TObject);
733     procedure SelectItemNameCopyActionExecute(Sender: TObject);
734 yoffy 1.2 procedure SelectItemNameCopyActionUpdate(Sender: TObject);
735 yoffy 1.51 procedure BoardIEActionUpdate(Sender: TObject);
736     procedure FormMouseWheel(Sender: TObject; Shift: TShiftState;
737     WheelDelta: Integer; MousePos: TPoint; var Handled: Boolean);
738     procedure NameCopyActionUpdate(Sender: TObject);
739     procedure SelectComboBoxChange(Sender: TObject);
740     procedure SelectComboBoxKeyDown(Sender: TObject; var Key: Word;
741     Shift: TShiftState);
742     procedure SelectComboBoxExit(Sender: TObject);
743     procedure NG1Click(Sender: TObject);
744     procedure SelectResActionExecute(Sender: TObject);
745     procedure SelectResActionUpdate(Sender: TObject);
746     procedure FormKeyDown(Sender: TObject; var Key: Word;
747     Shift: TShiftState);
748     procedure FormKeyUp(Sender: TObject; var Key: Word;
749     Shift: TShiftState);
750     procedure AllResActionExecute(Sender: TObject);
751     procedure AllResActionUpdate(Sender: TObject);
752     procedure ReloadClick(Sender: TObject);
753     procedure GoBackClick(Sender: TObject);
754     procedure GoFowardClick(Sender: TObject);
755     procedure ListCoolBarContextPopup(Sender: TObject; MousePos: TPoint;
756     var Handled: Boolean);
757     procedure BrowserCoolBarContextPopup(Sender: TObject; MousePos: TPoint;
758     var Handled: Boolean);
759     procedure MainCoolBarContextPopup(Sender: TObject; MousePos: TPoint;
760     var Handled: Boolean);
761     procedure SelectComboBoxSplitterMouseMove(Sender: TObject;
762     Shift: TShiftState; X, Y: Integer);
763     procedure SelectComboBoxSplitterMouseDown(Sender: TObject;
764     Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
765     procedure SelectComboBoxSplitterMouseUp(Sender: TObject;
766     Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
767     procedure StatusBarResize(Sender: TObject);
768     procedure IndividualAbon1Click(Sender: TObject);
769     procedure IndividualAbon2Click(Sender: TObject);
770     procedure N42Click(Sender: TObject);
771     procedure SelectComboBoxEnter(Sender: TObject);
772     procedure AntiIndividualAbonClick(Sender: TObject);
773     procedure N51Click(Sender: TObject);
774     procedure TreeSelectSearchBoardNameExecute(Sender: TObject);
775 yoffy 1.57 procedure CabinetFavoriteActionExecute(Sender: TObject);
776     procedure FavoriteTreeViewDragDrop(Sender, Source: TObject; X,
777     Y: Integer);
778 yoffy 1.71 procedure FavoriteTreeViewDragOver(Sender, Source: TObject; X, Y: Integer; State: TDragState; var Accept: Boolean);
779 yoffy 1.57 procedure FavoriteTreeViewEdited(Sender: TObject; Node: TTreeNode;
780     var S: String);
781     procedure FavoriteTreeViewKeyDown(Sender: TObject; var Key: Word;
782     Shift: TShiftState);
783     procedure FavoriteTreePopupMenuPopup(Sender: TObject);
784     procedure FavoriteTreeViewDeleteActionExecute(Sender: TObject);
785     procedure FavoriteTreeViewRenameActionExecute(Sender: TObject);
786     procedure FavoriteTreeViewNewFolderActionExecute(Sender: TObject);
787     procedure ToolButton19Click(Sender: TObject);
788 yoffy 1.61 procedure FavoriteTreeViewBrowseFolderActionExecute(Sender: TObject);
789 yoffy 1.64 procedure FavoriteTreeViewChange(Sender: TObject; Node: TTreeNode);
790 yoffy 1.65 procedure FavoriteTreeViewDblClick(Sender: TObject);
791     procedure FavoriteTreeViewLogDeleteActionExecute(Sender: TObject);
792     procedure FavoriteTreeViewReloadActionExecute(Sender: TObject);
793     procedure FavoriteTreeViewURLCopyActionExecute(Sender: TObject);
794     procedure FavoriteTreeViewNameCopyActionExecute(Sender: TObject);
795     procedure FavoriteTreeViewNameURLCopyActionExecute(Sender: TObject);
796 yoffy 1.68 procedure LinkToolBarDragDrop(Sender, Source: TObject; X, Y: Integer);
797 yoffy 1.71 procedure BrowserTabMouseUp(Sender: TObject; Button: TMouseButton;
798     Shift: TShiftState; X, Y: Integer);
799 yoffy 1.68 procedure LinkToolBarDragOver(Sender, Source: TObject; X, Y: Integer;
800     State: TDragState; var Accept: Boolean);
801 h677 1.70 procedure OnlyAHundredResExecute(Sender: TObject);
802 h677 1.78 procedure LinkToolBarClick(Sender: TObject);
803 hi_ 1.1 private
804     { Private 鐃緒申鐃緒申 }
805    
806     FSortIndex: Integer;
807     FSortOrder: Boolean;
808    
809     FEnabledCloseButton: Boolean;
810     // ThreadCreate: TThreadCreate;
811    
812     FClickNode: TTreeNode;
813     FHttpState: Boolean;
814     FHint: TResPopup;
815     FPreviewBrowser: TPreviewBrowser;
816     FPreviewURL: string;
817    
818     FBrowserSizeHeight: Integer;
819     FBrowserSizeWidth: Integer;
820    
821     // FFavorite: TFavorite;
822     FBrowserComplete: Boolean;
823     FTabHintIndex: Integer;
824     FListStyle: TViewStyle; //鐃緒申鐃?鐃?鐃?鐃?鐃?鐃緒申鐃?鐃?鐃?鐃緒申
825     FItemNoVisible: Boolean; //鐃緒申鐃?鐃?鐃緒申鐃緒申鐃?鐃緒申鐃?鐃緒申鐃?
826     FViewType: TGikoViewType; //鐃緒申鐃?鐃?鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃?鐃?鐃?
827     FActiveList: TObject;
828     FActiveContent: TThreadItem; //
829     FHistoryList: TList; //鐃?鐃?鐃?鐃緒申鐃緒申鐃?鐃?
830     FTreeType: TGikoTreeType;
831     FWorkCount: Integer;
832     FNameCookie: string;
833     FMailCookie: string;
834     // FLastRoundTime: TDateTime;
835     BrowserNullTab: TThreadItem;
836     // DoubleClickOccurred: array [TMouseButton] of Boolean;
837     FDownloadTitle: string; //鐃?鐃?鐃緒申鐃緒申鐃?鐃?鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申鐃緒申
838     FDownloadMax: Integer; //鐃?鐃?鐃緒申鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?
839     FEvent: THTMLDocumentEventSink;//鐃?鐃緒申鐃?鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申鐃?
840 h677 1.14
841 yoffy 1.51 Fkeynum : Integer; //鐃?鐃?鐃?鐃?鐃?鐃緒申鐃?鐃?鐃?鐃?鐃?鐃?鐃?鐃?
842 yoffy 1.29
843 yoffy 1.51 IsDraggingSelectComboBox : Boolean;
844     DraggingSelectComboBoxPosition : TPoint;
845 yoffy 1.29
846 yoffy 1.54 FSearchDialog: TSearchDialog;
847 yoffy 1.49
848 yoffy 1.69 FTabIsDragging: Integer;
849 yoffy 1.72 FTabMouseDownX, FTabMouseDownY: Integer;
850 yoffy 1.73 FTabMouseUpTime: TDateTime;
851 yoffy 1.71 FLinkToolButtonIsDragging: Integer;
852 yoffy 1.72 FLinkToolButtonMouseDownX, FLinkToolButtonMouseDownY: Integer;
853 yoffy 1.73 FLinkToolButtonMouseUpTime: TDateTime;
854 yoffy 1.69
855 yoffy 1.74 DropSpaceNode: TTreeNode;
856    
857 hi_ 1.1 procedure SetBoardTreeNode;
858     function SetCategoryListItem(ABBS2ch: TBBS2ch): Integer;
859     function SetBoardListItem(Category: TCategory): Integer;
860     function SetThreadListItem(Board: TBoard): Integer;
861     // function GetRoundName(index: integer): string;
862    
863     procedure DownloadEnd(Sender: TObject; Item: TDownloadItem);
864     procedure DownloadMsg(Sender: TObject; Item: TDownloadItem; Msg: string; Icon: TGikoMessageIcon);
865     procedure WorkBegin(Sender: TObject; AWorkMode: TWorkMode; const AWorkCountMax: Integer; Number: Integer);
866     procedure WorkEnd(Sender: TObject; AWorkMode: TWorkMode; Number: Integer);
867     procedure Work(Sender: TObject; AWorkMode: TWorkMode; const AWorkCount: Integer; Number: Integer);
868    
869     procedure SetActiveList(Obj: TObject);
870     procedure ListClick;
871     procedure ListDoubleClick;
872     procedure BrowserMovement(AName: string);
873     procedure SelectListItem(List: TList);
874     // procedure SetProgressValue(Number: Integer; Value: Integer; Max: Integer = -1);
875     procedure DeleteTab(ThreadItem: TThreadItem);
876     function Hook(var Message: TMessage): Boolean;
877     procedure AddRoundNameMenu(MenuItem: TMenuItem);
878     procedure SetSelectItemRound(RoundFlag: Boolean; RoundName: string);
879     procedure SetSelectRoundName(Sender: TObject);
880     function GetCoolBand(CoolBar: TCoolBar; Control: TWinControl): TCoolBand;
881    
882     procedure SetMenuFont;
883     // procedure CreateFavMenu(Folder: TFavoriteFolder);
884     procedure CreateFavMenu(Node: TTreeNode; MenuItem: TMenuItem);
885 yoffy 1.62 procedure FavoriteClick(Sender: TObject; ActiveTab: Boolean); overload;
886     procedure FavoriteClick(Sender: TObject); overload;
887 yoffy 1.71 procedure FavoriteDragOver(Sender, Source: TObject; X, Y: Integer; State: TDragState; var Accept: Boolean);
888 yoffy 1.2 procedure SelectTreeNode(Item: TObject; CallEvent: Boolean);
889 hi_ 1.1 function OnDocumentContextMenu(Sender: TObject): WordBool;
890     // function GetThreadText(sBoard: string; sThread: string; StNum, ToNum: Integer; Title, First: Boolean): string;
891     procedure SetResPopupText(sBoard: string; sThread: string; StNum, ToNum: Integer; Title, First: Boolean);
892     procedure ShowTextPopup;
893     //procedure ShowTextPopup(HintData: THintData);
894 yoffy 1.2 // procedure SetStdToolBar;
895     // function GetAction(ActionName: string): TContainedAction;
896 hi_ 1.1 procedure SetLinkBar;
897     function GetWidthAllToolButton(ToolBar: TToolBar): Integer;
898 yoffy 1.2 procedure MenuBarChevronMenu;
899     procedure LinkBarChevronMenu;
900     procedure ToolBarChevronMenu(ToolBar: TToolBar);
901 yoffy 1.51 procedure ModifySelectList;
902 yoffy 1.61 procedure FavoriteBrowseFolder( node: TTreeNode );
903 yoffy 1.72 procedure LinkToolButtonDragDrop(Sender, Source: TObject; X, Y: Integer);
904 yoffy 1.71 procedure LinkToolButtonOnMouseDown(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
905     procedure LinkToolButtonOnMouseMove(Sender: TObject; Shift: TShiftState; X, Y: Integer);
906     procedure LinkToolButtonOnMouseUp(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
907 yoffy 1.72 function TreeNodeDataFind(Node: TTreeNode; FindPointer: Pointer): TTreeNode;
908     procedure FavoriteMoveTo( SenderNode, SourceNode: TTreeNode );
909     procedure FavoriteAddTo( SenderNode: TTreeNode; Source: TObject );
910     procedure FavoriteDragDrop( SenderNode: TTreeNode; Source: TObject );
911 h677 1.77 //
912     procedure BrowserTabClick(Sender: TObject);
913 hi_ 1.1 protected
914     procedure CreateParams(var Params: TCreateParams); override;
915 yoffy 1.2 procedure WndProc(var Message: TMessage); override;
916 hi_ 1.1 procedure WMSetCursor(var Message: TWMSetCursor); message WM_SETCURSOR;
917     procedure WMSettingChange(var Message: TWMWinIniChange); message WM_SETTINGCHANGE;
918     procedure WMCopyData(var Message: TWMCopyData); message WM_COPYDATA;
919     public
920     { Public 鐃緒申鐃緒申 }
921     // FDownload: TDownload;
922     FControlThread: TThreadControl;
923 yoffy 1.48 procedure MoveToURL(URL: string);
924     procedure InsertBrowserTab(ThreadItem: TThreadItem; ActiveTab: Boolean = True);
925 hi_ 1.1 procedure ReloadBBS;
926     function GetHttpState: Boolean;
927     procedure SetEnabledCloseButton(Enabled: Boolean);
928     function GetTreeNode(Data: TObject): TTreeNode;
929     procedure AppFormDeactivate(Sender: TObject);
930     // procedure CabinetPanelVisible(PanelVisible: Boolean);
931     procedure ListViewAllSelect;
932    
933     property ListStyle: TViewStyle read FListStyle write FListStyle;
934     property ItemNoVisible: Boolean read FItemNoVisible write FItemNoVisible;
935     property ViewType: TGikoViewType read FViewType write FViewType;
936    
937     property NameCookie: string read FNameCookie write FNameCookie;
938     property MailCookie: string read FMailCookie write FMailCookie;
939    
940     procedure SetContent(ThreadItem: TThreadItem);
941     function GetActiveContent: TThreadItem;
942     function GetActiveList: TObject;
943    
944     property ActiveList: TObject read GetActiveList write SetActiveList;
945     // property LastRoundTime: TDateTime read FLastRoundTime write FLastRoundTime;
946    
947     procedure SetListViewType(AViewType: TGikoViewType); overload;
948     procedure SetListViewType(AViewType: TGikoViewType; SelectText: string; KubetsuChk: Boolean); overload;
949     procedure DownloadContent(ThreadItem: TThreadItem);
950     procedure DownloadList(Board: TBoard);
951     procedure PlaySound(SoundEventName: string);
952    
953     function AddHistory(ThreadItem: TThreadItem): Boolean;
954     procedure DeleteHistory(ThreadItem: TThreadItem);
955     procedure ClearHistory;
956     procedure Show2chTree;
957     procedure ShowHistoryTree;
958     procedure SetHistoryTreeNode;
959     // procedure SelectTreeNode(Item: TObject);
960     procedure AddMessageList(ACaption: string; AObject: TObject; Icon: TGikoMessageIcon);
961     procedure SetBrowserTabState;
962     // property Favorite: TFavorite read FFavorite write FFavorite;
963 yoffy 1.2 procedure SetToolBarPopup;
964 hi_ 1.1 published
965     property EnabledCloseButton: Boolean read FEnabledCloseButton write SetEnabledCloseButton;
966     end;
967    
968     TFavoriteMenuItem = class(TMenuItem)
969     private
970     FData : Pointer;
971     public
972     property Data: Pointer read FData write FData;
973     end;
974    
975     TLinkToolButton = class(TToolButton)
976     private
977     FData : Pointer;
978     public
979     property Data: Pointer read FData write FData;
980     end;
981    
982     var
983     GikoForm: TGikoForm;
984    
985     implementation
986    
987     uses
988     About, Option, Round, Splash, Sort, ListSelect,
989 yoffy 1.54 NewBoard;
990 hi_ 1.1
991     const
992     CAPTION_NAME: string = '鐃?鐃?鐃?鐃?';
993     BLANK_HTML: string = 'about:blank';
994 yoffy 1.51 SELECTCOMBOBOX_NAME: string = ''; // '鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申';
995     SELECTCOMBOBOX_COLOR: TColor = clWindow;
996 h677 1.79 //D&D鐃緒申鐃?
997     DandD_THRESHOLD = 5; //D&D鐃緒申鐃緒申鐃?鐃?pixcel)
998 yoffy 1.2 //鐃?鐃緒申鐃?鐃?鐃緒申鐃?鐃?鐃?鐃?鐃?鐃緒申
999     ITEM_ICON_2CH1 = 0; //2ch鐃?鐃?鐃?鐃緒申
1000     ITEM_ICON_2CH2 = 1; //2ch鐃?鐃?鐃?鐃緒申
1001     ITEM_ICON_CATEGORY1 = 2; //鐃?鐃?鐃?鐃緒申鐃?鐃?鐃?鐃緒申
1002     ITEM_ICON_CATEGORY2 = 3; //鐃?鐃?鐃?鐃緒申鐃?鐃?鐃?鐃緒申
1003     ITEM_ICON_BOARD1 = 4; //鐃緒申鐃?鐃?鐃?鐃緒申
1004     ITEM_ICON_BOARD2 = 5; //鐃緒申鐃?鐃?鐃?鐃緒申
1005     ITEM_ICON_THREADLOG1 = 6; //鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃?
1006     ITEM_ICON_THREADLOG2 = 7; //鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃?
1007     ITEM_ICON_THREAD1 = 8; //鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃?
1008     ITEM_ICON_THREAD2 = 9; //鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃?
1009     ITEM_ICON_THREADNEW1 = 10; //鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃?
1010     ITEM_ICON_THREADNEW2 = 11; //鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃?
1011     ITEM_ICON_SORT1 = 12; //鐃?鐃?鐃?鐃?鐃?鐃?鐃緒申
1012     ITEM_ICON_SORT2 = 13; //鐃?鐃?鐃?鐃?鐃?鐃?鐃緒申
1013    
1014     //鐃?鐃?鐃緒申鐃?鐃?鐃?鐃?鐃?鐃緒申
1015 yoffy 1.48 TOOL_ICON_HEIGHT_MAX = 16; //鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申
1016     TOOL_ICON_HEIGHT_MIN = 17; //鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申
1017     TOOL_ICON_HEIGHT_NORMAL = 18; //鐃緒申鐃緒申鐃?鐃緒申鐃?鐃?鐃?鐃緒申
1018     TOOL_ICON_WIDTH_MAX = 19; //鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申
1019     TOOL_ICON_WIDTH_MIN = 20; //鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申
1020     TOOL_ICON_WIDTH_NORMAL = 21; //鐃緒申鐃?鐃緒申鐃?鐃?鐃?鐃緒申
1021    
1022 yoffy 1.51 TOOL_ICON_FAV_FOLDER = 30; //鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃?鐃?鐃緒申鐃?鐃?鐃?鐃?鐃緒申
1023     TOOL_ICON_FAV_BOARD = 31; //鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申
1024     TOOL_ICON_FAV_THREAD = 32; //鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃?鐃?鐃?鐃緒申
1025 hi_ 1.1
1026     HTML_FILE_NAME = 'temp_preview.html';
1027    
1028     {$R *.DFM}
1029    
1030     procedure TGikoForm.CreateParams(var Params: TCreateParams);
1031     begin
1032     inherited;
1033     if FormStyle in [fsNormal, fsStayOnTop] then begin
1034     if BorderStyle in [bsSingle, bsSizeable] then begin
1035     Params.ExStyle := Params.ExStyle or WS_EX_APPWINDOW;
1036     Params.WndParent := 0;
1037     end;
1038     end;
1039     end;
1040    
1041     procedure TGikoForm.FormCreate(Sender: TObject);
1042     const
1043     TVS_NOTOOLTIPS = $0080;
1044     var
1045     FileName: string;
1046     Style: DWORD;
1047     msg: string;
1048     i: Integer;
1049     wp: TWindowPlacement;
1050 hi_ 1.32 s: string;
1051 hi_ 1.1 begin
1052     {$IFDEF DEBUG}
1053     AllocConsole;
1054     Writeln('============================================================');
1055     Writeln(' 鐃?鐃?鐃?鐃?鐃?鐃?鐃?鐃? 鐃?鐃緒申鐃?鐃?鐃緒申');
1056     Writeln('');
1057     Writeln(' 鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?');
1058     Writeln(' 鐃?鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃?鐃?鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申');
1059     Writeln('============================================================');
1060     {$ENDIF}
1061     Application.OnDeactivate := AppFormDeactivate;
1062     Self.OnDeactivate := AppFormDeactivate;
1063     Application.HookMainWindow(Hook);
1064    
1065     FTreeType := gttNone;
1066    
1067 yoffy 1.51 FSearchDialog := nil;
1068 yoffy 1.49
1069 hi_ 1.1 //鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申
1070     Screen.Cursors[5] := LoadCursor(HInstance, 'GIKOHAND');
1071    
1072     //鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申
1073     RoundList := TRoundList.Create;
1074     RoundList.LoadRoundFile;
1075    
1076     //BBS鐃緒申鐃緒申
1077     BBS2ch := TBBS2ch.Create(GikoSys.Setting.LogFolder);
1078    
1079     //鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1080     // FFavorite := TFavorite.Create(FavoriteTreeView);
1081     FavoriteDM.SetFavTreeView(FavoriteTreeView);
1082     FavoriteDM.ReadFavorite;
1083    
1084     //鐃?鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1085     AddressHistoryDM.ReadHistory(AddressComboBox.Items, GikoSys.Setting.AddressHistoryCount);
1086    
1087     EnabledCloseButton := True;
1088     BoardGroup.BBS2ch.ReadBoardFile; //鐃?鐃?鐃?鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申
1089     // SetBoardTreeNode; //鐃?鐃緒申鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃緒申
1090    
1091     //鐃緒申鐃?鐃?鐃?鐃?鐃?鐃緒申
1092     ListView.ViewStyle := GikoSys.Setting.ListStyle;
1093    
1094     //鐃緒申鐃?鐃緒申鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃?
1095     // MainCoolBar.Top := 0;
1096     // MainCoolBar.Left := 0;
1097    
1098     //鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申鐃?
1099     AnimePanel.Top := 0;
1100     AnimePanel.Left := 0;
1101    
1102     //鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1103    
1104     //鐃?鐃緒申鐃?鐃?鐃?鐃?
1105     CabinetVisibleAction.Checked := not GikoSys.Setting.CabinetVisible;
1106     CabinetVisibleAction.Execute;
1107     CabinetPanel.Width := GikoSys.Setting.CabinetWidth;
1108    
1109     //鐃緒申鐃?鐃?鐃?鐃?鐃?鐃?
1110     MsgBarVisibleAction.Checked := GikoSys.Setting.MessageBarVisible;
1111     MsgBarVisibleActionExecute(nil);
1112     MessagePanel.Height := GikoSys.Setting.MessegeBarHeight;
1113    
1114     //鐃?鐃?鐃?鐃?鐃?鐃?鐃?
1115     StatusBarVisibleAction.Checked := GikoSys.Setting.StatusBarVisible;
1116     StatusBarVisibleActionExecute(nil);
1117    
1118     //鐃?鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃緒申
1119     TreeView.Items.BeginUpdate;
1120 yoffy 1.67 FavoriteTreeView.Items.BeginUpdate;
1121 hi_ 1.1 ListView.Items.BeginUpdate;
1122     try
1123     TreeView.Font.Name := GikoSys.Setting.CabinetFontName;
1124     TreeView.Font.Size := GikoSys.Setting.CabinetFontSize;
1125     TreeView.Font.Color := GikoSys.Setting.CabinetFontColor;
1126     TreeView.Color := GikoSys.Setting.CabinetBackColor;
1127    
1128 yoffy 1.67 FavoriteTreeView.Font.Name := GikoSys.Setting.CabinetFontName;
1129     FavoriteTreeView.Font.Size := GikoSys.Setting.CabinetFontSize;
1130     FavoriteTreeView.Font.Color := GikoSys.Setting.CabinetFontColor;
1131     FavoriteTreeView.Color := GikoSys.Setting.CabinetBackColor;
1132    
1133 hi_ 1.1 ListView.Font.Name := GikoSys.Setting.ListFontName;
1134     ListView.Font.Size := GikoSys.Setting.ListFontSize;
1135     ListView.Font.Color := GikoSys.Setting.ListFontColor;
1136     ListView.Color := GikoSys.Setting.ListBackColor;
1137     finally
1138     TreeView.Items.EndUpdate;
1139 yoffy 1.67 FavoriteTreeView.Items.EndUpdate;
1140 hi_ 1.1 ListView.Items.EndUpdate;
1141     end;
1142     //ViewNoButton.Down := GikoSys.Setting.ListViewNo;
1143     ListNumberVisibleAction.Checked := GikoSys.Setting.ListViewNo;
1144    
1145     //鐃?鐃緒申鐃?鐃?鐃?鐃?鐃?鐃?鐃緒申鐃?
1146     BrowserTab.Font.Name := GikoSys.Setting.BrowserTabFontName;
1147     BrowserTab.Font.Size := GikoSys.Setting.BrowserTabFontSize;
1148 h677 1.77
1149 hi_ 1.1
1150     // TreeView.TopItem.Expanded := True; //鐃?鐃緒申鐃?鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申
1151     // TreeView.Selected := TreeView.Items[0]; //鐃?鐃緒申鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申
1152     SetContent(nil); //鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申鐃?鐃緒申
1153    
1154     //鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃?鐃緒申鐃緒申
1155     wp.length := sizeof(wp);
1156     wp.rcNormalPosition.Top := GikoSys.Setting.WindowTop;
1157     wp.rcNormalPosition.Left := GikoSys.Setting.WindowLeft;
1158     wp.rcNormalPosition.Bottom := GikoSys.Setting.WindowTop + GikoSys.Setting.WindowHeight;
1159     wp.rcNormalPosition.Right := GikoSys.Setting.WindowLeft + GikoSys.Setting.WindowWidth;
1160     wp.showCmd := SW_HIDE;
1161     SetWindowPlacement(Handle, @wp);
1162    
1163     // SetBounds(GikoSys.Setting.WindowLeft, GikoSys.Setting.WindowTop,
1164     // GikoSys.Setting.WindowWidth, GikoSys.Setting.WindowHeight);
1165     if GikoSys.Setting.WindowMax then
1166     WindowState := wsMaximized;
1167    
1168     //鐃?鐃?鐃?鐃?鐃緒申
1169     try
1170     FileName := GikoSys.GetAppDir + 'gikoNavi.avi';
1171     if FileExists(FileName) then
1172     Animate.FileName := FileName;
1173     except
1174     end;
1175     // AnimePanel.Height := 26;
1176     // AnimePanel.Width := 39;
1177     // AnimePanel.Top := 2;
1178     // AnimePanel.Left := Width - 48;
1179    
1180     //鐃?鐃?鐃?鐃?
1181     FNameCookie := '';
1182     FMailCookie := '';
1183    
1184     //鐃?鐃緒申鐃?鐃緒申鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1185     AllItemAction.Checked := True;
1186 yoffy 1.51 AllResAction.Checked := True;
1187 hi_ 1.1
1188     //TreeView鐃緒申鐃緒申鐃緒申鐃?鐃緒申ToolTip鐃緒申鐃緒申鐃?鐃緒申
1189     Style := GetWindowLong(TreeView.Handle, GWL_STYLE);
1190     Style := Style or TVS_NOTOOLTIPS;
1191     SetWindowLong(TreeView.Handle, GWL_STYLE, Style);
1192    
1193     // 鐃?鐃緒申鐃?鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1194     TreeView.Align := alClient;
1195 yoffy 1.57 FavoriteTreeView.Align := alClient;
1196 hi_ 1.1 FavoriteTreeView.Visible := False;
1197    
1198     //鐃?鐃緒申鐃?鐃?鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申
1199     // FBrowserSizeFlag := False;
1200     // FBrowserSizeHeight := ViewPanel.Height;
1201    
1202     FBrowserSizeHeight := GikoSys.Setting.ListHeight;
1203     FBrowserSizeWidth := GikoSys.Setting.ListWidth;
1204    
1205     ArrangeAction.Checked := not (GikoSys.Setting.ListOrientation = gloVertical);
1206     ArrangeAction.Execute;
1207    
1208     if GikoSys.Setting.ListOrientation = gloHorizontal then begin
1209     case GikoSys.Setting.ListWidthState of
1210     glsMax: begin
1211     ViewPanel.Width := 1;
1212 yoffy 1.2 BrowserMaxAction.ImageIndex := TOOL_ICON_WIDTH_NORMAL;
1213     BrowserMinAction.ImageIndex := TOOL_ICON_WIDTH_MIN;
1214 hi_ 1.1 end;
1215     glsMin: begin
1216     ViewPanel.Width := GikoSys.Setting.ListWidth;
1217 yoffy 1.2 BrowserMaxAction.ImageIndex := TOOL_ICON_WIDTH_MAX;
1218     BrowserMinAction.ImageIndex := TOOL_ICON_WIDTH_NORMAL;
1219 hi_ 1.1 end;
1220     else begin
1221     ViewPanel.Width := GikoSys.Setting.ListWidth;
1222 yoffy 1.2 BrowserMaxAction.ImageIndex := TOOL_ICON_WIDTH_MAX;
1223     BrowserMinAction.ImageIndex := TOOL_ICON_WIDTH_MIN;
1224 hi_ 1.1 end;
1225     end;
1226     // if GikoSys.Setting.ListWidthMax then begin
1227     // ViewPanel.Width := 1;
1228     // BrowserSizeAction.ImageIndex := ICON_WIDTH_MIN;
1229     // end else begin
1230     // ViewPanel.Width := GikoSys.Setting.ListWidth;
1231     // BrowserSizeAction.ImageIndex := ICON_WIDTH_MAX;
1232     // end;
1233     end else begin
1234     case GikoSys.Setting.ListHeightState of
1235     glsMax: begin
1236     ViewPanel.Height := 1;
1237 yoffy 1.2 BrowserMaxAction.ImageIndex := TOOL_ICON_HEIGHT_NORMAL;
1238     BrowserMinAction.ImageIndex := TOOL_ICON_HEIGHT_MIN;
1239 hi_ 1.1 end;
1240     glsMin: begin
1241     ViewPanel.Height := GikoSys.Setting.ListHeight;
1242 yoffy 1.2 BrowserMaxAction.ImageIndex := TOOL_ICON_HEIGHT_MAX;
1243     BrowserMinAction.ImageIndex := TOOL_ICON_HEIGHT_NORMAL;
1244 hi_ 1.1 end;
1245     else begin
1246     ViewPanel.Height := GikoSys.Setting.ListHeight;
1247 yoffy 1.2 BrowserMaxAction.ImageIndex := TOOL_ICON_HEIGHT_MAX;
1248     BrowserMinAction.ImageIndex := TOOL_ICON_HEIGHT_MIN;
1249 hi_ 1.1 end;
1250     end;
1251     // if GikoSys.Setting.ListHeightState = glsMax then begin
1252     // end else begin
1253     // ViewPanel.Height := GikoSys.Setting.ListHeight;
1254     // BrowserSizeAction.ImageIndex := ICON_HEIGHT_MAX;
1255     // end;
1256     end;
1257    
1258     //鐃?鐃緒申鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申
1259     // ProgressBar.Visible := False;
1260     ProgressBar.Parent := StatusBar;
1261     ProgressBar.Top := 2;
1262     ProgressBar.Left := 0;
1263     ProgressBar.Width := StatusBar.Panels[0].Width;
1264     ProgressBar.Height := StatusBar.Height - 2;
1265     ProgressBar.Position := 0;
1266    
1267     //鐃?鐃?鐃緒申鐃?鐃?鐃?鐃緒申
1268     //formshow()鐃緒申鐃緒申鐃緒申
1269 yoffy 1.2
1270 hi_ 1.1 //鐃?鐃?鐃緒申鐃緒申鐃?鐃?鐃?鐃?鐃?鐃?鐃?鐃?
1271     // FDownload := TDownload.Create;
1272     // FDownload.OnDownloadEnd := OnDonloadEnd;
1273     // FDownload.OnWork := Work;
1274     // FDownload.OnWorkBegin := WorkBegin;
1275     // FDownload.OnWorkEnd := WorkEnd;
1276    
1277     //鐃?鐃?鐃緒申鐃緒申鐃?鐃?鐃?鐃?鐃?鐃?鐃?鐃?
1278     FControlThread := TThreadControl.Create(True);
1279     FControlThread.MaxThreadCount := 1;
1280     FControlThread.Resume;
1281     FControlThread.OnDownloadEnd := DownloadEnd;
1282     FControlThread.OnDownloadMsg := DownloadMsg;
1283     FControlThread.OnWork := Work;
1284     FControlThread.OnWorkBegin := WorkBegin;
1285     FControlThread.OnWorkEnd := WorkEnd;
1286     // ProgressPanel.Width := FControlThread.MaxThreadCount * 12;
1287    
1288     //鐃?鐃?鐃?鐃緒申鐃緒申鐃?鐃?
1289     FHistoryList := TList.Create;
1290    
1291 yoffy 1.51 // 鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1292     SelectComboBox.Items.Assign( GikoSys.Setting.SelectTextList );
1293 yoffy 1.2
1294 hi_ 1.1 //鐃?鐃緒申鐃?鐃?鐃?鐃?鐃緒申鐃緒申
1295     SetBrowserTabState;
1296    
1297     BrowserBoardNameLabel.Caption := '';
1298     BrowserNameLabel.Caption := '';
1299     FWorkCount := 0;
1300    
1301     // DetailIconAction.Execute;
1302    
1303     // FBrowserSizeHeight := ViewPanel.Height;
1304     FTabHintIndex := -1;
1305    
1306     //鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1307     // if not GikoSys.DirectoryExistsEx(BBS2ch.GetLogFolder) then begin
1308     // GikoSys.ForceDirectoriesEx(BBS2ch.GetLogFolder);
1309     // end;
1310     // FormResize(Sender);
1311     // MainCoolBarResize(Sender);
1312     // Application.ProcessMessages;
1313    
1314     //鐃緒申鐃緒申鐃?鐃?鐃?
1315     SetLinkBar;
1316    
1317     //鐃緒申鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?
1318     SetMenuFont;
1319    
1320     //鐃?鐃?鐃緒申鐃?鐃?Wrapable
1321     ListToolBar.Wrapable := GikoSys.Setting.ListToolBarWrapable;
1322     BrowserToolBar.Wrapable := GikoSys.Setting.BrowserToolBarWrapable;
1323    
1324 yoffy 1.2 //鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1325     ReadToolBarSetting(ActionList, StdToolBar);
1326     ReadToolBarSetting(ActionList, ListToolBar);
1327 yoffy 1.51 try
1328     for i := ListToolBar.ControlCount - 1 downto 0 do
1329     begin
1330     if ListToolBar.Controls[ i ].Action = SelectItemAction then
1331     begin
1332     // 鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申
1333     if (i + 1) < ListToolBar.ControlCount then
1334     if ListToolBar.Controls[ i + 1 ] is TToolButton then
1335     if TToolButton( ListToolBar.Controls[ i + 1 ] ).Style = tbsSeparator then
1336     ListToolBar.Controls[ i + 1 ].Visible := False;
1337    
1338     // 鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申鐃?鐃緒申
1339     ListToolBar.Controls[ i ].Visible := False;
1340     // 鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃?鐃緒申
1341     SelectComboBox.Left := ListToolBar.Controls[ i ].Left;
1342     SelectComboBox.Width := GikoSys.Setting.SelectComboBoxWidth;
1343     SelectComboBox.Parent := ListToolBar;
1344     // 鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃緒申鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃?鐃緒申
1345     SelectComboBoxSplitter.Left := SelectComboBox.Left + SelectComboBox.Width;
1346     SelectComboBoxSplitter.Parent := ListToolBar;
1347    
1348     break;
1349     end;
1350     end;
1351     except
1352     end;
1353 yoffy 1.2 ReadToolBarSetting(ActionList, BrowserToolBar);
1354     SetToolBarPopup;
1355    
1356 hi_ 1.1 //鐃?鐃?鐃緒申鐃?鐃?鐃?
1357     AddressComboBox.TabStop := GikoSys.Setting.AddressBarTabStop;
1358    
1359 yoffy 1.2 //鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申FormShow鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1360    
1361     //鐃?鐃?鐃?鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃?鐃?鐃緒申
1362     if not FileExists(GikoSys.GetBoardFileName) then begin
1363     msg := '鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃?鐃緒申鐃?鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申' + #13#10#13#10
1364     + '鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃?鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃?鐃?鐃緒申鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申' + #13#10
1365     + '鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃?鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?';
1366     MsgBox(SplashWindow.Handle, msg, '鐃?鐃?鐃?鐃?', MB_OK or MB_ICONINFORMATION);
1367     NewBoardAction.Execute;
1368     end;
1369    
1370     //鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1371     GikoSys.LoadKeySetting(ActionList);
1372    
1373     //鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申
1374     // FLastRoundTime := 0;
1375    
1376     //ResHint
1377     FHint := TResPopup.Create(Self);
1378    
1379 yoffy 1.67 // 鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃?鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申
1380     Case GikoSys.Setting.CabinetIndex of
1381     0: Cabinet2chAction.Execute;
1382     1: CabinetHistoryAction.Execute;
1383     2: CabinetFavoriteAction.Execute;
1384     end;
1385    
1386 yoffy 1.2 //鐃?鐃?鐃?鐃緒申鐃?鐃?鐃緒申
1387     if GikoSys.Setting.AutoLogin then
1388     LoginAction.Execute;
1389    
1390     //鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃緒申鐃緒申鐃?鐃?鐃?
1391     for i := 1 to ParamCount do begin
1392     MoveToURL(ParamStr(i));
1393     end;
1394     // SetStdToolBar;
1395     // SetLinkBar;
1396 h677 1.22
1397 hi_ 1.32 s := GikoSys.FAbon.NGwordname;
1398     StatusBar.Panels[2].Text := s;
1399     StatusBar.Panels[2].Width := Max(StatusBar.Canvas.TextWidth(s), 100);
1400     StatusBarResize(Sender);
1401 yoffy 1.2 end;
1402    
1403     //
1404     //
1405     //
1406     procedure TGikoForm.FormShow(Sender: TObject);
1407     var
1408     i: Integer;
1409     CoolSet: TCoolSet;
1410     begin
1411     ShowWindow(Application.Handle, SW_HIDE);
1412    
1413     //FormCreate鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申FormShow鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1414     //鐃?鐃?鐃緒申鐃?鐃?鐃?鐃緒申
1415     StdToolBarVisibleAction.Checked := GikoSys.Setting.StdToolBarVisible;
1416     StdToolBarVisibleActionExecute( nil );
1417     AddressBarVisibleAction.Checked := GikoSys.Setting.AddressBarVisible;
1418     AddressBarVisibleActionExecute( nil );
1419     LinkBarVisibleAction.Checked := GikoSys.Setting.LinkBarVisible;
1420     LinkBarVisibleActionExecute( nil );
1421     ListToolBarVisibleAction.Checked := GikoSys.Setting.ListToolBarVisible;
1422     ListToolBarVisibleActionExecute( nil );
1423     ListNameBarVisibleAction.Checked := GikoSys.Setting.ListNameBarVisible;
1424     ListNameBarVisibleActionExecute( nil );
1425     BrowserToolBarVisibleAction.Checked := GikoSys.Setting.BrowserToolBarVisible;
1426     BrowserToolBarVisibleActionExecute( nil );
1427     BrowserNameBarVisibleAction.Checked := GikoSys.Setting.BrowserNameBarVisible;
1428     BrowserNameBarVisibleActionExecute( nil );
1429    
1430     //鐃?鐃緒申鐃?鐃?鐃?鐃?
1431     BrowserTabVisibleAction.Checked := GikoSys.Setting.BrowserTabVisible;
1432     BrowserTabVisibleActionExecute(nil);
1433    
1434     if GikoSys.Setting.BrowserTabPosition = gtpTop then begin
1435     BrowserTabTopAction.Checked := True;
1436     BrowserTabTopActionExecute(nil);
1437     end else begin
1438     BrowserTabBottomAction.Checked := True;
1439     BrowserTabBottomActionExecute(nil);
1440     end;
1441    
1442     if GikoSys.Setting.BrowserTabStyle = gtsTab then begin
1443     BrowserTabTabStyleAction.Checked := True;
1444     BrowserTabTabStyleActionExecute(nil);
1445     end else if GikoSys.Setting.BrowserTabStyle = gtsButton then begin
1446     BrowserTabButtonStyleAction.Checked := True;
1447     BrowserTabButtonStyleActionExecute(nil);
1448     end else begin
1449     BrowserTabFlatStyleAction.Checked := True;
1450     BrowserTabFlatStyleActionExecute(nil);
1451     end;
1452    
1453    
1454 hi_ 1.1 //鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申(Main)
1455     MainCoolBar.Bands.BeginUpdate;
1456     try
1457     for i := 0 to MainCoolBar.Bands.Count - 1 do begin
1458     CoolSet := GikoSys.Setting.MainCoolSet[i];
1459     if (CoolSet.FCoolID = -1) or (CoolSet.FCoolWidth = -1) then
1460     Continue;
1461     MainCoolBar.Bands.FindItemID(CoolSet.FCoolID).Index := i;
1462     MainCoolBar.Bands[i].Break := CoolSet.FCoolBreak;
1463     MainCoolBar.Bands[i].Width := CoolSet.FCoolWidth;
1464     end;
1465     finally
1466     MainCoolBar.Bands.EndUpdate;
1467     end;
1468    
1469     //鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申(Board)
1470     ListCoolBar.Bands.BeginUpdate;
1471     try
1472     for i := 0 to ListCoolBar.Bands.Count - 1 do begin
1473     CoolSet := GikoSys.Setting.ListCoolSet[i];
1474     if (CoolSet.FCoolID = -1) or (CoolSet.FCoolWidth = -1) then
1475     Continue;
1476     ListCoolBar.Bands.FindItemID(CoolSet.FCoolID).Index := i;
1477     ListCoolBar.Bands[i].Break := CoolSet.FCoolBreak;
1478     ListCoolBar.Bands[i].Width := CoolSet.FCoolWidth;
1479     end;
1480     finally
1481     ListCoolBar.Bands.EndUpdate;
1482     end;
1483    
1484     //鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申(Browser)
1485     BrowserCoolBar.Bands.BeginUpdate;
1486     try
1487     for i := 0 to BrowserCoolBar.Bands.Count - 1 do begin
1488     CoolSet := GikoSys.Setting.BrowserCoolSet[i];
1489     if (CoolSet.FCoolID = -1) or (CoolSet.FCoolWidth = -1) then
1490     Continue;
1491     BrowserCoolBar.Bands.FindItemID(CoolSet.FCoolID).Index := i;
1492     BrowserCoolBar.Bands[i].Break := CoolSet.FCoolBreak;
1493     BrowserCoolBar.Bands[i].Width := CoolSet.FCoolWidth;
1494     end;
1495     finally
1496     BrowserCoolBar.Bands.EndUpdate;
1497     end;
1498    
1499     end;
1500 yoffy 1.2 {
1501 hi_ 1.1 procedure TGikoForm.SetStdToolBar;
1502     var
1503     i: Integer;
1504     FileName: string;
1505     ini: TMemIniFile;
1506     s: string;
1507     Action: TContainedAction;
1508     ToolButton: TToolButton;
1509     begin
1510     exit;
1511     for i := StdToolBar.ButtonCount - 1 downto 0 do begin
1512     StdToolBar.RemoveControl(StdToolBar.Buttons[i]);
1513     //StdToolBar.Buttons[i].Free;
1514     end;
1515     FileName := GikoSys.GetConfigDir + 'ToolBar.ini';
1516     ini := TMemIniFile.Create(FileName);
1517     i := 0;
1518     while true do begin
1519     s := ini.ReadString('StdToolBar', IntToStr(i), '');
1520     if s = '' then
1521     Break;
1522     if s = '-' then begin
1523     ToolButton := TToolButton.Create(StdToolBar);
1524     ToolButton.Style := tbsSeparator;
1525     ToolButton.Width := 8;
1526     ToolButton.Left := 10000;
1527     StdToolBar.InsertControl(ToolButton);
1528     end else begin
1529     Action := GetAction(s);
1530     if Action <> nil then begin
1531     ToolButton := TToolButton.Create(StdToolBar);
1532     ToolButton.Action := Action;
1533     ToolButton.Left := 10000;
1534     StdToolBar.InsertControl(ToolButton);
1535     end;
1536     end;
1537     Inc(i);
1538     end;
1539     end;
1540 yoffy 1.2 }
1541     {function TGikoForm.GetAction(ActionName: string): TContainedAction;
1542 hi_ 1.1 var
1543     i: Integer;
1544     begin
1545     for i := 0 to ActionList.ActionCount - 1 do begin
1546     if ActionList.Actions[i].Name = ActionName then begin
1547     Result := ActionList.Actions[i];
1548     Exit;
1549     end;
1550     end;
1551     Result := nil;
1552 yoffy 1.2 end;}
1553 hi_ 1.1
1554     procedure TGikoForm.FormCloseQuery(Sender: TObject; var CanClose: Boolean);
1555     var
1556     i: Integer;
1557     CoolSet: TCoolSet;
1558     wp: TWindowPlacement;
1559     begin
1560 yoffy 1.2 // if not EnabledCloseButton then begin
1561     // CanClose := False;
1562     // Exit;
1563     // end;
1564    
1565 hi_ 1.1 CanClose := True;
1566     Application.OnDeactivate := nil;
1567     Self.OnDeactivate := nil;
1568    
1569 yoffy 1.2 //column鐃緒申
1570     if GetActiveList is TBBS2ch then begin
1571     for i := 0 to ListView.Columns.Count - 1 do
1572     GikoSys.Setting.BBSColumnWidth[i] := ListView.Column[i].Width;
1573     end else if GetActiveList is TCategory then begin
1574     for i := 0 to ListView.Columns.Count - 1 do
1575     GikoSys.Setting.CategoryColumnWidth[i] := ListView.Column[i].Width;
1576     end else if GetActiveList is TBoard then begin
1577     for i := 0 to ListView.Columns.Count - 1 do
1578     GikoSys.Setting.BoardColumnWidth[i] := ListView.Column[i].Width;
1579     end;
1580    
1581     //鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃?鐃緒申鐃緒申
1582     wp.length := sizeof(wp);
1583     GetWindowPlacement(Handle, @wp);
1584     GikoSys.Setting.WindowTop := wp.rcNormalPosition.Top;
1585     GikoSys.Setting.WindowLeft := wp.rcNormalPosition.Left;
1586     GikoSys.Setting.WindowHeight := wp.rcNormalPosition.Bottom - wp.rcNormalPosition.Top;
1587     GikoSys.Setting.WindowWidth := wp.rcNormalPosition.Right - wp.rcNormalPosition.Left;
1588     GikoSys.Setting.WindowMax := WindowState = wsMaximized;
1589    
1590     GikoSys.Setting.ListStyle := ListView.ViewStyle;
1591     GikoSys.Setting.CabinetVisible := CabinetVisibleAction.Checked;
1592     GikoSys.Setting.CabinetWidth := CabinetPanel.Width;
1593     GikoSys.Setting.ListHeight := FBrowserSizeHeight;
1594     GikoSys.Setting.ListWidth := FBrowserSizeWidth;
1595     if ArrangeAction.Checked then
1596     GikoSys.Setting.ListOrientation := gloVertical
1597     else
1598     GikoSys.Setting.ListOrientation := gloHorizontal;
1599     GikoSys.Setting.MessegeBarHeight := MessagePanel.Height;
1600    
1601     //鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申(Main)
1602     for i := 0 to MAIN_COOLBAND_COUNT - 1 do begin
1603     CoolSet.FCoolID := MainCoolBar.Bands[i].ID;
1604     CoolSet.FCoolWidth := MainCoolBar.Bands[i].Width;
1605     CoolSet.FCoolBreak := MainCoolBar.Bands[i].Break;
1606     GikoSys.Setting.MainCoolSet[i] := CoolSet;
1607     end;
1608     //鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申(Board)
1609     for i := 0 to LIST_COOLBAND_COUNT - 1 do begin
1610     CoolSet.FCoolID := ListCoolBar.Bands[i].ID;
1611     CoolSet.FCoolWidth := ListCoolBar.Bands[i].Width;
1612     CoolSet.FCoolBreak := ListCoolBar.Bands[i].Break;
1613     GikoSys.Setting.ListCoolSet[i] := CoolSet;
1614     end;
1615     //鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申(Browser)
1616     for i := 0 to BROWSER_COOLBAND_COUNT - 1 do begin
1617     CoolSet.FCoolID := BrowserCoolBar.Bands[i].ID;
1618     CoolSet.FCoolWidth := BrowserCoolBar.Bands[i].Width;
1619     CoolSet.FCoolBreak := BrowserCoolBar.Bands[i].Break;
1620     GikoSys.Setting.BrowserCoolSet[i] := CoolSet;
1621 hi_ 1.1 end;
1622    
1623 yoffy 1.2 GikoSys.Setting.WriteWindowSettingFile;
1624     GikoSys.Setting.WriteNameMailSettingFile;
1625    
1626     //鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1627 hi_ 1.1 try
1628 yoffy 1.2 FavoriteDM.WriteFavorite;
1629 hi_ 1.1 except
1630     end;
1631 yoffy 1.2 // Favorite.Free;
1632 hi_ 1.1
1633     try
1634     //鐃?鐃?鐃?鐃緒申鐃?鐃?
1635     NotSelectTabCloseAction.Execute;
1636     if BrowserTab.Tabs.Count >= 1 then begin
1637     DeleteTab(TThreadItem(BrowserTab.Tabs.Objects[0]));
1638     end;
1639     except
1640     end;
1641    
1642     //鐃緒申鐃緒申鐃緒申鐃?鐃?鐃緒申鐃緒申&鐃?鐃緒申
1643     try
1644     RoundList.SaveRoundFile;
1645     except
1646     end;
1647     try
1648     RoundList.Clear;
1649     except
1650     end;
1651     try
1652     RoundList.Free;
1653     except
1654     end;
1655    
1656     //鐃?鐃?鐃?鐃緒申鐃緒申鐃?鐃?
1657     try
1658     FHistoryList.Free;
1659     except
1660     end;
1661    
1662     //鐃?鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申
1663     try
1664     AddressHistoryDM.WriteHistory(AddressComboBox.Items, GikoSys.Setting.AddressHistoryCount);
1665     except
1666     end;
1667    
1668     try
1669     FControlThread.Terminate;
1670     except
1671     end;
1672    
1673     // FDownload.Free;
1674     try
1675     SetActiveList(nil);
1676     except
1677     end;
1678     //TreeView鐃?鐃緒申鐃?鐃?BBS2ch.Free鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申XP鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃?鐃?鐃緒申鐃?
1679     Sleep(10);
1680     try
1681     TreeView.Items.Clear;
1682     except
1683     end;
1684    
1685     try
1686     if FavoriteDM <> nil then
1687     FavoriteDM.Free;
1688     FavoriteDM := nil;
1689     if AddressHistoryDM <> nil then
1690     AddressHistoryDM.Free;
1691     AddressHistoryDM := nil;
1692     except
1693     end;
1694     try
1695     if BBS2ch <> nil then
1696     BBS2ch.Free;
1697     BBS2ch := nil;
1698     except
1699     end;
1700 yoffy 1.2
1701     try
1702     //Hint鐃?鐃緒申
1703     if FHint <> nil then begin
1704     FHint.ReleaseHandle;
1705     FHint.Free;
1706     FHint := nil;
1707     end;
1708     //Preview鐃?鐃緒申
1709     if TPreviewBrowser <> nil then begin
1710     FPreviewBrowser.Free;
1711     FPreviewBrowser := nil;
1712     end;
1713     except
1714     end;
1715 hi_ 1.1 end;
1716    
1717     procedure TGikoForm.FormDestroy(Sender: TObject);
1718     //var
1719     // wp: TWindowPlacement;
1720     begin
1721     { //鐃?鐃?鐃?鐃緒申鐃緒申鐃?鐃?
1722     FHistoryList.Free;
1723    
1724     //鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃?鐃緒申鐃緒申
1725     wp.length := sizeof(wp);
1726     GetWindowPlacement(Handle, @wp);
1727    
1728     GikoSys.Setting.WindowTop := wp.rcNormalPosition.Top;
1729     GikoSys.Setting.WindowLeft := wp.rcNormalPosition.Left;
1730     GikoSys.Setting.WindowHeight := wp.rcNormalPosition.Bottom - wp.rcNormalPosition.Top;
1731     GikoSys.Setting.WindowWidth := wp.rcNormalPosition.Right - wp.rcNormalPosition.Left;
1732     GikoSys.Setting.WindowMax := WindowState = wsMaximized;
1733    
1734     GikoSys.Setting.CabinetVisible := CabinetPanel.Visible;
1735     GikoSys.Setting.CabinetWidth := CabinetPanel.Width;
1736    
1737     GikoSys.Setting.WriteWindowSettingFile;
1738     GikoSys.Setting.WriteNameMailSettingFile;
1739     FDownload.Free;
1740     BBS2ch.Free;}
1741     end;
1742    
1743     //鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃?鐃?
1744     procedure TGikoForm.FormClose(Sender: TObject; var Action: TCloseAction);
1745     begin
1746     Application.Terminate;
1747     Action := caFree;
1748     end;
1749    
1750     //鐃?鐃緒申鐃?鐃?鐃?鐃?鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃?鐃?
1751     procedure TGikoForm.CabinetPanelHide(Sender: TObject);
1752     begin
1753     CabinetVisibleAction.Execute;
1754     // CabinetPanelVisible(false);
1755     end;
1756    
1757     procedure TGikoForm.ReloadBBS;
1758     begin
1759     //鐃?鐃?鐃?鐃緒申鐃?鐃?
1760     NotSelectTabCloseAction.Execute;
1761     if BrowserTab.Tabs.Count >= 1 then
1762     DeleteTab(TThreadItem(BrowserTab.Tabs.Objects[0]));
1763     //鐃?鐃?鐃?鐃緒申鐃緒申鐃?鐃?
1764     FHistoryList.Clear;
1765     //TreeView鐃?鐃緒申鐃?鐃?BBS2ch.Free鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申XP鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃?鐃?鐃緒申鐃?
1766     TreeView.Items.Clear;
1767    
1768     //BBS鐃?鐃緒申
1769     BBS2ch.Free;
1770    
1771     SetActiveList(nil);
1772    
1773     FTreeType := gttNone;
1774    
1775     //BBS鐃緒申鐃緒申
1776     BBS2ch := TBBS2ch.Create(GikoSys.Setting.LogFolder);
1777    
1778     BBS2ch.ReadBoardFile; //鐃?鐃?鐃?鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申
1779     Show2chTree;
1780     end;
1781    
1782     //鐃?鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃緒申
1783     procedure TGikoForm.SetBoardTreeNode;
1784     var
1785     i, j: integer;
1786     Root: TTreeNode;
1787     CategoryNode: TTreeNode;
1788     BoardNode: TTreeNode;
1789     Category: TCategory;
1790     Board: TBoard;
1791     begin
1792     TreeView.Items.BeginUpdate;
1793     TreeView.Items.Clear;
1794     try
1795     Root := TreeView.Items.Add(nil, BBS2ch.Title);
1796 yoffy 1.2 Root.ImageIndex := ITEM_ICON_2CH1;
1797     Root.SelectedIndex := ITEM_ICON_2CH2;
1798 hi_ 1.1 Root.Data := BBS2ch;
1799     if SplashWindow <> nil then
1800     SplashWindow.ProgressBar.Max := BoardGroup.BBS2ch.Count;
1801    
1802     for i := 0 to BoardGroup.BBS2ch.Count - 1 do begin
1803     Category := TCategory(BoardGroup.BBS2ch.Items[i]);
1804     CategoryNode := TreeView.Items.AddChild(Root, Category.Title);
1805     CategoryNode.Data := Category;
1806 yoffy 1.2 CategoryNode.ImageIndex := ITEM_ICON_CATEGORY1;
1807     CategoryNode.SelectedIndex := ITEM_ICON_CATEGORY2;
1808 hi_ 1.1
1809     for j := 0 to Category.Count - 1 do begin
1810     Board := TBoard(Category.Items[j]);
1811     Board.BeginUpdate;
1812     BoardNode := TreeView.Items.AddChild(CategoryNode, Board.Title);
1813     BoardNode.Data := Board;
1814 yoffy 1.2 BoardNode.ImageIndex := ITEM_ICON_BOARD1;
1815     BoardNode.SelectedIndex := ITEM_ICON_BOARD2;
1816 hi_ 1.1 Board.LoadSettings;
1817     Board.EndUpdate;
1818     end;
1819    
1820     CategoryNode.Expanded := Category.NodeExpand;
1821    
1822     if SplashWindow <> nil then begin
1823     SplashWindow.ProgressBar.StepIt;
1824     Application.ProcessMessages;
1825     end;
1826    
1827     end;
1828     finally
1829     TreeView.Items.EndUpdate;
1830     end;
1831     end;
1832    
1833     function TGikoForm.SetCategoryListItem(ABBS2ch: TBBS2ch): Integer;
1834     const
1835     COLUMN: array[0..0] of string = ('鐃?鐃?鐃?鐃緒申鐃緒申');
1836     var
1837     ListColumn: TListColumn;
1838     i: Integer;
1839     begin
1840     ListView.Items.BeginUpdate;
1841     try
1842     Screen.Cursor := crHourGlass;
1843    
1844     ListView.Columns.Clear;
1845     for i := 0 to Length(COLUMN) - 1 do begin
1846     ListColumn := ListView.Columns.Add;
1847     ListColumn.Caption := COLUMN[i];
1848     ListColumn.Width := GikoSys.Setting.BBSColumnWidth[i];
1849     end;
1850    
1851     ListView.Items.Count := 0;
1852     ListView.Items.Clear;
1853     ListView.Items.Count := ABBS2ch.Count;
1854    
1855     // UpFolderAction.Enabled := False;
1856     // AllItemAction.Enabled := False;
1857     // LogItemAction.Enabled := False;
1858     // NewItemAction.Enabled := False;
1859     // SelectItemAction.Enabled := False;
1860     // ListDownloadToolButton.Enabled := False;
1861     // BoardReservToolButton.Enabled := False;
1862     // ListThreadDownloadToolButton.Enabled := False;
1863    
1864     ListNameLabel.Caption := ABBS2ch.Title;
1865     FolderImage.Picture := nil;
1866     ItemIcon16.GetBitmap(1, FolderImage.Picture.Bitmap);
1867    
1868 yoffy 1.2 FSortIndex := 0;
1869     FSortOrder := False;
1870     ListViewColumnClick(nil, ListView.Column[0]);
1871    
1872 hi_ 1.1 Result := ABBS2ch.Count;
1873     finally
1874     Screen.Cursor := crDefault;
1875     ListView.Items.EndUpdate;
1876     end;
1877     end;
1878    
1879     function TGikoForm.SetBoardListItem(Category: TCategory): Integer;
1880     const
1881     COLUMN: array[0..2] of string = ('鐃緒申鐃緒申', '鐃緒申鐃緒申鐃?鐃緒申', '鐃緒申鐃緒申鐃緒申鐃緒申');
1882     var
1883     ListColumn: TListColumn;
1884     i: Integer;
1885     begin
1886     ListView.Items.BeginUpdate;
1887     try
1888     Screen.Cursor := crHourGlass;
1889    
1890     ListView.Columns.Clear;
1891     for i := 0 to Length(COLUMN) - 1 do begin
1892     ListColumn := ListView.Columns.Add;
1893     ListColumn.Caption := COLUMN[i];
1894     ListColumn.Width := GikoSys.Setting.CategoryColumnWidth[i];
1895     end;
1896    
1897     ListView.Items.Count := 0;
1898     ListView.Items.Clear;
1899     ListView.Items.Count := Category.Count;
1900    
1901     // UpFolderAction.Enabled := True;
1902     // AllItemAction.Enabled := False;
1903     // LogItemAction.Enabled := False;
1904     // NewItemAction.Enabled := False;
1905     // SelectItemAction.Enabled := False;
1906     // ListDownloadToolButton.Enabled := False;
1907     // BoardReservToolButton.Enabled := False;
1908     // ListThreadDownloadToolButton.Enabled := False;
1909    
1910     ListNameLabel.Caption := Category.Title;
1911     FolderImage.Picture := nil;
1912     ItemIcon16.GetBitmap(3, FolderImage.Picture.Bitmap);
1913    
1914 yoffy 1.2 FSortIndex := 0;
1915     FSortOrder := False;
1916     ListViewColumnClick(nil, ListView.Column[0]);
1917    
1918 hi_ 1.1 Result := Category.Count;
1919     finally
1920     Screen.Cursor := crDefault;
1921     ListView.Items.EndUpdate;
1922     end;
1923     end;
1924    
1925     function TGikoForm.SetThreadListItem(Board: TBoard): Integer;
1926     const
1927     COLUMN: array[0..6] of string = ('鐃?鐃緒申鐃?鐃?鐃緒申', '鐃?鐃?鐃緒申鐃?', '鐃緒申鐃緒申', '鐃?鐃緒申',
1928     '鐃緒申鐃緒申', '鐃緒申鐃緒申鐃?鐃緒申', '鐃緒申鐃緒申鐃緒申鐃緒申');
1929     COLUMN_ALIGNMENT: array[0..6] of TAlignment = (taLeftJustify, taRightJustify,
1930     taRightJustify, taRightJustify,
1931     taRightJustify, taLeftJustify,
1932     taLeftJustify);
1933     //No, 鐃?鐃緒申鐃?鐃?鐃緒申, 鐃?鐃?鐃緒申鐃?, 鐃緒申鐃緒申鐃?鐃緒申, 鐃緒申鐃緒申鐃緒申鐃緒申
1934     var
1935     ListColumn: TListColumn;
1936     i: Integer;
1937     begin
1938     ListView.Items.BeginUpdate;
1939     try
1940     Screen.Cursor := crHourGlass;
1941    
1942 yoffy 1.51 // 鐃?鐃緒申鐃緒申鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1943     // 鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1944     if ListView.Columns.Count <> (High( COLUMN ) - Low( COLUMN ) + 1) then
1945     begin
1946     ListView.Columns.Clear;
1947     for i := 0 to Length(COLUMN) - 1 do begin
1948     ListColumn := ListView.Columns.Add;
1949     ListColumn.Caption := COLUMN[i];
1950     ListColumn.Width := GikoSys.Setting.BoardColumnWidth[i];
1951     ListColumn.Alignment := COLUMN_ALIGNMENT[i];
1952     end;
1953     end;
1954 hi_ 1.1
1955     ListView.Items.Count := 0;
1956     ListView.Items.Clear;
1957    
1958     case GikoForm.ViewType of
1959     gvtAll: ListView.Items.Count := Board.Count;
1960     gvtLog: ListView.Items.Count := Board.GetLogThreadCount;
1961     gvtNew: ListView.Items.Count := Board.GetNewThreadCount;
1962     gvtUser: ListView.Items.Count := Board.GetUserThreadCount;
1963     end;
1964    
1965     ListNameLabel.Caption := Board.Title;
1966     FolderImage.Picture := nil;
1967     ItemIcon16.GetBitmap(5, FolderImage.Picture.Bitmap);
1968    
1969 yoffy 1.2 FSortIndex := 0;
1970     FSortOrder := False;
1971     ListViewColumnClick(nil, ListView.Column[0]);
1972 hi_ 1.1
1973     Result := Board.Count;
1974     finally
1975     Screen.Cursor := crDefault;
1976     ListView.Items.EndUpdate;
1977     end;
1978     end;
1979    
1980     procedure TGikoForm.TreeViewChange(Sender: TObject; Node: TTreeNode);
1981     var
1982     i: Integer;
1983     begin
1984     if FTreeType = gttHistory then begin
1985     // SetContent(TThreadItem(Node.Data));
1986     InsertBrowserTab(TThreadItem(Node.Data));
1987     Exit;
1988     end;
1989    
1990     ListView.Selected := nil;
1991     ListView.Items.Count := 0;
1992     ListView.Items.Clear;
1993     // ListView.Columns.Clear;
1994    
1995     Caption := CAPTION_NAME;
1996     //Application.Title := CAPTION_NAME;
1997    
1998    
1999     if GetActiveList is TBBS2ch then begin
2000     for i := 0 to ListView.Columns.Count - 1 do
2001     GikoSys.Setting.BBSColumnWidth[i] := ListView.Column[i].Width;
2002     end else if GetActiveList is TCategory then begin
2003     for i := 0 to ListView.Columns.Count - 1 do
2004     GikoSys.Setting.CategoryColumnWidth[i] := ListView.Column[i].Width;
2005     end else if GetActiveList is TBoard then begin
2006     for i := 0 to ListView.Columns.Count - 1 do
2007     GikoSys.Setting.BoardColumnWidth[i] := ListView.Column[i].Width;
2008     end;
2009    
2010     if TObject(Node.Data) is TBBS2ch then begin
2011     SetActiveList(Node.data);
2012     end else if TObject(Node.Data) is TCategory then begin
2013     SetActiveList(Node.data);
2014     end else if TObject(Node.Data) is TBoard then begin
2015     if not TBoard(Node.Data).IsThreadDatRead then begin
2016     Screen.Cursor := crHourGlass;
2017     try
2018     GikoSys.ReadSubjectFile(TBoard(Node.Data));
2019     finally
2020     Screen.Cursor := crDefault;
2021     end;
2022     end;
2023     SetActiveList(Node.data);
2024     end;
2025     end;
2026    
2027     procedure TGikoForm.ListViewData(Sender: TObject; Item: TListItem);
2028     var
2029     // FileName: string;
2030     // DateTime: TDateTime;
2031     BoardCnt: Integer;
2032     BBS: TBBS2ch;
2033     Category: TCategory;
2034     Board: TBoard;
2035     ThreadItem: TThreadItem;
2036     RepStr: string;
2037     begin
2038     if ActiveList is TBBS2ch then begin
2039     BBS := TBBS2ch(ActiveList);
2040    
2041     ListView.StateImages := nil;
2042    
2043     if BBS = nil then Exit;
2044     if BBS.Count <= 0 then Exit;
2045     if Item = nil then Exit;
2046     if Item.Index > BBS.Count then Exit;
2047     if ListView.Items.Count = 0 then Exit;
2048    
2049     if not (BBS.Items[Item.Index] is TCategory) then Exit;
2050     Category := TCategory(BBS.Items[Item.Index]);
2051    
2052     if Category = nil then Exit;
2053    
2054     if ListNumberVisibleAction.Checked then
2055     Item.Caption := IntToStr(Category.No) + ': ' + Category.Title
2056     else
2057     Item.Caption := Category.Title;
2058    
2059 yoffy 1.2 Item.ImageIndex := ITEM_ICON_CATEGORY1;
2060 hi_ 1.1 Item.Data := Category;
2061     end else if ActiveList is TCategory then begin
2062     Category := TCategory(ActiveList);
2063    
2064     ListView.StateImages := nil;
2065    
2066     if Category = nil then Exit;
2067     if Category.Count <= 0 then Exit;
2068     if Item = nil then Exit;
2069     if Item.Index >= Category.Count then Exit;
2070     if ListView.Items.Count = 0 then Exit;
2071    
2072     if not (Category.Items[Item.Index] is TBoard) then Exit;
2073     Board := TBoard(Category.Items[Item.Index]);
2074    
2075     if Board = nil then Exit;
2076    
2077     if ListNumberVisibleAction.Checked then
2078     Item.Caption := IntToStr(Board.No) + ': ' + Board.Title
2079     else
2080     Item.Caption := Board.Title;
2081    
2082     if Item.SubItems.Count <> 2 then begin
2083     Item.SubItems.Clear;
2084     Item.SubItems.Add('');
2085     Item.SubItems.Add('');
2086     end;
2087    
2088 yoffy 1.2 Item.ImageIndex := ITEM_ICON_BOARD1;
2089 hi_ 1.1
2090     if Board.Round then
2091 yoffy 1.51 Item.SubItems[0] := Board.RoundName // '鐃?鐃緒申'
2092 hi_ 1.1 else
2093     Item.SubItems[0] := '';
2094    
2095     if Board.RoundDate = ZERO_DATE then begin
2096     Item.SubItems[1] := '';
2097     end else
2098     Item.SubItems[1] := FormatDateTime('yyyy/mm/dd hh:mm:ss', Board.RoundDate);
2099     Item.Data := Board;
2100     end else if ActiveList is TBoard then begin
2101     Board := TBoard(ActiveList);
2102    
2103     if GikoSys.Setting.ListIconVisible then
2104     ListView.StateImages := StateIconImageList
2105     else
2106     ListView.StateImages := nil;
2107    
2108     case GikoForm.ViewType of
2109     gvtAll: BoardCnt := Board.Count;
2110     gvtLog: BoardCnt := Board.GetLogThreadCount;
2111     gvtNew: BoardCnt := Board.GetNewThreadCount;
2112     gvtUser: BoardCnt := Board.GetUserThreadCount;
2113 yoffy 1.2 else
2114     BoardCnt := 0;
2115 hi_ 1.1 end;
2116    
2117     // if Board = nil then Exit;
2118     if BoardCnt <= 0 then Exit;
2119     if Item = nil then Exit;
2120     if Item.Index > BoardCnt then Exit;
2121     if ListView.Items.Count = 0 then Exit;
2122    
2123     // if not (Board.Items[Item.Index] is TThreadItem) then Exit;
2124    
2125     ThreadItem := nil;
2126     case GikoForm.ViewType of
2127     gvtAll: ThreadItem := TThreadItem(Board.Items[Item.Index]);
2128     gvtLog: ThreadItem := Board.GetLogThread(Item.Index);
2129     gvtNew: ThreadItem := Board.GetNewThread(Item.Index);
2130     gvtUser: ThreadItem := Board.GetUserThread(Item.Index);
2131     end;
2132    
2133     if ThreadItem = nil then Exit;
2134    
2135     // if ListNumberVisibleAction.Checked then
2136     // RepStr := IntToStr(ThreadItem.No) + ': ' + ThreadItem.Title
2137     // else
2138     RepStr := ThreadItem.Title;
2139 yoffy 1.2 //RepStr := StringReplace(RepStr, '&amp;', '&', [rfReplaceAll]);
2140 hi_ 1.1 RepStr := StringReplace(RepStr, '&lt;', '<', [rfReplaceAll]);
2141     RepStr := StringReplace(RepStr, '&gt;', '>', [rfReplaceAll]);
2142     RepStr := StringReplace(RepStr, '&quot;', '"', [rfReplaceAll]);
2143 yoffy 1.2 RepStr := StringReplace(RepStr, '&amp', '&', [rfReplaceAll]);
2144 hi_ 1.1 //RepStr := StringReplace(RepStr, '鐃緒申鐃?', ',', [rfReplaceAll]);
2145    
2146     if Item.SubItems.Count <> 6 then begin
2147     Item.SubItems.Clear;
2148     Item.SubItems.Add('');
2149     Item.SubItems.Add('');
2150     Item.SubItems.Add('');
2151     Item.SubItems.Add('');
2152     Item.SubItems.Add('');
2153     Item.SubItems.Add('');
2154     end;
2155    
2156     if ListNumberVisibleAction.Checked then
2157     Item.Caption := IntToStr(ThreadItem.No) + ': ' + RepStr
2158     else
2159     Item.Caption := RepStr;
2160    
2161     case ThreadItem.AgeSage of
2162     gasNone: Item.StateIndex := -1;
2163 yoffy 1.51 gasNew: Item.StateIndex := 0;
2164     gasAge: Item.StateIndex := 1;
2165 hi_ 1.1 gasSage: Item.StateIndex := 2;
2166     end;
2167    
2168     if ThreadItem.IsLogFile then begin
2169 yoffy 1.2 Item.ImageIndex := ITEM_ICON_THREADLOG1;
2170 hi_ 1.1 Item.SubItems[0] := IntToStr(ThreadItem.AllResCount);
2171     Item.SubItems[1] := IntToStr(ThreadItem.Count);
2172     if ThreadItem.NewResCount = 0 then
2173     Item.SubItems[2] := ''
2174     else
2175     Item.SubItems[2] := IntToStr(ThreadItem.NewResCount);
2176     Item.SubItems[3] := '';
2177     if ThreadItem.Round then
2178     Item.SubItems[4] := ThreadItem.RoundName
2179     else
2180     Item.SubItems[4] := '';
2181     if ThreadItem.RoundDate = ZERO_DATE then begin
2182     Item.SubItems[5] := '';
2183     end else
2184     Item.SubItems[5] := FormatDateTime('yyyy/mm/dd hh:mm:ss', ThreadItem.RoundDate);
2185     if ThreadItem.NewArrival then
2186 yoffy 1.2 Item.ImageIndex := ITEM_ICON_THREADNEW1;
2187 hi_ 1.1 end else begin
2188 yoffy 1.2 Item.ImageIndex := ITEM_ICON_THREAD1;
2189 hi_ 1.1 Item.SubItems[0] := IntToStr(ThreadItem.AllResCount);
2190     Item.SubItems[1] := '';
2191     Item.SubItems[2] := '';
2192     Item.SubItems[3] := '';
2193     Item.SubItems[4] := '';
2194     Item.SubItems[5] := '';
2195     end;
2196     Item.Data := ThreadItem;
2197     end;
2198     end;
2199    
2200     procedure TGikoForm.ListViewDataFind(Sender: TObject; Find: TItemFind;
2201     const FindString: String; const FindPosition: TPoint; FindData: Pointer;
2202     StartIndex: Integer; Direction: TSearchDirection; Wrap: Boolean;
2203     var Index: Integer);
2204     begin
2205     //
2206     end;
2207    
2208     procedure TGikoForm.ListViewDataHint(Sender: TObject; StartIndex,
2209     EndIndex: Integer);
2210     begin
2211     //
2212     end;
2213    
2214     procedure TGikoForm.ListViewDataStateChange(Sender: TObject; StartIndex,
2215     EndIndex: Integer; OldState, NewState: TItemStates);
2216     begin
2217     //
2218     end;
2219    
2220     procedure TGikoForm.BrowserStatusTextChange(Sender: TObject; const Text: WideString);
2221     var
2222     p: TPoint;
2223     s: string;
2224     tmp2: string;
2225     URL: string;
2226     ATitle: Boolean;
2227    
2228     wkBBS: string;
2229     wkKey: string;
2230    
2231 h677 1.40 //wkInt: Integer;
2232 hi_ 1.1 wkIntSt: Integer;
2233     wkIntTo: Integer;
2234    
2235     ActiveFileName: string;
2236     e: IHTMLElement;
2237     Ext: string;
2238     PathRec: TPathRec;
2239     begin
2240     try
2241     try
2242     if (FActiveContent <> nil) and (Assigned(Browser.Document)) then begin
2243     if LowerCase(OleVariant(IHTMLDocument2(Browser.Document)).charset) <> 'shift_jis' then
2244     OleVariant(IHTMLDocument2(Browser.Document)).charset := 'shift_jis';
2245     end;
2246     except
2247     end;
2248     finally
2249     end;
2250     if PreviewTimer.Enabled then
2251     PreviewTimer.Enabled := False;
2252     Application.CancelHint;
2253     if GetActiveContent <> nil then
2254     ActiveFileName := ChangeFileExt(ExtractFileName(GetActiveContent.FileName), '')
2255     else
2256     ActiveFileName := '';
2257    
2258     StatusBar.Panels[1].Text := Text;
2259    
2260     if FHint <> nil then begin
2261     FHint.ReleaseHandle;
2262     FHint.ClearAllRes;
2263     end;
2264     if FPreviewBrowser <> nil then
2265     ShowWindow(FPreviewBrowser.Handle, SW_HIDE);
2266    
2267     if not GikoSys.Setting.UnActivePopup then
2268     if not GikoForm.Active then
2269     Exit;
2270    
2271     //file:///C:/Borland/Projects/gikoNavi/test/read.cgi/qa/990576336/10
2272     //file:///C:/Borland/Projects/gikoNavi/test/read.cgi/qa/990576336/10-15
2273    
2274     s := '';
2275     Ext := AnsiLowerCase(ExtractFileExt(Text));
2276     if (Pos('http://', Text) = 1) and (GikoSys.Setting.PreviewVisible) and
2277     ((Ext = '.jpg') or (Ext = '.jpeg') or (Ext = '.gif') or (Ext = '.png')) then begin
2278     if FPreviewBrowser = nil then begin
2279     FPreviewBrowser := TPreviewBrowser.Create(Self);
2280     ShowWindow(FPreviewBrowser.Handle, SW_HIDE);
2281     TOleControl(FPreviewBrowser).Parent := nil;
2282     end;
2283 yoffy 1.50 FPreviewBrowser.Navigate('about:blank');//鐃?鐃緒申鐃緒申鐃?鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃?
2284 hi_ 1.1 FPreviewURL := Text;
2285     PreviewTimer.Interval := GikoSys.Setting.PreviewWait;
2286     PreviewTimer.Enabled := True;
2287     end else if (Pos('about:blank', Text) = 1) or (Pos('http://', Text) = 1) or (Pos('mailto:', Text) = 1) then begin
2288     if Pos('mailto:', Text) = 1 then begin
2289     s := StringReplace(Text, 'mailto:', '', [rfIgnoreCase]);
2290     //鐃?鐃?鐃?鐃?鐃?鐃緒申 鐃?鐃?鐃?3鐃緒申466鐃緒申鐃緒申鐃緒申鐃緒申
2291     GetCursorPos(p);
2292     p.x := p.x - TWebBrowser(Sender).ClientOrigin.x;
2293     p.y := p.y - TWebBrowser(Sender).ClientOrigin.y;
2294     e := IHTMLDocument2(TWebBrowser(Sender).Document).elementFromPoint(p.x, p.y);
2295     if (Assigned(e)) then begin
2296     tmp2 := GikoSys.ZenToHan(e.Get_outerText);
2297     if (GikoSys.IsNumeric(tmp2)) then begin
2298     //鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?
2299     wkBBS := GetActiveContent.ParentBoard.BBSID;
2300     wkKey := ChangeFileExt(GetActiveContent.FileName, '');
2301     wkIntSt := StrToInt(tmp2);
2302     wkIntTo := StrToInt(tmp2);
2303     //s := GetThreadText(wkBBS, wkKey, wkIntSt, wkIntTo, False, False);
2304     FHint.PopupType := gptThread;
2305     SetResPopupText(wkBBS, wkKey, wkIntSt, wkIntTo, False, False);
2306     end else begin
2307     FHint.PopupType := gptRaw;
2308     FHint.Caption := s;
2309     end;
2310     end;
2311     end else begin
2312     URL := Text;
2313 yoffy 1.54
2314 yoffy 1.67 if Pos('about:blank..', URL) = 1 then
2315 yoffy 1.66 URL := StringReplace(URL, 'about:blank..', 'http://www.2ch.net', []);
2316 hi_ 1.1
2317     PathRec := Gikosys.Parse2chURL2(URL);
2318