Commit Graph

59 Commits

Author SHA1 Message Date
Alexander Larsson
fbefec52a5 Broadway: Add id for nodes and reuse old ones
When sending render nodes from the client to the daemon we add an id,
and whenever we're about to re-send the entire tree node we instead
send the old id. We track all the nodes for the previous frame
of the surface this way.

Having the id on the daemon side will allow us do to much better deltas.
2019-03-26 17:07:47 +01:00
Alexander Larsson
b097f0a7d8 Broadway: Add node for debug nodes
This can be helpful when debugging broadway.
2019-03-26 17:07:47 +01:00
Alexander Larsson
1b5b1bfd0e broadway: Don't fall back for translation transform nodes
These are trivial anyway
2019-03-26 17:07:47 +01:00
Alexander Larsson
d141bd4121 broadway: Use "surface" instead of window/toplevel for browser object
Als fixes indentation/tabs and removes some unused code.
2017-12-05 15:50:34 +01:00
Alexander Larsson
e80ad0e0f9 broadway: Remove references to unused BROADWAY_EVENT_DELETE_NOTIFY 2017-12-05 15:50:34 +01:00
Alexander Larsson
521b09cc96 broadway: Send diffs of node trees
Reusing pre-created nodes is a lot faster both in terms of
dom modifications and of transfer sizes.
2017-11-30 21:57:42 +01:00
Alexander Larsson
3d4a9324e6 broadway: Add broadway_node_equal 2017-11-30 21:57:42 +01:00
Alexander Larsson
1820362b2b broadway: Deserialize node tree in server
This doesn't really change anything, but it is in preparation for diffing
the trees.
2017-11-30 21:57:42 +01:00
Alexander Larsson
cfb76fedb6 broadway: Roundtrip each update to rate limit redraw 2017-11-23 10:48:29 +01:00
Alexander Larsson
b74959a605 broadway: Add clip node 2017-11-23 10:48:29 +01:00
Alexander Larsson
9e5a22bbe5 broadway: Add opacity node 2017-11-23 10:48:29 +01:00
Alexander Larsson
9b1f6acc2b broadway: Add shadow node 2017-11-23 10:48:29 +01:00
Alexander Larsson
278370c8e5 broadway: Add linear gradient node 2017-11-23 10:48:29 +01:00
Alexander Larsson
f7ff6dbb66 broadway: Add RoundedClip node 2017-11-23 10:48:29 +01:00
Alexander Larsson
0083c084e4 broadway: Add inset shadow 2017-11-23 10:48:29 +01:00
Alexander Larsson
35ceb8e626 broadway: Add outset shadow node 2017-11-23 10:48:29 +01:00
Alexander Larsson
cf03229a99 broadway: Add border node 2017-11-23 10:48:29 +01:00
Alexander Larsson
0b38ab339e broadway: Add color nodes 2017-11-23 10:48:29 +01:00
Alexander Larsson
fd0285de09 broadway: Rewrite textures in nodes to global 2017-11-23 10:48:29 +01:00
Alexander Larsson
54e7a8f0c0 broadway: Remove remaining unused window_update code 2017-11-23 10:48:29 +01:00
Alexander Larsson
f7d8ee041b broadway: Initial version of using actual render nodes 2017-11-23 10:48:29 +01:00
Alexander Larsson
cc7423855b broadway: Use textures to configure window contents
Instead of using the old buffer code, just use textures to define the
window contents.
2017-11-23 10:46:47 +01:00
Alexander Larsson
ef79621c44 broadway: Introduce global ids for the textures 2017-11-23 10:46:47 +01:00
Alexander Larsson
48d587d255 broadway: Add support for uploading textures to daemon 2017-11-23 10:46:47 +01:00
Alexander Larsson
f31d7e1f91 broadway: Support fd passing in protocol
This will be used to pass buffers
2017-11-23 10:46:47 +01:00
Alexander Larsson
43a02da07b broadwayd: Read using socket API
This changes nothing, but it allows us to later recieve
unix messages and thus fd passing
2017-11-23 10:46:47 +01:00
Alexander Larsson
620d3cf402 broadway: Only support (non-abstract) sockets
We want to use fd passing, so drop tcp
2017-11-23 10:46:47 +01:00
Benjamin Otte
c1e9869329 build: Don't turn off critical warnings
-Wint-conversion is important because it checks casts from ints to
pointers.

-Wdiscarded-qualifiers is important to catch cases where we don't
strings when we should.
2017-10-06 16:03:08 +02:00
Matthias Clasen
b15bc437a6 Rename broadwayd to gtk4-broadwayd
This was the last unprefixed binary, and it was causing file
conflicts between gtk3 and gtk4.
2016-11-18 13:40:37 -05:00
Matthias Clasen
94342300a8 broadway: Strip newlines from g_warning and g_error
g_logv adds one for us already.
2016-02-28 12:23:12 -05:00
Benjamin Otte
a2ac9524bc broadway: Define variables where they are used
Avoids gcc warnings about unused variables.
2016-02-03 23:07:05 +01:00
Ting-Wei Lan
f4d2d66b1e broadway: Call setlocale in main function of broadwayd
It is required to correctly show translated messages on some locales.

https://bugzilla.gnome.org/show_bug.cgi?id=760416
2016-01-12 23:00:03 -05:00
Matthias Clasen
9c1063f602 broadway: Only use abstract sockets when they are supported
GIO has a function to check whether abstract sockets are
supported, so use it. This should make broadway work on
Freebsd again.

https://bugzilla.gnome.org/show_bug.cgi?id=742980
2015-01-18 15:24:30 -05:00
Michael Natterer
c00cc269c5 broadway: Initial SSL support
Use the new --cert and --key parameters to broadwayd to pass paths to
cert and key files.

https://bugzilla.gnome.org/show_bug.cgi?id=730364
2014-12-15 11:25:43 +00:00
Matthias Clasen
24b8499833 Broadway: Fix various compiler warnings
Mostly missing declarations and unused functions.
2014-09-05 19:39:05 -04:00
Domenico Tortorella
43bddd205b BroadwayServer support for unix socket listening
At the present time broadway listens only for TCP/IP incoming
display connections. This patch implements the support for listening
on unix domain sockets too, adding the broadway_server_on_unix_socket_new()
constructor and the commandline option --unixsocket [path] to broadwayd.

https://bugzilla.gnome.org/show_bug.cgi?id=734420
2014-08-14 20:24:10 -04:00
Alexander Larsson
4226f97d54 broadway: Support ipad on-screen keyboard
We add a custom im module for broadway that calls some broadway
specific APIs to show/hide the keyboard on focus in/out. We then forward this
to the browser, and on the ipad we focus an input field to activate
the keyboard.
2013-11-13 12:23:06 +01:00
Alexander Larsson
82acc05cba broadway: Add initial touch event support
This seems to get something going on an ipad, but some events seem
to get swallowed. For instance, window dragging doesn't work.
2013-11-12 16:11:15 +01:00
Alexander Larsson
ddade66496 broadway: use 'click-to-focus' approach instead of 'focus-follows-mouse'
The broadway backend would move the focus from one window to another based on
where the mouse was (i.e. 'focus-follows-mouse' approach). Handling the focus
this wait didn't play well with widgets which rely on focus-in-event and
focus-out-event, like the GtkEntry when using a completion popup window, see
e.g:
  https://bugzilla.gnome.org/show_bug.cgi?id=708984

So instead, setup broadway to require a click in a window to move the focus
(i.e. 'click-to-focus' approach):

 * The implicit GDK_FOCUS_CHANGE events that were generated upon reception of
   BROADWAY_EVENT_ENTER or BROADWAY_EVENT_LEAVE are removed.

 * The broadway daemon will now keep track of which is the focused window

 * Whenever the daemon detects an incoming BROADWAY_EVENT_BUTTON_PRESS, it will
   trigger the focused window switch, which sends a new BROADWAY_EVENT_FOCUS to
   the client, specifying which windows holds the focus.

 * Upon reception of a BROADWAY_EVENT_FOCUS, the client will generate a new
   GDK_FOCUS_CHANGE.

 * gdk_broadway_window_focus() was also implemented, which now requests the
   focus to the broadway server using a new BROADWAY_REQUEST_FOCUS_WINDOW.

This is based on an initial patch from Aleksander Morgado <aleksander@lanedo.com>.
2013-11-12 12:03:50 +01:00
Alexander Larsson
b436f06a94 broadway: Remove window translation code
This is no longer used as we neutered gdk_window_scroll & co.
2013-11-07 14:09:53 +01:00
Tarnyko
4b49c44b0a win32: Make broadway build 2013-07-01 14:46:25 +02:00
Tarnyko
e2da2259ad broadway: Support TCP displays 2013-06-13 19:12:46 +02:00
Tarnyko
d4dacc596f broadway: Only use gio-unix on G_OS_UNIX 2013-06-13 18:15:10 +02:00
Tarnyko
b20d949470 broadway: Add configure checks for sys/mman.h 2013-06-13 18:01:44 +02:00
Alexander Larsson
c6baa9bc25 broadway: Move surface open to server
This way we can cache the last opened surface
2013-03-29 14:09:47 +01:00
Alexander Larsson
8fb60cda19 broadway: Fix assert failure
Requests are not limited in size by BroadwayRequest, as
BroadwayRequestTranslation can be of variable size. No need
to copy the request anymore though, because requests are aligned
now.
2013-03-18 16:41:05 +01:00
Alexander Larsson
2e76e5a543 broadway: Allow binding http server to an ip 2013-01-10 21:38:39 +01:00
Alexander Larsson
d5812de2e6 broadway: Send window size to new clients
Tell all new clients about the current (last sent) window size.
2013-01-08 18:05:06 +01:00
Alexander Larsson
8e686357c4 broadway: Move window position ownership to browser
With this we always roundtrip position change to the webbrowser.
This avoids conflicts when things change from both directions (app and user).

Also, we fake configure evens when there is no web client to ensure
apps get the events.
2013-01-08 18:05:06 +01:00
Alexander Larsson
6f910e5e02 broadway: Clean up broadwayd event sending code
Use the right size and put the client serial in the right place.
2013-01-08 18:05:06 +01:00