Class GeolocationPermissionRequest
- All Implemented Interfaces:
Proxy, PermissionRequest
A permission request for sharing the user's location.
WebKitGeolocationPermissionRequest represents a request for permission to decide whether WebKit should provide the user's location to a website when requested through the Geolocation API.
When a WebKitGeolocationPermissionRequest is not handled by the user, it is denied by default.
When embedding web views in your application, you must configure an
application identifier to allow web content to use geolocation services.
The identifier must match the name of the .desktop file which describes
the application, sans the suffix.
If your application uses GApplication (or any subclass like
GtkApplication), WebKit will automatically use the identifier returned by
g_application_get_application_id(). This is the recommended approach for
enabling geolocation in applications.
If an identifier cannot be obtained through GApplication, the value
returned by g_get_prgname() will be used instead as a fallback. For
programs which cannot use GApplication, calling g_set_prgname() early
during initialization is needed when the name of the executable on disk
does not match the name of a valid .desktop file.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classInner class implementing a builder pattern to construct a GObject with properties.static classNested classes/interfaces inherited from class GObject
GObject.NotifyCallback, GObject.ObjectClassNested classes/interfaces inherited from interface PermissionRequest
PermissionRequest.PermissionRequest$Impl, PermissionRequest.PermissionRequestInterface -
Constructor Summary
ConstructorsConstructorDescriptionCreate a new GeolocationPermissionRequest.Create a GeolocationPermissionRequest instance for the provided memory address. -
Method Summary
Modifier and TypeMethodDescriptionprotected GeolocationPermissionRequestasParent()Return this instance as if it were its parent type.static GeolocationPermissionRequest.Builder<? extends GeolocationPermissionRequest.Builder> builder()AGeolocationPermissionRequest.Builderobject constructs aGeolocationPermissionRequestwith the specified properties.static MemoryLayoutThe memory layout of the native struct.static @Nullable TypegetType()Get the GType of the GeolocationPermissionRequest class.Methods inherited from class GObject
addToggleRef, addWeakPointer, bindProperty, bindProperty, bindProperty, bindPropertyFull, bindPropertyFull, bindPropertyWithClosures, bindPropertyWithClosures, compatControl, connect, connect, connect, constructed, disconnect, dispatchPropertiesChanged, dispose, dupData, dupQdata, emit, emitNotify, finalize_, forceFloating, freezeNotify, get, getData, getProperty, getProperty, getProperty, getQdata, getv, interfaceFindProperty, interfaceInstallProperty, interfaceListProperties, isFloating, newInstance, newInstance, newv, notify, notify, notifyByPspec, onNotify, ref, refSink, removeToggleRef, removeWeakPointer, replaceData, replaceQdata, runDispose, set, setData, setDataFull, setProperty, setProperty, setProperty, setQdata, setQdataFull, setv, stealData, stealQdata, takeRef, thawNotify, unref, watchClosure, weakRef, weakUnref, withPropertiesMethods inherited from class TypeInstance
callParent, callParent, cast, getPrivate, readGClass, writeGClassMethods inherited from class ProxyInstance
equals, handle, hashCodeMethods inherited from class Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface PermissionRequest
allow, deny
-
Constructor Details
-
GeolocationPermissionRequest
Create a GeolocationPermissionRequest instance for the provided memory address.- Parameters:
address- the memory address of the native object
-
GeolocationPermissionRequest
public GeolocationPermissionRequest()Create a new GeolocationPermissionRequest.
-
-
Method Details
-
getType
Get the GType of the GeolocationPermissionRequest class.- Returns:
- the GType
-
getMemoryLayout
The memory layout of the native struct.- Returns:
- the memory layout
-
asParent
Return this instance as if it were its parent type. Comparable to the Javasuperkeyword, but ensures the parent typeclass is also used in native code. -
builder
public static GeolocationPermissionRequest.Builder<? extends GeolocationPermissionRequest.Builder> builder()AGeolocationPermissionRequest.Builderobject constructs aGeolocationPermissionRequestwith the specified properties. Use the variousset...()methods to set properties, and finish construction withGeolocationPermissionRequest.Builder.build().- Returns:
- the builder object
-