Skip to content

Commit

Permalink
fdo: Explicitly set the backend implementation name
Browse files Browse the repository at this point in the history
Fixes #11
  • Loading branch information
aperezdc authored and elima committed Sep 6, 2018
1 parent ed26f03 commit 56401ee
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 0 deletions.
1 change: 1 addition & 0 deletions core/cog-platform.c
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@


G_DEFINE_QUARK (COG_PLATFORM_EGL_ERROR, cog_platform_egl_error)
G_DEFINE_QUARK (COG_PLATFORM_WPE_ERROR, cog_platform_wpe_error)


/* @FIXME: Move this implementation to use a GIO extension point. */
Expand Down
8 changes: 8 additions & 0 deletions core/cog-platform.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,14 @@ G_BEGIN_DECLS
#define COG_PLATFORM_EGL_ERROR (cog_platform_egl_error_quark ())
GQuark cog_platform_egl_error_quark (void);

#define COG_PLATFORM_WPE_ERROR (cog_platform_wpe_error_quark ())
GQuark cog_platform_wpe_error_quark (void);


typedef enum {
COG_PLATFORM_WPE_ERROR_INIT,
} CogPlatformWpeError;


/* @FIXME: Eventually move this interface to GObject. */
typedef struct _CogPlatform CogPlatform;
Expand Down
8 changes: 8 additions & 0 deletions platform/cog-platform-fdo.c
Original file line number Diff line number Diff line change
Expand Up @@ -1357,6 +1357,14 @@ cog_platform_setup (CogPlatform *platform,
g_assert_nonnull (platform);
g_return_val_if_fail (COG_IS_SHELL (shell), FALSE);

if (!wpe_loader_init ("libWPEBackend-fdo-0.1.so")) {
g_set_error_literal (error,
COG_PLATFORM_WPE_ERROR,
COG_PLATFORM_WPE_ERROR_INIT,
"Failed to set backend library name");
return FALSE;
}

if (!init_wayland (error))
return FALSE;

Expand Down

0 comments on commit 56401ee

Please sign in to comment.