Skip to content

<webview>.src issue #1754

Closed
Closed

Description

@thyrrestrup

Hi

@deepak1556 and I - tracked down an issue with .src while trying to solve the html5 fullscreen implementation.

Here is a sample app:
index.html

<!DOCTYPE html>
<html>
    <head>
        <title>Webview</title>
        <script>
            onload = function() {
                var content = document.getElementById('content');
                content.addEventListener('new-window', function(e) {
                    content.src = e.url;
                });
            };
        </script>
        <style>
            .webview {
                position: absolute;
                top: 0;
                bottom: 0;
                left: 0;
                right: 0;
                margin: 0;
                padding: 0;
                outline: none !important;
            }
        </style>
    </head>
    <body>
        <webview id="content" src="./link.html" class="webview" plugins></webview>
    </body>
</html>

link.html

<!DOCTYPE html>
<html>
    <head>
        <title>Link</title>
    </head>
    <body>
        <a href="http://www.youtube.com/user/StateofGreenDK" target="_blank">YouTube</a>
    </body>
</html>

Recap of findings by @deepak1556 (link to original comment):
In the above scenario the intermediate page loaded from link.html doesn't get recorded on dying_render_process_ so it leads to a weird scenario in UpdateGuestProcessID.

Page Transition Old Id New Id
index.html load 6 7
link.html load 7 8
onclick link 7 9

the solution i can think of is have the webview_info_map_ as append only assuming ids are incremental or find another way to record dying render process. Thoughts ?

@deepak1556 - Do you have anything to add?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions