aboutsummaryrefslogtreecommitdiffstats
path: root/vncviewer/Viewport.cxx
Commit message (Collapse)AuthorAgeFilesLines
* Retry connection in case of an errorJohannes2021-07-231-21/+29
|
* Merge branch 'autoclip' of https://github.com/CendioOssman/tigervncPierre Ossman2021-02-031-5/+7
|\
| * Improve clipboard debug logging in viewerPierre Ossman2021-01-041-5/+7
| |
* | Merge branch 'noblock' of https://github.com/CendioOssman/tigervncPierre Ossman2021-01-191-8/+16
|\ \ | |/ |/|
| * Better error messages when terminatingPierre Ossman2020-05-211-8/+16
| | | | | | | | | | Include something more user friendly when we need to fail fatally and not just the technical error.
* | Fake key release events for some Japanese keysPierre Ossman2020-11-201-0/+10
| | | | | | | | | | Windows either completely omits WM_KEYUP for these, or only sends it just before the next WM_KEYDOWN for the key.
* | Cancel AltGr timeout on mouse events as wellSamuel Mannehed2020-05-291-16/+32
|/ | | | | | | | | | We have a timer after Ctrl is pressed in order to see if an Alt will come right after. Ctrl + Alt is what windows sends for AltGr. If a key other than Alt was pressed we knew that we could cancel this timer, this commit extends that to mouse events too. Since this detection breaks the true order of events we want to make a decision as fast as possible.
* Add emulated middle mouse buttonAlex Tanskanen2020-01-161-16/+21
| | | | | | | | Not every mouse has three buttons e.g. laptops. Some OS might not have support for middle mouse button emulation. This commit adds emulation for middle mouse button when pressing both left and right mouse button simultaneously.
* Remove "Dismiss menu" from context menuAlex Tanskanen2020-01-091-8/+2
| | | | | This was not necessary since you could use ESC key or simply just clicking outside of the context menu to close the menu.
* Set initial blank cursorPierre Ossman2019-12-231-3/+6
| | | | | | | | If the server doesn't support local cursors and want to render them itself then we need to make sure the local cursor is invisible. This also makes sure we always have some cursor allocated, so we can remove the checks in some places.
* Use UTF-8 in clipboard APIPierre Ossman2019-07-011-11/+5
| | | | | In prepartion for better clipboard extensions that can send Unicode data between the client and server.
* Improved clipboard APIPierre Ossman2019-07-011-62/+81
| | | | | Change the internal clipboard API to use a request based model in order to be prepared for more advanced clipboard transfers.
* Add UTF-8 to/from ISO 8859-1 conversion routinesPierre Ossman2019-07-011-29/+13
| | | | | We convert between UTF-8 and ISO 8859-1 (latin 1) in several places so create some common routines for this.
* Clean up internal clipboard handlingPierre Ossman2019-07-011-5/+5
| | | | | | We now filter incoming data, which means we can start assuming the clipboard data is always null terminated. This allows us to clean up a lot of the internal handling.
* Make sure clipboard uses \n line endingsPierre Ossman2019-07-011-6/+10
| | | | | | This is required by the protocol so we should make sure it is enforced. We are tolerant of clients that violate this though and convert incoming clipboard data.
* Hide setPrimary parameter on non-X11 platformsPierre Ossman2019-04-011-0/+4
| | | | | | It is already hidden in the UI, so make sure it also is gone as a command line parameter. This follows the behaviour of the similar sendPrimary parameter.
* Only do initial LED sync if focusedPierre Ossman2019-02-281-3/+5
| | | | | | | | | | We always sync when we get focus, so this code path is really only for when the server announces LED state support after we already have focus. Make sure we only handle this specific scenario as otherwise we could end up syncing twice, which just toggles things back and forth and ends up syncing incorrectly.
* Merge branch 'connparams' of https://github.com/CendioOssman/tigervncPierre Ossman2018-12-101-5/+5
|\
| * Split out ServerParams from ConnParamsPierre Ossman2018-11-011-5/+5
| | | | | | | | | | | | We need to track different things in the server and client, so separate things to two independent structures to keep things more clear.
* | Fixed handling of AltGr from Windows' touch keyboardPierre Ossman2018-11-061-7/+13
| | | | | | | | | | | | We need to test this always in order to catch Ctrl+AltGr, and to handle release of the key properly. Hopefully there isn't any other case where VK_MENU is sent without a scan code.
* | Handle AltGr from Windows' touch keyboardPierre Ossman2018-11-061-0/+7
|/
* Ignore buttons in mouse leave eventsPierre Ossman2018-07-311-1/+4
| | | | | | | | For KDE we can sometimes get a bunch of stray FL_LEAVE events before gaining focus. Sending their included button information gets things in the incorrect order with regard to other synchronisation we do on focus. So just ignore buttons as the only information we want out of the leave information is a position update.
* Fix try/catch for flushPendingClipboard()Pierre Ossman2018-07-111-10/+10
| | | | | We put the try/catch as close as possible to the writes in all other case, so make sure this code also follows that pattern.
* viewer: reset ctrl / alt to menu state on focusDominique Martinet2018-07-081-0/+6
| | | | | | Setting Ctrl or Alt key on menu only sends the key press, and the state is lost when focus is lost and recovered. This checks the menu variable and sends the keys again if needed.
* Properly sync LED state on connectPierre Ossman2018-06-071-0/+10
| | | | | | We should start by getting the remote end in sync with the actual keyboard state. This would work randomly before depending on if we got the first LED state message before or after we got focus.
* Merge branch 'clipfocus' of https://github.com/CendioOssman/tigervncPierre Ossman2018-04-201-17/+104
|\
| * Avoid clipboard updates when not focusedPierre Ossman2018-03-261-0/+46
| | | | | | | | | | | | | | We don't want to surprise the user with unexpected clipboard changes when vncviewer is in the background, and it is both wasteful and possibly insecure to inform the server of every clipboard update when the user isn't interacting with it.
| * Add focus test helper for ViewportPierre Ossman2018-03-261-17/+13
| |
| * Handle LED state sync entirely in ViewportPierre Ossman2018-03-261-0/+15
| | | | | | | | | | Apply workaround for FLTK's bad focus handling so that we can let Viewport handle LED synchronisation without help from DesktopWindow.
| * Move server cut text handler to ViewportPierre Ossman2018-03-261-0/+30
| | | | | | | | | | That way both incoming and outgoing clipboard are both in the same place, making things clearer.
* | Stop abusing InputHandler class for write classPierre Ossman2018-03-281-7/+8
|/ | | | | | The handler is for incoming data and we should not be abusing that class for the writer class. Do proper write prototypes for the relevant functions.
* Handle Ctrl+AltGr on WindowsPierre Ossman2018-03-081-17/+17
| | | | | Improve AltGr detection even further on Windows so we can detect the case when Ctrl and AltGr are pressed together.
* Better detection of AltGr on WindowsPierre Ossman2018-03-081-34/+58
| | | | | | Try to properly detect the fake CtrlL+AltR sequence Windows sends when pressing AltGr. This allows us to send more accurate key events over to the server.
* Merge branch 'pause' of https://github.com/CendioOssman/tigervncPierre Ossman2017-11-171-8/+36
|\
| * Handle right shift better on WindowsPierre Ossman2017-11-131-0/+14
| | | | | | | | | | The shift buttons are a bit buggy on Windows unfortunately, but we can do slightly better than we're doing today.
| * Handle Windows scan code exceptionsPierre Ossman2017-11-131-9/+23
| | | | | | | | | | Windows mostly follows the AT set 1 scan codes that we want, but there are a few exceptions.
* | Remove double cursor workaround in clientPierre Ossman2017-11-171-6/+0
|/ | | | | We've fixed the issue more properly in the server now, so remove the workaround we had in the client.
* Be explicit which Exception class we wantPierre Ossman2017-09-181-2/+2
|
* Add support for raw keyboard in vncviewerPierre Ossman2017-09-111-52/+122
| | | | | Make sure it can map between the key codes of the local system in to the key codes used by the protocol.
* Basic support for QEMU Extended Key EventsPierre Ossman2017-08-281-6/+6
| | | | | | This adds the basic infrastructure and handshake for the QEMU Extended Key Events extension. No viewer or server makes use of the extra functionality yet though.
* Sync LED state when gaining focusPierre Ossman2017-08-241-0/+81
| | | | | The state might have changed when we didn't have focus. Get everything back in sync once we're back in control.
* Add client support for LED state syncPierre Ossman2017-08-241-0/+172
|
* Change cursor API to use RGBA dataPierre Ossman2017-02-221-34/+8
| | | | | This will allow us to use better formats that preserve the entire alpha channel.
* Render on a temporary surface when neededPierre Ossman2017-02-101-0/+13
| | | | | | Some platforms draw directly to the screen, which means that updates will flicker if we draw multiple layers. Prevent this by first composing the update on a hidden surface.
* Abstract platform rendering to "surfaces"Pierre Ossman2017-02-101-34/+2
| | | | This will allow us to render more things than just the framebuffer.
* Respect SendClipboard settingPierre Ossman2017-01-021-0/+3
|
* Only show sendPrimary on X11 platformsPierre Ossman2015-12-111-0/+2
| | | | | Primary selection is inherently a X11 concept so there is no point showing the settings related to it on other platforms.
* Delegate decoder object management to a separate classPierre Ossman2015-11-271-49/+7
| | | | | | | | | Done in preparation for multi-core decoding. Keeps the complexity out of the other classes. This also moves ownership of the framebuffer in to CConnection. It's the CConnection object that is aware of the threads and how to synchronise with them. Therefore the ownership of the framebuffer must also be there to make sure it isn't deleted whilst threads are working.
* Give context for strings used in menusPierre Ossman2015-09-231-22/+25
| | | | | Makes it easier to see which hot-keys might conflict with each other, and allow some variation in translation in the future.
* Display partial updates on slow transfersPierre Ossman2015-09-231-1/+0
| | | | | | | Normally we only display screen changes once we have the updates for the entire screen. This may give the impression that the viewer is hung though. So display the partial data if the update is taking to long to arrive.