Skip to content

Commit 5862dc6

Browse files
committed
OR is it? control the default via vala flags
1 parent 854b5bc commit 5862dc6

File tree

3 files changed

+21
-1
lines changed

3 files changed

+21
-1
lines changed

data/meson.build

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ i18n.merge_file(
2929
#======== ICONS ========
3030

3131
# Install our icons in all the required sizes
32-
variant = get_option('variant')[0]
32+
# "variant" variable has been declared earlier in the base meson
3333
icon_sizes = ['16', '24', '32', '48', '64', '128']
3434

3535
foreach i : icon_sizes

meson.build

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,20 @@ i18n = import('i18n')
99
add_global_arguments('-DGETTEXT_PACKAGE="@0@"'.format (meson.project_name()), language:'c')
1010

1111

12+
vala_flags = []
13+
variant = get_option('variant')[0]
14+
15+
if variant == 'pride'
16+
vala_flags = ['--define', 'PRIDE']
17+
elif variant == 'halloween'
18+
vala_flags = ['--define', 'HALLOWEEN']
19+
else
20+
vala_flags = ['--define', 'DEFAULT']
21+
endif
22+
23+
add_project_arguments(vala_flags, language: 'vala')
24+
25+
1226
#================================
1327
# Import the stylesheet
1428

src/Services/Constants.vala

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,13 @@ namespace Jorts.Constants {
1515
const string DONATE_LINK = "https://ko-fi.com/teamcons";
1616

1717
// signature theme
18+
#if PRIDE
19+
const Jorts.Themes DEFAULT_THEME = Jorts.Themes.BUBBLEGUM;
20+
#elif HALLOWEEN
21+
const Jorts.Themes DEFAULT_THEME = Jorts.Themes.ORANGE;
22+
#else
1823
const Jorts.Themes DEFAULT_THEME = Jorts.Themes.BLUEBERRY;
24+
#endif
1925

2026
// in ms
2127
const int DEBOUNCE = 1000;

0 commit comments

Comments
 (0)