[Webkit-unassigned] [Bug 83877] [GTK][WK2] Implement geolocation provider for the GTK port

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Apr 16 00:57:29 PDT 2012


https://bugs.webkit.org/show_bug.cgi?id=83877





--- Comment #2 from Carlos Garcia Campos <cgarcia at igalia.com>  2012-04-16 00:57:30 PST ---
(From update of attachment 137070)
View in context: https://bugs.webkit.org/attachment.cgi?id=137070&action=review

We implement C API clients in the API layer, so please move this to UIProcess/API/gtk and implement it the same way we do for other C API clients. Maybe we could move common code to WebCore so that wk1 and wk2 could use the same geolocation provider based on geoclue.

> Source/WebKit2/UIProcess/gtk/WebGeolocationProviderGtk.cpp:28
> +

Add #if ENABLE(GEOLOCATION) here.

> Source/WebKit2/UIProcess/gtk/WebGeolocationProviderGtk.cpp:29
> +#include "WKGeolocationPosition.h"

Use angle-bracket form to include WK2 C API headers.

> Source/WebKit2/UIProcess/gtk/WebGeolocationProviderGtk.cpp:80
> +    , m_geoclueClient(0)
> +    , m_geocluePosition(0)

This is already initialized to 0 by GRefPtr

> Source/WebKit2/UIProcess/gtk/WebGeolocationProviderGtk.cpp:118
> +    if (m_geoclueClient)
> +        m_geoclueClient.clear();
> +
> +    if (m_geocluePosition)
> +        m_geocluePosition.clear();

GRefPtr::clear already checks the pointer before unrefing it, so no need to check it here too.

> Source/WebKit2/UIProcess/gtk/WebGeolocationProviderGtk.cpp:128
> +    double horizontalAccuracy = 0.0;

Use 0 instead of 0.0

> Source/WebKit2/UIProcess/gtk/WebGeolocationProviderGtk.cpp:138
> +void WebGeolocationProviderGtk::errorOccured(const char* message) const
> +{
> +    WKGeolocationManagerProviderDidFailToDeterminePosition(m_manager);
> +}

The error message is ignored.

> Source/WebKit2/UIProcess/gtk/WebGeolocationProviderGtk.h:22
> +

Add #if ENABLE(GEOLOCATION) here

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list