Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
BuffyBox
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
_ _
BuffyBox
Commits
925b56d1
Commit
925b56d1
authored
1 year ago
by
Johannes Marbach
Browse files
Options
Downloads
Patches
Plain Diff
Fix naming
parent
479a3aca
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
shared/theme.c
+4
-4
4 additions, 4 deletions
shared/theme.c
shared/theme.h
+2
-2
2 additions, 2 deletions
shared/theme.h
shared/themes.c
+5
-5
5 additions, 5 deletions
shared/themes.c
shared/themes.h
+1
-1
1 addition, 1 deletion
shared/themes.h
unl0kr/main.c
+2
-2
2 additions, 2 deletions
unl0kr/main.c
with
14 additions
and
14 deletions
shared/theme.c
+
4
−
4
View file @
925b56d1
...
...
@@ -16,7 +16,7 @@
* Static variables
*/
static
ul
_theme
current_theme
;
static
bb
_theme
current_theme
;
static
lv_theme_t
lv_theme
;
static
struct
{
...
...
@@ -55,7 +55,7 @@ static bool are_styles_initialised = false;
*
* @param theme theme to derive the styles from
*/
static
void
init_styles
(
const
ul
_theme
*
theme
);
static
void
init_styles
(
const
bb
_theme
*
theme
);
/**
* Initialise or reset a style.
...
...
@@ -84,7 +84,7 @@ static void keyboard_draw_task_added_cb(lv_event_t *event);
* Static functions
*/
static
void
init_styles
(
const
ul
_theme
*
theme
)
{
static
void
init_styles
(
const
bb
_theme
*
theme
)
{
reset_style
(
&
(
styles
.
widget
));
lv_style_set_text_font
(
&
(
styles
.
widget
),
&
font_32
);
...
...
@@ -369,7 +369,7 @@ void bb_theme_prepare_keyboard(lv_obj_t *keyboard) {
lv_obj_add_flag
(
keyboard
,
LV_OBJ_FLAG_SEND_DRAW_TASK_EVENTS
);
}
void
bb_theme_apply
(
const
ul
_theme
*
theme
)
{
void
bb_theme_apply
(
const
bb
_theme
*
theme
)
{
if
(
!
theme
)
{
bb_log
(
BB_LOG_LEVEL_ERROR
,
"Could not apply theme from NULL pointer"
);
return
;
...
...
This diff is collapsed.
Click to expand it.
shared/theme.h
+
2
−
2
View file @
925b56d1
...
...
@@ -172,7 +172,7 @@ typedef struct {
bb_theme_label
label
;
bb_theme_msgbox
msgbox
;
bb_theme_bar
bar
;
}
ul
_theme
;
}
bb
_theme
;
/**
* Prepare a keyboard widget to be themed with a theme.
...
...
@@ -186,6 +186,6 @@ void bb_theme_prepare_keyboard(lv_obj_t *keyboard);
*
* @param theme the theme to apply
*/
void
bb_theme_apply
(
const
ul
_theme
*
theme
);
void
bb_theme_apply
(
const
bb
_theme
*
theme
);
#endif
/* BB_THEME_H */
This diff is collapsed.
Click to expand it.
shared/themes.c
+
5
−
5
View file @
925b56d1
...
...
@@ -16,7 +16,7 @@
*/
/* Breezy light (based on KDE Breeze color palette, see https://develop.kde.org/hig/style/color/default/) */
static
const
ul
_theme
bb_themes_breezy_light
=
{
static
const
bb
_theme
bb_themes_breezy_light
=
{
.
name
=
"breezy-light"
,
.
window
=
{
.
bg_color
=
0xeff0f1
...
...
@@ -174,7 +174,7 @@ static const ul_theme bb_themes_breezy_light = {
/* Breezy dark (based on KDE Breeze Dark color palette, see https://develop.kde.org/hig/style/color/dark/) */
static
const
ul
_theme
bb_themes_breezy_dark
=
{
static
const
bb
_theme
bb_themes_breezy_dark
=
{
.
name
=
"breezy-dark"
,
.
window
=
{
.
bg_color
=
0x31363b
...
...
@@ -331,7 +331,7 @@ static const ul_theme bb_themes_breezy_dark = {
};
/* pmOS light (based on palette https://coolors.co/009900-395e66-db504a-e3b505-ebf5ee) */
static
const
ul
_theme
bb_themes_pmos_light
=
{
static
const
bb
_theme
bb_themes_pmos_light
=
{
.
name
=
"pmos-light"
,
.
window
=
{
.
bg_color
=
0xf2f7f8
,
...
...
@@ -488,7 +488,7 @@ static const ul_theme bb_themes_pmos_light = {
};
/* pmOS dark (based on palette https://coolors.co/009900-395e66-db504a-e3b505-ebf5ee) */
static
const
ul
_theme
bb_themes_pmos_dark
=
{
static
const
bb
_theme
bb_themes_pmos_dark
=
{
.
name
=
"pmos-dark"
,
.
window
=
{
.
bg_color
=
0x070c0d
...
...
@@ -649,7 +649,7 @@ static const ul_theme bb_themes_pmos_dark = {
*/
const
int
bb_themes_num_themes
=
4
;
const
ul
_theme
*
bb_themes_themes
[]
=
{
const
bb
_theme
*
bb_themes_themes
[]
=
{
&
bb_themes_breezy_light
,
&
bb_themes_breezy_dark
,
&
bb_themes_pmos_light
,
...
...
This diff is collapsed.
Click to expand it.
shared/themes.h
+
1
−
1
View file @
925b56d1
...
...
@@ -20,7 +20,7 @@ typedef enum {
/* Themes */
extern
const
int
bb_themes_num_themes
;
extern
const
ul
_theme
*
bb_themes_themes
[];
extern
const
bb
_theme
*
bb_themes_themes
[];
/**
* Find the first theme with a given name.
...
...
This diff is collapsed.
Click to expand it.
unl0kr/main.c
+
2
−
2
View file @
925b56d1
...
...
@@ -78,7 +78,7 @@ static void set_theme(bool is_alternate);
*
* @param is_alternate true if the alternate theme should be selected, false if the default theme should be selected
*/
static
const
ul
_theme
*
get_theme
(
bool
is_alternate
);
static
const
bb
_theme
*
get_theme
(
bool
is_alternate
);
/**
* Handle LV_EVENT_CLICKED events from the show/hide password toggle button.
...
...
@@ -223,7 +223,7 @@ static void set_theme(bool is_alternate) {
bb_theme_apply
(
get_theme
(
is_alternate
));
}
static
const
ul
_theme
*
get_theme
(
bool
is_alternate
)
{
static
const
bb
_theme
*
get_theme
(
bool
is_alternate
)
{
return
bb_themes_themes
[
is_alternate
?
conf_opts
.
theme
.
alternate_id
:
conf_opts
.
theme
.
default_id
];
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment