Commit Graph

1126 Commits

Author SHA1 Message Date
Drew DeVault
4a1584be53 Fix background extensions
Thanks @Cloudef, it works great
2015-11-19 07:23:11 -05:00
Drew DeVault
65b8a5c3ce Add background handling
This does not work as expected. I think the problem is on the wlc side.
Please review, @Cloudef. To reproduce the issues:

1. Run sway
2. Open terminal in sway
3. Run swaybg

swaybg will create a surface and ask to have it set as the background,
but wlc_handle_from_wl_surface_resource will return 0. If the swaybg
surface is a shell surface, then it works - but wlc complains about the
pointer type and segfaults as soon as the pre-render hook tries to draw
the background.
2015-11-18 22:14:57 -05:00
Drew DeVault
82db2a57a9 Basic support for extensions in server and clients 2015-11-18 22:01:22 -05:00
Drew DeVault
fb0bfa13ce Fix warning about uninitialized variable 2015-11-18 19:59:47 -05:00
Drew DeVault
2f01a3265d Exit if unable to allocate buffer 2015-11-18 19:58:38 -05:00
Drew DeVault
7a40eb6de6 Support cursors over wayland clients
Apparently wayland has fucking client-side cursors, too
2015-11-18 19:38:42 -05:00
Drew DeVault
929537c158 Generate protocol headers 2015-11-18 17:59:35 -05:00
Drew DeVault
86372d00db Fix SIGBUS from wayland clients 2015-11-18 09:55:55 -05:00
Drew DeVault
665d4baaf1 Normalize indentation 2015-11-18 08:44:08 -05:00
Drew DeVault
9a1e95b7da Clean up memory pool files better 2015-11-18 08:36:08 -05:00
Drew DeVault
49388eb88b Support resizing in wayland client implementation 2015-11-18 08:27:40 -05:00
Drew DeVault
399220f14b Fix up wayland client implementation
Now it receives frame callbacks and renders properly, and is double
buffered and such.
2015-11-18 08:22:53 -05:00
Drew DeVault
01202568f9 Track pid of child process from exec
This will allow us to eventually open that process on the current view.
Requires support from @Cloudef.
2015-11-16 19:40:44 -05:00
Drew DeVault
6850174049 Merge pull request #233 from sce/multiple_adjacent_outputs
output: Support multiple adjacent outputs.
2015-11-16 15:57:02 -05:00
S. Christoffer Eliesen
236f26f62e output: Support multiple adjacent outputs.
When querying for an adjacent output we now need an absolute position in
order to know which adjacent output that matches. (The position is
either the current mouse position or the center of the currently focused
container, depending on context.)

If two outputs have one edge each that at least partially align with
each other they now count as adjacent.

Seamless mouse is affected by this and now properly moves and positions
itself between outputs with "uneven" placement (as long as they have at
least some part of the edge adjacent to each other).

When focusing or moving a container in a specified direction the center
of the current focused container decides where to look for an adjacent
output. So if e.g. an output has two adjacent outputs to the right and a
"focus right" command is issued then it's the placement of the currently
focused container that decides which output actually gets focused.

Also, if an output has at least one output adjacent in some direction
but the entire edge is not covered (ie. it has "holes" with no outputs),
then the algorithm will choose the output that is closest to the
currently focused container (this does not apply to seamless mouse, the
pointer will just stop at the edge in that case).
2015-11-16 21:32:18 +01:00
Drew DeVault
95c65ee33e Merge pull request #232 from sce/replace_output_config
cmd_output: Replace existing config if called multiple times.
2015-11-16 10:49:02 -05:00
S. Christoffer Eliesen
a94a91a723 cmd_output: Replace existing config if called multiple times. 2015-11-16 15:57:42 +01:00
Drew DeVault
00a4591b39 Update README 2015-11-15 20:22:28 -05:00
Drew DeVault
63a3f24b79 Merge pull request #230 from sce/code_overview
README: Add long code overview section.
2015-11-15 16:58:14 -05:00
S. Christoffer Eliesen
2f7f8512bd HACKING.md: Add code overview section. 2015-11-15 22:55:02 +01:00
Drew DeVault
cd161aa985 We somewhat more wlc_point now
Apparently I missed some

cc @Cloudef
2015-11-14 17:14:23 -05:00
Drew DeVault
95442dac8d We wlc_point now
cc @Cloudef
2015-11-14 11:30:29 -05:00
Drew DeVault
ab3d6f6fa1 Merge pull request #227 from xerpi/master
Check the client_setup() return value
2015-11-13 14:48:11 -05:00
Sergi Granell
a8b18b5159 Check the client_setup() return value 2015-11-13 20:42:45 +01:00
Drew DeVault
3dbdc40b0e Merge pull request #226 from sce/fix_get_socketpath
ipc: Store socketname in SWAYSOCK. Fixes `--get-socketpath`.
2015-11-13 14:10:00 -05:00
S. Christoffer Eliesen
f64b7e71d4 ipc: Store socketname in SWAYSOCK. Fixes --get-socketpath.
After adding pid to the socket path the `--get-socketpath` command broke
because it doesn't know the pid of the running instance. Fix this by
setting and querying `SWAYSOCK`.

Also ignore `SWAYSOCK` upon normal startup if a socket exists at that
location (ie. from another sway instance), and don't overwrite `I3SOCK`
if it exists either.
2015-11-13 18:18:52 +01:00
Drew DeVault
2cc6d39d46 New screenshot for README
This one was actually taken from within sway!
2015-11-13 11:07:57 -05:00
Drew DeVault
f7c0d2badb Clean up some things better in wayland clients 2015-11-13 10:27:16 -05:00
Drew DeVault
1011957465 Merge branch 'master' of github.com:SirCmpwn/sway 2015-11-13 08:17:35 -05:00
Drew DeVault
38b18d460a Revert "Try ~/.i3/config earlier than /etc/sway/config"
This reverts commit f0ceb4e909.
2015-11-13 08:17:29 -05:00
Drew DeVault
f3fc48f692 Merge pull request #225 from sce/logind_socket_path
ipc: Put socket into proper user runtime dir.
2015-11-13 08:15:14 -05:00
Drew DeVault
f0ceb4e909 Try ~/.i3/config earlier than /etc/sway/config
And ~/.config/i3/config, of course.
2015-11-13 08:09:30 -05:00
S. Christoffer Eliesen
253204efb9 ipc: Put socket into proper user runtime dir. 2015-11-13 14:07:18 +01:00
Drew DeVault
5c3f40111a Fix man page installs 2015-11-13 07:56:06 -05:00
Drew DeVault
fd1a59def3 Clean up CMake stuff 2015-11-13 07:17:48 -05:00
Drew DeVault
44d0b3282f Merge pull request #224 from mathstuf/cmake-cleanups
CMake cleanups
2015-11-12 22:20:44 -05:00
Ben Boeckel
8e8bdbcae2 cmake: run git in the source directory 2015-11-12 21:56:14 -05:00
Ben Boeckel
ec013d1f1a common: create a static library 2015-11-12 21:56:14 -05:00
Ben Boeckel
98678dea5d cmake: clean up installation rules 2015-11-12 21:56:14 -05:00
Ben Boeckel
f8ae8cb820 cmake: clean up definition settings 2015-11-12 21:56:14 -05:00
Ben Boeckel
28f1e9842c cmake: manipulate CMAKE_MODULE_PATH as a list
Also prefer local modules.
2015-11-12 21:56:14 -05:00
Ben Boeckel
2e9183e4de cmake: set the output directory once 2015-11-12 21:56:14 -05:00
Ben Boeckel
4714262c3d cmake: simplify manpage generation 2015-11-12 21:56:14 -05:00
Ben Boeckel
c8599dba02 cmake: use string(TIMESTAMP) 2015-11-12 21:56:14 -05:00
Ben Boeckel
f002baed7a cmake: bump requirement to 3.1.0
CMAKE_C_STANDARD was introduced in 3.1.0.
2015-11-12 21:43:21 -05:00
Drew DeVault
c43ef2aedd We don't need to implement strdup
After defining _GNU_SOURCE
2015-11-12 19:43:03 -05:00
Drew DeVault
11b1ba397f Further refinement of wayland client support 2015-11-12 19:35:39 -05:00
Drew DeVault
bfcabe48ef Start fleshing out wayland client implementation
This introduces a basic shared framework for making wayland clients
within sway itself.
2015-11-12 19:04:01 -05:00
Drew DeVault
5c4e98aa4e Merge branch 'master' of github.com:SirCmpwn/sway 2015-11-12 12:37:38 -05:00
Drew DeVault
ef8335d694 Start working on IPC for get_pixels
This is broken
2015-11-12 12:37:23 -05:00