Develop and Download Open Source Software

Browse CVS Repository

Contents of /gikonavigoeson/gikonavi/Giko.pas

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


Revision 1.215 - (show annotations) (download) (as text)
Tue Mar 16 15:37:55 2004 UTC (20 years, 1 month ago) by h677
Branch: MAIN
Changes since 1.214: +29 -6 lines
File MIME type: text/x-pascal
メモリリーク対策

1 unit Giko;
2
3 interface
4
5 uses
6 Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms,
7 OleCtrls, ComCtrls, ExtCtrls, Menus, StdCtrls, MMSystem, DateUtils, Math,
8 {$IF Defined(DELPRO) }
9 SHDocVw,
10 MSHTML,
11 {$ELSE}
12 SHDocVw_TLB,
13 MSHTML_TLB,
14 {$IFEND}
15 IdHTTP, ActiveX, ActnList, ImgList,
16 ToolWin, Buttons, {Clipbrd,} {HTTPApp,} YofUtils, IdComponent,
17 ShellAPI, UrlMon, Tabs, IdGlobal, StrUtils,
18 CommCtrl, IniFiles, Dialogs,
19 GikoSystem, GikoUtil, Setting, BoardGroup, ThreadControl, ItemDownload,
20 Editor, RoundData, RoundName, KeySetting, GikoPanel, Favorite, FavoriteAdd,
21 FavoriteArrange, AddressHistory, Preview, HTMLDocumentEvent, Kotehan,
22 HintWindow, GikoCoolBar, GikoListView, ToolBarSetting, ToolBarUtil,
23 IndividualAbon, Search, ExternalBoardManager, ExternalBoardPlugInMain,
24 StdActns, GikoXMLDoc;
25
26 type
27 TGikoTreeType = (gttNone, gtt2ch, gttHistory, gttFavorite);
28
29 TGikoForm = class(TForm)
30 StatusBar: TStatusBar;
31 MainPanel: TPanel;
32 ClientPanel: TPanel;
33 TreeSplitter: TSplitter;
34 CabinetPanel: TPanel;
35 TreeView: TTreeView;
36 ThreadMainPanel: TPanel;
37 ListSplitter: TSplitter;
38 ViewPanel: TPanel;
39 ListView: TGikoListView;
40 ThreadPanel: TPanel;
41 MessagePanel: TPanel;
42 MessageBar: TPanel;
43 MessageHideButton: TSpeedButton;
44 MessageListView: TListView;
45 MessageSplitter: TSplitter;
46 Panel3: TPanel;
47 SpeedButton1: TSpeedButton;
48 ToolBar1: TToolBar;
49 CabinetSelectToolButton: TToolButton;
50 HistoryToolBar: TToolBar;
51 ToolButton15: TToolButton;
52 ToolButton18: TToolButton;
53 ItemIcon16: TImageList;
54 ItemIcon32: TImageList;
55 HotToobarImageList: TImageList;
56 ToobarImageList: TImageList;
57 ItemImageList: TImageList;
58 ActionList: TActionList;
59 LogDeleteAction: TAction;
60 KidokuAction: TAction;
61 StdToolBarVisibleAction: TAction;
62 SearchAction: TAction;
63 GikoNaviWebPageAction: TAction;
64 AboutAction: TAction;
65 ExitAction: TAction;
66 MsgBarVisibleAction: TAction;
67 StatusBarVisibleAction: TAction;
68 LargeIconAction: TAction;
69 SmallIconAction: TAction;
70 ListIconAction: TAction;
71 DetailIconAction: TAction;
72 CabinetBBSAction: TAction;
73 CabinetHistoryAction: TAction;
74 CabinetVisibleAction: TAction;
75 MidokuAction: TAction;
76 AllSelectAction: TAction;
77 UpFolderAction: TAction;
78 ListNumberVisibleAction: TAction;
79 AllItemAction: TAction;
80 LogItemAction: TAction;
81 NewItemAction: TAction;
82 SelectItemAction: TAction;
83 ShowThreadAction: TAction;
84 StopAction: TAction;
85 MainMenu: TMainMenu;
86 FileMenu: TMenuItem;
87 DeleteMenu: TMenuItem;
88 ExitMenu: TMenuItem;
89 KidokuMenu: TMenuItem;
90 MidokuMenu: TMenuItem;
91 AllSelectMenu: TMenuItem;
92 ViewMenu: TMenuItem;
93 StdToolBarMenu: TMenuItem;
94 CabinetMenu: TMenuItem;
95 H1: TMenuItem;
96 N4: TMenuItem;
97 CabinetVisibleMenu: TMenuItem;
98 MessageMenu: TMenuItem;
99 StatusBarMenu: TMenuItem;
100 MMSep03: TMenuItem;
101 LargeIconMenu: TMenuItem;
102 SmallIconMenu: TMenuItem;
103 ListMenu: TMenuItem;
104 DetailMenu: TMenuItem;
105 ToolMenu: TMenuItem;
106 Find1: TMenuItem;
107 RoundMenu: TMenuItem;
108 MMSep04: TMenuItem;
109 OptionMenu: TMenuItem;
110 HelpMenu: TMenuItem;
111 G1: TMenuItem;
112 N1: TMenuItem;
113 AboutMenu: TMenuItem;
114 IconStyle: TAction;
115 BrowserPopupMenu: TPopupMenu;
116 ShowThreadMenu: TMenuItem;
117 ShowBoardMenu: TMenuItem;
118 ShowBoardAction: TAction;
119 ListIconPopupMenu: TPopupMenu;
120 LargeIconPMenu: TMenuItem;
121 SmallIconPMenu: TMenuItem;
122 ListPMenu: TMenuItem;
123 DetailPMenu: TMenuItem;
124 CabinetCloseAction: TAction;
125 ClosePopupMenu: TPopupMenu;
126 CloseMenu: TMenuItem;
127 OptionAction: TAction;
128 U1: TMenuItem;
129 N3: TMenuItem;
130 B1: TMenuItem;
131 S1: TMenuItem;
132 N2: TMenuItem;
133 A1: TMenuItem;
134 L1: TMenuItem;
135 N5: TMenuItem;
136 S2: TMenuItem;
137 RoundAction: TAction;
138 ListPopupMenu: TPopupMenu;
139 ListRoundPMenu: TMenuItem;
140 ListReservPMenu: TMenuItem;
141 LPMSep01: TMenuItem;
142 ItemRoundPMenu: TMenuItem;
143 LPMSep02: TMenuItem;
144 KidokuPMenu: TMenuItem;
145 MidokuPMenu: TMenuItem;
146 AllSelectPMenu: TMenuItem;
147 UrlCopyPMenu: TMenuItem;
148 LPMSep05: TMenuItem;
149 DeletePMenu: TMenuItem;
150 LPMSep06: TMenuItem;
151 ViewPMenu: TMenuItem;
152 LargeIconLPMenu: TMenuItem;
153 SmallIconLPMenu: TMenuItem;
154 ListLPMenu: TMenuItem;
155 DetailLPMenu: TMenuItem;
156 T1: TMenuItem;
157 B2: TMenuItem;
158 N8: TMenuItem;
159 URLCopyAction: TAction;
160 URLC1: TMenuItem;
161 N9: TMenuItem;
162 N10: TMenuItem;
163 MsgBarCloseAction: TAction;
164 ScrollTopAction: TAction;
165 ScrollLastAction: TAction;
166 ScrollNewAction: TAction;
167 ScrollKokoAction: TAction;
168 EditorAction: TAction;
169 IEAction: TAction;
170 ItemReloadAction: TAction;
171 BrowserMaxAction: TAction;
172 G2: TMenuItem;
173 N11: TMenuItem;
174 T3: TMenuItem;
175 L2: TMenuItem;
176 N12: TMenuItem;
177 K1: TMenuItem;
178 N13: TMenuItem;
179 N14: TMenuItem;
180 R1: TMenuItem;
181 A2: TMenuItem;
182 N15: TMenuItem;
183 SelectListReloadAction: TAction;
184 SelectThreadReloadAction: TAction;
185 SelectTimer: TTimer;
186 KokoPopupMenu: TPopupMenu;
187 KokomadePMenu: TMenuItem;
188 AllPMenu: TMenuItem;
189 MenuItem1: TMenuItem;
190 MenuItem2: TMenuItem;
191 BrowserTabCloseAction: TAction;
192 BrowserTabPopupMenu: TPopupMenu;
193 Close1: TMenuItem;
194 KokomadeAction: TAction;
195 ZenbuAction: TAction;
196 KokoResAction: TAction;
197 SelectItemURLCopyAction: TAction;
198 SelectReservAction: TAction;
199 NotSelectTabCloseAction: TAction;
200 A3: TMenuItem;
201 N16: TMenuItem;
202 A4: TMenuItem;
203 TreePopupMenu: TPopupMenu;
204 TreeSelectThreadPupupMenu: TMenuItem;
205 TreeSelectBoardPupupMenu: TMenuItem;
206 TPMSep01: TMenuItem;
207 TreeSelectURLPupupMenu: TMenuItem;
208 TreeSelectBoradReload: TAction;
209 TreeSelectThreadReload: TAction;
210 TreeSelectURLCopy: TAction;
211 ListToolBarVisibleAction: TAction;
212 BrowserToolBarVisibleAction: TAction;
213 T2: TMenuItem;
214 L3: TMenuItem;
215 B3: TMenuItem;
216 BrowserBottomPanel: TGikoPanel;
217 CabinetSelectPopupMenu: TPopupMenu;
218 H2: TMenuItem;
219 ItemReservPMenu: TMenuItem;
220 RoundNamePopupMenu: TPopupMenu;
221 SelectNewRoundName: TAction;
222 SelectDeleteRound: TAction;
223 NewBoardAction: TAction;
224 N7: TMenuItem;
225 B4: TMenuItem;
226 LoginAction: TAction;
227 L4: TMenuItem;
228 KeySettingAction: TAction;
229 K2: TMenuItem;
230 AllTabCloseAction: TAction;
231 A5: TMenuItem;
232 A6: TMenuItem;
233 C1: TMenuItem;
234 V1: TMenuItem;
235 N19: TMenuItem;
236 D1: TMenuItem;
237 D2: TMenuItem;
238 MessageImageList: TImageList;
239 ProgressBar: TProgressBar;
240 ArrangeAction: TAction;
241 URL1: TMenuItem;
242 NameURLCopyAction: TAction;
243 SelectItemNameURLCopyAction: TAction;
244 NameUrlCopyPMenu: TMenuItem;
245 URLC2: TMenuItem;
246 URLN1: TMenuItem;
247 N21: TMenuItem;
248 URLC3: TMenuItem;
249 URLN2: TMenuItem;
250 N22: TMenuItem;
251 N23: TMenuItem;
252 ListCoolBar: TGikoCoolBar;
253 ListToolBar: TToolBar;
254 ViewNoButton: TToolButton;
255 IconToolButton: TToolButton;
256 UpFolderButton: TToolButton;
257 Sepa01ToolButton: TToolButton;
258 AllItemToolButton: TToolButton;
259 LogItemToolButton: TToolButton;
260 NewItemToolButton: TToolButton;
261 ListDownloadToolButton: TToolButton;
262 ListThreadDownloadToolButton: TToolButton;
263 ToolButton2: TToolButton;
264 ToolButton1: TToolButton;
265 BrowserCoolBar: TGikoCoolBar;
266 BrowserToolBar: TToolBar;
267 BrowserSizeButton: TToolButton;
268 ToolButton3: TToolButton;
269 TopButton: TToolButton;
270 LastBotton: TToolButton;
271 NewButton: TToolButton;
272 KokoButton: TToolButton;
273 ToolButton9: TToolButton;
274 EditorButton: TToolButton;
275 ToolButton11: TToolButton;
276 IEButton: TToolButton;
277 ToolButton5: TToolButton;
278 ItemReloadButton: TToolButton;
279 ListNameToolBar: TToolBar;
280 ListNameLabel: TLabel;
281 FolderImage: TImage;
282 BrowserNameToolBar: TToolBar;
283 ItemBoardImage: TImage;
284 BrowserBoardNameLabel: TLabel;
285 ItemImage: TImage;
286 BrowserNameLabel: TLabel;
287 ActiveLogDeleteAction: TAction;
288 D3: TMenuItem;
289 N25: TMenuItem;
290 N26: TMenuItem;
291 ListNameBarVisibleAction: TAction;
292 D4: TMenuItem;
293 BrowserNameBarVisibleAction: TAction;
294 S3: TMenuItem;
295 R2: TMenuItem;
296 TreeSelectNameURLCopy: TAction;
297 TreeSelectNameURLPupupMenu: TMenuItem;
298 N27: TMenuItem;
299 H3: TMenuItem;
300 PaneInitAction: TAction;
301 I1: TMenuItem;
302 BrowserTabToolBar: TToolBar;
303 BrowserTab: TTabControl;
304 ToolButton7: TToolButton;
305 BrowserMinAction: TAction;
306 About1: TMenuItem;
307 N28: TMenuItem;
308 SelectTextClearAction: TAction;
309 MailTextClearAction: TAction;
310 NameTextClearAction: TAction;
311 S4: TMenuItem;
312 N29: TMenuItem;
313 N30: TMenuItem;
314 LeftmostTabSelectAction: TAction;
315 LeftTabSelectAction: TAction;
316 RightTabSelectAction: TAction;
317 RightmostTabSelectAction: TAction;
318 N31: TMenuItem;
319 L5: TMenuItem;
320 L6: TMenuItem;
321 A7: TMenuItem;
322 R3: TMenuItem;
323 FavoriteMenu: TMenuItem;
324 FavoriteAddAction: TAction;
325 N32: TMenuItem;
326 BoardFavoriteAddMenu: TMenuItem;
327 BoardFavoriteAddAction: TAction;
328 ThreadFavoriteAddAction: TAction;
329 ThreadFavoriteAddMenu: TMenuItem;
330 TreeSelectFavoriteAddAction: TAction;
331 N33: TMenuItem;
332 TreeSelectFavoriteAddPupupMenu: TMenuItem;
333 FavoriteArrangeAction: TAction;
334 FavoriteTreeView: TTreeView;
335 StateIconImageList: TImageList;
336 TopPanel: TPanel;
337 TopRightPanel: TPanel;
338 AnimePanel: TPanel;
339 Animate: TAnimate;
340 TopCoolPanel: TPanel;
341 MainCoolBar: TGikoCoolBar;
342 MenuToolBar: TToolBar;
343 StdToolBar: TToolBar;
344 RoundToolButton: TToolButton;
345 ToolButton6: TToolButton;
346 ToolButton4: TToolButton;
347 ToolButton13: TToolButton;
348 AbortToolButton: TToolButton;
349 LoginToolButton: TToolButton;
350 AddressToolBar: TToolBar;
351 AddressComboBox: TComboBox;
352 MoveToToolButton: TToolButton;
353 MoveToAction: TAction;
354 AddressImageList: TImageList;
355 AddressBarVisibleAction: TAction;
356 AddressToolBarMenu: TMenuItem;
357 T4: TMenuItem;
358 BrowserTabVisibleAction: TAction;
359 Show1: TMenuItem;
360 N34: TMenuItem;
361 BrowserTabTopAction: TAction;
362 BrowserTabBottomAction: TAction;
363 T5: TMenuItem;
364 B5: TMenuItem;
365 N35: TMenuItem;
366 BrowserTabTabStyleAction: TAction;
367 BrowserTabButtonStyleAction: TAction;
368 BrowserTabFlatStyleAction: TAction;
369 A8: TMenuItem;
370 U2: TMenuItem;
371 F1: TMenuItem;
372 PreviewTimer: TTimer;
373 MonazillaWebPageAction: TAction;
374 MonazillaWebPageAction1: TMenuItem;
375 GikoHelpAction: TAction;
376 N36: TMenuItem;
377 H4: TMenuItem;
378 KotehanAction: TAction;
379 K3: TMenuItem;
380 LinkBarVisibleAction: TAction;
381 L7: TMenuItem;
382 N37: TMenuItem;
383 A9: TMenuItem;
384 ChevronPopupMenu: TPopupMenu;
385 BBS2chWebPageAction: TAction;
386 N2N1: TMenuItem;
387 N38: TMenuItem;
388 GikoFolderOpenAction: TAction;
389 F2: TMenuItem;
390 LinkToolBar: TToolBar;
391 a10: TMenuItem;
392 ToolButton8: TToolButton;
393 ToolButton10: TToolButton;
394 ThreadEditorAction: TAction;
395 N39: TMenuItem;
396 T6: TMenuItem;
397 N40: TMenuItem;
398 LinkBarPopupMenu: TPopupMenu;
399 ToolBarSettingAction: TAction;
400 T7: TMenuItem;
401 ToolButton12: TToolButton;
402 ToolButton14: TToolButton;
403 ThreadPopupMenu: TPopupMenu;
404 MenuItem4: TMenuItem;
405 MenuItem5: TMenuItem;
406 MenuItem6: TMenuItem;
407 T8: TMenuItem;
408 NameCopyAction: TAction;
409 BoardIEAction: TAction;
410 URLN3: TMenuItem;
411 SelectItemNameCopyAction: TAction;
412 SelectItemNameCopyAction1: TMenuItem;
413 B6: TMenuItem;
414 T9: TMenuItem;
415 C2: TMenuItem;
416 SelectComboBox: TComboBox;
417 MainCoolBarPopupMenu: TPopupMenu;
418 StdToolBarVisiblePMenu: TMenuItem;
419 AddressToolBarVisiblePMenu: TMenuItem;
420 LinkToolBarVisiblePMenu: TMenuItem;
421 NG1: TMenuItem;
422 NG2: TMenuItem;
423 N43: TMenuItem;
424 N44: TMenuItem;
425 L9: TMenuItem;
426 I3: TMenuItem;
427 N45: TMenuItem;
428 B9: TMenuItem;
429 R5: TMenuItem;
430 T12: TMenuItem;
431 Show3: TMenuItem;
432 N46: TMenuItem;
433 T13: TMenuItem;
434 B10: TMenuItem;
435 N47: TMenuItem;
436 A12: TMenuItem;
437 U4: TMenuItem;
438 F4: TMenuItem;
439 N48: TMenuItem;
440 T14: TMenuItem;
441 SelectItemToolButton: TToolButton;
442 SelectResToolButton: TToolButton;
443 SelectResAction: TAction;
444 ToolButton16: TToolButton;
445 AllResAction: TAction;
446 AllResToolButton: TToolButton;
447 N50: TMenuItem;
448 A11: TMenuItem;
449 S5: TMenuItem;
450 Reload: TMenuItem;
451 GoBack: TMenuItem;
452 GoFoward: TMenuItem;
453 EditAction: TAction;
454 ReloadAction: TAction;
455 GoFowardAction: TAction;
456 GoBackAction: TAction;
457 SelectComboBoxSplitter: TImage;
458 IndividualAbon1: TMenuItem;
459 N41: TMenuItem;
460 IndividualAbon2: TMenuItem;
461 N42: TMenuItem;
462 CancellIndividualAbon: TAction;
463 AntiIndividualAbon: TMenuItem;
464 N49: TMenuItem;
465 N51: TMenuItem;
466 N52: TMenuItem;
467 N53: TMenuItem;
468 SearchBoardName: TMenuItem;
469 TreeSelectLogDeleteSeparator: TMenuItem;
470 TreeSelectSearchBoardName: TAction;
471 CabinetFavoriteAction: TAction;
472 N54: TMenuItem;
473 A13: TMenuItem;
474 FavoriteTreePopupMenu: TPopupMenu;
475 FavoriteTreeViewRenameAction: TAction;
476 FavoriteTreeRenamePopupMenu: TMenuItem;
477 FavoriteTreeViewNewFolderAction: TAction;
478 FavoriteTreeNewFolderPopupMenu: TMenuItem;
479 N56: TMenuItem;
480 FavoriteTreeViewDeleteAction: TAction;
481 FavoriteTreeDeletePopupMenu: TMenuItem;
482 FavoriteToolBar: TToolBar;
483 ToolButton17: TToolButton;
484 ToolButton19: TToolButton;
485 FavoriteTreeViewBrowseFolderAction: TAction;
486 FavoriteTreeBrowseFolderPopupMenu: TMenuItem;
487 N57: TMenuItem;
488 FavoriteTreeReloadPopupMenu: TMenuItem;
489 N58: TMenuItem;
490 FavoriteTreeURLCopyPopupMenu: TMenuItem;
491 FavoriteTreeNameCopyPopupMenu: TMenuItem;
492 FavoriteTreeLogDeletePopupMenu: TMenuItem;
493 N59: TMenuItem;
494 FavoriteTreeNameURLCopyPopupMenu: TMenuItem;
495 FavoriteTreeViewReloadAction: TAction;
496 FavoriteTreeViewURLCopyAction: TAction;
497 FavoriteTreeViewNameCopyAction: TAction;
498 FavoriteTreeViewNameURLCopyAction: TAction;
499 FavoriteTreeViewLogDeleteAction: TAction;
500 OnlyAHundredRes: TAction;
501 ToolButton20: TToolButton;
502 AHundredResButton: TToolButton;
503 N60: TMenuItem;
504 ExportFavoriteFileAction1: TMenuItem;
505 ExportFavoriteFile: TFileSaveAs;
506 ToolButton21: TToolButton;
507 CabinetBBSToolButton: TToolButton;
508 ToolButton23: TToolButton;
509 ToolButton24: TToolButton;
510 N6: TMenuItem;
511 N17: TMenuItem;
512 FavoriteTreeViewBrowseBoardAction: TAction;
513 FavoriteTreeViewBrowseThreadAction: TAction;
514 UpBoardAction: TAction;
515 N18: TMenuItem;
516 N20: TMenuItem;
517 N24: TMenuItem;
518 N62: TMenuItem;
519 N61: TMenuItem;
520 N63: TMenuItem;
521 KoreCopy: TAction;
522 N64: TMenuItem;
523 dummy1: TMenuItem;
524 Browser: TWebBrowser;
525 TreeSelectLogDeletePopupMenu: TMenuItem;
526 N65: TMenuItem;
527 BBSSelectPopupMenu: TPopupMenu;
528 procedure FormCreate(Sender: TObject);
529 procedure FormDestroy(Sender: TObject);
530 procedure CabinetPanelHide(Sender: TObject);
531 procedure FormClose(Sender: TObject; var Action: TCloseAction);
532 procedure TreeViewChange(Sender: TObject; Node: TTreeNode);
533 procedure ListViewData(Sender: TObject; Item: TListItem);
534 procedure ListViewDataFind(Sender: TObject; Find: TItemFind;
535 const FindString: String; const FindPosition: TPoint;
536 FindData: Pointer; StartIndex: Integer; Direction: TSearchDirection;
537 Wrap: Boolean; var Index: Integer);
538 procedure ListViewDataHint(Sender: TObject; StartIndex,
539 EndIndex: Integer);
540 procedure ListViewDataStateChange(Sender: TObject; StartIndex,
541 EndIndex: Integer; OldState, NewState: TItemStates);
542 procedure BrowserStatusTextChange(Sender: TObject;
543 const Text: WideString);
544 procedure BrowserTitleChange(Sender: TObject; const Text: WideString);
545 procedure FormCloseQuery(Sender: TObject; var CanClose: Boolean);
546 procedure TreeViewChanging(Sender: TObject; Node: TTreeNode;
547 var AllowChange: Boolean);
548 procedure ListViewKeyDown(Sender: TObject; var Key: Word;
549 Shift: TShiftState);
550 procedure ListViewColumnClick(Sender: TObject; Column: TListColumn);
551 procedure MenuToolBarCustomDrawButton(Sender: TToolBar;
552 Button: TToolButton; State: TCustomDrawState;
553 var DefaultDraw: Boolean);
554 procedure BrowserBeforeNavigate2(Sender: TObject;
555 const pDisp: IDispatch; var URL, Flags, TargetFrameName, PostData,
556 Headers: OleVariant; var Cancel: WordBool);
557 procedure ListViewAdvancedCustomDrawItem(Sender: TCustomListView;
558 Item: TListItem; State: TCustomDrawState; Stage: TCustomDrawStage;
559 var DefaultDraw: Boolean);
560 procedure TreeViewCustomDraw(Sender: TCustomTreeView;
561 const ARect: TRect; var DefaultDraw: Boolean);
562 procedure TreeViewCustomDrawItem(Sender: TCustomTreeView;
563 Node: TTreeNode; State: TCustomDrawState; var DefaultDraw: Boolean);
564 procedure TreeViewExpanded(Sender: TObject; Node: TTreeNode);
565 procedure TreeViewDblClick(Sender: TObject);
566 procedure FavoriteTreeViewClick(Sender: TObject);
567 procedure ListViewCustomDraw(Sender: TCustomListView;
568 const ARect: TRect; var DefaultDraw: Boolean);
569 procedure ListViewMouseDown(Sender: TObject; Button: TMouseButton;
570 Shift: TShiftState; X, Y: Integer);
571 procedure TreeViewCollapsed(Sender: TObject; Node: TTreeNode);
572 procedure MessageListViewResize(Sender: TObject);
573 procedure ExitActionExecute(Sender: TObject);
574 procedure AllSelectActionExecute(Sender: TObject);
575 procedure StdToolBarVisibleActionExecute(Sender: TObject);
576 procedure MsgBarVisibleActionExecute(Sender: TObject);
577 procedure StatusBarVisibleActionExecute(Sender: TObject);
578 procedure LargeIconActionExecute(Sender: TObject);
579 procedure SmallIconActionExecute(Sender: TObject);
580 procedure ListIconActionExecute(Sender: TObject);
581 procedure DetailIconActionExecute(Sender: TObject);
582 procedure SearchActionExecute(Sender: TObject);
583 procedure OptionActionExecute(Sender: TObject);
584 procedure GikoNaviWebPageActionExecute(Sender: TObject);
585 procedure AboutActionExecute(Sender: TObject);
586 procedure CabinetHistoryActionExecute(Sender: TObject);
587 procedure CabinetVisible( isVisible : Boolean );
588 procedure CabinetVisibleActionExecute(Sender: TObject);
589 procedure AllItemActionExecute(Sender: TObject);
590 procedure LogItemActionExecute(Sender: TObject);
591 procedure NewItemActionExecute(Sender: TObject);
592 procedure SelectItemActionExecute(Sender: TObject);
593 procedure ListNumberVisibleActionExecute(Sender: TObject);
594 procedure UpFolderActionExecute(Sender: TObject);
595 procedure IconStyleExecute(Sender: TObject);
596 procedure RoundActionExecute(Sender: TObject);
597 procedure StopActionExecute(Sender: TObject);
598 procedure MsgBarCloseActionExecute(Sender: TObject);
599 procedure BrowserMaxActionExecute(Sender: TObject);
600 procedure ScrollTopActionExecute(Sender: TObject);
601 procedure ScrollLastActionExecute(Sender: TObject);
602 procedure ScrollNewActionExecute(Sender: TObject);
603 procedure ScrollKokoActionExecute(Sender: TObject);
604 procedure EditorActionExecute(Sender: TObject);
605 procedure IEActionExecute(Sender: TObject);
606 procedure ShowThreadActionExecute(Sender: TObject);
607 procedure ShowBoardActionExecute(Sender: TObject);
608 procedure URLCopyActionExecute(Sender: TObject);
609 procedure ItemReloadActionExecute(Sender: TObject);
610 procedure SelectListReloadActionExecute(Sender: TObject);
611 procedure SelectThreadReloadActionExecute(Sender: TObject);
612 procedure SelectListReloadActionUpdate(Sender: TObject);
613 procedure AllItemActionUpdate(Sender: TObject);
614 procedure LogItemActionUpdate(Sender: TObject);
615 procedure NewItemActionUpdate(Sender: TObject);
616 procedure SelectItemActionUpdate(Sender: TObject);
617 procedure UpFolderActionUpdate(Sender: TObject);
618 procedure FormResize(Sender: TObject);
619 procedure ScrollTopActionUpdate(Sender: TObject);
620 procedure ScrollLastActionUpdate(Sender: TObject);
621 procedure ScrollNewActionUpdate(Sender: TObject);
622 procedure ScrollKokoActionUpdate(Sender: TObject);
623 procedure EditorActionUpdate(Sender: TObject);
624 procedure IEActionUpdate(Sender: TObject);
625 procedure ShowThreadActionUpdate(Sender: TObject);
626 procedure ShowBoardActionUpdate(Sender: TObject);
627 procedure SelectThreadReloadActionUpdate(Sender: TObject);
628 procedure ListViewSelectItem(Sender: TObject; Item: TListItem;
629 Selected: Boolean);
630 procedure SelectTimerTimer(Sender: TObject);
631 procedure ItemReloadActionUpdate(Sender: TObject);
632 procedure ListViewDblClick(Sender: TObject);
633 procedure LogDeleteActionExecute(Sender: TObject);
634 procedure KokomadeActionExecute(Sender: TObject);
635 procedure ZenbuActionExecute(Sender: TObject);
636 procedure KokoResActionExecute(Sender: TObject);
637 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 procedure ArrangeActionExecute(Sender: TObject);
675 procedure NameURLCopyActionExecute(Sender: TObject);
676 procedure SelectItemNameURLCopyActionExecute(Sender: TObject);
677 procedure URLCopyActionUpdate(Sender: TObject);
678 procedure NameURLCopyActionUpdate(Sender: TObject);
679 procedure BrowserTabCloseActionUpdate(Sender: TObject);
680 procedure NotSelectTabCloseActionUpdate(Sender: TObject);
681 procedure AllTabCloseActionUpdate(Sender: TObject);
682 procedure SelectItemNameURLCopyActionUpdate(Sender: TObject);
683 procedure ActiveLogDeleteActionExecute(Sender: TObject);
684 procedure ActiveLogDeleteActionUpdate(Sender: TObject);
685 procedure ListNameBarVisibleActionExecute(Sender: TObject);
686 procedure BrowserNameBarVisibleActionExecute(Sender: TObject);
687 procedure TreeSelectNameURLCopyExecute(Sender: TObject);
688 procedure PaneInitActionExecute(Sender: TObject);
689 procedure FormShow(Sender: TObject);
690 procedure BrowserTabToolBarResize(Sender: TObject);
691 procedure BrowserMinActionExecute(Sender: TObject);
692 procedure SelectTextClearActionExecute(Sender: TObject);
693 procedure NameTextClearActionExecute(Sender: TObject);
694 procedure MailTextClearActionExecute(Sender: TObject);
695 procedure LeftmostTabSelectActionExecute(Sender: TObject);
696 procedure LeftTabSelectActionExecute(Sender: TObject);
697 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 procedure ThreadFavoriteAddActionExecute(Sender: TObject);
709 procedure ThreadFavoriteAddActionUpdate(Sender: TObject);
710 procedure TreeSelectFavoriteAddActionExecute(Sender: TObject);
711 procedure FavoriteArrangeActionExecute(Sender: TObject);
712 procedure MainCoolBarResize(Sender: TObject);
713 procedure MoveToActionExecute(Sender: TObject);
714 procedure AddressToolBarResize(Sender: TObject);
715 procedure AddressComboBoxKeyDown(Sender: TObject; var Key: Word;
716 Shift: TShiftState);
717 procedure AddressBarVisibleActionExecute(Sender: TObject);
718 procedure BrowserEnter(Sender: TObject);
719 procedure FormShortCut(var Msg: TWMKey; var Handled: Boolean);
720 procedure BrowserTabVisibleActionExecute(Sender: TObject);
721 procedure BrowserTabTopActionExecute(Sender: TObject);
722 procedure BrowserTabBottomActionExecute(Sender: TObject);
723 procedure BrowserTabTabStyleActionExecute(Sender: TObject);
724 procedure BrowserTabButtonStyleActionExecute(Sender: TObject);
725 procedure BrowserTabFlatStyleActionExecute(Sender: TObject);
726 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 procedure LinkBarVisibleActionExecute(Sender: TObject);
733 procedure BBS2chWebPageActionExecute(Sender: TObject);
734 procedure GikoFolderOpenActionExecute(Sender: TObject);
735 procedure MainCoolBarBandInfo(Sender: TObject;
736 var BandInfo: PReBarBandInfoA);
737 procedure MainCoolBarChevronClick(Sender: TObject;
738 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 procedure BrowserCoolBarChevronClick(Sender: TObject;
746 RebarChevron: PNMRebarChevron);
747 procedure ListViewColumnInfo(Sender: TObject; var Column: PLVColumnA);
748 procedure ThreadEditorActionExecute(Sender: TObject);
749 procedure ThreadEditorActionUpdate(Sender: TObject);
750 procedure ToolBarSettingActionExecute(Sender: TObject);
751 procedure NameCopyActionExecute(Sender: TObject);
752 procedure BoardIEActionExecute(Sender: TObject);
753 procedure SelectItemNameCopyActionExecute(Sender: TObject);
754 procedure SelectItemNameCopyActionUpdate(Sender: TObject);
755 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 procedure CabinetFavoriteActionExecute(Sender: TObject);
788 procedure FavoriteTreeViewDragDrop(Sender, Source: TObject; X,
789 Y: Integer);
790 procedure FavoriteTreeViewDragOver(Sender, Source: TObject; X, Y: Integer; State: TDragState; var Accept: Boolean);
791 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 FavoriteTreeViewChange(Sender: TObject; Node: TTreeNode);
802 procedure FavoriteTreeViewDblClick(Sender: TObject);
803 procedure FavoriteTreeViewLogDeleteActionExecute(Sender: TObject);
804 procedure FavoriteTreeViewReloadActionExecute(Sender: TObject);
805 procedure FavoriteTreeViewURLCopyActionExecute(Sender: TObject);
806 procedure FavoriteTreeViewNameCopyActionExecute(Sender: TObject);
807 procedure FavoriteTreeViewNameURLCopyActionExecute(Sender: TObject);
808 procedure LinkToolBarDragDrop(Sender, Source: TObject; X, Y: Integer);
809 procedure BrowserTabMouseUp(Sender: TObject; Button: TMouseButton;
810 Shift: TShiftState; X, Y: Integer);
811 procedure LinkToolBarDragOver(Sender, Source: TObject; X, Y: Integer;
812 State: TDragState; var Accept: Boolean);
813 procedure OnlyAHundredResExecute(Sender: TObject);
814 procedure FavoriteTreeViewEndDrag(Sender, Target: TObject; X,
815 Y: Integer);
816 procedure ListCoolBarContextPopup(Sender: TObject; MousePos: TPoint;
817 var Handled: Boolean);
818 procedure MainCoolBarContextPopup(Sender: TObject; MousePos: TPoint;
819 var Handled: Boolean);
820 procedure BrowserCoolBarContextPopup(Sender: TObject; MousePos: TPoint;
821 var Handled: Boolean);
822 procedure ExportFavoriteFileAccept(Sender: TObject);
823 procedure ExportFavoriteFileBeforeExecute(Sender: TObject);
824 procedure CabinetBBSActionExecute(Sender: TObject);
825 procedure FavoriteTreeViewBrowseThreadActionExecute(Sender: TObject);
826 procedure FavoriteTreeBrowseBoardPopupMenuClick(Sender: TObject);
827 procedure UpBoardActionExecute(Sender: TObject);
828 procedure UpBoardActionUpdate(Sender: TObject);
829 procedure BrowserTabContextPopup(Sender: TObject; MousePos: TPoint;
830 var Handled: Boolean);
831 procedure KoreCopyExecute(Sender: TObject);
832 procedure BrowserTabPopupMenuPopup(Sender: TObject);
833 private
834 { Private 鐃緒申鐃緒申 }
835 //RoundList : TRoundList;
836 FSortIndex: Integer;
837 FSortOrder: Boolean;
838
839 FEnabledCloseButton: Boolean;
840 // ThreadCreate: TThreadCreate;
841
842 FClickNode: TTreeNode;
843 FHttpState: Boolean;
844 FHint: TResPopup;
845 FPreviewBrowser: TPreviewBrowser;
846 FPreviewURL: string;
847
848 FBrowserSizeHeight: Integer;
849 FBrowserSizeWidth: Integer;
850
851 // FFavorite: TFavorite;
852 FBrowserComplete: Boolean;
853 FTabHintIndex: Integer;
854 FListStyle: TViewStyle; //鐃緒申鐃?鐃?鐃?鐃?鐃?鐃緒申鐃?鐃?鐃?鐃緒申
855 FItemNoVisible: Boolean; //鐃緒申鐃?鐃?鐃緒申鐃緒申鐃?鐃緒申鐃?鐃緒申鐃?
856 FViewType: TGikoViewType; //鐃緒申鐃?鐃?鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃?鐃?鐃?
857 FActiveList: TObject;
858 FActiveContent: TThreadItem; //
859 FActiveBBS : TBBS;
860 FHistoryList: TList; //鐃?鐃?鐃?鐃緒申鐃緒申鐃?鐃?
861 FTreeType: TGikoTreeType;
862 FWorkCount: Integer;
863 FNameCookie: string;
864 FMailCookie: string;
865 // FLastRoundTime: TDateTime;
866 BrowserNullTab: TThreadItem;
867 // DoubleClickOccurred: array [TMouseButton] of Boolean;
868 FDownloadTitle: string; //鐃?鐃?鐃緒申鐃緒申鐃?鐃?鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申鐃緒申
869 FDownloadMax: Integer; //鐃?鐃?鐃緒申鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?
870 FEvent: THTMLDocumentEventSink;//鐃?鐃緒申鐃?鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申鐃?
871
872 // Fkeynum : Integer; //鐃?鐃?鐃?鐃?鐃?鐃緒申鐃?鐃?鐃?鐃?鐃?鐃?鐃?鐃?
873
874 IsDraggingSelectComboBox : Boolean;
875 DraggingSelectComboBoxPosition : TPoint;
876
877 FSearchDialog: TSearchDialog;
878
879 FDropSpaceNode: TTreeNode;
880
881 FDragTime : Cardinal; //鐃緒申鐃緒申鐃?鐃緒申D&D鐃?
882 FDragButton : TToolButton; //鐃緒申鐃緒申鐃?鐃緒申D&D鐃?鐃緒申Drag鐃緒申鐃緒申鐃緒申Button鐃緒申鐃緒申
883 FDragWFirst : Boolean; //WebTab鐃緒申D&D鐃?
884
885 FListViewBackGroundColor : TColor; //ListView鐃緒申BackGroundColor
886 FUseOddResOddColor : Boolean; //鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃?鐃緒申
887 FOddColor : TColor; //鐃緒申鐃緒申鐃?
888
889 FSelectResWord : string; // 鐃緒申鐃?鐃?鐃緒申鐃緒申鐃?鐃?
890 procedure SetBoardTreeNode( inBBS : TBBS );
891 function SetCategoryListItem(ABBS2ch: TBBS): Integer;
892 function SetBoardListItem(Category: TCategory): Integer;
893 function SetThreadListItem(Board: TBoard): Integer;
894 // function GetRoundName(index: integer): string;
895
896 procedure DownloadEnd(Sender: TObject; Item: TDownloadItem);
897 procedure DownloadMsg(Sender: TObject; Item: TDownloadItem; Msg: string; Icon: TGikoMessageIcon);
898 procedure WorkBegin(Sender: TObject; AWorkMode: TWorkMode; const AWorkCountMax: Integer; Number: Integer);
899 procedure WorkEnd(Sender: TObject; AWorkMode: TWorkMode; Number: Integer);
900 procedure Work(Sender: TObject; AWorkMode: TWorkMode; const AWorkCount: Integer; Number: Integer);
901
902 procedure SetActiveList(Obj: TObject);
903 procedure ListClick;
904 procedure ListDoubleClick;
905 procedure BrowserMovement(AName: string);
906 procedure SelectListItem(List: TList);
907 // procedure SetProgressValue(Number: Integer; Value: Integer; Max: Integer = -1);
908 procedure DeleteTab(ThreadItem: TThreadItem);
909 function Hook(var Message: TMessage): Boolean;
910 procedure AddRoundNameMenu(MenuItem: TMenuItem);
911 procedure SetSelectItemRound(RoundFlag: Boolean; RoundName: string); overload;
912 procedure SetSelectItemRound(RoundFlag: Boolean; RoundName: string; ParentName: string); overload;
913 procedure SetSelectRoundName(Sender: TObject);
914 function GetCoolBand(CoolBar: TCoolBar; Control: TWinControl): TCoolBand;
915
916 procedure SetMenuFont;
917 // procedure CreateFavMenu(Folder: TFavoriteFolder);
918 procedure CreateFavMenu(Node: TTreeNode; MenuItem: TMenuItem);
919 procedure FavoriteClick(Sender: TObject; ActiveTab: Boolean); overload;
920 procedure FavoriteClick(Sender: TObject); overload;
921 procedure FavoriteDragOver(Sender, Source: TObject; X, Y: Integer; State: TDragState; var Accept: Boolean);
922 procedure SelectTreeNode(Item: TObject; CallEvent: Boolean);
923 function OnDocumentContextMenu(Sender: TObject): WordBool;
924 // function GetThreadText(sBoard: string; sThread: string; StNum, ToNum: Integer; Title, First: Boolean): string;
925 procedure SetResPopupText(ThreadItem : TThreadItem; StNum, ToNum: Integer; Title, First: Boolean);
926 procedure ShowTextPopup;
927 //procedure ShowTextPopup(HintData: THintData);
928 // procedure SetStdToolBar;
929 // function GetAction(ActionName: string): TContainedAction;
930 procedure SetLinkBar;
931 procedure ClearLinkBar;
932 function GetWidthAllToolButton(ToolBar: TToolBar): Integer;
933 procedure MenuBarChevronMenu;
934 procedure LinkBarChevronMenu;
935 procedure ToolBarChevronMenu(ToolBar: TToolBar);
936 procedure ModifySelectList;
937 procedure FavoriteBrowseFolder( node: TTreeNode );
938 procedure LinkToolButtonDragDrop(Sender, Source: TObject; X, Y: Integer);
939 procedure LinkToolButtonOnMouseDown(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
940 procedure LinkToolButtonOnMouseMove(Sender: TObject; Shift: TShiftState; X, Y: Integer);
941 procedure LinkToolButtonOnMouseUp(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
942 procedure LinkToolButtonStartDrag(Sender: TObject; var DragObject: TDragObject);
943 function TreeNodeDataFind(Node: TTreeNode; FindPointer: Pointer): TTreeNode;
944 procedure FavoriteMoveTo( SenderNode, SourceNode: TTreeNode );
945 procedure FavoriteAddTo( SenderNode: TTreeNode; Source: TObject );
946 procedure FavoriteDragDrop( SenderNode: TTreeNode; Source: TObject );
947 //
948 procedure BrowserTabClick(Sender: TObject);
949 procedure SetListViewBackGroundColor(value: TColor);
950 procedure BBSMenuItemOnClick( Sender : TObject );
951 //
952 procedure KonoresCopy(Number: Integer; ReplaceTag : Boolean);
953 protected
954 procedure CreateParams(var Params: TCreateParams); override;
955 procedure WndProc(var Message: TMessage); override;
956 procedure WMSetCursor(var Message: TWMSetCursor); message WM_SETCURSOR;
957 procedure WMSettingChange(var Message: TWMWinIniChange); message WM_SETTINGCHANGE;
958 procedure WMCopyData(var Message: TWMCopyData); message WM_COPYDATA;
959 public
960 { Public 鐃緒申鐃緒申 }
961 // FDownload: TDownload;
962 FControlThread: TThreadControl;
963 procedure MoveToURL(URL: string);
964 procedure InsertBrowserTab(ThreadItem: TThreadItem; ActiveTab: Boolean = True);
965 procedure ReloadBBS;
966 function GetHttpState: Boolean;
967 procedure SetEnabledCloseButton(Enabled: Boolean);
968 function GetTreeNode(Data: TObject): TTreeNode;
969 procedure AppFormDeactivate(Sender: TObject);
970 // procedure CabinetPanelVisible(PanelVisible: Boolean);
971 procedure ListViewAllSelect;
972
973 property ListStyle: TViewStyle read FListStyle write FListStyle;
974 property ItemNoVisible: Boolean read FItemNoVisible write FItemNoVisible;
975 property ViewType: TGikoViewType read FViewType write FViewType;
976
977 property NameCookie: string read FNameCookie write FNameCookie;
978 property MailCookie: string read FMailCookie write FMailCookie;
979
980 procedure SetContent(ThreadItem: TThreadItem);
981 function GetActiveContent: TThreadItem;
982 function GetActiveList: TObject;
983
984 property ActiveList: TObject read GetActiveList write SetActiveList;
985 // property LastRoundTime: TDateTime read FLastRoundTime write FLastRoundTime;
986
987 procedure SetListViewType(AViewType: TGikoViewType); overload;
988 procedure SetListViewType(AViewType: TGikoViewType; SelectText: string; KubetsuChk: Boolean); overload;
989 procedure DownloadContent(ThreadItem: TThreadItem);
990 procedure DownloadList(Board: TBoard);
991 procedure PlaySound(SoundEventName: string);
992
993 function AddHistory( FavItem: TFavoriteThreadItem ): Boolean;
994 procedure DeleteHistory( threadItem: TThreadItem );
995 procedure ClearHistory;
996 procedure SaveHistory;
997 procedure LoadHistory;
998 procedure ShowBBSTree( inBBS : TBBS );
999 procedure ShowHistoryTree;
1000 procedure SetHistoryTreeNode;
1001 // procedure SelectTreeNode(Item: TObject);
1002 procedure AddMessageList(ACaption: string; AObject: TObject; Icon: TGikoMessageIcon);
1003 procedure SetBrowserTabState;
1004 // property Favorite: TFavorite read FFavorite write FFavorite;
1005 procedure SetToolBarPopup;
1006 procedure ShowFavoriteAddDialog( Item : TObject );
1007 procedure FavoritesURLReplace(oldURLs: TStringList; newURLs: TStringList);
1008
1009 property ListViewBackGroundColor: TColor read FListViewBackGroundColor write SetListViewBackGroundColor;
1010 property UseOddResOddColor : Boolean read FUseOddResOddColor write FUseOddResOddColor;
1011 property OddColor : TColor read FOddColor write FOddColor;
1012
1013 function FindToolBarButton( bar : TToolBar; action : TAction ) : TToolButton;
1014
1015 published
1016 property EnabledCloseButton: Boolean read FEnabledCloseButton write SetEnabledCloseButton;
1017 end;
1018
1019 TFavoriteMenuItem = class(TMenuItem)
1020 private
1021 FData : Pointer;
1022 public
1023 property Data: Pointer read FData write FData;
1024 end;
1025
1026 TBBSMenuItem = class(TMenuItem)
1027 private
1028 FData : Pointer;
1029 public
1030 property Data: Pointer read FData write FData;
1031 end;
1032
1033 TLinkToolButton = class(TToolButton)
1034 private
1035 FData : Pointer;
1036 public
1037 property Data: Pointer read FData write FData;
1038 end;
1039
1040 var
1041 GikoForm: TGikoForm;
1042
1043 implementation
1044
1045 uses
1046 About, Option, Round, Splash, Sort, ListSelect,
1047 NewBoard, MojuUtils,Clipbrd;
1048
1049 const
1050 CAPTION_NAME: string = '鐃?鐃?鐃?鐃?';
1051 BLANK_HTML: string = 'about:blank';
1052 SELECTCOMBOBOX_NAME: string = ''; // '鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申';
1053 SELECTCOMBOBOX_COLOR: TColor = clWindow;
1054 //D&D鐃緒申鐃?
1055 DandD_THRESHOLD = 5; //D&D鐃緒申鐃緒申鐃?鐃?pixcel)
1056 //鐃?鐃緒申鐃?鐃?鐃緒申鐃?鐃?鐃?鐃?鐃?鐃緒申
1057 ITEM_ICON_2CH1 = 0; //2ch鐃?鐃?鐃?鐃緒申
1058 ITEM_ICON_2CH2 = 1; //2ch鐃?鐃?鐃?鐃緒申
1059 ITEM_ICON_CATEGORY1 = 2; //鐃?鐃?鐃?鐃緒申鐃?鐃?鐃?鐃緒申
1060 ITEM_ICON_CATEGORY2 = 3; //鐃?鐃?鐃?鐃緒申鐃?鐃?鐃?鐃緒申
1061 ITEM_ICON_BOARD_NOSUBJECT = 3; //鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申
1062 ITEM_ICON_BOARD1 = 4; //鐃緒申鐃?鐃?鐃?鐃緒申
1063 ITEM_ICON_BOARD2 = 5; //鐃緒申鐃?鐃?鐃?鐃緒申
1064 ITEM_ICON_THREADLOG1 = 6; //鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃?
1065 ITEM_ICON_THREADLOG2 = 7; //鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃?
1066 ITEM_ICON_THREAD1 = 8; //鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃?
1067 ITEM_ICON_THREAD2 = 9; //鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃?
1068 ITEM_ICON_THREADNEW1 = 10; //鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃?
1069 ITEM_ICON_THREADNEW2 = 11; //鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃?
1070 ITEM_ICON_SORT1 = 12; //鐃?鐃?鐃?鐃?鐃?鐃?鐃緒申
1071 ITEM_ICON_SORT2 = 13; //鐃?鐃?鐃?鐃?鐃?鐃?鐃緒申
1072 ITEM_ICON_BOARD_LOG = 17; //鐃?鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申
1073 ITEM_ICON_BOARD_NEW = 18; //鐃?鐃緒申鐃?鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申
1074
1075 //鐃?鐃?鐃緒申鐃?鐃?鐃?鐃?鐃?鐃緒申
1076 TOOL_ICON_HEIGHT_MAX = 16; //鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申
1077 TOOL_ICON_HEIGHT_MIN = 17; //鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申
1078 TOOL_ICON_HEIGHT_NORMAL = 18; //鐃緒申鐃緒申鐃?鐃緒申鐃?鐃?鐃?鐃緒申
1079 TOOL_ICON_WIDTH_MAX = 19; //鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申
1080 TOOL_ICON_WIDTH_MIN = 20; //鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申
1081 TOOL_ICON_WIDTH_NORMAL = 21; //鐃緒申鐃?鐃緒申鐃?鐃?鐃?鐃緒申
1082
1083 TOOL_ICON_FAV_FOLDER = 30; //鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃?鐃?鐃緒申鐃?鐃?鐃?鐃?鐃緒申
1084 TOOL_ICON_FAV_BOARD = 31; //鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申
1085 TOOL_ICON_FAV_THREAD = 32; //鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃?鐃?鐃?鐃緒申
1086
1087 HTML_FILE_NAME = 'temp_preview.html';
1088
1089 {$R *.DFM}
1090
1091 procedure TGikoForm.CreateParams(var Params: TCreateParams);
1092 begin
1093 inherited;
1094 if FormStyle in [fsNormal, fsStayOnTop] then begin
1095 if BorderStyle in [bsSingle, bsSizeable] then begin
1096 Params.ExStyle := Params.ExStyle or WS_EX_APPWINDOW;
1097 Params.WndParent := 0;
1098 end;
1099 end;
1100 end;
1101
1102 procedure TGikoForm.FormCreate(Sender: TObject);
1103 const
1104 TVS_NOTOOLTIPS = $0080;
1105 var
1106 FileName: string;
1107 Style: DWORD;
1108 msg: string;
1109 i: Integer;
1110 wp: TWindowPlacement;
1111 s: string;
1112 item : TBBSMenuItem;
1113 begin
1114 {$IFDEF DEBUG}
1115 AllocConsole;
1116 Writeln('============================================================');
1117 Writeln(' 鐃?鐃?鐃?鐃?鐃?鐃?鐃?鐃? 鐃?鐃緒申鐃?鐃?鐃緒申');
1118 Writeln('');
1119 Writeln(' 鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?');
1120 Writeln(' 鐃?鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃?鐃?鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申');
1121 Writeln('============================================================');
1122 {$ENDIF}
1123 Application.OnDeactivate := AppFormDeactivate;
1124 Self.OnDeactivate := AppFormDeactivate;
1125 Application.HookMainWindow(Hook);
1126
1127 FTreeType := gttNone;
1128
1129 FSearchDialog := nil;
1130
1131 //鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申
1132 Screen.Cursors[5] := LoadCursor(HInstance, 'GIKOHAND');
1133
1134
1135 //鐃?鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1136 AddressHistoryDM.ReadHistory(AddressComboBox.Items, GikoSys.Setting.AddressHistoryCount);
1137
1138 // 鐃?鐃緒申鐃緒申鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申鐃?鐃?(ReadBoardFile, LoadHistory 鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申)
1139 InitializeBoardPlugIns;
1140
1141 EnabledCloseButton := True;
1142
1143
1144 //鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申
1145 RoundList := TRoundList.Create;
1146 RoundList.LoadRoundBoardFile;
1147
1148 // 鐃?鐃?鐃?鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申(ReadFavorite 鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申)
1149 GikoSys.ListBoardFile;
1150
1151 RoundList.LoadRoundThreadFile;
1152
1153 if RoundList.OldFileRead or ( RoundList.Count[grtItem] > 0 ) then
1154 GikoSys.ListBoardFile;
1155
1156 // 鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申
1157 for i := Length( BBSs ) - 1 downto 0 do begin
1158 try
1159 item := TBBSMenuItem.Create( PopupMenu );
1160 item.Caption := BBSs[ i ].Title;
1161 item.Data := BBSs[ i ];
1162 item.OnClick := BBSMenuItemOnClick;
1163 CabinetSelectPopupMenu.Items.Insert( 0, item );
1164 item := TBBSMenuItem.Create( PopupMenu );
1165 item.Caption := BBSs[ i ].Title;
1166 item.Data := BBSs[ i ];
1167 item.OnClick := BBSMenuItemOnClick;
1168 CabinetMenu.Insert( 0, item );
1169 item := TBBSMenuItem.Create( PopupMenu );
1170 item.Caption := BBSs[ i ].Title;
1171 item.Data := BBSs[ i ];
1172 item.OnClick := BBSMenuItemOnClick;
1173 BBSSelectPopupMenu.Items.Insert( 0, Item );
1174 except
1175 end;
1176 end;
1177
1178
1179 // 鐃?鐃?鐃?鐃緒申鐃緒申鐃?鐃?(LoadHistory 鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申)
1180 FHistoryList := TList.Create;
1181
1182 // 鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1183 LoadHistory;
1184
1185 //鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1186 // FFavorite := TFavorite.Create(FavoriteTreeView);
1187 FavoriteDM.SetFavTreeView(FavoriteTreeView);
1188 FavoriteDM.ReadFavorite;
1189
1190 //鐃緒申鐃?鐃?鐃?鐃?鐃?鐃緒申
1191 ListView.ViewStyle := GikoSys.Setting.ListStyle;
1192
1193 //鐃緒申鐃?鐃緒申鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃?
1194 // MainCoolBar.Top := 0;
1195 // MainCoolBar.Left := 0;
1196
1197 //鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申鐃?
1198 AnimePanel.Top := 0;
1199 AnimePanel.Left := 0;
1200
1201 //鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1202
1203 //鐃?鐃緒申鐃?鐃?鐃?鐃?
1204 CabinetPanel.Width := GikoSys.Setting.CabinetWidth;
1205
1206 //鐃緒申鐃?鐃?鐃?鐃?鐃?鐃?
1207 MsgBarVisibleAction.Checked := GikoSys.Setting.MessageBarVisible;
1208 MsgBarVisibleActionExecute(nil);
1209 MessagePanel.Height := GikoSys.Setting.MessegeBarHeight;
1210
1211 //鐃?鐃?鐃?鐃?鐃?鐃?鐃?
1212 StatusBarVisibleAction.Checked := GikoSys.Setting.StatusBarVisible;
1213 StatusBarVisibleActionExecute(nil);
1214
1215 //鐃?鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃緒申
1216 TreeView.Items.BeginUpdate;
1217 FavoriteTreeView.Items.BeginUpdate;
1218 ListView.Items.BeginUpdate;
1219 try
1220 TreeView.Font.Name := GikoSys.Setting.CabinetFontName;
1221 TreeView.Font.Size := GikoSys.Setting.CabinetFontSize;
1222 TreeView.Font.Color := GikoSys.Setting.CabinetFontColor;
1223 TreeView.Color := GikoSys.Setting.CabinetBackColor;
1224
1225 FavoriteTreeView.Font.Name := GikoSys.Setting.CabinetFontName;
1226 FavoriteTreeView.Font.Size := GikoSys.Setting.CabinetFontSize;
1227 FavoriteTreeView.Font.Color := GikoSys.Setting.CabinetFontColor;
1228 FavoriteTreeView.Color := GikoSys.Setting.CabinetBackColor;
1229
1230 ListView.Font.Name := GikoSys.Setting.ListFontName;
1231 ListView.Font.Size := GikoSys.Setting.ListFontSize;
1232 ListView.Font.Color := GikoSys.Setting.ListFontColor;
1233 //ListView.Color := GikoSys.Setting.ListBackColor;
1234 ListViewBackGroundColor := GikoSys.Setting.ListBackColor;
1235 FUseOddResOddColor := GikoSys.Setting.UseOddColorOddResNum;
1236 FOddColor := GikoSys.Setting.OddColor;
1237
1238 finally
1239 TreeView.Items.EndUpdate;
1240 FavoriteTreeView.Items.EndUpdate;
1241 ListView.Items.EndUpdate;
1242 end;
1243 //ViewNoButton.Down := GikoSys.Setting.ListViewNo;
1244 ListNumberVisibleAction.Checked := GikoSys.Setting.ListViewNo;
1245
1246 //鐃?鐃緒申鐃?鐃?鐃?鐃?鐃?鐃?鐃緒申鐃?
1247 BrowserTab.Font.Name := GikoSys.Setting.BrowserTabFontName;
1248 BrowserTab.Font.Size := GikoSys.Setting.BrowserTabFontSize;
1249 FDragWFirst := false;
1250
1251 // TreeView.TopItem.Expanded := True; //鐃?鐃緒申鐃?鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申
1252 // TreeView.Selected := TreeView.Items[0]; //鐃?鐃緒申鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申
1253 SetContent(nil); //鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申鐃?鐃緒申
1254
1255 //鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃?鐃緒申鐃緒申
1256 wp.length := sizeof(wp);
1257 wp.rcNormalPosition.Top := GikoSys.Setting.WindowTop;
1258 wp.rcNormalPosition.Left := GikoSys.Setting.WindowLeft;
1259 wp.rcNormalPosition.Bottom := GikoSys.Setting.WindowTop + GikoSys.Setting.WindowHeight;
1260 wp.rcNormalPosition.Right := GikoSys.Setting.WindowLeft + GikoSys.Setting.WindowWidth;
1261 wp.showCmd := SW_HIDE;
1262 SetWindowPlacement(Handle, @wp);
1263
1264 // SetBounds(GikoSys.Setting.WindowLeft, GikoSys.Setting.WindowTop,
1265 // GikoSys.Setting.WindowWidth, GikoSys.Setting.WindowHeight);
1266 if GikoSys.Setting.WindowMax then
1267 WindowState := wsMaximized;
1268
1269 //鐃?鐃?鐃?鐃?鐃緒申
1270 try
1271 FileName := GikoSys.GetAppDir + 'gikoNavi.avi';
1272 if FileExists(FileName) then
1273 Animate.FileName := FileName;
1274 except
1275 end;
1276
1277 //鐃?鐃?鐃?鐃?
1278 FNameCookie := '';
1279 FMailCookie := '';
1280
1281 //鐃?鐃緒申鐃?鐃緒申鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1282 AllItemAction.Checked := True;
1283 AllResAction.Checked := True;
1284
1285 //TreeView鐃緒申鐃緒申鐃緒申鐃?鐃緒申ToolTip鐃緒申鐃緒申鐃?鐃緒申
1286 Style := GetWindowLong(TreeView.Handle, GWL_STYLE);
1287 Style := Style or TVS_NOTOOLTIPS;
1288 SetWindowLong(TreeView.Handle, GWL_STYLE, Style);
1289
1290 // 鐃?鐃緒申鐃?鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1291 TreeView.Align := alClient;
1292 FavoriteTreeView.Align := alClient;
1293 FavoriteTreeView.Visible := False;
1294
1295 //鐃?鐃緒申鐃?鐃?鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申
1296 // FBrowserSizeFlag := False;
1297 // FBrowserSizeHeight := ViewPanel.Height;
1298
1299 FBrowserSizeHeight := GikoSys.Setting.ListHeight;
1300 FBrowserSizeWidth := GikoSys.Setting.ListWidth;
1301
1302 ArrangeAction.Checked := not (GikoSys.Setting.ListOrientation = gloVertical);
1303 ArrangeAction.Execute;
1304
1305 if GikoSys.Setting.ListOrientation = gloHorizontal then begin
1306 case GikoSys.Setting.ListWidthState of
1307 glsMax: begin
1308 ViewPanel.Width := 1;
1309 BrowserMaxAction.ImageIndex := TOOL_ICON_WIDTH_NORMAL;
1310 BrowserMinAction.ImageIndex := TOOL_ICON_WIDTH_MIN;
1311 end;
1312 glsMin: begin
1313 ViewPanel.Width := GikoSys.Setting.ListWidth;
1314 BrowserMaxAction.ImageIndex := TOOL_ICON_WIDTH_MAX;
1315 BrowserMinAction.ImageIndex := TOOL_ICON_WIDTH_NORMAL;
1316 end;
1317 else begin
1318 ViewPanel.Width := GikoSys.Setting.ListWidth;
1319 BrowserMaxAction.ImageIndex := TOOL_ICON_WIDTH_MAX;
1320 BrowserMinAction.ImageIndex := TOOL_ICON_WIDTH_MIN;
1321 end;
1322 end;
1323 end else begin
1324 case GikoSys.Setting.ListHeightState of
1325 glsMax: begin
1326 ViewPanel.Height := 1;
1327 BrowserMaxAction.ImageIndex := TOOL_ICON_HEIGHT_NORMAL;
1328 BrowserMinAction.ImageIndex := TOOL_ICON_HEIGHT_MIN;
1329 end;
1330 glsMin: begin
1331 ViewPanel.Height := GikoSys.Setting.ListHeight;
1332 BrowserMaxAction.ImageIndex := TOOL_ICON_HEIGHT_MAX;
1333 BrowserMinAction.ImageIndex := TOOL_ICON_HEIGHT_NORMAL;
1334 end;
1335 else begin
1336 ViewPanel.Height := GikoSys.Setting.ListHeight;
1337 BrowserMaxAction.ImageIndex := TOOL_ICON_HEIGHT_MAX;
1338 BrowserMinAction.ImageIndex := TOOL_ICON_HEIGHT_MIN;
1339 end;
1340 end;
1341 end;
1342
1343 //鐃?鐃緒申鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申
1344 // ProgressBar.Visible := False;
1345 ProgressBar.Parent := StatusBar;
1346 ProgressBar.Top := 2;
1347 ProgressBar.Left := 0;
1348 ProgressBar.Width := StatusBar.Panels[0].Width;
1349 ProgressBar.Height := StatusBar.Height - 2;
1350 ProgressBar.Position := 0;
1351
1352 //鐃?鐃?鐃緒申鐃緒申鐃?鐃?鐃?鐃?鐃?鐃?鐃?鐃?
1353 FControlThread := TThreadControl.Create(True);
1354 FControlThread.MaxThreadCount := 1;
1355 FControlThread.Resume;
1356 FControlThread.OnDownloadEnd := DownloadEnd;
1357 FControlThread.OnDownloadMsg := DownloadMsg;
1358 FControlThread.OnWork := Work;
1359 FControlThread.OnWorkBegin := WorkBegin;
1360 FControlThread.OnWorkEnd := WorkEnd;
1361 // ProgressPanel.Width := FControlThread.MaxThreadCount * 12;
1362
1363 // 鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1364 SelectComboBox.Items.Assign( GikoSys.Setting.SelectTextList );
1365
1366 //鐃?鐃緒申鐃?鐃?鐃?鐃?鐃緒申鐃緒申
1367 SetBrowserTabState;
1368
1369 BrowserBoardNameLabel.Caption := '';
1370 BrowserNameLabel.Caption := '';
1371 FWorkCount := 0;
1372
1373 FTabHintIndex := -1;
1374
1375 //鐃緒申鐃緒申鐃?鐃?鐃?
1376 SetLinkBar;
1377
1378 //鐃緒申鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?
1379 SetMenuFont;
1380
1381 //鐃?鐃?鐃緒申鐃?鐃?Wrapable
1382 ListToolBar.Wrapable := GikoSys.Setting.ListToolBarWrapable;
1383 BrowserToolBar.Wrapable := GikoSys.Setting.BrowserToolBarWrapable;
1384
1385 //鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1386 ReadToolBarSetting(ActionList, StdToolBar);
1387 ReadToolBarSetting(ActionList, ListToolBar);
1388 try
1389 for i := ListToolBar.ControlCount - 1 downto 0 do
1390 begin
1391 if ListToolBar.Controls[ i ].Action = SelectItemAction then
1392 begin
1393 // 鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申
1394 if (i + 1) < ListToolBar.ControlCount then
1395 if ListToolBar.Controls[ i + 1 ] is TToolButton then
1396 if TToolButton( ListToolBar.Controls[ i + 1 ] ).Style = tbsSeparator then
1397 ListToolBar.Controls[ i + 1 ].Visible := False;
1398
1399 // 鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申鐃?鐃緒申
1400 ListToolBar.Controls[ i ].Visible := False;
1401 // 鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃?鐃緒申
1402 SelectComboBox.Left := ListToolBar.Controls[ i ].Left;
1403 SelectComboBox.Width := GikoSys.Setting.SelectComboBoxWidth;
1404 SelectComboBox.Parent := ListToolBar;
1405 // 鐃?鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃緒申鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃?鐃緒申
1406 SelectComboBoxSplitter.Left := SelectComboBox.Left + SelectComboBox.Width;
1407 SelectComboBoxSplitter.Parent := ListToolBar;
1408
1409 break;
1410 end;
1411 end;
1412 except
1413 end;
1414 ReadToolBarSetting(ActionList, BrowserToolBar);
1415 SetToolBarPopup;
1416 OnlyAHundredRes.Checked := GikoSys.Setting.OnlyAHundredRes;
1417 //鐃?鐃?鐃緒申鐃?鐃?鐃?
1418 AddressComboBox.TabStop := GikoSys.Setting.AddressBarTabStop;
1419
1420 //鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申FormShow鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1421
1422 //鐃?鐃?鐃?鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃?鐃?鐃緒申
1423 if not FileExists(GikoSys.GetBoardFileName) then begin
1424 msg := '鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃?鐃緒申鐃?鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申' + #13#10#13#10
1425 + '鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃?鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃?鐃?鐃緒申鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申' + #13#10
1426 + '鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃?鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?';
1427 MsgBox(SplashWindow.Handle, msg, '鐃?鐃?鐃?鐃?', MB_OK or MB_ICONINFORMATION);
1428 NewBoardAction.Execute;
1429 end;
1430
1431 //鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1432 GikoSys.LoadKeySetting(ActionList);
1433
1434 //鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申
1435 // FLastRoundTime := 0;
1436
1437 //ResHint
1438 FHint := TResPopup.Create(Self);
1439
1440 // 鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃?鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申
1441 CabinetVisible( False );
1442 if GikoSys.Setting.CabinetVisible then begin
1443 i := CabinetSelectPopupMenu.Items.Count - 1;
1444 if GikoSys.Setting.CabinetIndex = i - 1 then
1445 CabinetHistoryAction.Execute
1446 else if GikoSys.Setting.CabinetIndex = i then
1447 CabinetFavoriteAction.Execute
1448 else begin
1449 if GikoSys.Setting.CabinetIndex < Length( BBSs ) then
1450 ShowBBSTree( BBSs[ GikoSys.Setting.CabinetIndex ] );
1451 CabinetBBSAction.Execute;
1452 end;
1453 end else begin
1454 ShowBBSTree( BBSs[ 0 ] );
1455 end;
1456
1457 //鐃?鐃?鐃?鐃緒申鐃?鐃?鐃緒申
1458 if GikoSys.Setting.AutoLogin then
1459 LoginAction.Execute;
1460
1461 //鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃?鐃緒申鐃緒申鐃?鐃?鐃?
1462 for i := 1 to ParamCount do begin
1463 MoveToURL(ParamStr(i));
1464 end;
1465 // SetStdToolBar;
1466 // SetLinkBar;
1467
1468 s := GikoSys.FAbon.NGwordname;
1469 StatusBar.Panels[2].Text := s;
1470 StatusBar.Panels[2].Width := Max(StatusBar.Canvas.TextWidth(s), 100);
1471 StatusBarResize(Sender);
1472
1473 dummy1.Caption := ItemReservPMenu.Caption;
1474 dummy1.Hint := ItemReservPMenu.Hint;
1475
1476 end;
1477
1478 //
1479 //
1480 //
1481 procedure TGikoForm.FormShow(Sender: TObject);
1482 var
1483 i: Integer;
1484 CoolSet: TCoolSet;
1485 begin
1486 ShowWindow(Application.Handle, SW_HIDE);
1487
1488 //FormCreate鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申FormShow鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1489 //鐃?鐃?鐃緒申鐃?鐃?鐃?鐃緒申
1490 StdToolBarVisibleAction.Checked := GikoSys.Setting.StdToolBarVisible;
1491 StdToolBarVisibleActionExecute( nil );
1492 AddressBarVisibleAction.Checked := GikoSys.Setting.AddressBarVisible;
1493 AddressBarVisibleActionExecute( nil );
1494 LinkBarVisibleAction.Checked := GikoSys.Setting.LinkBarVisible;
1495 LinkBarVisibleActionExecute( nil );
1496 ListToolBarVisibleAction.Checked := GikoSys.Setting.ListToolBarVisible;
1497 ListToolBarVisibleActionExecute( nil );
1498 ListNameBarVisibleAction.Checked := GikoSys.Setting.ListNameBarVisible;
1499 ListNameBarVisibleActionExecute( nil );
1500 BrowserToolBarVisibleAction.Checked := GikoSys.Setting.BrowserToolBarVisible;
1501 BrowserToolBarVisibleActionExecute( nil );
1502 BrowserNameBarVisibleAction.Checked := GikoSys.Setting.BrowserNameBarVisible;
1503 BrowserNameBarVisibleActionExecute( nil );
1504
1505 //鐃?鐃緒申鐃?鐃?鐃?鐃?
1506 BrowserTabVisibleAction.Checked := GikoSys.Setting.BrowserTabVisible;
1507 BrowserTabVisibleActionExecute(nil);
1508
1509 if GikoSys.Setting.BrowserTabPosition = gtpTop then begin
1510 BrowserTabTopAction.Checked := True;
1511 BrowserTabTopActionExecute(nil);
1512 end else begin
1513 BrowserTabBottomAction.Checked := True;
1514 BrowserTabBottomActionExecute(nil);
1515 end;
1516
1517 if GikoSys.Setting.BrowserTabStyle = gtsTab then begin
1518 BrowserTabTabStyleAction.Checked := True;
1519 BrowserTabTabStyleActionExecute(nil);
1520 end else if GikoSys.Setting.BrowserTabStyle = gtsButton then begin
1521 BrowserTabButtonStyleAction.Checked := True;
1522 BrowserTabButtonStyleActionExecute(nil);
1523 end else begin
1524 BrowserTabFlatStyleAction.Checked := True;
1525 BrowserTabFlatStyleActionExecute(nil);
1526 end;
1527
1528
1529 //鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申(Main)
1530 MainCoolBar.Bands.BeginUpdate;
1531 try
1532 for i := 0 to MainCoolBar.Bands.Count - 1 do begin
1533 CoolSet := GikoSys.Setting.MainCoolSet[i];
1534 if (CoolSet.FCoolID = -1) or (CoolSet.FCoolWidth = -1) then
1535 Continue;
1536 MainCoolBar.Bands.FindItemID(CoolSet.FCoolID).Index := i;
1537 MainCoolBar.Bands[i].Break := CoolSet.FCoolBreak;
1538 MainCoolBar.Bands[i].Width := CoolSet.FCoolWidth;
1539 end;
1540 finally
1541 MainCoolBar.Bands.EndUpdate;
1542 end;
1543
1544 //鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申(Board)
1545 ListCoolBar.Bands.BeginUpdate;
1546 try
1547 for i := 0 to ListCoolBar.Bands.Count - 1 do begin
1548 CoolSet := GikoSys.Setting.ListCoolSet[i];
1549 if (CoolSet.FCoolID = -1) or (CoolSet.FCoolWidth = -1) then
1550 Continue;
1551 ListCoolBar.Bands.FindItemID(CoolSet.FCoolID).Index := i;
1552 ListCoolBar.Bands[i].Break := CoolSet.FCoolBreak;
1553 ListCoolBar.Bands[i].Width := CoolSet.FCoolWidth;
1554 end;
1555 finally
1556 ListCoolBar.Bands.EndUpdate;
1557 end;
1558
1559 //鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申(Browser)
1560 BrowserCoolBar.Bands.BeginUpdate;
1561 try
1562 for i := 0 to BrowserCoolBar.Bands.Count - 1 do begin
1563 CoolSet := GikoSys.Setting.BrowserCoolSet[i];
1564 if (CoolSet.FCoolID = -1) or (CoolSet.FCoolWidth = -1) then
1565 Continue;
1566 BrowserCoolBar.Bands.FindItemID(CoolSet.FCoolID).Index := i;
1567 BrowserCoolBar.Bands[i].Break := CoolSet.FCoolBreak;
1568 BrowserCoolBar.Bands[i].Width := CoolSet.FCoolWidth;
1569 end;
1570 finally
1571 BrowserCoolBar.Bands.EndUpdate;
1572 end;
1573
1574 end;
1575 procedure TGikoForm.FormCloseQuery(Sender: TObject; var CanClose: Boolean);
1576 var
1577 i: Integer;
1578 CoolSet: TCoolSet;
1579 wp: TWindowPlacement;
1580 begin
1581 if ( GikoSys.Setting.ShowDialogForEnd ) and
1582 (MessageDlg('鐃?鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?', mtConfirmation,[mbOk, mbCancel], 0) = mrCancel ) then begin
1583 CanClose := false;
1584 Exit;
1585 end else begin
1586 CanClose := True;
1587 end;
1588 // Application.OnDeactivate := nil;
1589 // Self.OnDeactivate := nil;
1590
1591 //column鐃緒申
1592 if GetActiveList is TBBS then begin
1593 for i := 0 to ListView.Columns.Count - 1 do
1594 GikoSys.Setting.BBSColumnWidth[i] := ListView.Column[i].Width;
1595 end else if GetActiveList is TCategory then begin
1596 for i := 0 to ListView.Columns.Count - 1 do
1597 GikoSys.Setting.CategoryColumnWidth[i] := ListView.Column[i].Width;
1598 end else if GetActiveList is TBoard then begin
1599 for i := 0 to ListView.Columns.Count - 1 do
1600 GikoSys.Setting.BoardColumnWidth[i] := ListView.Column[i].Width;
1601 end;
1602
1603 //鐃緒申鐃緒申鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃?鐃緒申鐃緒申
1604 wp.length := sizeof(wp);
1605 GetWindowPlacement(Handle, @wp);
1606 GikoSys.Setting.WindowTop := wp.rcNormalPosition.Top;
1607 GikoSys.Setting.WindowLeft := wp.rcNormalPosition.Left;
1608 GikoSys.Setting.WindowHeight := wp.rcNormalPosition.Bottom - wp.rcNormalPosition.Top;
1609 GikoSys.Setting.WindowWidth := wp.rcNormalPosition.Right - wp.rcNormalPosition.Left;
1610 GikoSys.Setting.WindowMax := WindowState = wsMaximized;
1611
1612 GikoSys.Setting.ListStyle := ListView.ViewStyle;
1613 GikoSys.Setting.CabinetVisible := CabinetVisibleAction.Checked;
1614 GikoSys.Setting.CabinetWidth := CabinetPanel.Width;
1615 GikoSys.Setting.ListHeight := FBrowserSizeHeight;
1616 GikoSys.Setting.ListWidth := FBrowserSizeWidth;
1617 if ArrangeAction.Checked then
1618 GikoSys.Setting.ListOrientation := gloVertical
1619 else
1620 GikoSys.Setting.ListOrientation := gloHorizontal;
1621 GikoSys.Setting.MessegeBarHeight := MessagePanel.Height;
1622
1623 //鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申(Main)
1624 for i := 0 to MAIN_COOLBAND_COUNT - 1 do begin
1625 CoolSet.FCoolID := MainCoolBar.Bands[i].ID;
1626 CoolSet.FCoolWidth := MainCoolBar.Bands[i].Width;
1627 CoolSet.FCoolBreak := MainCoolBar.Bands[i].Break;
1628 GikoSys.Setting.MainCoolSet[i] := CoolSet;
1629 end;
1630 //鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申(Board)
1631 for i := 0 to LIST_COOLBAND_COUNT - 1 do begin
1632 CoolSet.FCoolID := ListCoolBar.Bands[i].ID;
1633 CoolSet.FCoolWidth := ListCoolBar.Bands[i].Width;
1634 CoolSet.FCoolBreak := ListCoolBar.Bands[i].Break;
1635 GikoSys.Setting.ListCoolSet[i] := CoolSet;
1636 end;
1637 //鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申(Browser)
1638 for i := 0 to BROWSER_COOLBAND_COUNT - 1 do begin
1639 CoolSet.FCoolID := BrowserCoolBar.Bands[i].ID;
1640 CoolSet.FCoolWidth := BrowserCoolBar.Bands[i].Width;
1641 CoolSet.FCoolBreak := BrowserCoolBar.Bands[i].Break;
1642 GikoSys.Setting.BrowserCoolSet[i] := CoolSet;
1643 end;
1644
1645 GikoSys.Setting.WriteWindowSettingFile;
1646 GikoSys.Setting.WriteNameMailSettingFile;
1647
1648 //鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1649 try
1650 FavoriteDM.WriteFavorite;
1651 except
1652 end;
1653 // Favorite.Free;
1654
1655 try
1656 //鐃?鐃?鐃?鐃緒申鐃?鐃?
1657 NotSelectTabCloseAction.Execute;
1658 if BrowserTab.Tabs.Count >= 1 then begin
1659 DeleteTab(TThreadItem(BrowserTab.Tabs.Objects[0]));
1660 end;
1661 except
1662 end;
1663
1664 //鐃?鐃?鐃?鐃緒申鐃緒申鐃?鐃?鐃緒申鐃緒申
1665 try
1666 SaveHistory;
1667 except
1668 end;
1669
1670 //鐃?鐃?鐃?鐃緒申鐃緒申鐃?鐃?
1671 try
1672 FHistoryList.Free;
1673 except
1674 end;
1675
1676 //鐃?鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申
1677 try
1678 AddressHistoryDM.WriteHistory(AddressComboBox.Items, GikoSys.Setting.AddressHistoryCount);
1679 except
1680 end;
1681
1682 try
1683 FControlThread.Terminate;
1684 except
1685 end;
1686
1687 try
1688 ClearLinkBar;
1689 except
1690 end;
1691
1692 // FDownload.Free;
1693 try
1694 //SetActiveList(nil);
1695 except
1696 end;
1697
1698 //TreeView鐃?鐃緒申鐃?鐃?BBS2ch.Free鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申XP鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃?鐃?鐃緒申鐃?
1699 //Sleep(10);
1700 Application.ProcessMessages;
1701 try
1702 TreeView.Items.Clear;
1703 except
1704 end;
1705 try
1706 FavoriteTreeView.Items.Clear;
1707 except
1708 end;
1709
1710 try
1711 if FavoriteDM <> nil then
1712 FavoriteDM.Free;
1713 FavoriteDM := nil;
1714 if AddressHistoryDM <> nil then
1715 AddressHistoryDM.Free;
1716 AddressHistoryDM := nil;
1717 except
1718 end;
1719 //鐃緒申鐃緒申鐃緒申鐃?鐃?鐃緒申鐃緒申&鐃?鐃緒申
1720 try
1721 RoundList.SaveRoundFile;
1722 except
1723 end;
1724
1725 try
1726 RoundList.Clear;
1727 except
1728 end;
1729 try
1730 RoundList.Free;
1731 except
1732 end;
1733
1734 // TBBS 鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申 TCategory, TBoard, TThreadItem 鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申
1735 // TBoard, TThreadItem 鐃緒申鐃?鐃?鐃?鐃緒申鐃?鐃?鐃緒申鐃?鐃緒申鐃?鐃?鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申
1736 // BoardPluteIns 鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申
1737 try
1738 for i := 0 to Length( BBSs ) - 1 do begin
1739 if BBSs[ i ] <> nil then
1740 BBSs[ i ].Free;
1741 BBSs[ i ] := nil;
1742 end;
1743 except
1744 end;
1745
1746 try
1747 for i := 0 to Length( BoardPlugIns ) - 1 do begin
1748 if BoardPlugIns[ i ] <> nil then
1749 BoardPlugIns[ i ].Free;
1750 BoardPlugIns[ i ] := nil;
1751 end;
1752 except
1753 end;
1754
1755 try
1756 for i := CabinetSelectPopupMenu.Items.Count - 1 downto 0 do begin
1757 if CabinetSelectPopupMenu.Items[ i ] is TBBSMenuItem then begin
1758 CabinetSelectPopupMenu.Items[ i ].Free;
1759 CabinetMenu.Items[ i ].Free;
1760 end;
1761 end;
1762 except
1763 end;
1764
1765
1766 try
1767 //Hint鐃?鐃緒申
1768 if FHint <> nil then begin
1769 FHint.ReleaseHandle;
1770 FHint.Free;
1771 FHint := nil;
1772 end;
1773 //Preview鐃?鐃緒申
1774 if TPreviewBrowser <> nil then begin
1775 FPreviewBrowser.Free;
1776 FPreviewBrowser := nil;
1777 end;
1778 except
1779 end;
1780
1781
1782 end;
1783
1784 procedure TGikoForm.FormDestroy(Sender: TObject);
1785 begin
1786 ;
1787 end;
1788
1789 //鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃?鐃?
1790 procedure TGikoForm.FormClose(Sender: TObject; var Action: TCloseAction);
1791 begin
1792 // ListCoolBar.WindowProc := nil;
1793 // BrowserCoolBar.WindowProc := nil;
1794 // MainCoolBar.WindowProc := nil;
1795 Application.Terminate;
1796 Action := caFree;
1797 // Application.UnhookMainWindow(Hook);
1798 end;
1799
1800 //鐃?鐃緒申鐃?鐃?鐃?鐃?鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃?鐃?
1801 procedure TGikoForm.CabinetPanelHide(Sender: TObject);
1802 begin
1803 CabinetVisibleAction.Execute;
1804 // CabinetPanelVisible(false);
1805 end;
1806
1807 procedure TGikoForm.ReloadBBS;
1808 var
1809 i : Integer;
1810 item : TBBSMenuItem;
1811 begin
1812 //鐃?鐃?鐃?鐃緒申鐃?鐃?
1813 NotSelectTabCloseAction.Execute;
1814 if BrowserTab.Tabs.Count >= 1 then
1815 DeleteTab(TThreadItem(BrowserTab.Tabs.Objects[0]));
1816 //鐃?鐃?鐃?鐃緒申鐃緒申鐃?鐃?
1817 //FHistoryList.Clear;
1818 //TreeView鐃?鐃緒申鐃?鐃?BBS2ch.Free鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申XP鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃?鐃?鐃緒申鐃?
1819 TreeView.Items.Clear;
1820
1821 //BBS鐃?鐃緒申
1822 try
1823 for i := Length( BBSs ) - 1 downto 0 do begin
1824 if BBSs[ i ] <> nil then
1825 BBSs[ i ].Free;
1826 BBSs[ i ] := nil;
1827 end;
1828 except
1829 end;
1830
1831 ActiveList := nil;
1832
1833 FTreeType := gttNone;
1834
1835 GikoSys.ListBoardFile; //鐃?鐃?鐃?鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申
1836 // 鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申
1837 for i := CabinetSelectPopupMenu.Items.Count - 1 downto 0 do begin
1838 try
1839 if CabinetSelectPopupMenu.Items[ i ] is TBBSMenuItem then begin
1840 CabinetSelectPopupMenu.Items[ i ].Free;
1841 CabinetMenu.Items[ i ].Free;
1842 end;
1843 except
1844 end;
1845 end;
1846 // 鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申
1847 for i := Length( BBSs ) - 1 downto 0 do begin
1848 try
1849 item := TBBSMenuItem.Create( PopupMenu );
1850 item.Caption := BBSs[ i ].Title;
1851 item.Data := BBSs[ i ];
1852 item.OnClick := BBSMenuItemOnClick;
1853 CabinetSelectPopupMenu.Items.Insert( 0, item );
1854 item := TBBSMenuItem.Create( PopupMenu );
1855 item.Caption := BBSs[ i ].Title;
1856 item.Data := BBSs[ i ];
1857 item.OnClick := BBSMenuItemOnClick;
1858 CabinetMenu.Insert( 0, item );
1859 except
1860 end;
1861 end;
1862 ShowBBSTree( BBSs[ 0 ] );
1863
1864 // 鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1865 SaveHistory;
1866 try
1867 for i := FHistoryList.Count - 1 downto 0 do
1868 TFavoriteThreadItem( FHistoryList[ i ] ).Free;
1869 except
1870 end;
1871 FHistoryList.Clear;
1872 LoadHistory;
1873
1874 //鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
1875 // FFavorite := TFavorite.Create(FavoriteTreeView);
1876 FavoriteTreeView.Items.Clear;
1877 FavoriteDM.SetFavTreeView(FavoriteTreeView);
1878 FavoriteDM.ReadFavorite;
1879 SetLinkBar;
1880
1881 end;
1882
1883 //鐃?鐃?鐃?鐃?鐃緒申鐃?鐃緒申鐃緒申
1884 procedure TGikoForm.SetBoardTreeNode(
1885 inBBS : TBBS
1886 );
1887 var
1888 i, j, k: integer;
1889 Root: TTreeNode;
1890 CategoryNode: TTreeNode;
1891 BoardNode: TTreeNode;
1892 Category: TCategory;
1893 Board: TBoard;
1894 begin
1895 // 鐃緒申鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申
1896 FActiveBBS := inBBS;
1897 TreeView.Items.BeginUpdate;
1898 TreeView.Items.Clear;
1899 try
1900 if not inBBS.IsBoardFileRead then
1901 GikoSys.ReadBoardFile( inBBS );
1902 try
1903 if SplashWindow <> nil then
1904 SplashWindow.ProgressBar.Max := inBBS.Count;
1905 except
1906 end;
1907
1908 Root := TreeView.Items.Add( nil, inBBS.Title );
1909 Root.ImageIndex := ITEM_ICON_2CH1;
1910 Root.SelectedIndex := ITEM_ICON_2CH2;
1911 Root.Data := inBBS;
1912 for i := 0 to inBBS.Count - 1 do begin
1913 Category := TCategory(inBBS.Items[i]);
1914 CategoryNode := TreeView.Items.AddChild(Root, Category.Title);
1915 CategoryNode.Data := Category;
1916 CategoryNode.ImageIndex := ITEM_ICON_CATEGORY1;
1917 CategoryNode.SelectedIndex := ITEM_ICON_CATEGORY2;
1918
1919 for j := 0 to Category.Count - 1 do begin
1920 Board := TBoard(Category.Items[j]);
1921 Board.BeginUpdate;
1922 BoardNode := TreeView.Items.AddChild(CategoryNode, Board.Title);
1923 BoardNode.Data := Board;
1924 //if (Board.LastGetTime = 0) or (Board.LastGetTime = ZERO_DATE) then begin
1925 if not Board.IsLogFile then begin
1926 BoardNode.ImageIndex := ITEM_ICON_BOARD_NOSUBJECT;
1927 BoardNode.SelectedIndex := ITEM_ICON_BOARD_NOSUBJECT;
1928 end else begin
1929 BoardNode.ImageIndex := ITEM_ICON_BOARD1;
1930 BoardNode.SelectedIndex := ITEM_ICON_BOARD2;
1931 for k := 0 to Board.Count - 1 do begin
1932 if Board.Items[ k ].IsLogFile then begin
1933 BoardNode.ImageIndex := ITEM_ICON_BOARD_LOG;
1934 BoardNode.SelectedIndex := ITEM_ICON_BOARD_LOG;
1935
1936 Break;
1937 end;
1938 end;
1939 end;
1940 Board.EndUpdate;
1941 end;
1942
1943 CategoryNode.Expanded := Category.NodeExpand;
1944
1945 if SplashWindow <> nil then begin
1946 SplashWindow.ProgressBar.StepIt;
1947 Application.ProcessMessages;
1948 end;
1949 end;
1950 finally
1951 TreeView.Items.EndUpdate;
1952 end;
1953 end;
1954
1955 function TGikoForm.SetCategoryListItem(ABBS2ch: TBBS): Integer;
1956 const
1957 COLUMN: array[0..0] of string = ('鐃?鐃?鐃?鐃緒申鐃緒申');
1958 var
1959 ListColumn: TListColumn;
1960 i: Integer;
1961 begin
1962 ListView.Items.BeginUpdate;
1963 try
1964 Screen.Cursor := crHourGlass;
1965
1966 ListView.Columns.Clear;
1967 for i := 0 to Length(COLUMN) - 1 do begin
1968 ListColumn := ListView.Columns.Add;
1969 ListColumn.Caption := COLUMN[i];
1970 ListColumn.Width := GikoSys.Setting.BBSColumnWidth[i];
1971 end;
1972
1973 ListView.Items.Count := 0;
1974 ListView.Items.Clear;
1975 ListView.Items.Count := ABBS2ch.Count;
1976
1977 // UpFolderAction.Enabled := False;
1978 // AllItemAction.Enabled := False;
1979 // LogItemAction.Enabled := False;
1980 // NewItemAction.Enabled := False;
1981 // SelectItemAction.Enabled := False;
1982 // ListDownloadToolButton.Enabled := False;
1983 // BoardReservToolButton.Enabled := False;
1984 // ListThreadDownloadToolButton.Enabled := False;
1985
1986 ListNameLabel.Caption := ABBS2ch.Title;
1987 FolderImage.Picture := nil;
1988 ItemIcon16.GetBitmap(1, FolderImage.Picture.Bitmap);
1989
1990 FSortIndex := 0;
1991 FSortOrder := False;
1992 ListViewColumnClick(nil, ListView.Column[0]);
1993
1994 Result := ABBS2ch.Count;
1995 finally
1996 Screen.Cursor := crDefault;
1997 ListView.Items.EndUpdate;
1998 end;
1999 end;
2000
2001 function TGikoForm.SetBoardListItem(Category: TCategory): Integer;
2002 const
2003 COLUMN: array[0..2] of string = ('鐃緒申鐃緒申', '鐃緒申鐃緒申鐃?鐃緒申', '鐃緒申鐃緒申鐃緒申鐃緒申');
2004 var
2005 ListColumn: TListColumn;
2006 i: Integer;
2007 begin
2008 ListView.Items.BeginUpdate;
2009 try
2010 Screen.Cursor := crHourGlass;
2011
2012 ListView.Columns.Clear;
2013 for i := 0 to Length(COLUMN) - 1 do begin
2014 ListColumn := ListView.Columns.Add;
2015 ListColumn.Caption := COLUMN[i];
2016 ListColumn.Width := GikoSys.Setting.CategoryColumnWidth[i];
2017 end;
2018
2019 ListView.Items.Count := 0;
2020 ListView.Items.Clear;
2021 ListView.Items.Count := Category.Count;
2022
2023 // UpFolderAction.Enabled := True;
2024 // AllItemAction.Enabled := False;
2025 // LogItemAction.Enabled := False;
2026 // NewItemAction.Enabled := False;
2027 // SelectItemAction.Enabled := False;
2028 // ListDownloadToolButton.Enabled := False;
2029 // BoardReservToolButton.Enabled := False;
2030 // ListThreadDownloadToolButton.Enabled := False;
2031
2032 ListNameLabel.Caption := Category.Title;
2033 FolderImage.Picture := nil;
2034 ItemIcon16.GetBitmap(3, FolderImage.Picture.Bitmap);
2035
2036 FSortIndex := 0;
2037 FSortOrder := False;
2038 ListViewColumnClick(nil, ListView.Column[0]);
2039
2040 Result := Category.Count;
2041 finally
2042 Screen.Cursor := crDefault;
2043 ListView.Items.EndUpdate;
2044 end;
2045 end;
2046
2047 function TGikoForm.SetThreadListItem(Board: TBoard): Integer;
2048 const
2049 COLUMN: array[0..7] of string = ('鐃?鐃緒申鐃?鐃?鐃緒申', '鐃?鐃?鐃緒申鐃?', '鐃緒申鐃緒申', '鐃?鐃緒申',
2050 '鐃緒申鐃緒申', '鐃緒申鐃緒申鐃?鐃緒申', '鐃緒申鐃緒申鐃緒申鐃緒申', '鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申');
2051 COLUMN_ALIGNMENT: array[0..7] of TAlignment = (taLeftJustify, taRightJustify,
2052 taRightJustify, taRightJustify,
2053 taRightJustify, taLeftJustify,
2054 taLeftJustify, taLeftJustify);
2055 //No, 鐃?鐃緒申鐃?鐃?鐃緒申, 鐃?鐃?鐃緒申鐃?, 鐃緒申鐃緒申鐃?鐃緒申, 鐃緒申鐃緒申鐃緒申鐃緒申
2056 var
2057 ListColumn: TListColumn;
2058 i: Integer;
2059 begin
2060 ListView.Items.BeginUpdate;
2061 try
2062 Screen.Cursor := crHourGlass;
2063
2064 // 鐃?鐃緒申鐃緒申鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
2065 // 鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申
2066 if ListView.Columns.Count <> (High( COLUMN ) - Low( COLUMN ) + 1) then
2067 begin
2068 ListView.Columns.Clear;
2069 for i := 0 to Length(COLUMN) - 1 do begin
2070 ListColumn := ListView.Columns.Add;
2071 ListColumn.Caption := COLUMN[i];
2072 ListColumn.Width := GikoSys.Setting.BoardColumnWidth[i];
2073 ListColumn.Alignment := COLUMN_ALIGNMENT[i];
2074 end;
2075 end;
2076
2077 ListView.Items.Count := 0;
2078 ListView.Items.Clear;
2079
2080 case GikoForm.ViewType of
2081 gvtAll: ListView.Items.Count := Board.Count;
2082 gvtLog: ListView.Items.Count := Board.GetLogThreadCount;
2083 gvtNew: ListView.Items.Count := Board.GetNewThreadCount;
2084 gvtUser: ListView.Items.Count := Board.GetUserThreadCount;
2085 end;
2086
2087 ListNameLabel.Caption := Board.Title;
2088 FolderImage.Picture := nil;
2089 ItemIcon16.GetBitmap(5, FolderImage.Picture.Bitmap);
2090
2091 FSortIndex := 0;
2092 FSortOrder := False;
2093 ListViewColumnClick(nil, ListView.Column[0]);
2094
2095 Result := Board.Count;
2096 finally
2097 Screen.Cursor := crDefault;
2098 ListView.Items.EndUpdate;
2099 end;
2100 end;
2101
2102 procedure TGikoForm.TreeViewChange(Sender: TObject; Node: TTreeNode);
2103 var
2104 i: Integer;
2105 begin
2106 if FTreeType = gttHistory then begin
2107 if Node <> nil then
2108 if TObject( Node.Data ) is TFavoriteThreadItem then
2109 if GetActiveContent <> TFavoriteThreadItem( Node.Data ).Item then
2110 FavoriteClick( Node );
2111 Exit;
2112 end;
2113
2114 ListView.Selected := nil;
2115 ListView.Items.Count := 0;
2116 ListView.Items.Clear;
2117 // ListView.Columns.Clear;
2118
2119 Caption := CAPTION_NAME;
2120 //Application.Title := CAPTION_NAME;
2121
2122
2123 if GetActiveList is TBBS then begin
2124 for i := 0 to ListView.Columns.Count - 1 do
2125 GikoSys.Setting.BBSColumnWidth[i] := ListView.Column[i].Width;
2126 end else if GetActiveList is TCategory then begin
2127 for i := 0 to ListView.Columns.Count - 1 do
2128 GikoSys.Setting.CategoryColumnWidth[i] := ListView.Column[i].Width;
2129 end else if GetActiveList is TBoard then begin
2130 for i := 0 to ListView.Columns.Count - 1 do
2131 GikoSys.Setting.BoardColumnWidth[i] := ListView.Column[i].Width;
2132 end;
2133
2134 if TObject(Node.Data) is TBBS then begin
2135 SetActiveList(Node.data);
2136 end else if TObject(Node.Data) is TCategory then begin
2137 SetActiveList(Node.data);
2138 end else if TObject(Node.Data) is TBoard then begin
2139 if not TBoard(Node.Data).IsThreadDatRead then begin
2140 Screen.Cursor := crHourGlass;
2141 try
2142 GikoSys.ReadSubjectFile(TBoard(Node.Data));
2143 finally
2144 Screen.Cursor := crDefault;
2145 end;
2146 end;
2147 SetActiveList(Node.data);
2148 end;
2149 end;
2150
2151 procedure TGikoForm.ListViewData(Sender: TObject; Item: TListItem);
2152 var
2153 // FileName: string;
2154 // DateTime: TDateTime;
2155 BoardCnt: Integer;
2156 BBS: TBBS;
2157 Category: TCategory;
2158 Board: TBoard;
2159 ThreadItem: TThreadItem;
2160 RepStr: string;
2161 ActivListObj : TObject;
2162 begin
2163 ActivListObj := ActiveList;
2164 if ActivListObj is TBBS then begin
2165 BBS := TBBS(ActivListObj);
2166
2167 ListView.StateImages := nil;
2168
2169 if BBS = nil then Exit;
2170 if BBS.Count <= 0 then Exit;
2171 if Item = nil then Exit;
2172 if Item.Index > BBS.Count then Exit;
2173 if ListView.Items.Count = 0 then Exit;
2174
2175 if not (BBS.Items[Item.index] is TCategory) then Exit;
2176 Category := TCategory(BBS.Items[Item.index]);
2177
2178 if Category = nil then Exit;
2179
2180 if ListNumberVisibleAction.Checked then
2181 Item.Caption := IntToStr(Category.No) + ': ' + Category.Title
2182 else
2183 Item.Caption := Category.Title;
2184
2185 Item.ImageIndex := ITEM_ICON_CATEGORY1;
2186 Item.Data := Category;
2187 end else if ActivListObj is TCategory then begin
2188 Category := TCategory(ActivListObj);
2189
2190 ListView.StateImages := nil;
2191
2192 if Category = nil then Exit;
2193 if Category.Count <= 0 then Exit;
2194 if Item = nil then Exit;
2195 if Item.Index >= Category.Count then Exit;
2196 if ListView.Items.Count = 0 then Exit;
2197
2198 if not (Category.Items[Item.Index] is TBoard) then Exit;
2199 Board := TBoard(Category.Items[Item.Index]);
2200
2201 if Board = nil then Exit;
2202
2203 if ListNumberVisibleAction.Checked then
2204 Item.Caption := IntToStr(Board.No) + ': ' + Board.Title
2205 else
2206 Item.Caption := Board.Title;
2207
2208 if Item.SubItems.Count <> 2 then begin
2209 Item.SubItems.Clear;
2210 Item.SubItems.Add('');
2211 Item.SubItems.Add('');
2212 end;
2213
2214 Item.ImageIndex := ITEM_ICON_BOARD1;
2215
2216 if Board.Round then
2217 Item.SubItems[0] := Board.RoundName // '鐃?鐃緒申'
2218 else
2219 Item.SubItems[0] := '';
2220
2221 if Board.RoundDate = ZERO_DATE then begin
2222 Item.SubItems[1] := '';
2223 end else
2224 Item.SubItems[1] := FormatDateTime('yyyy/mm/dd hh:mm:ss', Board.RoundDate);
2225 Item.Data := Board;
2226 end else if ActivListObj is TBoard then begin
2227 Board := TBoard(ActivListObj);
2228
2229 if GikoSys.Setting.ListIconVisible then
2230 ListView.StateImages := StateIconImageList
2231 else
2232 ListView.StateImages := nil;
2233
2234 case GikoForm.ViewType of
2235 gvtAll: BoardCnt := Board.Count;
2236 gvtLog: BoardCnt := Board.GetLogThreadCount;
2237 gvtNew: BoardCnt := Board.GetNewThreadCount;
2238 gvtUser: BoardCnt := Board.GetUserThreadCount;
2239 else
2240 BoardCnt := 0;
2241 end;
2242
2243 // if Board = nil then Exit;
2244 if BoardCnt <= 0 then Exit;
2245 if Item = nil then Exit;
2246 if Item.Index > BoardCnt then Exit;
2247 if ListView.Items.Count = 0 then Exit;
2248
2249 // if not (Board.Items[Item.Index] is TThreadItem) then Exit;
2250
2251 ThreadItem := nil;
2252 case GikoForm.ViewType of
2253 gvtAll: ThreadItem := TThreadItem(Board.Items[Item.Index]);
2254 gvtLog: ThreadItem := Board.GetLogThread(Item.Index);
2255 gvtNew: ThreadItem := Board.GetNewThread(Item.Index);
2256 gvtUser: ThreadItem := Board.GetUserThread(Item.Index);
2257 end;
2258
2259 if ThreadItem = nil then Exit;
2260
2261 // if ListNumberVisibleAction.Checked then
2262 // RepStr := IntToStr(ThreadItem.No) + ': ' + ThreadItem.Title
2263 // else
2264 RepStr := ThreadItem.Title;
2265 RepStr := CustomStringReplace(RepStr, '&lt;', '<' );
2266 RepStr := CustomStringReplace(RepStr, '&gt;', '>' );
2267 RepStr := CustomStringReplace(RepStr, '&quot;', '"' );
2268 RepStr := CustomStringReplace(RepStr, '&amp;', '&' );
2269 //RepStr := StringReplace(RepStr, '鐃緒申鐃?', ',', [rfReplaceAll]);
2270
2271 if Item.SubItems.Count <> 7 then begin
2272 Item.SubItems.Clear;
2273 Item.SubItems.Add('');
2274 Item.SubItems.Add('');
2275 Item.SubItems.Add('');
2276 Item.SubItems.Add('');
2277 Item.SubItems.Add('');
2278 Item.SubItems.Add('');
2279 Item.SubItems.Add('');
2280 end;
2281
2282 if ListNumberVisibleAction.Checked then
2283 Item.Caption := IntToStr(ThreadItem.No) + ': ' + RepStr
2284 else
2285 Item.Caption := RepStr;
2286
2287 case ThreadItem.AgeSage of
2288 gasNone: Item.StateIndex := -1;
2289 gasNew: Item.StateIndex := 0;
2290 gasAge: Item.StateIndex := 1;
2291 gasSage: Item.StateIndex := 2;
2292 end;
2293
2294 if ThreadItem.IsLogFile then begin
2295 Item.ImageIndex := ITEM_ICON_THREADLOG1;
2296 Item.SubItems[0] := IntToStr(ThreadItem.AllResCount);
2297 Item.SubItems[1] := IntToStr(ThreadItem.Count);
2298 if ThreadItem.NewResCount = 0 then
2299 Item.SubItems[2] := ''
2300 else
2301 Item.SubItems[2] := IntToStr(ThreadItem.NewResCount);
2302 Item.SubItems[3] := '';
2303 if ThreadItem.Round then
2304 Item.SubItems[4] := ThreadItem.RoundName
2305 else
2306 Item.SubItems[4] := '';
2307 if ThreadItem.RoundDate = ZERO_DATE then begin
2308 Item.SubItems[5] := '';
2309 end else
2310 Item.SubItems[5] := FormatDateTime('yyyy/mm/dd hh:mm:ss', ThreadItem.RoundDate);
2311 if ThreadItem.NewArrival then
2312 Item.ImageIndex := ITEM_ICON_THREADNEW1;
2313 if ThreadItem.CreateDate = ZERO_DATE then begin
2314 Item.SubItems[6] := '';
2315 end else
2316 Item.SubItems[6] := FormatDateTime('yyyy/mm/dd hh:mm:ss', ThreadItem.CreateDate);
2317
2318 end else begin
2319 Item.ImageIndex := ITEM_ICON_THREAD1;
2320 Item.SubItems[0] := IntToStr(ThreadItem.AllResCount);
2321 Item.SubItems[1] := '';
2322 Item.SubItems[2] := '';
2323 Item.SubItems[3] := '';
2324 Item.SubItems[4] := '';
2325 Item.SubItems[5] := '';
2326 if not GikoSys.Setting.CreationTimeLogs then
2327 if ThreadItem.CreateDate = ZERO_DATE then
2328 Item.SubItems[6] := ''
2329 else
2330 Item.SubItems[6] := FormatDateTime('yyyy/mm/dd hh:mm:ss', ThreadItem.CreateDate);
2331
2332 end;
2333
2334 Item.Data := ThreadItem;
2335 end;
2336 end;
2337
2338 procedure TGikoForm.ListViewDataFind(Sender: TObject; Find: TItemFind;
2339 const FindString: String; const FindPosition: TPoint; FindData: Pointer;
2340 StartIndex: Integer; Direction: TSearchDirection; Wrap: Boolean;
2341 var Index: Integer);
2342 begin
2343
2344 //
2345 end;
2346
2347 procedure TGikoForm.ListViewDataHint(Sender: TObject; StartIndex,
2348 EndIndex: Integer);
2349 begin
2350 //
2351 end;
2352
2353 procedure TGikoForm.ListViewDataStateChange(Sender: TObject; StartIndex,
2354 EndIndex: Integer; OldState, NewState: TItemStates);
2355 begin
2356 //
2357 end;
2358
2359 procedure TGikoForm.BrowserStatusTextChange(Sender: TObject; const Text: WideString);
2360 var
2361 p: TPoint;
2362 s: string;
2363 tmp2: string;
2364 URL: string;
2365 ATitle: Boolean;
2366
2367 threadItem : TThreadItem;
2368 board : TBoard;
2369 Protocol, Host, Path, Document, Port, Bookmark: string;
2370
2371 //wkInt: Integer;
2372 wkIntSt: Integer;
2373 wkIntTo: Integer;
2374 ActiveFileName: string;
2375 e: IHTMLElement;
2376 Ext: string;
2377 buf: string;
2378 PathRec: TPathRec;
2379 begin
2380 try
2381 try
2382 if (FActiveContent <> nil) and (Assigned(Browser.Document)) then begin
2383 if LowerCase(OleVariant(IHTMLDocument2(Browser.Document)).charset) <> 'shift_jis' then
2384 OleVariant(IHTMLDocument2(Browser.Document)).charset := 'shift_jis';
2385 end;
2386 except
2387 end;
2388 finally
2389 end;
2390 if PreviewTimer.Enabled then
2391 PreviewTimer.Enabled := False;
2392 Application.CancelHint;
2393 if GetActiveContent <> nil then
2394 ActiveFileName := ChangeFileExt(ExtractFileName(GetActiveContent.FileName), '')
2395 else
2396 ActiveFileName := '';
2397
2398 StatusBar.Panels[1].Text := Text;
2399
2400 if FHint <> nil then begin
2401 FHint.ReleaseHandle;
2402 FHint.ClearAllRes;
2403 end;
2404 if FPreviewBrowser <> nil then
2405 ShowWindow(FPreviewBrowser.Handle, SW_HIDE);
2406
2407 if not GikoSys.Setting.UnActivePopup then
2408 if not GikoForm.Active then
2409 Exit;
2410
2411 //file:///C:/Borland/Projects/gikoNavi/test/read.cgi/qa/990576336/10
2412 //file:///C:/Borland/Projects/gikoNavi/test/read.cgi/qa/990576336/10-15
2413
2414 s := '';
2415 Ext := AnsiLowerCase(ExtractFileExt(Text));
2416 if (Pos('http://', Text) = 1) and (GikoSys.Setting.PreviewVisible) and
2417 ((Ext = '.jpg') or (Ext = '.jpeg') or (Ext = '.gif') or (Ext = '.png')) then begin
2418 if FPreviewBrowser = nil then begin
2419 FPreviewBrowser := TPreviewBrowser.Create(Self);
2420 ShowWindow(FPreviewBrowser.Handle, SW_HIDE);
2421 TOleControl(FPreviewBrowser).Parent := nil;
2422 end;
2423 FPreviewBrowser.Navigate('about:blank');//鐃?鐃緒申鐃緒申鐃?鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃?
2424 FPreviewURL := Text;
2425 PreviewTimer.Interval := GikoSys.Setting.PreviewWait;
2426 PreviewTimer.Enabled := True;
2427 end else if (Pos('about:blank', Text) = 1) or (Pos('http://', Text) = 1) or (Pos('mailto:', Text) = 1) then begin
2428 if Pos('mailto:', Text) = 1 then begin
2429 s := StringReplace(Text, 'mailto:', '', [rfIgnoreCase]);
2430 //鐃?鐃?鐃?鐃?鐃?鐃緒申 鐃?鐃?鐃?3鐃緒申466鐃緒申鐃緒申鐃緒申鐃緒申
2431 GetCursorPos(p);
2432 p.x := p.x - TWebBrowser(Sender).ClientOrigin.x;
2433 p.y := p.y - TWebBrowser(Sender).ClientOrigin.y;
2434 e := IHTMLDocument2(TWebBrowser(Sender).Document).elementFromPoint(p.x, p.y);
2435 if (Assigned(e)) then begin
2436 tmp2 := GikoSys.ZenToHan(e.Get_outerText);
2437 if (GikoSys.IsNumeric(tmp2)) then begin
2438 //鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?
2439 wkIntSt := StrToInt(tmp2);
2440 wkIntTo := StrToInt(tmp2);
2441 //s := GetThreadText(wkBBS, wkKey, wkIntSt, wkIntTo, False, False);
2442 FHint.PopupType := gptThread;
2443 SetResPopupText(GetActiveContent, wkIntSt, wkIntTo, False, False);
2444 end else begin
2445 FHint.PopupType := gptRaw;
2446 FHint.Caption := s;
2447 end;
2448 end;
2449 end else begin
2450 URL := Text;
2451
2452 if Pos('about:blank..', URL) = 1 then begin
2453 threadItem := GetActiveContent;
2454 if AnsiPos('http://jbbs.shitaraba.com/', threadItem.URL) <> 0 then begin
2455 URL := Copy(threadItem.URL, 1, LastDelimiter('/',threadItem.URL));
2456 Gikosys.GetPopupResNumber(Text,PathRec.FSt,PathRec.FTo);
2457 if ( PathRec.FSt <> 0 ) and ( PathRec.FTo <> 0 ) then
2458 buf := IntToStr(PathRec.FSt) + '-' + IntToStr(PathRec.FTo)
2459 else if( PathRec.FSt <> 0 ) then
2460 buf := IntToStr(PathRec.FSt);
2461 end else if AnsiPos('machi.to/bbs/', threadItem.URL) <> 0 then begin
2462 URL := threaditem.URL;
2463 buf := Copy(Text,AnsiPos('&st=',Text),Length(Text)-AnsiPos('&st=',Text) + 1);
2464 end else begin
2465
2466 URL := Copy(threadItem.URL, 1, LastDelimiter('/',threadItem.URL));
2467 buf := Copy(Text,LastDelimiter('/',Text)+1,Length(Text)-LastDelimiter('/',Text));
2468 end;
2469 URL := URL + buf;
2470 end;
2471 PathRec := Gikosys.Parse2chURL2(URL);
2472 Gikosys.GetPopupResNumber(URL,PathRec.FSt,PathRec.FTo);
2473 GikoSys.ParseURI( URL, Protocol, Host, Path, Document, Port, Bookmark );
2474
2475 if PathRec.FDone or (not GikoSys.Is2chHost( Host )) then begin
2476
2477 URL := GikoSys.GetBrowsableThreadURL( URL );
2478 wkIntSt := PathRec.FSt;
2479 wkIntTo := PathRec.FTo;
2480
2481 if (wkIntSt = 0) and (wkIntTo = 0) then begin
2482 wkIntSt := 1;
2483 wkIntTo := 1;
2484 end else if (wkIntSt = 0) and (wkIntTo > 0) then begin
2485 wkIntSt := wkIntTo;
2486 end else if (wkIntSt > 0) and (wkIntTo = 0) then begin
2487 wkIntTo := wkIntSt;
2488 end else if wkIntSt > wkIntTo then begin
2489 //wkInt := wkIntTo;
2490 wkIntTo := wkIntSt;
2491 wkIntSt := wkIntTo;
2492 end;
2493 //if wkIntSt = 0 then
2494 // wkIntSt := 1;
2495 //if wkINtTo = 0 then
2496 // wkIntTo := 1;
2497 //if PathRec.FFirst then
2498 // wkIntSt := 1;
2499 if PathRec.FStBegin then
2500 wkIntSt := 1;
2501 if PathRec.FToEnd then
2502 wkIntTo := 9999;
2503
2504 //ATitle := ActiveFileName <> PathRec.FKey;
2505 if GetActiveContent.URL = URL then
2506 ATitle := false
2507 else
2508 ATitle := true;
2509
2510 threadItem := BBSsFindThreadFromURL( URL );
2511
2512 if (threadItem = nil) and GikoSys.Is2chHost( Host ) then begin
2513 board := BBSs[ 0 ].FindBBSID( PathRec.FBBS );
2514 if board <> nil then
2515 threadItem := board.Find( PathRec.FKey + '.dat' );
2516
2517 end;
2518
2519 if threadItem <> nil then begin
2520 //HintData := GetThreadText(PathRec.FBBS, PathRec.FKey, wkIntSt, wkIntTo, ATitle, PathRec.FFirst);
2521 FHint.PopupType := gptThread;
2522 SetResPopupText( threadItem, wkIntSt, wkIntTo, ATitle, PathRec.FFirst );
2523 end;
2524 end;
2525 end;
2526
2527 //if s <> '' then
2528 // ShowTextPopup(s);
2529 if FHint.PopupType = gptRaw then begin
2530 if FHint.Caption <> '' then
2531 ShowTextPopup;
2532 end else begin
2533 if (FHint.ResCount <> 0) or (FHint.Title <> '') then
2534 ShowTextPopup;
2535 end;
2536 end;
2537 end;
2538
2539 procedure TGikoForm.BrowserTitleChange(Sender: TObject;
2540 const Text: WideString);
2541 var
2542 Title: string;
2543 begin
2544 if (Text = BLANK_HTML) or (Text = GikoSys.GetHtmlTempFileName) then
2545 Title := CAPTION_NAME
2546 else
2547 Title := CAPTION_NAME + ' - [' + Text + ']';
2548 Caption := Title;
2549 //Application.Title := Title;
2550 end;
2551
2552 procedure TGikoForm.SetEnabledCloseButton(Enabled: Boolean);
2553 var
2554 SysMenu: HMenu;
2555 //SysMenuApp: HMenu;
2556 begin
2557 FEnabledCloseButton := Enabled;
2558 SysMenu := GetSystemMenu(Handle, False);
2559 //SysMenuApp := GetSystemMenu(Application.Handle, False);
2560
2561 if Enabled then begin
2562 EnableMenuItem(SysMenu, SC_CLOSE, MF_BYCOMMAND or MF_ENABLED);
2563 //EnableMenuItem(SysMenuApp, SC_CLOSE, MF_BYCOMMAND or MF_ENABLED);
2564 end else begin
2565 EnableMenuItem(SysMenu, SC_CLOSE, MF_BYCOMMAND or MF_GRAYED);
2566 //EnableMenuItem(SysMenuApp, SC_CLOSE, MF_BYCOMMAND or MF_GRAYED);
2567 end;
2568
2569 DrawMenuBar(Handle);
2570 //DrawMenuBar(Application.Handle);
2571 end;
2572
2573 procedure TGikoForm.TreeViewChanging(Sender: TObject; Node: TTreeNode;
2574 var AllowChange: Boolean);
2575 begin
2576 if FTreeType = gtt2ch then
2577 FSortIndex := -1;
2578 end;
2579
2580 procedure TGikoForm.ListViewKeyDown(Sender: TObject; var Key: Word;
2581 Shift: TShiftState);
2582 begin
2583 if Key = VK_BACK then begin
2584 // UpFolderButtonClick(Sender);
2585 end else if Key = VK_SPACE then begin
2586 // ListClick;
2587 end else if Key = VK_RETURN then begin
2588 ListDoubleClick;
2589 end;
2590 end;
2591
2592 function TGikoForm.GetHttpState: Boolean;
2593 begin
2594 Result := FHttpState;
2595 end;
2596
2597 procedure TGikoForm.ListViewColumnClick(Sender: TObject;
2598 Column: TListColumn);
2599 var
2600 i: Integer;
2601 wkBBS: TBBS;
2602 wkCategory: TCategory;
2603 wkBoard: TBoard;
2604 begin
2605 if FSortIndex = Column.Index then
2606 FSortOrder := not FSortOrder
2607 else
2608 FSortOrder := False;
2609
2610 for i := 0 to ListView.Columns.Count - 1 do
2611 ListView.Column[i].ImageIndex := -1;
2612 if FSortOrder then
2613 ListView.Column[Column.Index].ImageIndex := ITEM_ICON_SORT1
2614 else
2615 ListView.Column[Column.Index].ImageIndex := ITEM_ICON_SORT2;
2616
2617 Sort.SortNoFlag := ListNumberVisibleAction.Checked;
2618
2619 //if TObject(TreeView.Selected.Data) is TBBS then begin
2620 if TObject( FActiveList ) is TBBS then begin
2621 //wkBBS := TBBS(TreeView.Selected.Data);
2622 wkBBS := TBBS( FActiveList );
2623 Sort.SortOrder := FSortOrder;
2624 Sort.SortIndex := Column.Index;
2625 wkBBS.Sort(CategorySortProc);
2626 ListView.Refresh;
2627 //end else if TObject(TreeView.Selected.Data) is TCategory then begin
2628 end else if TObject( FActiveList ) is TCategory then begin
2629 //wkCategory := TCategory(TreeView.Selected.Data);
2630 wkCategory := TCategory( FActiveList );
2631 Sort.SortOrder := FSortOrder;
2632 Sort.SortIndex := Column.Index;
2633 wkCategory.Sort(BoardSortProc);
2634 ListView.Refresh;
2635 //end else if TObject(TreeView.Selected.Data) is TBoard then begin
2636 end else if TObject( FActiveList ) is TBoard then begin
2637 //wkBoard := TBoard(TreeView.Selected.Data);
2638 wkBoard := TBoard( FActiveList );
2639 Sort.SortOrder := FSortOrder;
2640 Sort.SortIndex := Column.Index;
2641 wkBoard.Sort(ThreadItemSortProc);
2642 ListView.Refresh;
2643 end;
2644 FSortIndex := Column.Index;
2645 end;
2646
2647 procedure TGikoForm.MenuToolBarCustomDrawButton(Sender: TToolBar;
2648 Button: TToolButton; State: TCustomDrawState; var DefaultDraw: Boolean);
2649 var
2650 ARect: TRect;
2651 begin
2652 DefaultDraw := True;
2653 Exit;
2654 DefaultDraw := False;
2655 if (cdsSelected in State) or (cdsHot in State) then begin
2656 Sender.Canvas.Brush.Color := clHighlight;
2657 Sender.Canvas.Font.Color := clHighlightText;
2658 end else begin
2659 Sender.Canvas.Brush.Color := clBtnFace;
2660 Sender.Canvas.Font.Color := clBtnText;
2661 end;
2662 ARect := Rect(Button.Left, Button.Top, Button.Left + Button.Width, Button.Top + Button.Height);
2663 Sender.Canvas.FillRect(ARect);
2664 DrawText(Sender.Canvas.Handle, PChar(Button.Caption), -1, ARect, DT_SINGLELINE or DT_VCENTER or DT_CENTER);
2665 end;
2666
2667 function TGikoForm.GetTreeNode(Data: TObject): TTreeNode;
2668 var
2669 Nodes: TTreeNodes;
2670 i: integer;
2671 begin
2672 Nodes := TreeView.Items;
2673
2674 for i := 0 to Nodes.Count - 1 do begin
2675 if Nodes.Item[i].Data = Data then begin
2676 Result := Nodes.Item[i];
2677 Exit;
2678 end;
2679 end;
2680 Result := nil;
2681 end;
2682
2683 procedure TGikoForm.BrowserBeforeNavigate2(Sender: TObject;
2684 const pDisp: IDispatch; var URL, Flags, TargetFrameName, PostData,
2685 Headers: OleVariant; var Cancel: WordBool);
2686 var
2687 sNo: string;
2688 p: TPoint;
2689 const
2690 kMenuName: string = 'menu:';
2691 begin
2692
2693 if Pos(kMenuName, URL) <> 0 then begin
2694 sNo := Copy( URL, Pos( kMenuName, URL ) + Length( kMenuName ), Length( URL ) );
2695
2696 if not GikoSys.IsNumeric(sNo) then Exit;
2697
2698 Cancel := True;
2699 GetCursorpos(p);
2700 KokoPopupMenu.Tag := StrToInt(sNo);
2701 KokoPopupMenu.Popup(p.x, p.y);
2702 end else if Pos('mailto', LowerCase(URL)) <> 0 then begin
2703 Cancel := not GikoSys.Setting.OpenMailer;
2704 end;
2705
2706 end;
2707
2708 procedure TGikoForm.ListViewAdvancedCustomDrawItem(Sender: TCustomListView;
2709 Item: TListItem; State: TCustomDrawState; Stage: TCustomDrawStage;
2710 var DefaultDraw: Boolean);
2711 var
2712 ThreadItem: TThreadItem;
2713 begin
2714 //
2715 // TListView(Sender).Canvas.Font.Style := [];
2716 if TObject(Item.Data) is TThreadItem then begin
2717 ThreadItem := TThreadItem(Item.Data);
2718 if ( FUseOddResOddColor ) and ( ThreadItem.Count <> 0 ) and ( ThreadItem.AllResCount <> ThreadItem.Count) then begin
2719 ListView.Canvas.Brush.Color := FOddColor;
2720 end else begin
2721 ListView.Canvas.Brush.Color := FListViewBackGroundColor;
2722 end;
2723 // if (ThreadItem.Kokomade <> ThreadItem.Count) and (ThreadItem.IsLogFile) then
2724 if ThreadItem.UnRead then
2725 TListView(Sender).Canvas.Font.Style := [fsBold];
2726 end;
2727 end;
2728
2729 procedure TGikoForm.AppFormDeactivate(Sender: TObject);
2730 begin
2731 if Application.Terminated then
2732 Exit;
2733 if PreviewTimer.Enabled then
2734 PreviewTimer.Enabled := False;
2735 //鐃?鐃?鐃?鐃?鐃?鐃緒申鐃緒申鐃緒申鐃?鐃?鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃緒申鐃?鐃緒申鐃?鐃緒申鐃緒申鐃緒申
2736 if FHint <> nil then begin
2737 FHint.ReleaseHandle;
2738 FHint.ClearAllRes;
2739 // FHint.Free;
2740 // FHint := nil;
2741 end;
2742 if FPreviewBrowser <> nil then
2743 ShowWindow(FPreviewBrowser.Handle, SW_HIDE);
2744
2745 end;
2746
2747 procedure TGikoForm.TreeViewCustomDraw(Sender: TCustomTreeView;
2748 const ARect: TRect; var DefaultDraw: Boolean);
2749 var
2750 NodeRect: TRect;
2751 i, j: Integer;
2752 IsBoardNode: Boolean;
2753 Cnt: Integer;
2754 CntText: string;
2755 TextWidth: Integer;
2756 TextRect: TRect;
2757 Board: TBoard;
2758 Category: TCategory;
2759 Bitmap: TBitmap;
2760 NodeWidth: Integer;
2761 begin
2762 DefaultDraw := True;
2763
2764 if FTreeType = gttHistory then Exit;
2765
2766 TreeView.Canvas.Font.Color := clBlue;
2767 IsBoardNode := False;
2768 for i := 0 to TreeView.Items.Count - 1 do begin
2769 Cnt := 0;
2770 if not TreeView.Items[i].IsVisible then
2771 continue;
2772
2773 if TObject(TreeView.Items[i].Data) is TCategory then begin
2774 if TreeView.Items[i].Expanded then
2775 continue;
2776
2777 IsBoardNode := False;
2778 Category := TCategory(TreeView.Items[i].Data);
2779 for j := 0 to Category.Count - 1 do begin
2780 Board := Category.Items[j];
2781 if Board <> nil then begin
2782 if Board.UnRead > 0 then begin
2783 Cnt := 1;
2784 Break;
2785 end;
2786 end;
2787 end;
2788 if Cnt <> 1 then
2789 continue;
2790 end else if TObject(TreeView.Items[i].Data) is TBoard then begin
2791 IsBoardNode := True;
2792 Board := TBoard(TreeView.Items[i].Data);
2793 Cnt := Board.UnRead;
2794 if Cnt <= 0 then
2795 continue;
2796 end else
2797 continue;
2798
2799 Bitmap := TBitmap.Create;
2800 try
2801 Bitmap.Canvas.Font.Assign(TreeView.Canvas.Font);
2802 Bitmap.Canvas.Font.Style := [fsBold];
2803 NodeWidth := Bitmap.Canvas.TextWidth(TreeView.Items[i].Text);
2804 finally
2805 Bitmap.Free;
2806 end;
2807
2808 NodeRect := TreeView.Items[i].DisplayRect(True);
2809
2810 if IsBoardNode then
2811 CntText := '(' + IntToStr(Cnt) + ')'
2812 else if Cnt = 1 then
2813 CntText := '(+)';
2814
2815
2816 TextWidth := TreeView.Canvas.TextWidth(CntText);
2817
2818 TextRect := Rect(NodeRect.Left + NodeWidth + 8,
2819 NodeRect.Top,
2820 NodeRect.Left + NodeWidth + TextWidth + 8,
2821 NodeRect.Bottom);
2822 DrawText(TreeView.Canvas.Handle,
2823 PChar(CntText),
2824 -1,
2825 TextRect,
2826 DT_SINGLELINE or DT_VCENTER);
2827 end;
2828 TreeViewCustomDrawItem(nil, nil, [], DefaultDraw);
2829 end;
2830
2831 procedure TGikoForm.TreeViewCustomDrawItem(Sender: TCustomTreeView;
2832 Node: TTreeNode; State: TCustomDrawState; var DefaultDraw: Boolean);
2833 var
2834 Board: TBoard;
2835 Category: TCategory;
2836 i: Integer;
2837 begin
2838 DefaultDraw := True;
2839
2840 if FTreeType = gttHistory then Exit;
2841
2842 TreeView.Canvas.Font.Style := [];
2843 if Node <> nil then begin
2844 if TObject(Node.Data) is TCategory then begin
2845 Category := TCategory(Node.Data);
2846 for i := 0 to Category.Count - 1 do begin
2847 Board := Category.Items[i];
2848 if Board <> nil then begin
2849 if Board.UnRead > 0 then begin
2850 TreeView.Canvas.Font.Style := [fsBold];
2851 Break;
2852 end;
2853 end;
2854 end;
2855 end else if TObject(Node.Data) is TBoard then begin
2856 Board := TBoard(Node.Data);
2857 if Board.UnRead > 0 then
2858 TreeView.Canvas.Font.Style := [fsBold];
2859 end;
2860 end;
2861 end;
2862
2863 procedure TGikoForm.TreeViewExpanded(Sender: TObject; Node: TTreeNode);
2864 begin
2865 TreeView.Invalidate;
2866
2867 if TObject(Node.Data) is TBBS then begin
2868 TBBS(Node.Data).NodeExpand := True;
2869 end else if TObject(Node.Data) is TCategory then begin
2870 TCategory(Node.Data).NodeExpand := True;
2871 end else if TObject(Node.Data) is TBoard then begin
2872 TBoard(Node.Data).NodeExpand := True;
2873 end;
2874 end;
2875
2876 {procedure TGikoForm.CabinetPanelVisible(PanelVisible: Boolean);
2877 begin
2878 TreeSplitter.Visible := PanelVisible;
2879 CabinetPanel.Visible := PanelVisible;
2880 CabinetToolButton.Down := PanelVisible;
2881 end;}
2882
2883 procedure TGikoForm.ListViewAllSelect;
2884 begin
2885 ListView.SetFocus;
2886 ListView.SelectAll;
2887 end;
2888
2889 procedure TGikoForm.TreeViewDblClick(Sender: TObject);
2890 var
2891 Board: TBoard;
2892 ThreadItem: TThreadItem;
2893 APoint: TPoint;
2894 HitTest: THitTests;
2895 begin
2896 GetCursorPos(APoint);
2897 APoint := TreeView.ScreenToClient(APoint);
2898 HitTest := TreeView.GetHitTestInfoAt(APoint.x, APoint.y);
2899 if not (htOnLabel in HitTest) then Exit;
2900 if TreeView.Selected = nil then Exit;
2901
2902 if FTreeType = gtt2ch then begin
2903 if not (TObject(TreeView.Selected.Data) is TBoard) then Exit;
2904 Board := TBoard(TreeView.Selected.Data);
2905 DownloadList(Board);
2906 end else if FTreeType = gttHistory then begin
2907 if not (TObject(TreeView.Selected.Data) is TFavoriteThreadItem) then Exit;
2908 ThreadItem := TFavoriteThreadItem(TreeView.