Bug 1367503 - webkitgtk seems incompatible with Google Maps API
Summary: webkitgtk seems incompatible with Google Maps API
Keywords:
Status: CLOSED UPSTREAM
Alias: None
Product: Fedora
Classification: Fedora
Component: webkitgtk4
Version: 24
Hardware: Unspecified
OS: Linux
unspecified
unspecified
Target Milestone: ---
Assignee: Tomas Popela
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-08-16 14:35 UTC by Philippe Charpentier
Modified: 2016-08-16 16:08 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-08-16 16:08:05 UTC
Type: Bug


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
WebKit Project 142074 0 None None None 2016-08-16 16:08:04 UTC

Description Philippe Charpentier 2016-08-16 14:35:01 UTC
Description of problem:
compatibility webkitgtk and Google Maps API

Version-Release number of selected component (if applicable): webkitgtk-2.4.11, webkitgtk3-2.4.11 webkitgtk4-2.12.3


How reproducible:


Steps to Reproduce:
run (for example)
MiniBrowser https://developers.google.com/maps/documentation/javascript/examples/icon-simple?hl=fr

Actual results:
the page is displayed correctly but when you put the mouse over the map
and you move the Mouse wheel, it scrolls the entire page rather than
zooming into the map. And if you click into the map and drags it, it
don't works.

Same problem with GtkLauncher (from webkitgtk or webkitgtk3), with 'midori --plain' and with epiphany.
I also have the same problem with a python program using pywebkitgtk.

midori (without the option --plain) doesn't show the problem.

On other sites similar problems appear with many functions defines in Google Maps API.

I asked on the webkit-gtk list and it appears that this is not a bug of webkitgtk (this behavior can't be reproduce on Debian) but of the WebKitGTK+ version shipped and packaged by Fedora.
Moreover, a developer of WebKitGTK tested a recent build of WebKit trunk on Fedora 24, and it doesn't show the problem.

Best regards.

Comment 1 Philippe Charpentier 2016-08-16 15:55:10 UTC
Carlos Alberto Lopez Perez (developer of webkitgtk) found the problem:

it is in the spec files (of each packages webkitgtk, webkitgtk3 and webkitgtk4): the lines

%if 0%{?fedora}
%global optflags %{optflags} -DUSER_AGENT_GTK_DISTRIBUTOR_NAME=\'\\"Fedora\\"\'
%endif

has to be removed (or at least changed)

because they imply that MiniBrowser and GtkLauncher  have this UA:

Mozilla/5.0 (Fedora; Linux arch) AppleWebKit/602.1 (KHTML, like Gecko) Version/8.0 Safari/602.1

and on Debian this UA:

Mozilla/5.0 (X11; Linux arch) AppleWebKit/602.1 (KHTML, like Gecko) Version/8.0 Safari/602.1

and Google Maps don't like the first UA.

Thus I tried MiniBrowser and GtkLauncher with the option --user-agent='Mozilla/5.0 (X11; Linux arch)' and everything went fine.

As (as far as I know) such an option cannot be used, via pywebkitgtk, in a python program, I think that these packages must be modify.

Regards

Comment 2 Michael Catanzaro 2016-08-16 16:08:05 UTC
Yup, thanks. I'll add Google Maps to our UA quirks list.


Note You need to log in before you can comment on or make changes to this bug.