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.284 - (hide annotations) (download) (as text)
Tue Apr 13 12:53:01 2004 UTC (20 years ago) by h677
Branch: MAIN
Changes since 1.283: +1 -1 lines
File MIME type: text/x-pascal
スレ一覧でコンテキストメニューからダウンロードしたときのタブの切り替えの問題で、
スレ以外を表示してると例外がでる不具合の修正

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