Commit Graph

35 Commits

Author SHA1 Message Date
Armin Novak fe4cb6de65
[warnings] fix float/double warnings 2024-09-02 16:20:20 +02:00
akallabeth d7ebec5a65 [tidy] move loop variable declaration to loop 2024-02-22 12:31:50 +01:00
akallabeth 0ba995655d [clang-tidy] cppcoreguidelines-init-variables 2024-02-15 11:49:16 +01:00
akallabeth 207def5c56 [clang-tidy] readability-isolate-declaration 2024-02-15 11:49:16 +01:00
akallabeth 4e438d1c3e [client] make settings opaque 2023-11-24 14:54:56 +01:00
James Fu a04021d38b Send resize on window state change 2022-09-22 13:48:24 +02:00
Armin Novak 98f9c7e04b Fix #8176: Check fullscreen state and not setting
Timer based dynamic resolution updates are disabled in fullscreen
state. Check current value and not (permanent) setting
2022-09-14 08:51:54 +02:00
akallabeth fb90ac280a Refactored color.h
* Remove implementations from header
* Rename functions to be FreeRDP specific
* Add deprecation define for old names
* Fixed missing includes
2022-04-28 08:40:47 +02:00
akallabeth 7641710f60 Use a client/common context component
* Allows moving common client code from specific client to a
  generic client/common implementation
2022-02-22 09:44:13 +01:00
akallabeth 8cc6582044
Unify struct definitions (#7633)
* Unified enum/struct definitions, fixed include issues

* Fixed mac compilation issues

* Added missing include

* Fixed windows server build warnings

* Fixed VS2010 build issue

* Removed unnecessary library linking

* Fixed ThreadPool WinXP compatibility

* Fixed pr review remarks
2022-02-14 14:59:22 +01:00
Armin Novak 2e17cee5a9 Fixed various warnings. 2022-01-31 15:55:10 +01:00
akallabeth e6e6ed5dbd Cleaned up PubSub
* Callback arguments now const
* Fixed missing includes
2022-01-19 09:24:57 +01:00
akallabeth 1dae0552d7 Fixed various warnings 2021-02-16 16:28:57 +01:00
akallabeth d3ed42a799 Fixed #6801: Delay sending of resolution change
Changed the logic of the disp channel to wait for 800ms after a
ConfigureNotify before sending the new resolution.
The problem fixed with this patch is the following:
1.  Resize the window with the mouse
2.  ConfigureNotify triggers a resize notification
3.  The server resizes to the desired resolution
3a. More ConfigureNotify events are generated
4.  The local window resize to the new resolution triggers another
    ConfigureNotify

a. Depending on the timing (sending is already rate limited) the
   events from 3a and 4 will make the size of the window jump
b. Very fast resizing will pick a random resolution from the
   sequence of ConfigureNotify events as the final resolution
2021-02-10 15:38:03 +01:00
akallabeth 13c8a60b70 Fixed display channel anounce race
* The display resolution change message was prone to a race condition
* Check for actual fullscreen state instead of settings
* Assume 75dpi for display resolution to mm conversion
2020-11-13 18:09:07 +01:00
Armin Novak f32a46370c X11 XEvent disp refactored to use const arguments 2020-03-04 10:38:41 +01:00
Armin Novak 72ca88f49c Reformatted to new style 2019-11-07 10:53:54 +01:00
Armin Novak 05901280fe Fixed unused argument warnings. 2019-04-05 09:14:35 +02:00
Armin Novak a471fc5939 Spelling fix in log message.
Integrate spelling fix from debian patch from
Mike Gabriel <mike.gabriel@das-netzwerkteam.de>
2018-11-22 12:06:30 +01:00
Armin Novak a8a6accc15 Fixed compiler warnings. 2018-10-03 15:16:59 +02:00
Armin Novak 00489ae75b Reworked checks in xf_disp.c 2018-10-02 12:33:52 +02:00
Armin Novak 8357f61818 Fixed load/unload for display channel. 2018-09-24 16:44:25 +02:00
Armin Novak 51f97f2d3e Fixed #3423: Process xevents when in reconnect mode.
Fixed crashes due to unloaded disp channel in reconnect mode.
2018-09-24 16:24:32 +02:00
Armin Novak 02dc6ab3f7 Fixed single monitor fullscreen resolution update. 2018-08-21 13:00:39 +02:00
Armin Novak a334aa9657 Fixed #4786: Added fullscreen handling for dynamic resolution. 2018-08-08 13:04:26 +02:00
Armin Novak 4e4ec0b035 Fix #4752: Unsubscirbe all PubSub in dynamic channel. 2018-07-18 14:29:22 +02:00
Armin Novak ced4d06f74 Fixed #4679, #4753 dynamic resizing
Simplified resize logic, do not check before setting current resolution.
2018-07-18 09:48:19 +02:00
Bernhard Miklautz c0afb8bd6b
Merge pull request #4322 from akallabeth/rail_fixes
Rail fixes for GFX mode
2018-04-11 10:49:44 +02:00
Armin Novak 990b8c23a9 Fixed PubSub function pointer casts. 2018-02-14 11:00:52 +01:00
David Fort 441975a4aa video, geometry: fix prototypes for timer callbacks 2018-02-14 10:16:38 +01:00
Armin Novak 51e59e1f2e Check argument, xfc->window is NULL in RAILS mode 2018-01-08 13:21:03 +01:00
David Fort 191b8f950f Fix for #4330
Since ec027bf dynamic resolution is broken when used with egfx. Before that commit
we were tracking a server sent resize by setting a DesktopResize callback. This callback
is called when the desktop is resized by the server. Anyway the problem was that when this
callback is called, the activation sequence is not always completed, which were leading to
some freeze with 2012r2 servers (sending packets before the sequence is finished).
So with the faulty commit, we are tracking server resizes by subscribing to the Actived
event, that is called at the end of a reactivation sequence, so we're sure to not send packets
when not fully activated.
Anyway the issue that shows on (#4330) is that when you use egfx, no reactivation sequence happens,
the server only sends a ResetGraphics message with the new size, and so we miss the resized event.
This fix introduces a new GraphicsReset event, makes the display channel subscribe to that event,
and react accordingly.
2017-12-23 13:50:54 +01:00
David Fort 58b5573c82 Use more xrandr attributes when available and preserve [desktop|device]ScaleFactor
Fix a too restrictive detection of XRandr support.
Set more monitor's attributes like physical size and orientation when XRandr is
available.
Set [desktop|device]ScaleFactor when it has been given on the command line, this
should fix #4324.
2017-12-23 13:46:42 +01:00
David Fort ce89a9096e disp: improve window resizing
To workaround a bug with 2012r2 servers, don't send any resize during renegociation
and don't resize at a too high rate (every 200ms is good enough).
2017-12-19 20:59:10 +01:00
David Fort 80dab90f1a disp: implement dynamic resolution for X11
If the display channel is available we use it to allow the user to resize the
xfreerdp window. When the window is resized we announce a new monitor layout and
the server reacts by doing a reactivation sequence to the new size.
The minimum window size is limited to 300x300 as 2012 servers crash horribly
if we send them a smaller layout.
2017-12-14 15:13:11 +01:00