I'm trying to use following procedure in Delphi XE2 with Chromium component (version 306):

procedure TForm1.Chromium1BeforeBrowse(Sender: TObject;
  const browser: ICefBrowser; const frame: ICefFrame;
  const request: ICefRequest; navType: TCefHandlerNavtype; isRedirect: Boolean;
  out Result: Boolean);

but it's not working. Delphi doesn't recognize onBeforeBrowse event. Chromium seems to be correctly installed, samples are working, and I'm trying to add onBeforeBrowse event handling in GuiClient sample... Is there that event in Delphi Chromium component ?

有帮助吗?

其他提示

Yes.. this event exists. You can find its usage in unit cefvcl. Its type is declared in cefgui, TOnBeforeBrowse.

enter image description here

I'll probably remove my answer later.. just to share the screenshot...

I open the Demo project... double-click on the event OnBeforeBrowse and added the showmessage you can see

Regarding the screenshot.. do not trust the TEdit.. I only change the DefaultUrl property of the TChromium itself ;o)

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top