aboutsummaryrefslogtreecommitdiff
path: root/sway/handlers.c
AgeCommit message (Collapse)Author
2015-11-19Add wallpapers to output commandDrew DeVault
2015-11-19Fix background extensionsDrew DeVault
Thanks @Cloudef, it works great
2015-11-18Add background handlingDrew DeVault
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-16output: Support multiple adjacent outputs.S. Christoffer Eliesen
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-14We somewhat more wlc_point nowDrew DeVault
Apparently I missed some cc @Cloudef
2015-10-29input_state: Remove mouse_origin (x&y). Query wlc instead.S. Christoffer Eliesen
2015-10-29input_state: Extract 'pointer_position_set' function from handlers.S. Christoffer Eliesen
2015-10-29container: Move container_under_pointer here from handlers.S. Christoffer Eliesen
2015-10-27handlers: Pass workspace to workspace_switch, not output.S. Christoffer Eliesen
2015-10-25sway/output: Create, move code from handlers.c here.S. Christoffer Eliesen
2015-10-23Update set_origin to match wlc changesDrew DeVault
2015-10-23seamless_mouse: Move pointer only if successfully changed workspace.S. Christoffer Eliesen
If e.g. a window has a popup open then that will lock the current focus, making a workspace switch denied. So don't move the mouse pointer in such cases.
2015-10-23handlers: Don't switch output when mouse button is pressed.S. Christoffer Eliesen
(E.g. if the user is using a scrollbar at the edge of the screen then switching workspace would cancel the scroll.)
2015-10-22ipc,commands,config: Replace cmd_status enum with cmd_results struct.S. Christoffer Eliesen
In i3 the ipc reply will contain a human readable error message, and this patch replicates that behaviour. However, that error message is also useful for logging, which this patch takes advantage of. E.g. instead of logging errors directly in commands.c/checkargs, it is fed back to the caller which eventually ends up logging everything with maximum context available (config.c/read_config). So instead of logging e.g. "Error on line 'exit'" it will now log: "Error on line 'exit': Can't execute from config."
2015-10-22handlers: Fix swapped top/bottom for seamless transitions.S. Christoffer Eliesen
2015-10-22Move pointer during seamless transitionsDrew DeVault
2015-10-22config: Add "seamless_mouse" to decide if pointer crosses output edges.S. Christoffer Eliesen
2015-10-22Switch to adjacent output when hitting output edge.S. Christoffer Eliesen
(Currently, after switching output the relative position of the mouse stays the same.)
2015-09-22Merge branch 'master' of https://github.com/taiyu-len/swaytaiyu
merge
2015-09-22#184taiyu
2015-09-18minor fixtaiyu
2015-09-13Revert "new_workspace null behavior + testmap functions + regex"Drew DeVault
This reverts commit e1d18e42a8f3a597b9bf5f1bb2ab6c346e4e7983. Fixes #180 cc @taiyu-len
2015-09-12new_workspace null behavior + testmap functions + regextaiyu
2015-09-10cmd status + workspace ws output optaiyu
2015-09-07config modestaiyu
2015-09-06config_path cleanuptaiyu
2015-09-02properly free cmd_queue, should partially fix #165 from what i tell from its ↵taiyu
log.
2015-08-30#154 destroy view handler properly destroys viewstaiyu
2015-08-29Made scratchpad handling identical to i3Luminarys
2015-08-28#149 change focus before pointer_modetaiyu
2015-08-28#149 fix, reorder floating windows on click.taiyu
2015-08-28#148 fix, choose non-floating view for inserting containertaiyu
2015-08-28styletaiyu
2015-08-28fix issue #140, dont set pointer mode if no floating_modtaiyu
2015-08-27Added in default_orientation handlingLuminarys
2015-08-26move workspace from dead output to other outputtaiyu
2015-08-26Do not pass modifiers when getting keysyms from wlcDrew DeVault
Fixes #124 Keyboard handling can likely be simplified after this change.
2015-08-25Merge pull request #133 from minus7/wlc-keyboard-fixDrew DeVault
fixed keyboard handling
2015-08-25fixed keyboard handlingminus
handle_key does not get the keysym from wlc anymore
2015-08-25fixed segfault on exit + a little fixup of that floatfocus prtaiyu
2015-08-25Merge pull request #131 from nicklaswj/masterDrew DeVault
Focus floating window, if any, when the last tiling window has been closed
2015-08-25code style clean upNicklas Warming Jacobsen
2015-08-25removed stupid test codeNicklas Warming Jacobsen
2015-08-25Focus floating window, if any, when the last tiling has been closedNicklas Warming Jacobsen
2015-08-25changed view visibility to be boolminus
view_visibility enum remains with one constant that is the mask to wlc's view masking
2015-08-25refactored view visibilityminus
- replace visibilty mask integers with an enum - set output's visibilty mask on creation - added update_visibility to manually update a containers visibility (e.g. when it moved to an invisible workspace)
2015-08-23Minor fixes to keyboard handlingDrew DeVault
2015-08-23mergetaiyu
2015-08-23Refactor keyboard to consider modified keysymsDrew DeVault
Press Shift Press 0 # Reads as ')' Release Shift Release 0 # Reads as '0' but we now recognize it as the same
2015-08-23Cleanup and minor adjustments to disablingLuminarys