-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add new enum for poppover positioning
Signed-off-by: Ikey Doherty <[email protected]>
- Loading branch information
1 parent
dd63bd9
commit 48946c4
Showing
5 changed files
with
99 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
/*** BEGIN file-header ***/ | ||
#include "budgie-enums.h" | ||
|
||
/*** END file-header ***/ | ||
|
||
/*** BEGIN file-production ***/ | ||
/* enumerations from "@filename@" */ | ||
/*** END file-production ***/ | ||
|
||
/*** BEGIN value-header ***/ | ||
GType | ||
@enum_name@_get_type (void) | ||
{ | ||
static GType etype = 0; | ||
if (G_UNLIKELY(etype == 0)) { | ||
static const G@Type@Value values[] = { | ||
/*** END value-header ***/ | ||
|
||
/*** BEGIN value-production ***/ | ||
{ @VALUENAME@, "@VALUENAME@", "@valuenick@" }, | ||
/*** END value-production ***/ | ||
|
||
/*** BEGIN value-tail ***/ | ||
{ 0, NULL, NULL } | ||
}; | ||
etype = g_@type@_register_static (g_intern_static_string ("@EnumName@"), values); | ||
} | ||
return etype; | ||
} | ||
|
||
/*** END value-tail ***/ | ||
|
||
/*** BEGIN file-tail ***/ | ||
|
||
/*** END file-tail ***/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
/*** BEGIN file-header ***/ | ||
|
||
#pragma once | ||
|
||
#include <glib-object.h> | ||
|
||
#include "popover.h" | ||
|
||
G_BEGIN_DECLS | ||
/*** END file-header ***/ | ||
|
||
/*** BEGIN file-production ***/ | ||
|
||
/* enumerations from "@filename@" */ | ||
/*** END file-production ***/ | ||
|
||
/*** BEGIN value-header ***/ | ||
GType @enum_name@_get_type (void) G_GNUC_CONST; | ||
#define @ENUMPREFIX@_TYPE_@ENUMSHORT@ (@enum_name@_get_type ()) | ||
/*** END value-header ***/ | ||
|
||
/*** BEGIN file-tail ***/ | ||
G_END_DECLS | ||
|
||
/*** END file-tail ***/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
gnome = import('gnome') | ||
|
||
# Generate enums for gobject typing | ||
plugin_enums = gnome.mkenums( | ||
'budgie-enums', | ||
sources: 'popover.h', | ||
c_template: 'budgie-enums.c.template', | ||
h_template: 'budgie-enums.h.template', | ||
install_header: false, | ||
) | ||
|
||
# Fight meson race conditions.. | ||
libenum = static_library( | ||
'enum', | ||
plugin_enums, | ||
dependencies: dep_gtk3, | ||
) | ||
|
||
link_libenum = declare_dependency( | ||
sources: plugin_enums, | ||
include_directories: include_directories('.'), | ||
) | ||
|
||
executable( | ||
'popover-test', | ||
[ | ||
'popover.c', | ||
'popover-manager.c', | ||
'main.c', | ||
], | ||
dependencies: [dep_gtk3, link_libenum], | ||
install: false, | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters