Recent

Author Topic: fpCef3 - changing user agent string  (Read 1789 times)

laggyluk

  • Jr. Member
  • **
  • Posts: 69
fpCef3 - changing user agent string
« on: February 07, 2017, 12:52:04 pm »
I can set user agent while initializing application but I rather do that on the fly, without restart.

Stackoverflow says It should be possible to manipulate request header in OnBeforeResourcesLoad like that:

    CefRequest::HeaderMap hdrMap;
    request->GetHeaderMap(hdrMap);

    hdrMap.insert(std::make_pair("Test", "test"));
    request->SetHeaderMap(hdrMap);
    return false;

How to create this HeaderMap object?
dCef3 port has something like this:   headerMap := TCefStringMultiMapOwn.Create;
which I can't find in fpCef3, is it missing from the port or is named differently?

 

TinyPortal © 2005-2018