Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[AS2] Stage.displayState="fullScreen" doesn’t work #1562

Closed
ousia opened this issue Nov 15, 2020 · 2 comments
Closed

[AS2] Stage.displayState="fullScreen" doesn’t work #1562

ousia opened this issue Nov 15, 2020 · 2 comments
Labels
A-avm1 Area: AVM1 (ActionScript 1 & 2)

Comments

@ousia
Copy link
Contributor

ousia commented Nov 15, 2020

Neither desktop app (in Linux), nor web react to Stage.displayState="fullScreen".

Used in https://www.mejorar-presentaciones.tk/mejorar-presentaciones-presentation.swf.

Relevant AS code:

function toogle_fullscreen() {
    if(Stage.displayState == "normal"){
        Stage.displayState="fullScreen";
    } else {
        Stage.displayState="normal";
    }
}

key_listen=new Object();

key_listen.onKeyDown = function() {
        case 70:
            toogle_fullscreen();
        break;
    }
};

Key.addListener(key_listen);

Many thanks for your help.

@Herschel Herschel added actionscript A-avm1 Area: AVM1 (ActionScript 1 & 2) labels Nov 16, 2020
@ousia
Copy link
Contributor Author

ousia commented Nov 20, 2020

Maybe this is a clearer example.

If I play https://free-culture.tk/lfc-loader.swf with https://ruffle.rs/demo/, after pressing the button (the whole presentation), I should get the following (unrelated from the fact that loading isn’t performed [#1561]):

.on_release:
    fullscreen_button._visible = 0;
    fs_area._visible = 0;
    Stage["displayState"] = "fullScreen";
    _root.load_text = "[Click to start]";
    _root.dlprogress_mvclip._visible = true;
.end

[Click to start] is displayed, but content doesn’t go fullscreen.

But now I realize that Stage.displayState needs to be implemented first (according to #274).

Now I realize that one thing is to add fullscreen capabilities (such as @relrelb did with #1515) and quite another one is to be able to deal with fullscreen statements in AS2 code.

Many thanks for your help.

@ousia
Copy link
Contributor Author

ousia commented Nov 12, 2021

PR #5137 has fixed the issue.

Many thanks to @hatal175 for the code and to @kmeisthax for the merge.

@ousia ousia closed this as completed Nov 12, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-avm1 Area: AVM1 (ActionScript 1 & 2)
Projects
None yet
Development

No branches or pull requests

2 participants