altmp / altv-issues

Issues and roadmap for alt:V project
93 stars 16 forks source link

OnScreen Keyboard Native Broken Again #1897

Closed Stuyk closed 1 year ago

Stuyk commented 1 year ago

Description of the problem

Recently the on screen keyboard built in to GTA:V broke again.

Some additional information:

Reproduction steps

function showInputBox(title: string = "", text: string = "", maxLength: number = 100): string {
    return new Promise((resolve) => {
        alt.addGxtText("INPUT_BOX_CUSTOM_TITLE", title);
        native.displayOnscreenKeyboard(0, "INPUT_BOX_CUSTOM_TITLE", "", text, "", "", "", maxLength);

        let tick = alt.everyTick(() => {
            let state = native.updateOnscreenKeyboard();
            if(state === 0) return;
            let result = native.getOnscreenKeyboardResult();
            native.forceCloseTextInputBox();
            alt.clearEveryTick(tick);
            resolve(result);
        });
    });
}

Expected behaviour

Works with the above code again.

Additional context

Bunch of people in Discord have been talking about it but nobody knows how to make a god damn bug ticket.

Operating system

Windows 10

Version

latest

Crashdump ID

No response

Reproduction tested

C0kkie commented 1 year ago

1879

FabianTerhorst commented 1 year ago

its a feature request, not a bug report.so no duplicate.

FabianTerhorst commented 1 year ago

ah nvm that was not the issue with the new suggested feature.