The disconnect() function were not checking the existence of the file
transfer area element, leading to stop the disconnect() before its end.
Signed-off-by: Jeremy White <jwhite@codeweavers.com>
We don't want the users to rely on anything else than main.js. All the
helper functions from the other files are thus imported in main and
exported there too.
This way all the user needs to import is:
import * as SpiceHtml5 from './main.js';
Signed-off-by: Jeremy White <jwhite@codeweavers.com>
It is possible to transfer files from the client to the guest
using File API [0] when a spice vd agent is connected.
Methods for the transfer are based on spice-gtk implementation.
[0] http://www.w3.org/TR/file-upload/
The first approach is to use a moving image to simulate the cursor.
This does not work well, so a second approach, involving static
cursors is provided. That requires a site administrator to precreate
all the cursors that can be used by a particular application set.
A warning message strongly suggests using a different browser as well.
This allows IE10 to function. Note that we would normally subclass
this type, but ArrayBuffer is implemented in native code, and so is
difficult to subclass.