WordPress.org

Support

Support » Plugins and Hacks » [Resolved] Add keyboard functionality

[Resolved] Add keyboard functionality

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Stefan Boonstra
    Member

    @stefanboonstra

    Not yet, but I might add it as an option in a future release. Button functionality will probably be available when touchscreen control is implemented.

    frankaguilar
    Member

    @frankaguilar

    In “js/SlideshowPlugin/slideshow.js” add this code to put keyboard functionality to the slider. Hope this helps and saves you time!

    $(document.documentElement).keyup(function (event) {
    // handle cursor keys
    if (event.keyCode == 39) {
    resetInterval();
    gotoView(1, true)
    } else if (event.keyCode == 37) {
    // go right
    resetInterval();
    gotoView(-1, true)
    }
    });
    $previousButton.click(function () {
    if ($buttonsActive) {
    resetInterval();
    gotoView(-1, true)
    }
    });

    Plugin Author Stefan Boonstra
    Member

    @stefanboonstra

    Thanks, I love it that you’re thinking along!

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘[Resolved] Add keyboard functionality’ is closed to new replies.