Update .gitreview file
[src/agl-compositor.git] / src / ivi-compositor.h
index 65e06ad..5d210fb 100644 (file)
@@ -27,6 +27,7 @@
 #define IVI_COMPOSITOR_H
 
 #include <stdbool.h>
+#include "config.h"
 
 #include <libweston-6/compositor-drm.h>
 #include <libweston-6/compositor.h>
@@ -61,6 +62,10 @@ struct ivi_compositor {
        const struct weston_drm_output_api *drm_api;
 
        struct wl_global *agl_shell;
+       struct {
+               int activate_apps_by_default;   /* switches once xdg top level has been 'created' */
+       } quirks;
+
        struct {
                struct wl_client *client;
                struct wl_resource *resource;
@@ -68,18 +73,17 @@ struct ivi_compositor {
        } shell_client;
 
        struct wl_list outputs; /* ivi_output.link */
-       struct wl_list surfaces; /* ivi_desktop_surface.link */
+       struct wl_list surfaces; /* ivi_surface.link */
 
        struct weston_desktop *desktop;
 
        struct wl_list pending_surfaces;
 
+       struct weston_layer hidden;
        struct weston_layer background;
        struct weston_layer normal;
        struct weston_layer panel;
        struct weston_layer fullscreen;
-
-       struct wl_list shell_clients; /* ivi_shell_client.link */
 };
 
 struct ivi_surface;
@@ -99,6 +103,12 @@ struct ivi_output {
        struct ivi_surface *left;
        struct ivi_surface *right;
 
+       /* for the black surface */
+       struct fullscreen_view {
+               struct ivi_surface *fs;
+               struct wl_listener fs_destroy;
+       } fullscreen_view;
+
        struct wl_listener output_destroy;
 
        /*
@@ -107,8 +117,7 @@ struct ivi_output {
         */
        struct weston_geometry area;
 
-       //int32_t width;
-       //int32_t height;
+       struct ivi_surface *active;
 
        /* Temporary: only used during configuration */
        size_t add_len;
@@ -123,18 +132,17 @@ enum ivi_surface_role {
 };
 
 struct ivi_desktop_surface {
-       struct weston_view *view;
+       struct ivi_output *pending_output;
+       struct ivi_output *last_output;
 };
 
 struct ivi_background_surface {
        struct ivi_output *output;
-       struct weston_view *view;
 };
 
 struct ivi_panel_surface {
        struct ivi_output *output;
        enum agl_shell_edge edge;
-       struct weston_view *view;
 };
 
 enum ivi_surface_flags {
@@ -146,6 +154,7 @@ enum ivi_surface_flags {
 struct ivi_surface {
        struct ivi_compositor *ivi;
        struct weston_desktop_surface *dsurface;
+       struct weston_view *view;
 
        struct wl_list link;
 
@@ -155,8 +164,6 @@ struct ivi_surface {
                int32_t width, height;
        } pending;
 
-       struct weston_geometry old_geom;
-
        enum ivi_surface_role role;
        union {
                struct ivi_desktop_surface desktop;
@@ -179,9 +186,22 @@ struct ivi_shell_client {
 struct ivi_compositor *
 to_ivi_compositor(struct weston_compositor *ec);
 
+#ifdef HAVE_SYSTEMD
+int
+ivi_agl_systemd_notify(struct ivi_compositor *ivi);
+#else
+static int
+ivi_agl_systemd_notify(struct ivi_compositor *ivi)
+{
+}
+#endif
+
 int
 ivi_shell_init(struct ivi_compositor *ivi);
 
+void
+ivi_shell_init_black_fs(struct ivi_compositor *ivi);
+
 int
 ivi_shell_create_global(struct ivi_compositor *ivi);
 
@@ -217,4 +237,16 @@ ivi_layout_set_position(struct ivi_surface *surface,
 void
 ivi_layout_commit(struct ivi_compositor *ivi);
 
+void
+ivi_layout_init(struct ivi_compositor *ivi, struct ivi_output *output);
+
+void
+ivi_layout_activate(struct ivi_output *output, const char *app_id);
+
+void
+ivi_layout_desktop_committed(struct ivi_surface *surf);
+
+void
+ivi_layout_panel_committed(struct ivi_surface *surface);
+
 #endif