Signals | HTML Surface

These require you to run Steam.run_callbacks() in your _process() function to receive them.


html_browser_ready

  • A new browser was created and is ready for use.
  • Sends back no data.

html_can_go_backandforward

  • Called when page history status has changed the ability to go backwards and forward.
  • Sends back the following data:
    • go_back (bool)
    • go_forward (bool)

html_changed_title

  • Called when the current page in a browser gets a new title.
  • Sends back the following data:
    • title (string)

html_close_browser

  • Called when the browser has been requested to close due to user interaction; usually because of a javascript window.close() call.
  • Sends back no data.

html_file_open_dialog

  • Called when a browser surface has received a file open dialog from a input type="file" click or similar, you must call FileLoadDialogResponse with the file(s) the user selected.
  • Sends back the following data:
    • title (string)
    • initial_file (string)

html_finished_request

  • Called when a browser has finished loading a page.
  • Sends back the following data:
    • url (string)
    • title (string)

html_hide_tooltip

  • Called when a a browser wants to hide a tooltip.
  • Sends back no data.

html_horizontal_scroll

  • Provides details on the visibility and size of the horizontal scrollbar.
  • Sends back the following data:
    • scroll_data (dictionary)
      • scroll_max (int)
      • scroll_current (int)
      • page_scale (float)
      • visible (bool)
      • page_size (int)
    • scroll_data (dictionary)
      • scroll_max (uint32)
      • scroll_current (uint32)
      • page_scale (float)
      • visible (bool)
      • page_size (uint32)

html_js_alert

  • Called when the browser wants to display a Javascript alert dialog, call jsDialogResponse when the user dismisses this dialog; or right away to ignore it.
  • Sends back the following data:
    • message (string)

html_js_confirm

  • Called when the browser wants to display a Javascript confirmation dialog, call jsDialogResponse when the user dismisses this dialog; or right away to ignore it.
  • Sends back the following data:
    • message (string)

html_link_at_position

  • Result of a call to getLinkAtPosition.
  • Sends back the following data:
    • link_data (dictionary)
      • x (int)
      • y (int)
      • url (string)
      • input (bool)
      • live_link (bool)
    • link_data (dictionary)
      • x (uint32)
      • y (uint32)
      • url (string)
      • input (bool)
      • live_link (bool)

html_needs_paint

  • Called when a browser surface has a pending paint. This is where you get the actual image data to render to the screen.
  • Sends back the following data:
    • page_data (dictionary)
      • bgra (string)
      • wide (int)
      • tall (int)
      • update_x (int)
      • update_y (int)
      • update_wide (int)
      • update_tall (int)
      • scroll_x (int)
      • scroll_y (int)
      • page_scale (float)
      • page_serial (int)
    • page_data (dictionary)
      • bgra (string)
      • wide (uint32)
      • tall (uint32)
      • update_x (uint32)
      • update_y (uint32)
      • update_wide (uint32)
      • update_tall (uint32)
      • scroll_x (uint32)
      • scroll_y (uint32)
      • page_scale (float)
      • page_serial (uint32)

html_new_window

  • A browser has created a new HTML window.
  • Sends back the following data:
    • window_data (dictionary)
      • url (string)
      • x (int)
      • y (int)
      • wide (int)
      • tall (int)
      • new_handle (int)
    • window_data (dictionary)
      • url (string)
      • x (uint32)
      • y (uint32)
      • wide (uint32)
      • tall (uint32)
      • new_handle (uint32)

html_open_link_in_new_tab

  • The browser has requested to load a url in a new tab.
  • Sends back the following data:
    • url (string)

html_search_results

  • Results from a search.
  • Sends back the following data:
    • results (int)
    • current_match (int)
    • results (uint32)
    • current_match (uint32)

html_set_cursor

  • Called when a browser wants to change the mouse cursor.
  • Sends back the following data:
    • mouse_cursor (int)
    • mouse_cursor (uint32)

html_show_tooltip

  • Called when a browser wants to display a tooltip.
  • Sends back the following data:
    • message (string)

html_start_request

  • Called when a browser wants to navigate to a new page.
  • Sends back the following data:
    • url (string)
    • target (string)
    • post_data (string)
    • redirect (bool)

html_status_text

  • Called when a browser wants you to display an informational message. This is most commonly used when you hover over links.
  • Sends back the following data:
    • message (string)

html_update_tooltip

  • Called when the text of an existing tooltip has been updated.
  • Sends back the following data:
    • message (string)

html_url_changed

  • Called when the browser is navigating to a new url.
  • Sends back the following data:
    • urlData (dictionary)
      • url (string)
      • post_data (string)
      • redirect (bool)
      • title (string)
      • new_navigation (bool)

html_vertical_scroll

  • Provides details on the visibility and size of the vertical scrollbar.
  • Sends back the following data:
    • scroll_data (dictionary)
      • scroll_max (int)
      • scroll_current (int)
      • page_scale (float)
      • visible (bool)
      • page_size (int)
    • scroll_data (dictionary)
      • scroll_max (uint32)
      • scroll_current (uint32)
      • page_scale (float)
      • visible (bool)
      • page_size (uint32)