diff --git a/Bugs.md b/Bugs.md index f27debf..65b77ac 100644 --- a/Bugs.md +++ b/Bugs.md @@ -185,3 +185,34 @@ Steps to reproduce: * Edit tags * Observe suggestions not directly above the tags field +### Issue 14 + + * github issue number: N/A + * Fixed: 1.4.1 + +Cagebreak up to and including release 1.4.0 makes the screen flicker, when +invoking wl-copy or wl-paste. + +Steps to reproduce: + + * Open terminal + * Invoke wl-copy + * Observe screen flickering + +### Issue 15 + + * github issue number: N/A + * Fixed: 1.4.1 + +Cagebreak up to and including release 1.4.0 renders certain dropdown +menus incorrectly. + +Steps to reproduce: + + * Open firefox + * Download any file + * Select "save file" such that the file location dialog box appears + * Delete default file name and enter "." into the location bar, such that a long dropdown menu appears + * Click on dialog box (not on the dropdown menu) to make the menu disappear + * Observe flickering of the area, where the dropdown menu used to be + diff --git a/README.md b/README.md index 8ddb6a3..f88dff3 100644 --- a/README.md +++ b/README.md @@ -180,6 +180,11 @@ ninja -C build For every release after 1.0.5, hashes will be provided. +1.4.1 + + * sha 256: c3e0ccceaf1078b91071c40b0ccb7c4f8e53ae38b05ee6637f9f39f7f6ece2cb + * sha 512: fd77f39fc7a7e5376d8505a61d643ed4d8f4cfbbf38d70cf9ef6989645e8cc6cb9d4b1024d241dc689b6fd927a405c97b9c918b6994b8f9ab7406646f37b952d + 1.4.0 * sha 256: 14aa93d890c62cc763b3b546a51ad8560479d5e91fa9f949858ae6bc785e80be @@ -314,7 +319,7 @@ find bugs in other areas of the code. Currently, there are memory leaks which do not seem to stem from our code but rather the code of wl-roots or some other library we depend on. We are working on the problem. -In the meantime, add `-Ddetect-leaks=0` to the meson command to exclude memory leaks. +In the meantime, add `-Db_detect-leaks=0` to the meson command to exclude memory leaks. ## Bugs diff --git a/cagebreak.c b/cagebreak.c index c44aab0..4d1bd3b 100644 --- a/cagebreak.c +++ b/cagebreak.c @@ -23,6 +23,7 @@ #include #include #include +#include #include #include #include @@ -243,6 +244,7 @@ main(int argc, char *argv[]) { struct wlr_xdg_decoration_manager_v1 *xdg_decoration_manager = NULL; struct wlr_export_dmabuf_manager_v1 *export_dmabuf_manager = NULL; struct wlr_screencopy_manager_v1 *screencopy_manager = NULL; + struct wlr_data_control_manager_v1 *data_control_manager = NULL; struct wlr_xdg_output_manager_v1 *output_manager = NULL; struct wlr_gamma_control_manager_v1 *gamma_control_manager = NULL; struct wlr_xdg_shell *xdg_shell = NULL; @@ -355,6 +357,14 @@ main(int argc, char *argv[]) { goto end; } + data_control_manager = + wlr_data_control_manager_v1_create(server.wl_display); + if(!data_control_manager) { + wlr_log(WLR_ERROR, "Unable to create the data control manager"); + ret = 1; + goto end; + } + /* Configure a listener to be notified when new outputs are * available on the backend. We use this only to detect the * first output and ignore subsequent outputs. */ @@ -473,7 +483,7 @@ main(int argc, char *argv[]) { xwayland->display_name); } - if(wlr_xcursor_manager_load(xcursor_manager, 1)) { + if(!wlr_xcursor_manager_load(xcursor_manager, 1)) { wlr_log(WLR_ERROR, "Cannot load XWayland XCursor theme"); } struct wlr_xcursor *xcursor = diff --git a/man/cagebreak-config.5.md b/man/cagebreak-config.5.md index db37eeb..80a5cbc 100644 --- a/man/cagebreak-config.5.md +++ b/man/cagebreak-config.5.md @@ -1,4 +1,4 @@ -% CAGEBREAK-CONFIG(1) Version 1.4.0 | Cagebreak Manual +% CAGEBREAK-CONFIG(1) Version 1.4.1 | Cagebreak Manual # NAME diff --git a/man/cagebreak.1.md b/man/cagebreak.1.md index 6efb623..6e6df57 100644 --- a/man/cagebreak.1.md +++ b/man/cagebreak.1.md @@ -1,4 +1,4 @@ -% CAGEBREAK(1) Version 1.4.0 | Cagebreak Manual +% CAGEBREAK(1) Version 1.4.1 | Cagebreak Manual # NAME diff --git a/meson.build b/meson.build index 8f360a8..9f73e79 100644 --- a/meson.build +++ b/meson.build @@ -1,5 +1,5 @@ project('cagebreak', 'c', - version: '1.4.0', + version: '1.4.1', license: 'MIT', default_options: [ 'c_std=c11', @@ -196,7 +196,7 @@ reproducible_build_versions = { 'wayland_client': '1.18.0', 'wayland_cursor': '1.18.0', 'wlroots': '0.11.0', - 'xkbcommon': '1.0.0', + 'xkbcommon': '1.0.1', 'fontconfig': '2.13.91', 'pixman': '0.40.0', 'pango': '1.46.1', diff --git a/output.c b/output.c index fb35ea9..a330354 100644 --- a/output.c +++ b/output.c @@ -32,13 +32,13 @@ #include #include "keybinding.h" -#include "view.h" #include "message.h" #include "output.h" #include "render.h" #include "seat.h" #include "server.h" #include "util.h" +#include "view.h" #include "workspace.h" #if CG_HAS_XWAYLAND #include "xwayland.h" @@ -594,8 +594,8 @@ handle_new_output(struct wl_listener *listener, void *data) { output->curr_workspace = 0; wl_list_init(&output->messages); - if(wlr_xcursor_manager_load(server->seat->xcursor_manager, - wlr_output->scale)) { + if(!wlr_xcursor_manager_load(server->seat->xcursor_manager, + wlr_output->scale)) { wlr_log(WLR_ERROR, "Cannot load XCursor theme for output '%s' with scale %f", wlr_output->name, wlr_output->scale); diff --git a/signatures/1.4.0.sig b/signatures/1.4.0.sig new file mode 100644 index 0000000..5482cbd Binary files /dev/null and b/signatures/1.4.0.sig differ diff --git a/signatures/cagebreak.sig b/signatures/cagebreak.sig index 5482cbd..07c06c7 100644 Binary files a/signatures/cagebreak.sig and b/signatures/cagebreak.sig differ diff --git a/view.c b/view.c index 5aadd2a..a7817cf 100644 --- a/view.c +++ b/view.c @@ -74,6 +74,10 @@ view_child_finish(struct cg_view_child *child) { return; } + if(child->view != NULL && child->view->wlr_surface != NULL) { + view_damage_whole(child->view); + } + wl_list_remove(&child->link); wl_list_remove(&child->commit.link); wl_list_remove(&child->new_subsurface.link); @@ -305,18 +309,18 @@ view_unmap(struct cg_view *view) { wl_list_remove(&view->link); wl_list_remove(&view->new_subsurface.link); + view->wlr_surface = NULL; struct cg_view_child *child, *tmp; wl_list_for_each_safe(child, tmp, &view->children, link) { child->destroy(child); } - - view->wlr_surface = NULL; } void -view_map(struct cg_view *view, struct wlr_surface *surface) { - struct cg_output *output = view->workspace->output; +view_map(struct cg_view *view, struct wlr_surface *surface, + struct cg_workspace *ws) { + struct cg_output *output = ws->output; view->wlr_surface = surface; struct wlr_subsurface *subsurface; @@ -328,19 +332,18 @@ view_map(struct cg_view *view, struct wlr_surface *surface) { wl_signal_add(&view->wlr_surface->events.new_subsurface, &view->new_subsurface); + view->workspace = ws; + #if CG_HAS_XWAYLAND /* We shouldn't position override-redirect windows. They set their own (x,y) coordinates in handle_wayland_surface_map. */ if(view->type == CG_XWAYLAND_VIEW && !xwayland_view_should_manage(view)) { - wl_list_insert( - &output->workspaces[output->curr_workspace]->unmanaged_views, - &view->link); + wl_list_insert(&ws->unmanaged_views, &view->link); } else #endif { view_position(view); - wl_list_insert(&output->workspaces[output->curr_workspace]->views, - &view->link); + wl_list_insert(&ws->views, &view->link); } seat_set_focus(output->server->seat, view); } diff --git a/view.h b/view.h index e9fe6ab..7474198 100644 --- a/view.h +++ b/view.h @@ -99,7 +99,8 @@ view_unmap(struct cg_view *view); void view_maximize(struct cg_view *view, const struct wlr_box *tile_box); void -view_map(struct cg_view *view, struct wlr_surface *surface); +view_map(struct cg_view *view, struct wlr_surface *surface, + struct cg_workspace *ws); void view_destroy(struct cg_view *view); void diff --git a/xdg_shell.c b/xdg_shell.c index 6b3272c..9c076f2 100644 --- a/xdg_shell.c +++ b/xdg_shell.c @@ -300,7 +300,10 @@ handle_xdg_shell_surface_map(struct wl_listener *listener, void *_data) { wl_signal_add(&xdg_shell_view->xdg_surface->surface->events.commit, &xdg_shell_view->commit); - view_map(view, xdg_shell_view->xdg_surface->surface); + view_map( + view, xdg_shell_view->xdg_surface->surface, + view->workspace->server->curr_output + ->workspaces[view->workspace->server->curr_output->curr_workspace]); view_damage_whole(view); } diff --git a/xwayland.c b/xwayland.c index 294dc0e..4a19daf 100644 --- a/xwayland.c +++ b/xwayland.c @@ -188,7 +188,10 @@ handle_xwayland_surface_map(struct wl_listener *listener, void *_data) { wl_signal_add(&xwayland_view->xwayland_surface->surface->events.commit, &xwayland_view->commit); - view_map(view, xwayland_view->xwayland_surface->surface); + view_map( + view, xwayland_view->xwayland_surface->surface, + view->workspace->server->curr_output + ->workspaces[view->workspace->server->curr_output->curr_workspace]); view_damage_whole(view); }