PROTOCOL_HTTP : string = 'http://';
//! \83M\83R\83i\83r\83T\83C\83g\82ÌURL
URL_GIKONAVI: string = 'gikonavi.sourceforge.jp/';
+ //! \83M\83R\83i\83r(\94ð\93ï\8f\8a\94Å)\83T\83C\83g\82ÌURL
+ URL_GIKONAVIGO: string = 'gikonavigoeson.sourceforge.jp/';
//! Monazilla\83T\83C\83g\82ÌURL
URL_MONAZILLA: string = 'www.monazilla.org/';
//! 2\82¿\82á\82ñ\82Ë\82é\82ÌURL
URL_2ch: string = 'www.2ch.net/';
//! \83M\83R\83i\83rWiki\82ÌURL
- URL_Wiki: string = 'gikowiki.dyndns.info/index.php?FAQ';
+ URL_Wiki: string = 'sourceforge.jp/projects/gikonavi/wiki/FAQ';
+ //! \83M\83R\83i\83r(\94ð\93ï\8f\8a\94Å)Wiki\82ÌURL
+ URL_GoWiki: string = 'sourceforge.jp/projects/gikonavigoeson/wiki/FAQ';
SELECTCOMBOBOX_NAME: string = ''; // '\83X\83\8c\83b\83h\8di\8d\9e\8c\9f\8dõ';
SELECTCOMBOBOX_COLOR: TColor = clWindow;
NewLinkToClipboardAction: TAction;
AddIDtoNGWord0Action: TAction;
AddIDtoNGWord1Action: TAction;
+ ExtractSameIDAction: TAction;
+ ShowTabListAction: TAction;
+ DereferenceResAction: TAction;
+ UpdateGikonaviAction: TAction;
+ konoURLPATHAction: TAction;
+ konoURLQueryAction: TAction;
+ PopupMenuSettingAction: TAction;
+ GikoNaviGoesonWebPageAction: TAction;
+ GoWikiFAQWebPageAction: TAction;
+ ThreadSearchAction: TAction;
+ ThreadNgEditAction: TAction;
procedure EditNGActionExecute(Sender: TObject);
procedure ReloadActionExecute(Sender: TObject);
procedure GoFowardActionExecute(Sender: TObject);
procedure TabsSaveActionExecute(Sender: TObject);
procedure TabsOpenActionExecute(Sender: TObject);
procedure BeLogInOutActionExecute(Sender: TObject);
- procedure BeLogInOutActionUpdate(Sender: TObject);
procedure KokomadeActionExecute(Sender: TObject);
procedure ZenbuActionExecute(Sender: TObject);
procedure KokoResActionExecute(Sender: TObject);
procedure NewLinkToClipboardActionExecute(Sender: TObject);
procedure AddIDtoNGWord0ActionExecute(Sender: TObject);
procedure AddIDtoNGWord1ActionExecute(Sender: TObject);
+ procedure ExtractSameIDActionExecute(Sender: TObject);
+ procedure ShowTabListActionExecute(Sender: TObject);
+ procedure DereferenceResActionExecute(Sender: TObject);
+ procedure UpdateGikonaviActionExecute(Sender: TObject);
+ procedure konoURLPATHActionExecute(Sender: TObject);
+ procedure konoURLQueryActionExecute(Sender: TObject);
+ procedure konoURLQueryActionUpdate(Sender: TObject);
+ procedure PopupMenuSettingActionExecute(Sender: TObject);
+ procedure GikoNaviGoesonWebPageActionExecute(Sender: TObject);
+ procedure GoWikiFAQWebPageActionExecute(Sender: TObject);
+ procedure ThreadSearchActionExecute(Sender: TObject);
+ procedure ThreadNgEditActionExecute(Sender: TObject);
private
{ Private \90é\8c¾ }
procedure ClearResFilter;
procedure ClearSelectComboBox;
procedure ClearMailAllEditor();
procedure ClearNameTextAllEditor();
- procedure MoveURLWithHistory(URL : String);
+// procedure MoveURLWithHistory(URL : String; KeyMask: Boolean = False);
procedure BackToHistory(item: TMoveHistoryItem);
function GetActiveThreadLinks : IHTMLElementCollection;
procedure GetLinkURLs(links : IHTMLElementCollection;
function EditorFormExists(): boolean;
procedure GetTabURLs(AStringList: TStringList);
procedure OpenURLs(AStringList: TStringList);
+ procedure MoveURLWithHistory(URL : String; KeyMask: Boolean = False);
+ procedure SaveThreadSearchSetting;
published
{ Published \90é\8c¾ }
//! TAction\82ÅGetActiveContent\82ªnil\88È\8aO\82Å\97L\8cø\82É\82È\82é
procedure DependActiveCntentActionUpdate(Sender: TObject);
//! TAction\82ÅGetActiveContent\82ªnil\88È\8aO\82©\82Â\83\8d\83O\82ð\8e\9d\82Á\82Ä\82¢\82é\82Æ\97L\8cø\82É\82È\82é
procedure DependActiveCntentLogActionUpdate(Sender: TObject);
- //! TAction\82ÅActiveList\82ªTBoard\82Å\97L\8cø\82É\82È\82é
+ //! TAction\82ÅActiveList\82ªTBoard(\94ñ\93Á\8eê\94Â)\82Å\97L\8cø\82É\82È\82é
procedure DependActiveListTBoardActionUpdate(Sender: TObject);
+ //! TAction\82ÅActiveList\82ªTBoard\82Å\97L\8cø\82É\82È\82é
+ procedure DependActiveListTBoardWithSpeciapActionUpdate(Sender: TObject);
end;
var
GikoBayesian, About, ShellAPI,
RoundName, RoundData, Menus, ListViewUtils,
ThreadControl, GikoMessage, InputAssist,
- DefaultFileManager, Forms, NewBoardURL;
+ DefaultFileManager, Forms, NewBoardURL, UpdateCheck,
+ PopupMenuSetting, ThreadSearch, ThreadNGEdt;
const
MSG_ERROR : string = '\83G\83\89\81[';
and (GikoForm.GetActiveContent.IsLogFile);
end;
// *************************************************************************
-//! TAction\82ÅActiveList\82ªTBoard\82Å\97L\8cø\82É\82È\82é
+//! TAction\82ÅActiveList\82ªTBoard(\94ñ\93Á\8eê\94Â)\82Å\97L\8cø\82É\82È\82é
// *************************************************************************
procedure TGikoDM.DependActiveListTBoardActionUpdate(Sender: TObject);
begin
+ TAction(Sender).Enabled := (GikoForm.GetActiveList is TBoard) and
+ (GikoForm.GetActiveList <> BoardGroup.SpecialBoard);
+end;
+// *************************************************************************
+//! TAction\82ÅActiveList\82ªTBoard\82Å\97L\8cø\82É\82È\82é
+// *************************************************************************
+procedure TGikoDM.DependActiveListTBoardWithSpeciapActionUpdate(Sender: TObject);
+begin
TAction(Sender).Enabled := (GikoForm.GetActiveList is TBoard);
end;
// *************************************************************************
procedure TGikoDM.EditNGActionExecute(Sender: TObject);
begin
//\83e\83L\83X\83g\82É\8aÖ\98A\95t\82¯\82ç\82ê\82½\83A\83v\83\8a\82ÅNG\83\8f\81[\83h\83t\83@\83C\83\8b\82ð\83I\81[\83v\83\93
- GikoSys.FAbon.EditNGwords;
+ if (GikoSys.FAbon.EditNGwords(GikoForm) = True) then
+ ReloadAction.Execute;
end;
// *************************************************************************
//! NG\83\8f\81[\83h\93Ç\82Ý\8d\9e\82Ý\81i\8dÄ\93Ç\82Ý\8d\9e\82Ý\81j
GikoForm.ResRangeMenuSelect := 100;
OnlyAHundredResAction.Checked := True;
- //\81@\95\\8e¦\94Í\88Í\82ð\90Ý\92è\82·\82é
- SetResRange(100);
+ //\81@\95\\8e¦\94Í\88Í\82ð\90Ý\92è\82·\82é\81B\90Ý\92è\92l\82©\82ç\82Æ\82Á\82Ä\82\82é\81B
+ SetResRange(GikoSys.Setting.ResRangeExCount);
end;
// *************************************************************************
//! \96¢\93Ç\83\8c\83X\82Ì\82Ý\95\\8e¦
Editor := TEditorForm.Create(GikoForm.GetMainForm);
Editor.SetThreadItem(Item);
Editor.Show;
- Editor.BodyEdit.SetFocus;
+ Editor.SetFocusEdit;
end;
// *************************************************************************
//! \83X\83\8c\82ð\83u\83\89\83E\83U\82Å\95\\8e¦\82·\82é
// GikoDM\82æ\82è\82à\91\81\82\8f\89\8aú\89»\82³\82ê\82é\95K\97v\82ª\82 \82é\83t\83@\83C\83\8b\82ª\82¢\82é\82Æ\82±\82¯\82é\81I\81I
// \8f\89\8aú\89»\8f\87\94Ô\82É\92\8d\88Ó\82·\82é\82±\82Æ\81I\81I
//\8f\89\89ñ\8bN\93®\8e\9e\82Ì\8f\89\8aú\89»\83t\83@\83C\83\8b\90Ý\92è
- TDefaultFileManager.CopyDefaultFiles(
- GikoSys.GetAppDir + 'defaultFiles.ini');
+ TDefaultFileManager.CopyDefaultFiles(GikoSys.Setting.GetDefaultFilesFileName);
end;
// *************************************************************************
//! \83\8d\83O\8c\9f\8dõ\83_\83C\83A\83\8d\83O\82ð\95\\8e¦\82·\82é
GikoForm.DeleteHistory(ThreadItem);
GikoForm.DeleteTab(ThreadItem);
ThreadItem.DeleteLogFile;
-
- GikoForm.TreeView.Refresh; // UnRead \82Ì\95\\8e¦\82ð\8dX\90V
end;
+ GikoForm.TreeView.Refresh; // UnRead \82Ì\95\\8e¦\82ð\8dX\90V
GikoForm.ListView.Refresh;
finally
List.Free;
//! Be2ch\82É\83\8d\83O\83C\83\93/\83\8d\83O\83A\83E\83g\82·\82é
// *************************************************************************
procedure TGikoDM.BeLogInOutActionExecute(Sender: TObject);
+var
+ TmpCursor: TCursor;
+ msg : String;
begin
- GikoSys.Setting.BeLogin := not GikoSys.Setting.BeLogin;
-end;
-// *************************************************************************
-//! Be2ch\82É\83\8d\83O\83C\83\93/\83\8d\83O\83A\83E\83g\82·\82é\82ÌUpdate\83C\83x\83\93\83g
-// *************************************************************************
-procedure TGikoDM.BeLogInOutActionUpdate(Sender: TObject);
-begin
- if (GikoSys.Setting.BeUserID <> '') and (GikoSys.Setting.BeCode <> '') then begin
- if (GikoSys.Setting.BeLogin) then BeLogInOutAction.Checked := true
- else BeLogInOutAction.Checked := false;
- BeLogInOutAction.Enabled := true
- end else
- BeLogInOutAction.Enabled := false;
+ if GikoSys.Belib.Connected then begin
+ //\83\8d\83O\83A\83E\83g
+ GikoSys.Belib.Disconnect;
+ BeLogInOutAction.Checked := False;
+ GikoForm.AddMessageList(GikoSys.GetGikoMessage(gmBeLogout), nil, gmiOK);
+ end else begin
+ TmpCursor := GikoForm.ScreenCursor;
+ GikoForm.ScreenCursor := crHourGlass;
+ try
+ GikoSys.Belib.ClientUA := 'gikoNavi/1.00';
+ GikoSys.Belib.UserName := GikoSys.Setting.BeUserID;
+ GikoSys.Belib.Password := GikoSys.Setting.BePassword;
+ if GikoSys.Setting.ReadProxy then begin
+ GikoSys.Belib.ProxyAddress := GikoSys.Setting.ReadProxyAddress;
+ GikoSys.Belib.ProxyPort := GikoSys.Setting.ReadProxyPort;
+ end else begin
+ GikoSys.Belib.ProxyAddress := '';
+ GikoSys.Belib.ProxyPort := 0;
+ end;
+ if GikoSys.Belib.Connect then begin
+ GikoForm.AddMessageList(GikoSys.GetGikoMessage(gmBeLogin) + GikoSys.Setting.BeUserID, nil, gmiOK);
+ BeLogInOutAction.Checked := True;
+ end else begin
+ GikoForm.AddMessageList(GikoSys.Belib.ErrorMsg, nil, gmiNG);
+ GikoForm.PlaySound('Error');
+ BeLogInOutAction.Checked := False;
+ end;
+ finally
+ GikoForm.ScreenCursor := TmpCursor;
+ end;
+ end;
end;
////////////////////////////////\83t\83@\83C\83\8b\82Ü\82Å\82¨\82µ\82Ü\82¢/////////////////////
// *************************************************************************
ThreadItem: TThreadItem;
begin
No := GikoForm.KokoPopupMenu.Tag;
- if No = 0 then Exit;
- ThreadItem := GikoForm.GetActiveContent(True);
- if ThreadItem = nil then Exit;
+ if No = 0
+ then Exit;
+ ThreadItem := GikoForm.KokoPopupThreadItem;
+ if not Assigned(ThreadItem) then
+ Exit;
ThreadItem.Kokomade := No;
- GikoForm.ActiveContent.Thread.ScrollTop :=
- OleVariant(IHTMLDocument2(GikoForm.ActiveContent.Browser.Document)).Body.ScrollTop;
+ GikoForm.ActiveContent.Thread.ScrollTop := GikoForm.ActiveContent.Browser.OleObject.Document.Body.ScrollTop;
GikoForm.ActiveContent.Repaint := true;
GikoForm.InsertBrowserTab(GikoForm.ActiveContent.Thread, true);
//INFO 2005/11/19 \88ê\92U\89B\95Á\81A\95K\97v\82È\82çGikoForm\82Ì\95û\82É\83\81\83\\83b\83h\82ð\92Ç\89Á\82·\82é
ThreadItem := GikoForm.GetActiveContent(True);
if ThreadItem = nil then Exit;
ThreadItem.Kokomade := -1;
- GikoForm.ActiveContent.Thread.ScrollTop :=
- OleVariant(IHTMLDocument2(GikoForm.ActiveContent.Browser.Document)).Body.ScrollTop;
+ GikoForm.ActiveContent.Thread.ScrollTop := GikoForm.ActiveContent.Browser.OleObject.Document.Body.ScrollTop;
GikoForm.ActiveContent.Repaint := true;
GikoForm.InsertBrowserTab(GikoForm.ActiveContent.Thread, true);
//INFO 2005/11/19 \88ê\92U\89B\95Á\81A\95K\97v\82È\82çGikoForm\82Ì\95û\82É\83\81\83\\83b\83h\82ð\92Ç\89Á\82·\82é
begin
Number := GikoForm.KokoPopupMenu.Tag;
if Number = 0 then Exit;
- Item := GikoForm.GetActiveContent(True);
+ Item := GikoForm.KokoPopupThreadItem;
if Item = nil then Exit;
Editor := TEditorForm.Create(GikoForm);
Editor.SetThreadItem(Item);
- Editor.BodyEdit.Text := '>>' + IntToStr(Number) + #13#10;
+ Editor.SetTextEdit('>>' + IntToStr(Number) + #13#10);
Editor.Show;
- Editor.BodyEdit.SetFocus;
+ Editor.SetFocusEdit;
end;
// *************************************************************************
//! \91I\91ð\82µ\82½\83\8c\83X\82ð\83R\83s\81[\82·\82é
LIMIT = 20;
var
ThreadItem : TThreadItem;
- No, count: Integer;
- body : string;
- limited: Integer;
+ No : Integer;
+ AID: string;
begin
No := GikoForm.KokoPopupMenu.Tag;
if No = 0 then Exit;
- ThreadItem := GikoForm.GetActiveContent(True);
+ ThreadItem := GikoForm.KokoPopupThreadItem;
if ThreadItem = nil then Exit;
- count := GikoSys.GetSameIDResCount(No, GikoForm.ActiveContent.Thread);
- limited := LIMIT;
- if count > LIMIT then begin
- if ( GikoUtil.MsgBox(GikoForm.Handle,
- IntToStr(LIMIT) + '\8cÂ\88È\8fã\82 \82è\82Ü\82·\82ª\81A\82·\82×\82Ä\95\\8e¦\82µ\82Ü\82·\82©\81H',
- 'ID\83|\83b\83v\83A\83b\83v\8cx\8d\90',
- MB_YESNO or MB_ICONQUESTION) = ID_YES ) then begin
- limited := -1;
- end;
- end;
- body := GikoSys.GetSameIDResAnchor(No, ThreadItem, limited);
- GikoForm.ActiveContent.IDAnchorPopup(body);
+
+ AID := GikoSys.GetResID(No, ThreadItem);
+ if not IsNoValidID(AID) then begin
+ GikoForm.ShowSameIDAncher(AID);
+ end;
end;
// *************************************************************************
//! \82±\82Ì\83\8c\83X\82 \82Ú\81`\82ñ\81@\81i\92Ê\8fí\81j
IndividualForm := TIndividualAbonForm.Create(GikoForm);
try
ThreadItem := GikoForm.GetActiveContent(True);
- ThreadItem.ScrollTop :=
- OleVariant(IHTMLDocument2(GikoForm.ActiveContent.Browser.Document)).Body.ScrollTop;
+ ThreadItem.ScrollTop := GikoForm.ActiveContent.Browser.OleObject.Document.Body.ScrollTop;
if (ThreadItem <> nil) and (ThreadItem.IsLogFile) then begin
if IndividualForm.SetThreadLogFileName(ThreadItem.GetThreadFileName) then begin
ReadList := TStringList.Create;
IndividualForm := TIndividualAbonForm.Create(GikoForm);
try
ThreadItem := GikoForm.GetActiveContent(True);
- ThreadItem.ScrollTop :=
- OleVariant(IHTMLDocument2(GikoForm.ActiveContent.Browser.Document)).Body.ScrollTop;
+ ThreadItem.ScrollTop := GikoForm.ActiveContent.Browser.OleObject.Document.Body.ScrollTop;
if (ThreadItem <> nil) and (ThreadItem.IsLogFile) then begin
if IndividualForm.SetThreadLogFileName(ThreadItem.GetThreadFileName) then begin
if (IndividualForm.ShowModal = mrOK) then begin
GikoSys.OpenBrowser(PROTOCOL_HTTP + URL_GIKONAVI, gbtAuto);
end;
// *************************************************************************
+//! \83M\83R\83i\83r(\94ð\93ï\8f\8a\94Å)\82Ì\83E\83F\83u\83T\83C\83g\82ð\95\\8e¦\82·\82é
+// *************************************************************************
+procedure TGikoDM.GikoNaviGoesonWebPageActionExecute(Sender: TObject);
+begin
+ GikoSys.OpenBrowser(PROTOCOL_HTTP + URL_GIKONAVIGO, gbtAuto);
+end;
+// *************************************************************************
//! \83\82\83i\83W\83\89\82Ì\83E\83F\83u\83T\83C\83g\82ð\95\\8e¦\82·\82é
// *************************************************************************
procedure TGikoDM.MonazillaWebPageActionExecute(Sender: TObject);
begin
GikoSys.OpenBrowser(PROTOCOL_HTTP + URL_Wiki, gbtAuto);
end;
+// *************************************************************************
+//! \83M\83R\83i\83r(\94ð\93ï\8f\8a\94Å)Wiki\82Ì\83E\83F\83u\83T\83C\83g\82ð\95\\8e¦\82·\82é
+// *************************************************************************
+procedure TGikoDM.GoWikiFAQWebPageActionExecute(Sender: TObject);
+begin
+ GikoSys.OpenBrowser(PROTOCOL_HTTP + URL_GoWiki, gbtAuto);
+end;
////////////////////////////////\83w\83\8b\83v\82Ü\82Å\82¨\82µ\82Ü\82¢/////////////////////
// *************************************************************************
//! \83\8a\83X\83g\94Ô\8d\86\95\\8e¦\82ð\95Ï\8dX\82·\82é
// *************************************************************************
procedure TGikoDM.UpFolderActionUpdate(Sender: TObject);
begin
- UpFolderAction.Enabled := not (GikoForm.GetActiveList is TBBS);
+ UpFolderAction.Enabled := not (GikoForm.GetActiveList is TBBS) and
+ (GikoForm.GetActiveList <> BoardGroup.SpecialBoard);
end;
// *************************************************************************
//! \95\\8e¦\81@\95\\8e¦\83\8a\83X\83g\82Ì\83\82\81[\83h\95Ï\8dX
Editor := TEditorForm.Create(GikoForm);
Editor.SetBoard(TBoard(GikoForm.GetActiveList));
Editor.Show;
- Editor.BodyEdit.SetFocus;
+ Editor.SetFocusEdit;
end;
// *************************************************************************
//! \8c»\8dÝ\95\\8e¦\82µ\82Ä\82¢\82é\94Â\82ð\83u\83\89\83E\83U\82Å\95\\8e¦\82·\82é
begin
if (GikoForm.GetActiveList is TCategory) and (GikoForm.ListView.SelCount > 0) then
TAction(Sender).Enabled := True
- else if GikoForm.GetActiveList is TBoard then
- TAction(Sender).Enabled := True
- else
+ else if GikoForm.GetActiveList is TBoard then begin
+ TAction(Sender).Enabled :=
+ (GikoForm.GetActiveList <> BoardGroup.SpecialBoard);
+ end else
TAction(Sender).Enabled := False;
end;
// *************************************************************************
// *************************************************************************
procedure TGikoDM.LogFolderOpenActionUpdate(Sender: TObject);
begin
- if ((GikoForm.GetActiveList is TBoard) or (GikoForm.GetActiveList is TCategory))
- and (GikoForm.ListView.SelCount > 0) then
+ if (((GikoForm.GetActiveList is TBoard) and
+ (GikoForm.GetActiveList <> BoardGroup.SpecialBoard))
+ or (GikoForm.GetActiveList is TCategory))
+ and (GikoForm.ListView.SelCount > 0) then
TAction(Sender).Enabled := True
else
TAction(Sender).Enabled := False;
procedure TGikoDM.BackToHistory(item: TMoveHistoryItem);
var
browser : TWebBrowser;
- doc : OleVariant;
+ doc : IHTMLDocument2;
begin
if ( item <> nil ) then begin
if ( GikoForm.GetActiveContent = item.ThreadItem ) then begin
.Objects[GikoForm.BrowserTab.TabIndex]).Browser;
if (browser <> nil) then begin
try
- doc := Idispatch( olevariant(browser.ControlInterface).Document) as IHTMLDocument2;
- doc.Body.ScrollTop := item.ScrollTop;
+ doc := browser.ControlInterface.Document as IHTMLDocument2;
+ (doc.body as IHTMLElement2).ScrollTop := item.ScrollTop;
except
end;
end;
end else begin
//URL\82É\88Ú\93®
- MoveURLWithHistory(item.ThreadItem.URL);
+ MoveURLWithHistory(item.ThreadItem.URL, True);
end;
end;
end;
//! \97\9a\97ð\8f\88\97\9d\82Â\82«URL\88Ú\93®
-procedure TGikoDM.MoveURLWithHistory(URL : String);
+procedure TGikoDM.MoveURLWithHistory(URL : String; KeyMask: Boolean = False);
var
idx : Integer;
begin
//URL\82É\88Ú\93®
- GikoForm.MoveToURL(URL);
+ GikoForm.MoveToURL(URL, KeyMask);
//\88È\89º\81A\97\9a\97ð\82Ì\8f\88\97\9d
idx := GikoForm.AddressComboBox.Items.IndexOf(URL);
if idx = -1 then begin
var
browser : TWebBrowser;
elem : IHTMLElement;
+ doc : IHTMLDocument2;
begin
if (GikoForm.GetActiveContent <> nil) then begin
if (GikoForm.BrowserTab.Tabs.Count > 0) and
.Objects[GikoForm.BrowserTab.TabIndex]).Browser;
if (browser <> nil) then begin
try
- elem := IHTMLDocument2(browser.Document).activeElement;
- elem.click;
+ doc := browser.ControlInterface.Document as IHTMLDocument2;
+ if Assigned(doc) then begin
+ elem := doc.activeElement;
+ if Assigned(elem) then begin
+ elem.click;
+ end;
+ end;
except
end;
end;
function TGikoDM.GetActiveThreadLinks : IHTMLElementCollection;
var
browser : TWebBrowser;
+ doc : IHTMLDocument2;
begin
Result := nil;
if (GikoForm.GetActiveContent <> nil) then begin
.Objects[GikoForm.BrowserTab.TabIndex]).Browser;
if (browser <> nil) then begin
try
- Result := IHTMLDocument2(browser.Document).links;
+ doc := browser.ControlInterface.Document as IHTMLDocument2;
+ if Assigned(doc) then begin
+ Result := doc.links;
+ end;
except
Result := nil;
end;
// \83\8c\83X\82Ì\94Ô\8d\86\82ð\8dX\90V
if (Pos('menu:', url) > 0) then begin
index := StrToInt64Def(
- Copy(url, 5, Length(url)), index + 1
+ Copy(url, 6, Length(url)), index + 1
);
end else begin
// \8aJ\8en\83\8c\83X\94Ô\8d\86\88È\8d~\82©\83`\83F\83b\83N
begin
GikoForm.AddIDtoNGWord(false);
end;
+//! \83N\83\8a\83b\83v\83{\81[\83h\82Ì\95¶\8e\9a\97ñ\82ðID\82Æ\82µ\82Ä\93¯\88êID\83\8c\83X\83A\83\93\83J\81[\95\\8e¦
+procedure TGikoDM.ExtractSameIDActionExecute(Sender: TObject);
+var
+ ID: String;
+begin
+ ID := Trim(Clipboard.AsText);
+ if (Length(ID) > 0) then begin
+ if not IsNoValidID(ID) then begin
+ GikoForm.ShowSameIDAncher(ID);
+ end;
+ end;
+end;
+//! \83^\83u\82Ì\83X\83\8c\83b\83h\88ê\97\97\82ð\95\\8e¦\82·\82é
+procedure TGikoDM.ShowTabListActionExecute(Sender: TObject);
+var
+ i : Integer;
+begin
+ GikoForm.ListView.Items.BeginUpdate;
+ GikoForm.ListView.Items.Clear;
+ BoardGroup.SpecialBoard.Clear;
+ for i := GikoForm.BrowserTab.Tabs.Count - 1 downto 0 do begin
+ BoardGroup.SpecialBoard.Add(
+ TBrowserRecord(GikoForm.BrowserTab.Tabs.Objects[i]).Thread);
+ end;
+ GikoForm.ListView.Items.EndUpdate;
+ GikoForm.SetActiveList(BoardGroup.SpecialBoard);
+end;
+//! \8bt\8eQ\8fÆ\82µ\82Ä\82¢\82é\83\8c\83X\82ð\92Ç\89Á\82·\82é
+procedure TGikoDM.DereferenceResActionExecute(Sender: TObject);
+var
+ i, currentNo, No : Integer;
+ links : IHTMLElementCollection;
+ threadItem : TThreadItem;
+ item : IHTMLElement;
+ url, url2 : string;
+ resNo : TStringList;
+ alreadyExist : Boolean;
+ PathRec: TPathRec;
+begin
+ No := GikoForm.KokoPopupMenu.Tag;
+ if No = 0 then Exit;
+
+ ThreadItem := GikoForm.KokoPopupThreadItem;
+ // \83A\83N\83e\83B\83u\83^\83u\82©\82ç\91S\82Ä\82Ì\83\8a\83\93\83N\82ð\8eæ\93¾\82·\82é
+ links := GetActiveThreadLinks;
+ if (ThreadItem <> nil) and (links <> nil) then begin
+ resNo := TStringList.Create;
+ try
+ currentNo := 0;
+ alreadyExist := False;
+ // \83\8a\83\93\83N\82ð\91S\82Ä\91\96\8d¸\82·\82é
+ for i := 0 to links.length - 1 do begin
+ item := links.item(i, 0) as IHTMLElement;
+ if (item <> nil) then begin
+ url := item.getAttribute('href', 0);
+ // \83\8c\83X\82Ì\94Ô\8d\86\82ð\8dX\90V
+ if (Pos('menu:', url) > 0) then begin
+ currentNo := StrToInt64Def(
+ Copy(url, 6, Length(url)), currentNo + 1
+ );
+ alreadyExist := False;
+ end else if (currentNo <> -1) and (not alreadyExist) then begin
+ // IE7\91Î\89\9e
+ if Pos('about:..', url) = 1 then begin
+ url := 'about:blank..' + Copy( url, Length('about:..')+1, Length(url) )
+ end;
+ // \8e©\95ª\82Ö\82Ì\83\8a\83\93\83N\82©\82ç\83\8c\83X\83|\83b\83v\97p\82Ì\94Ô\8d\86\8eæ\93¾
+ if Pos('about:blank..', url) = 1 then begin
+ // No \94Ô\82Ö\82Ì\83\8a\83\93\83N\82ª\82 \82ê\82Î\8eQ\8fÆ\82 \82è
+ url2 := THTMLCreate.GetRespopupURL(url, ThreadItem.URL);
+ PathRec := Gikosys.Parse2chURL2(url2);
+ if (not PathRec.FNoParam) then begin
+ Gikosys.GetPopupResNumber(url2,PathRec.FSt,PathRec.FTo);
+ end;
+ // \91Î\8fÛ\83\8c\83X\82à\82µ\82\82Í\82»\82ê\82ð\8aÜ\82Þ\82È\82ç\8eQ\8fÆ\82 \82è\82Æ\82·\82é
+ if (PathRec.FSt = No) or
+ ((PathRec.FSt <= No) and (PathRec.FTo >= No)) then begin
+ alreadyExist := True;
+ resNo.Add(IntToStr(currentNo));
+ end;
+ end;
+ end;
+ end;
+ end;
+ // \96³\90§\8cÀ\82È\82Ì\82Å-1\8cÅ\92è
+ GikoForm.ActiveContent.IDAnchorPopup(
+ GikoSys.CreateResAnchor(resNo, ThreadItem, -1));
+ finally
+ resNo.Clear;
+ resNo.Free;
+ end;
+ end;
+end;
+
+procedure TGikoDM.UpdateGikonaviActionExecute(Sender: TObject);
+var
+ form : TUpdateCheckForm;
+ Msg: string;
+ shutdown: boolean;
+begin
+ if (EditorFormExists) then begin
+ Msg := '\83\8c\83X\83G\83f\83B\83^\82ð\91S\82Ä\95Â\82¶\82Ä\82\82¾\82³\82¢';
+ MsgBox(GikoForm.Handle, Msg, MSG_ERROR, MB_OK or MB_ICONSTOP);
+ Exit;
+ end;
+ GikoForm.UpdateExePath := '';
+ GikoForm.UpdateExeArgs := '';
+ form := TUpdateCheckForm.Create(GikoForm);
+ try
+ form.ShowModal;
+ shutdown := form.Allowshutdown;
+ if shutdown then begin
+ GikoForm.UpdateExePath := form.ExecPath;
+ GikoForm.UpdateExeArgs := form.ExecArgs;
+ end;
+ finally
+ form.Release;
+ end;
+ if shutdown then begin
+ // \83M\83R\83i\83r\8fI\97¹
+ GikoForm.Close;
+ end;
+
+end;
+//! \82±\82Ì\83\8c\83X\82ÌURL\83R\83s\81[\81iPATH_INFO)
+procedure TGikoDM.konoURLPATHActionExecute(Sender: TObject);
+var
+ No : Integer;
+ ThreadItem : TThreadItem;
+ URL, Protocol, Host, Path, Document, Port, Bookmark : String;
+begin
+ No := GikoForm.KokoPopupMenu.Tag;
+ if No = 0 then Exit;
+
+ ThreadItem := GikoForm.KokoPopupThreadItem;
+ if (ThreadItem.ParentBoard.Is2ch) or not (Pos('?', ThreadItem.URL) > 0) then begin
+ GikoSys.ParseURI(ThreadItem.URL,Protocol, Host, Path, Document, Port, Bookmark);
+ URL := Protocol + '://' + Host + Path + IntToStr(No);
+ end else begin
+ if Pos('?', ThreadItem.URL) > 0 then begin
+ URL := Copy(ThreadItem.URL, 1, Pos('?', ThreadItem.URL)-1);
+ // \82Ü\82¿BBS\97p\8f\88\92u
+ URL := MojuUtils.CustomStringReplace(URL, 'read.pl', 'read.cgi');
+ URL := URL + '/' + ThreadItem.ParentBoard.BBSID + '/' + ChangeFileExt(ThreadItem.FileName, '') + '/' + IntToStr(No);
+ end;
+ end;
+ Clipboard.SetTextBuf( PChar(URL) );
+end;
+//! \82±\82Ì\83\8c\83X\82ÌURL\83R\83s\81[\81iQuery_STRING)
+procedure TGikoDM.konoURLQueryActionExecute(Sender: TObject);
+var
+ No : Integer;
+ ThreadItem : TThreadItem;
+ URL, Protocol, Host, Path, Document, Port, Bookmark : String;
+begin
+ No := GikoForm.KokoPopupMenu.Tag;
+ if No = 0 then Exit;
+
+ ThreadItem := GikoForm.KokoPopupThreadItem;
+ // 2ch\82Æ\82µ\82½\82ç\82Î\82Í\81A\83\8c\83X\94Ô\8d\86\82ð\82¤\82Ü\82\8f\88\97\9d\82µ\82Ä\82\82ê\82È\82¢\82Ì\82Å\97\98\97p\95s\89Â
+ if ThreadItem.ParentBoard.Is2ch or not (Pos('?', ThreadItem.URL) > 0) then begin
+ GikoSys.ParseURI(ThreadItem.URL, Protocol, Host, Path, Document, Port, Bookmark);
+ URL := Protocol + '://' + Host + '/test/read.cgi?bbs=' + ThreadItem.ParentBoard.BBSID
+ + '&key=' + ChangeFileExt(ThreadItem.FileName, '') + '&st=' + IntToStr(No) + '&to=' + IntToStr(No);
+ end else begin
+ URL := ThreadItem.URL;
+ // \82Ü\82¿BBS
+ if Pos('&LAST=', URL) > 0 then begin
+ URL := Copy(URL, 1, Pos('&LAST=', URL) - 1);
+ URL := URL + '&START=' + IntToStr(No) + '&END=' + IntToStr(No);
+ end;
+ // \82»\82Ì\91¼\8aO\95\94\94Â
+ if Pos('&ls=', URL) > 0 then begin
+ URL := Copy(URL, 1, Pos('&ls=', URL) - 1);
+ URL := URL + '&st=' + IntToStr(No) + '&to=' + IntToStr(No);
+ end;
+
+ end;
+ Clipboard.SetTextBuf( PChar(URL) );
+end;
+//! \82±\82Ì\83\8c\83X\82ÌURL\83R\83s\81[\81iQuery_STRING\81j\82Ì\97\98\97p\83`\83F\83b\83N
+procedure TGikoDM.konoURLQueryActionUpdate(Sender: TObject);
+const
+ LIVEDOOR_URL = 'http://jbbs.shitaraba.net/';
+begin
+ // 2ch\82Æ\82µ\82½\82ç\82Î\82Í\97\98\97p\82Å\82«\82È\82¢\82æ\82¤\82É\82·\82é\81i\82¤\82Ü\82\83\8c\83X\8ew\92è\82Å\82«\82È\82¢\82Ì\82Å\81j
+ konoURLQueryAction.Enabled := false;
+ if (GikoForm.KokoPopupThreadItem <> nil) then begin
+ konoURLQueryAction.Enabled := not GikoForm.KokoPopupThreadItem.ParentBoard.Is2ch;
+ if konoURLQueryAction.Enabled then begin
+ konoURLQueryAction.Enabled := not (Pos(LIVEDOOR_URL, GikoForm.KokoPopupThreadItem.URL) = 1);
+ end;
+ end;
+end;
+//! \83|\83b\83v\83A\83b\83v\83\81\83j\83\85\81[\90Ý\92è\83_\83C\83A\83\8d\83O\82ð\8aJ\82
+procedure TGikoDM.PopupMenuSettingActionExecute(Sender: TObject);
+var
+ Dlg: TPopupMenuSettingDialog;
+begin
+ Dlg := TPopupMenuSettingDialog.Create(GikoForm, GikoFormActionList);
+ try
+ Dlg.ShowModal;
+ finally
+ Dlg.Release;
+ end;
+end;
+
+procedure TGikoDM.ThreadSearchActionExecute(Sender: TObject);
+begin
+ if (ThreadSrch <> nil) and (ThreadSrch.Visible = False) then begin
+ ThreadSrch.Free;
+ ThreadSrch := nil;
+ end;
+ if (ThreadSrch = nil) then begin
+ ThreadSrch := TThreadSrch.Create(GikoForm);
+ end;
+ ThreadSrch.Show;
+end;
+
+procedure TGikoDM.SaveThreadSearchSetting;
+begin
+ if (ThreadSrch <> nil) and (ThreadSrch.Visible = True) then
+ ThreadSrch.SaveSetting;
+end;
+
+procedure TGikoDM.ThreadNgEditActionExecute(Sender: TObject);
+begin
+ ThreadNGEdit := TThreadNGEdit.Create(GikoForm);
+ if (ThreadNGEdit.ShowModal = mrOk) then begin
+ GikoForm.ListView.Refresh;
+ end;
+ ThreadNGEdit.Free;
+ ThreadNGEdit := nil;
+end;
end.