-
Notifications
You must be signed in to change notification settings - Fork 550
Feature: New example project updates #152
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Feature: New example project updates #152
Conversation
- Added new styles for dark theme and checkbox in theme_switcher.xml. - Updated thermostat.xml to bind maximum value of scale sections to thermostat_temp for dynamic updates.
…pangroup bind_text
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
40 issues found across 265 files
Note: This PR contains a large number of files. cubic only reviews up to 150 files per PR, so some files may not have been reviewed.
Since this is your first cubic review, here's how it works:
- cubic automatically reviews your code and comments on bugs and improvements
- Teach cubic by replying to its comments. cubic learns from your replies and gets better over time
- Ask questions if you need clarification on any suggestion
React with 👍 or 👎 to teach cubic. Mention @cubic-dev-ai
to give feedback, ask questions, or re-run the review.
selector_and_prop = ((LV_STYLE_OPA & 0xff) << 24) | 0; | ||
lv_anim_init(&a); | ||
lv_anim_set_custom_exec_cb(&a, int_anim_exec_cb); | ||
lv_anim_set_var(&a, "div_1"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Animation var set to "div_1" string; treated as lv_obj_t* in exec callback, causing a crash.
Prompt for AI agents
Address the following comment on examples/components/cards/alarm/alarm_gen.c at line 254:
<comment>Animation var set to "div_1" string; treated as lv_obj_t* in exec callback, causing a crash.</comment>
<file context>
@@ -0,0 +1,282 @@
+ selector_and_prop = ((LV_STYLE_OPA & 0xff) << 24) | 0;
+ lv_anim_init(&a);
+ lv_anim_set_custom_exec_cb(&a, int_anim_exec_cb);
+ lv_anim_set_var(&a, "div_1");
+ lv_anim_set_values(&a, 0, 255);
+ lv_anim_set_duration(&a, 200);
</file context>
selector_and_prop = ((LV_STYLE_OPA & 0xff) << 24) | 0; | ||
lv_anim_init(&a); | ||
lv_anim_set_custom_exec_cb(&a, int_anim_exec_cb); | ||
lv_anim_set_var(&a, "div_0/roller_1"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Animation var set to "div_0/roller_1" string; exec callback treats it as lv_obj_t*, leading to undefined behavior.
Prompt for AI agents
Address the following comment on examples/components/cards/alarm/alarm_gen.c at line 234:
<comment>Animation var set to "div_0/roller_1" string; exec callback treats it as lv_obj_t*, leading to undefined behavior.</comment>
<file context>
@@ -0,0 +1,282 @@
+ selector_and_prop = ((LV_STYLE_OPA & 0xff) << 24) | 0;
+ lv_anim_init(&a);
+ lv_anim_set_custom_exec_cb(&a, int_anim_exec_cb);
+ lv_anim_set_var(&a, "div_0/roller_1");
+ lv_anim_set_values(&a, 0, 255);
+ lv_anim_set_duration(&a, 200);
</file context>
selector_and_prop = ((LV_STYLE_OPA & 0xff) << 24) | 0; | ||
lv_anim_init(&a); | ||
lv_anim_set_custom_exec_cb(&a, int_anim_exec_cb); | ||
lv_anim_set_var(&a, "div_0/roller_0"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Animation var set to "div_0/roller_0" string; exec callback expects an lv_obj_t*, leading to invalid pointer use.
Prompt for AI agents
Address the following comment on examples/components/cards/alarm/alarm_gen.c at line 214:
<comment>Animation var set to "div_0/roller_0" string; exec callback expects an lv_obj_t*, leading to invalid pointer use.</comment>
<file context>
@@ -0,0 +1,282 @@
+ selector_and_prop = ((LV_STYLE_OPA & 0xff) << 24) | 0;
+ lv_anim_init(&a);
+ lv_anim_set_custom_exec_cb(&a, int_anim_exec_cb);
+ lv_anim_set_var(&a, "div_0/roller_0");
+ lv_anim_set_values(&a, 0, 255);
+ lv_anim_set_duration(&a, 200);
</file context>
selector_and_prop = ((LV_STYLE_TRANSLATE_Y & 0xff) << 24) | 0; | ||
lv_anim_init(&a); | ||
lv_anim_set_custom_exec_cb(&a, int_anim_exec_cb); | ||
lv_anim_set_var(&a, "header"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Animation target is set to a string literal, but the exec callback treats it as an lv_obj_t*, leading to invalid pointer dereference at runtime.
Prompt for AI agents
Address the following comment on examples/components/cards/alarm/alarm_gen.c at line 194:
<comment>Animation target is set to a string literal, but the exec callback treats it as an lv_obj_t*, leading to invalid pointer dereference at runtime.</comment>
<file context>
@@ -0,0 +1,282 @@
+ selector_and_prop = ((LV_STYLE_TRANSLATE_Y & 0xff) << 24) | 0;
+ lv_anim_init(&a);
+ lv_anim_set_custom_exec_cb(&a, int_anim_exec_cb);
+ lv_anim_set_var(&a, "header");
+ lv_anim_set_values(&a, -40, 0);
+ lv_anim_set_duration(&a, 200);
</file context>
@@ -0,0 +1,554 @@ | |||
project/CMakeFiles/lib-ui.dir/components/cards/weather/weather_gen.c.o: \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Generated build dependency file (.o.d) is committed. Exclude CMake build outputs (e.g., examples/preview-build) from VCS to avoid churn, conflicts, and leaking environment-specific paths.
Prompt for AI agents
Address the following comment on examples/preview-build/project/CMakeFiles/lib-ui.dir/components/cards/weather/weather_gen.c.o.d at line 1:
<comment>Generated build dependency file (.o.d) is committed. Exclude CMake build outputs (e.g., examples/preview-build) from VCS to avoid churn, conflicts, and leaking environment-specific paths.</comment>
<file context>
@@ -0,0 +1,554 @@
+project/CMakeFiles/lib-ui.dir/components/cards/weather/weather_gen.c.o: \
+ /lved/project/components/cards/weather/weather_gen.c \
+ /lved/project/components/cards/weather/weather_gen.h \
</file context>
@@ -0,0 +1,554 @@ | |||
project/CMakeFiles/lib-ui.dir/components/basic/switch/switch_gen.c.o: \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Generated build artifacts are committed (object and dep files under preview-build), which are environment-specific and should be ignored to keep the repo clean and builds reproducible.
Prompt for AI agents
Address the following comment on examples/preview-build/project/CMakeFiles/lib-ui.dir/components/basic/switch/switch_gen.c.o.d at line 1:
<comment>Generated build artifacts are committed (object and dep files under preview-build), which are environment-specific and should be ignored to keep the repo clean and builds reproducible.</comment>
<file context>
@@ -0,0 +1,554 @@
+project/CMakeFiles/lib-ui.dir/components/basic/switch/switch_gen.c.o: \
+ /lved/project/components/basic/switch/switch_gen.c \
+ /lved/project/components/basic/switch/switch_gen.h \
</file context>
} | ||
} | ||
|
||
var noExitRuntime = Module['noExitRuntime'] || true; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Using || true here overrides an explicit false and prevents expected runtime exit; use nullish coalescing to preserve false.
Prompt for AI agents
Address the following comment on examples/preview-build/CMakeFiles/3.22.1/CompilerIdC/a.out.js at line 904:
<comment>Using || true here overrides an explicit false and prevents expected runtime exit; use nullish coalescing to preserve false.</comment>
<file context>
@@ -0,0 +1,1521 @@
+ }
+ }
+
+ var noExitRuntime = Module['noExitRuntime'] || true;
+
+ var ptrToString = (ptr) => {
</file context>
|
||
string(REPLACE ";" "\n" CMAKE_INSTALL_MANIFEST_CONTENT | ||
"${CMAKE_INSTALL_MANIFEST_FILES}") | ||
file(WRITE "/lved/project/preview-build/${CMAKE_INSTALL_MANIFEST}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Writes manifest to a hard-coded absolute path; use a path relative to the script directory for portability.
Prompt for AI agents
Address the following comment on examples/preview-build/cmake_install.cmake at line 54:
<comment>Writes manifest to a hard-coded absolute path; use a path relative to the script directory for portability.</comment>
<file context>
@@ -0,0 +1,55 @@
+
+string(REPLACE ";" "\n" CMAKE_INSTALL_MANIFEST_CONTENT
+ "${CMAKE_INSTALL_MANIFEST_FILES}")
+file(WRITE "/lved/project/preview-build/${CMAKE_INSTALL_MANIFEST}"
+ "${CMAKE_INSTALL_MANIFEST_CONTENT}")
</file context>
|
||
if(NOT CMAKE_INSTALL_LOCAL_ONLY) | ||
# Include the install script for each subdirectory. | ||
include("/lved/project/preview-build/project/cmake_install.cmake") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Absolute include path is non-portable; use a path based on CMAKE_CURRENT_LIST_DIR.
Prompt for AI agents
Address the following comment on examples/preview-build/cmake_install.cmake at line 42:
<comment>Absolute include path is non-portable; use a path based on CMAKE_CURRENT_LIST_DIR.</comment>
<file context>
@@ -0,0 +1,55 @@
+
+if(NOT CMAKE_INSTALL_LOCAL_ONLY)
+ # Include the install script for each subdirectory.
+ include("/lved/project/preview-build/project/cmake_install.cmake")
+
+endif()
</file context>
@@ -0,0 +1,63 @@ | |||
file(REMOVE_RECURSE |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Generated CMake build artifacts are being committed; these should be excluded from source control (e.g., via .gitignore) and removed from the repo to avoid churn and platform-specific noise.
Prompt for AI agents
Address the following comment on examples/preview-build/project/CMakeFiles/lib-ui.dir/cmake_clean.cmake at line 1:
<comment>Generated CMake build artifacts are being committed; these should be excluded from source control (e.g., via .gitignore) and removed from the repo to avoid churn and platform-specific noise.</comment>
<file context>
@@ -0,0 +1,63 @@
+file(REMOVE_RECURSE
+ "CMakeFiles/lib-ui.dir/components/basic/bar/bar_gen.c.o"
+ "CMakeFiles/lib-ui.dir/components/basic/bar/bar_gen.c.o.d"
</file context>
Summary by cubic
Revamps the examples with a new, themed component library and showcase cards, replacing legacy widgets and updating fonts and build setup. Improves Editor preview compatibility and unifies component create APIs.
New Features
Migration