why does pano require an initial click to get started?

  • I am new here and just starting to learn about using krpano. It looks great!

    I took one of the example panos and started editing it to get a feel for the product. I turned off the mouse by setting usercontrol to "keyb".
    I found that the pano requires a single mouse click (at least one) to allow me to use the keyboard arrows to move the pano.

    I used the onready statement to trigger an initial .focus() and/or a .click on the pano but they didn't work.

    Why does it require this initial click? Once I have made a single click then I can use focus() in the reset button and elsewhere to get the pano to accept other arrow keys for movement.

    My pano is here: http://demo.xplotiv.com/krpano/pano.html

    Thanks!
    -Kim

  • Hi,

    in Flash this is given by the Flashplayer, but in HTML5 the krpano viewer itself is wait for getting a mouse or touch down before taking the keyboard control.

    Here a way/hack to give krpano manually the keyboard focus on startup (for HTML5):

    Code
    embedpano({..., id:"krpanoSWFObject", onready:krpano_onready});
    
    
    function krpano_onready()
    {
      window.activekrpanowindow = "krpanoSWFObject";
    }

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!