Changed mime override callback to be called per context and added user_data
Whenever a new URLRequest is created, it is delegated via
ResourceThrottleEfl to our PolicyResponseDelegateEfl, where we postpone
the request and are able to check and handle the mime type of the
request on the UI thread. We ask the client if the mime_type should be
changed and if yes, we push the new mime type to MimeOverrideManagerEfl
and resume the URLRequest. Later on a
ResourceDispatcherHostDelegateEfl::ShouldOverrideMimeType call we deploy
the new overridden mime type on IO thread.
Mime override callback was global for the browser and didn't have
user_data, this patch changes it to be per context and adds user_data.
This patch is based on http://165.213.202.130:8080/#/c/72514/
Together with: I1baa8e92c0b2bea44fc0332c3e034f16f4efa428
Bug: http://107.108.218.239/bugzilla/show_bug.cgi?id=9463
Reviewed by: Antonio Gomes, Janusz Majnert, Min-Soo Koo, Piotr Tworek, SeungSeop Park
Change-Id: I3881faaf5fcf4d29c44a120d4723133095042b41
Signed-off-by: Tomasz Czekala <t.czekala@partner.samsung.com>
14 files changed: