Commit Graph

1256 Commits

Author SHA1 Message Date
Solly Ross 6048299a13 Use textContent instead of innerHTML
Previously, setting `innerHTML` was used to display the statuses.  These
could include content communicated from the remote VNC server, allowing
the remove VNC server to inject HTML into the noVNC page.

This commit switches all uses of `innerHTML` to use `textContent`, which
is not vulnerable to the HTML injection.
2017-01-12 14:47:36 -05:00
Samuel Mannehed 41f476a863 Add Pierre Ossman to core team 2017-01-12 09:38:23 +01:00
Samuel Mannehed 3e08594c89 Fix rfb._cleanup() (#743)
We don't have to check for _display or context here since this is a
private function which is never called under such circumstances. This
solves problems caused by display.get_context() which was previously
removed in e549ae074f.
2017-01-09 12:49:10 +01:00
Solly Ross 16ed7b8b43 Merge pull request #715 from CendioOssman/cleanup
Cleanup of settings (amongst other things)
2017-01-06 14:08:59 -05:00
Pierre Ossman 813458923e Avoid wrapping labels 2017-01-04 15:05:59 +01:00
Pierre Ossman cac935ffc2 Clean up z index ordering
We have enough layers now that we need to have some system for this.
E.g. make sure that dialogs during connect show up in front of the
blocking transition layer.
2017-01-04 15:05:59 +01:00
Pierre Ossman b3c932c386 Make connect button more prominent
It's generally the only thing the user needs to click on, so make
sure it clearly stands out.
2017-01-04 15:05:58 +01:00
Pierre Ossman 512d3605ad Remove connect dialog
It only contained a password field, which might not be needed, and
is handled by a separate dialog if it is.
2017-01-04 15:05:01 +01:00
Pierre Ossman ef3e12b595 Remove vendor prefix from border-radius
It's been standardised for quite some time, so remove the extra
noise in the CSS.
2017-01-04 15:05:01 +01:00
Pierre Ossman 13304bacd0 Group rarely changed settings together 2017-01-04 15:05:01 +01:00
Pierre Ossman 575f69832d Group WebSocket settings together
It was easy to confuse them as being VNC settings, so keep them all
under one group.
2017-01-04 15:05:01 +01:00
Pierre Ossman 340d9d66cc Remove alternative style sheets
Anyone with basic knowledge of CSS will easily figure out how to
customise the appearance of the UI, so remove the burden of having
to maintain these extra style sheets.
2017-01-04 15:05:01 +01:00
Pierre Ossman 58fc267b2b Remove unused token setting 2017-01-04 15:05:01 +01:00
Pierre Ossman 47fbdced45 Center canvas vertically as well 2017-01-04 15:05:01 +01:00
Pierre Ossman 8f2ca5feaa Black out background when connected 2017-01-04 15:04:51 +01:00
Lee-Feng 558544364c Fix no auth "this._updateState" bug
Fixes #735
2016-12-20 08:37:31 +01:00
Samuel Mannehed c01b2f0259 Merge pull request #699 from CendioOssman/double
Display double buffering
2016-12-13 12:42:22 +01:00
Pierre Ossman adf345fdc4 Clean up viewport handling
Make sure the viewport is properly updated when necessary, on respects
given restrictions.
2016-12-09 09:20:50 +01:00
Pierre Ossman 3f781f2aa3 Remove max dimension handling
The viewport handling is now a lot clearer, so simply limit the size
of the viewport in the caller rather than having this extra layer
of checks.
2016-12-09 09:20:50 +01:00
Pierre Ossman e549ae074f Prevent access to sensitive display variables
These should not be directly accessed. Instead use drawing operation
and Display.resize().
2016-12-09 09:20:50 +01:00
Pierre Ossman 84cd0e719e Double buffering damage tracking
Optimise the copy from the hidden canvas to the visible one a bit
by only copying the modified area.
2016-12-09 09:20:50 +01:00
Pierre Ossman 2ba767a7fe Use double buffering for the display
Do all rendering to a hidden canvas and then copy over the finished
frame to the visible canvas once everything is done. This simplifies
things and solves some bugs as we can retain a copy of the entire
frame buffer.
2016-12-09 09:20:50 +01:00
Pierre Ossman 18d21e3621 Update all state on session size change 2016-12-09 09:20:50 +01:00
Pierre Ossman 02329ab19c Don't violate Display abstraction
Use the normal API as much as possible instead of poking around in
internals that might change.
2016-12-09 09:20:50 +01:00
Pierre Ossman 3181a032f8 Add test for Display.flush() 2016-12-09 09:20:50 +01:00
Pierre Ossman 74e390512d Remove blitStringImage() in favour of imageRect()
The latter is more generic and can easily be modified for other
mechanisms in the future.
2016-12-09 09:20:50 +01:00
Pierre Ossman 18e96092c3 Flush out rendering after each performance test
There might be operations pending in the render queue. Make sure
these are fully handled before we consider the test run over.
2016-12-09 09:20:39 +01:00
Pierre Ossman e12e2759b0 Run performance tests at full speed
setTimeout() is subject to delays, possible massive ones. As such it
is rather useless for performance sensitive code. Use the non-standard
setImmediate() API instead, emulating it on postMessage() when it
isn't available.
2016-12-06 16:14:11 +01:00
Samuel Mannehed e663da8c32 Merge pull request #727 from CendioOssman/travis
Fix travis tests
2016-12-01 10:43:35 +01:00
Pierre Ossman 6ec3af22ca Skip language tests on broken browsers
The hacks needed to run these tests require proper handling of
properties. Unfortunately IE and old versions of Chrome mess up,
so just skip the tests there.
2016-11-29 17:00:24 +01:00
Pierre Ossman acca6487f2 Update test platforms
Test on the latest version of everything, as new versions are
coming out constantly. Also add some missing combinations.
2016-11-29 17:00:24 +01:00
Samuel Mannehed a8cc32d8b9 Merge pull request #725 from CendioOssman/rightbar
Allow control bar to be moved to the right side
2016-11-29 13:23:02 +01:00
Samuel Mannehed 77bc3a551b Fix translation util tests
We have to temporarily replace window.navigator due to the fact that
its property languages is read-only. The tests for the translation
utilities require different values of this property. The failing tests
were added in merge of PR #718 (in commit
f5bf2d84ef).
2016-11-28 16:14:55 +01:00
Samuel Mannehed ffa819eec1 Remove duplicate line 2016-11-28 16:11:03 +01:00
Samuel Mannehed d062074b5a Clear UI.connected state variable right away
Keeping it set for the disconnecting state was causing an issue where
the controlbar could be hidden without any way to open it, when a
session disconnects too quickly.
2016-11-28 12:36:29 +01:00
Samuel Mannehed d8ff7c9ed6 Further fixes for fallback error handler
Layout improvements as well as an check for ErrorEvent.error as it is
not standardized.
2016-11-28 12:33:42 +01:00
Samuel Mannehed 38d8cfdf83 Fix fallback error handling
Start using the correct API for window.addEventListener('error',..).
Unlike when using onerror, the handler function gets an event.
2016-11-28 10:02:13 +01:00
Pierre Ossman cf348b7892 Remember control bar position 2016-11-26 15:26:28 +01:00
Pierre Ossman 8ee432f1db Allow control bar to be moved to the right side 2016-11-26 15:13:33 +01:00
Pierre Ossman de315d6216 Touching the handle should keep the control bar visible
Calling stopPropagation() was causing the normal event listeners
to never get the proper events.
2016-11-24 17:03:47 +01:00
Samuel Mannehed 38f3d92c5e Merge pull request #720 from kosmasgiannis/locale-el
Update Greek translation
2016-11-24 11:50:01 +01:00
Giannis Kosmas dd085b40a9 Update Greek translation 2016-11-24 12:18:59 +02:00
Samuel Mannehed f5bf2d84ef Merge pull request #718 from ossman/po
Use gettext .po files, and translate everything
2016-11-22 21:02:13 +01:00
Samuel Mannehed 7629b03ee9 Added more useful links to README 2016-11-22 00:59:11 +01:00
Samuel Mannehed b55bfcf04b Formatting cleanup of README 2016-11-22 00:37:52 +01:00
Samuel Mannehed 4cb91c4269 Update browser requirements in README 2016-11-22 00:29:21 +01:00
Samuel Mannehed 0f725a3061 Update description in README 2016-11-22 00:03:28 +01:00
Samuel Mannehed 1983baf5bf Fix link tagname 2016-11-21 13:43:02 +01:00
Pierre Ossman 79b05f9f19 Update Swedish translation 2016-11-19 13:23:00 +01:00
Pierre Ossman edffd9e2f8 Also translate HTML elements 2016-11-19 13:23:00 +01:00