Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
mvladic committed Oct 10, 2024
1 parent 5610f6a commit 415ba48
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 0 deletions.
8 changes: 8 additions & 0 deletions packages/project-editor/lvgl/build.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1397,6 +1397,10 @@ ${source}`;
destinationFolder
) +
"/" +
(this.project.settings.build
.separateFolderForImagesAndFonts
? "images/"
: "") +
output +
".c",
source
Expand Down Expand Up @@ -1435,6 +1439,10 @@ ${source}`;
destinationFolder
) +
"/" +
(this.project.settings.build
.separateFolderForImagesAndFonts
? "fonts/"
: "") +
output +
".c",
font.lvglSourceFile
Expand Down
13 changes: 13 additions & 0 deletions packages/project-editor/project/project.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -270,6 +270,7 @@ export class Build extends EezObject {
configurations: BuildConfiguration[];
files: BuildFile[];
destinationFolder?: string;
separateFolderForImagesAndFonts?: boolean;
lvglInclude: string;
generateSourceCodeForEezFramework: boolean;
compressFlowDefinition: boolean;
Expand Down Expand Up @@ -299,6 +300,13 @@ export class Build extends EezObject {
name: "destinationFolder",
type: PropertyType.RelativeFolder
},
{
name: "separateFolderForImagesAndFonts",
displayName: "Store image and font files in a separate folder",
checkboxStyleSwitch: true,
type: PropertyType.Boolean,
disabled: isNotLVGLProject
},
{
name: "lvglInclude",
displayName: "LVGL include",
Expand Down Expand Up @@ -362,6 +370,10 @@ export class Build extends EezObject {
if (jsObject.expressionEvaluatorStackSize == undefined) {
jsObject.expressionEvaluatorStackSize = 20;
}

if (jsObject.separateFolderForImagesAndFonts == undefined) {
jsObject.separateFolderForImagesAndFonts = false;
}
},

updateObjectValueHook: (build: Build, values: Partial<Build>) => {
Expand All @@ -387,6 +399,7 @@ export class Build extends EezObject {
configurations: observable,
files: observable,
destinationFolder: observable,
separateFolderForImagesAndFonts: observable,
lvglInclude: observable,
generateSourceCodeForEezFramework: observable,
compressFlowDefinition: observable,
Expand Down

0 comments on commit 415ba48

Please sign in to comment.