예제 #1
0
 /// <summary>
 /// Create a new URL request that will be treated as originating from this
 /// frame and the associated browser. This request may be intercepted by the
 /// client via cef_resource_request_handler_t or cef_scheme_handler_factory_t.
 /// Use cef_urlrequest_t::Create instead if you do not want the request to have
 /// this association, in which case it may be handled differently (see
 /// documentation on that function). Requests may originate from both the
 /// browser process and the render process.
 /// For requests originating from the browser process:
 /// - POST data may only contain a single element of type PDE_TYPE_FILE or
 /// PDE_TYPE_BYTES.
 /// For requests originating from the render process:
 /// - POST data may only contain a single element of type PDE_TYPE_BYTES.
 /// - If the response contains Content-Disposition or Mime-Type header values
 /// that would not normally be rendered then the response may receive
 /// special handling inside the browser (for example, via the file download
 /// code path instead of the URL request code path).
 /// The |request| object will be marked as read-only after calling this
 /// function.
 /// </summary>
 public unsafe virtual CefUrlRequest CreateUrlRequest(CefRequest request, CefUrlRequestClient client)
 {
     return(SafeCall(CefUrlRequest.Wrap(CefUrlRequest.Create, NativeInstance->CreateUrlRequest((request != null) ? request.GetNativeInstance() : null, (client != null) ? client.GetNativeInstance() : null))));
 }
예제 #2
0
 /// <summary>
 /// Load the request represented by the |request| object.
 /// WARNING: This function will fail with &quot;bad IPC message&quot; reason
 /// INVALID_INITIATOR_ORIGIN (213) unless you first navigate to the request
 /// origin using some other mechanism (LoadURL, link click, etc).
 /// </summary>
 public unsafe virtual void LoadRequest(CefRequest request)
 {
     NativeInstance->LoadRequest((request != null) ? request.GetNativeInstance() : null);
     GC.KeepAlive(this);
 }