mirror of
https://github.com/cage-kiosk/cage.git
synced 2025-10-29 05:40:19 -04:00
view: remove cg_ prefix
This commit is contained in:
parent
f25460f365
commit
24517922cc
5 changed files with 8 additions and 7 deletions
2
seat.c
2
seat.c
|
|
@ -692,7 +692,7 @@ struct cg_view *
|
||||||
seat_get_focus(struct cg_seat *seat)
|
seat_get_focus(struct cg_seat *seat)
|
||||||
{
|
{
|
||||||
struct wlr_surface *prev_surface = seat->seat->keyboard_state.focused_surface;
|
struct wlr_surface *prev_surface = seat->seat->keyboard_state.focused_surface;
|
||||||
return cg_view_from_wlr_surface(seat->server, prev_surface);
|
return view_from_wlr_surface(seat->server, prev_surface);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
|
||||||
4
view.c
4
view.c
|
|
@ -160,7 +160,7 @@ view_destroy(struct cg_view *view)
|
||||||
}
|
}
|
||||||
|
|
||||||
struct cg_view *
|
struct cg_view *
|
||||||
cg_view_create(struct cg_server *server)
|
view_create(struct cg_server *server)
|
||||||
{
|
{
|
||||||
struct cg_view *view = calloc(1, sizeof(struct cg_view));
|
struct cg_view *view = calloc(1, sizeof(struct cg_view));
|
||||||
|
|
||||||
|
|
@ -169,7 +169,7 @@ cg_view_create(struct cg_server *server)
|
||||||
}
|
}
|
||||||
|
|
||||||
struct cg_view *
|
struct cg_view *
|
||||||
cg_view_from_wlr_surface(struct cg_server *server, struct wlr_surface *surface)
|
view_from_wlr_surface(struct cg_server *server, struct wlr_surface *surface)
|
||||||
{
|
{
|
||||||
struct cg_view *view;
|
struct cg_view *view;
|
||||||
wl_list_for_each(view, &server->views, link) {
|
wl_list_for_each(view, &server->views, link) {
|
||||||
|
|
|
||||||
5
view.h
5
view.h
|
|
@ -64,7 +64,8 @@ void view_position(struct cg_view *view);
|
||||||
void view_unmap(struct cg_view *view);
|
void view_unmap(struct cg_view *view);
|
||||||
void view_map(struct cg_view *view, struct wlr_surface *surface);
|
void view_map(struct cg_view *view, struct wlr_surface *surface);
|
||||||
void view_destroy(struct cg_view *view);
|
void view_destroy(struct cg_view *view);
|
||||||
struct cg_view *cg_view_create(struct cg_server *server);
|
struct cg_view *view_create(struct cg_server *server);
|
||||||
struct cg_view *cg_view_from_wlr_surface(struct cg_server *server, struct wlr_surface *surface);
|
|
||||||
|
struct cg_view *view_from_wlr_surface(struct cg_server *server, struct wlr_surface *surface);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
||||||
|
|
@ -110,7 +110,7 @@ handle_xdg_shell_surface_new(struct wl_listener *listener, void *data)
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
struct cg_view *view = cg_view_create(server);
|
struct cg_view *view = view_create(server);
|
||||||
view->type = CAGE_XDG_SHELL_VIEW;
|
view->type = CAGE_XDG_SHELL_VIEW;
|
||||||
view->xdg_surface = xdg_surface;
|
view->xdg_surface = xdg_surface;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -102,7 +102,7 @@ handle_xwayland_surface_new(struct wl_listener *listener, void *data)
|
||||||
struct cg_server *server = wl_container_of(listener, server, new_xwayland_surface);
|
struct cg_server *server = wl_container_of(listener, server, new_xwayland_surface);
|
||||||
struct wlr_xwayland_surface *xwayland_surface = data;
|
struct wlr_xwayland_surface *xwayland_surface = data;
|
||||||
|
|
||||||
struct cg_view *view = cg_view_create(server);
|
struct cg_view *view = view_create(server);
|
||||||
view->type = CAGE_XWAYLAND_VIEW;
|
view->type = CAGE_XWAYLAND_VIEW;
|
||||||
view->xwayland_surface = xwayland_surface;
|
view->xwayland_surface = xwayland_surface;
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue