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

getInputAction is wrongly typed #8929

Closed
rot1024 opened this issue Jun 8, 2020 · 2 comments · Fixed by #9002
Closed

getInputAction is wrongly typed #8929

rot1024 opened this issue Jun 8, 2020 · 2 comments · Fixed by #9002

Comments

@rot1024
Copy link

rot1024 commented Jun 8, 2020

In Cesium.d.ts, ScreenSpaceEventHandler#getInputAction' s type may be wrong.

Actual: returning void

    /**
     * Returns the function to be executed on an input event.
     * @param type - The ScreenSpaceEventType of input event.
     * @param [modifier] - A KeyboardEventModifier key that is held when a <code>type</code>
     * event occurs.
     */
    getInputAction(type: number, modifier?: number): void;

Expected: returning a function like (...args: any[]) => any;

    /**
     * Returns the function to be executed on an input event.
     * @param type - The ScreenSpaceEventType of input event.
     * @param [modifier] - A KeyboardEventModifier key that is held when a <code>type</code>
     * event occurs.
     */
    getInputAction(type: number, modifier?: number): (...args: any[]) => any;
@rot1024 rot1024 changed the title getInputAction is wrong typed getInputAction is wrongly typed Jun 8, 2020
@mramato
Copy link
Contributor

mramato commented Jun 10, 2020

Thanks @rot1024, not sure how I missed this issue but you are absolutely correct. There are some additional ScreenSpaceEventHandler issues as well (CC #8945) so hopefully we can address them all for the 1.71 on July 1st

@mramato
Copy link
Contributor

mramato commented Jun 10, 2020

I tagged this specific issue for next release so that it definitely gets fixed.

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

Successfully merging a pull request may close this issue.

3 participants