1
    2
    3
    4
    5
    6
    7
    8
    9
   10
   11
   12
   13
   14
   15
   16
   17
   18
   19
   20

content / test / data / back_forward_cache / presentation_controller.html [blame]

<!DOCTYPE html>
<head></head>
<body>
  This page is using the Presentation API as a presentation controller.
</body>
<script>
  let connection = null;
  let connectionClosed = false;

  const presentationRequest = new PresentationRequest("fake-url");
  // Trigger creation of PresentationService in browser side.
  presentationRequest.getAvailability();

  function setConnection(newConnection) {
    connection = newConnection;
    connection.onclose = () => {
      connectionClosed = true;
    }
  }
</script>