GNOME Python API

References

  • PyGObject Docs
  • GNOME Developer Documentation

Libraries

  • Adw
  • DBus
  • DBusGLib
  • Flatpak
  • GLib
  • GModule
  • GObject
  • Gcr
  • Gdk
  • GdkPixbuf
  • GdkPixdata
  • GdkWayland
  • GdkX11
  • Gio
  • Graphene
  • Gsk
  • Gst
  • GstBase
  • GstCheck
  • GstController
  • GstNet
  • Gtk
  • GtkSource
  • HarfBuzz
  • Pango
  • PangoCairo
  • PangoFT2
  • PangoFc
  • PangoOT
  • PangoXft
  • Shumate
  • Soup
  • Vte
  • WebKit
    • Classes
    • Interfaces
    • Structures
      • ApplicationInfo
      • Credential
      • Feature
      • FeatureList
      • GeolocationPosition
      • ITPFirstParty
      • ITPThirdParty
      • InputMethodUnderline
      • MemoryPressureSettings
      • NavigationAction
      • NetworkProxySettings
      • OptionMenuItem
      • PermissionStateQuery
      • ScriptDialog
      • ScriptMessageReply
      • SecurityOrigin
      • UserContentFilter
      • UserScript
      • UserStyleSheet
      • WebViewSessionState
      • WebsiteData
    • Enums
    • Functions
    • Constants
    • Dependencies
  • WebKitWebProcessExtension
  • Xdp
  • XdpGtk4
  • pycairo
GNOME Python API
  • WebKit
  • Structures
  • NavigationAction
  • View page source

NavigationAction

class NavigationAction(*args, **kwargs)

Provides details about interaction resulting in a resource load.

Methods

class NavigationAction
free() → None

Free the NavigationAction

Added in version 2.6.

get_frame_name() → str | None

Gets the navigation target frame name. For example if navigation was triggered by clicking a link with a target attribute equal to “_blank”, this will return the value of that attribute. In all other cases this function will return None.

Added in version 2.40.

get_modifiers() → int

Return the modifier keys.

Return a bitmask of ModifierType values describing the modifier keys that were in effect when the navigation was requested

Added in version 2.6.

get_mouse_button() → int

Return the number of the mouse button that triggered the navigation.

Return the number of the mouse button that triggered the navigation, or 0 if the navigation was not started by a mouse event.

Added in version 2.6.

get_navigation_type() → NavigationType

Return the type of action that triggered the navigation.

Added in version 2.6.

get_request() → URIRequest

Return the URIRequest associated with the navigation action.

Modifications to the returned object are <emphasis>not</emphasis> taken into account when the request is sent over the network, and is intended only to aid in evaluating whether a navigation action should be taken or not. To modify requests before they are sent over the network the WebKitPage::send-request signal can be used instead.

Added in version 2.6.

is_redirect() → bool

Returns whether the navigation was redirected.

Added in version 2.20.

is_user_gesture() → bool

Return whether the navigation was triggered by a user gesture like a mouse click.

Added in version 2.6.


Built with Sphinx using a theme provided by Read the Docs.
  • NavigationAction
    • Methods
      • NavigationAction.free()
      • NavigationAction.get_frame_name()
      • NavigationAction.get_modifiers()
      • NavigationAction.get_mouse_button()
      • NavigationAction.get_navigation_type()
      • NavigationAction.get_request()
      • NavigationAction.is_redirect()
      • NavigationAction.is_user_gesture()