!165 pika_lvgl_v0.4.1_1668858451209

Merge pull request !165 from pikabot/pika_lvgl_v0.4.1_1668858451209
This commit is contained in:
李昂 2022-11-19 11:48:59 +00:00 committed by Gitee
commit 8c0080ddf9
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
5 changed files with 18 additions and 18 deletions

View File

@ -434,7 +434,7 @@ void pika_lvgl_img_set_size_mode(PikaObj* self, int mode) {
void pika_lvgl_img_dsc_t___init__(PikaObj* self, PikaObj* dsc_dict) {
obj_setRef(self, "dsc_dict", dsc_dict);
PikaDict* dsc_dict_ = obj_getPtr(dsc_dict, "dict");
uint8_t* data = dict_getBytes(dsc_dict_, "data");
uint8_t* data = pikaDict_getBytes(dsc_dict_, "data");
unsigned char wtmp[4] = {'0'};
unsigned char htmp[4] = {'0'};
memcpy(&wtmp, data + 16, 4);
@ -443,7 +443,7 @@ void pika_lvgl_img_dsc_t___init__(PikaObj* self, PikaObj* dsc_dict) {
int h = ((int)(unsigned char)htmp[2]) * 256 + (int)(unsigned char)htmp[3];
lv_img_dsc_t img_dsc = {
.data = data,
.data_size = dict_getInt(dsc_dict_, "data_size"),
.data_size = pikaDict_getInt(dsc_dict_, "data_size"),
.header =
{
.always_zero = 0,

View File

@ -28,8 +28,8 @@
PikaObj* pika_lv_event_listener_g;
Args* pika_lv_id_register_g;
#if !PIKASCRIPT_VERSION_REQUIRE_MINIMUN(1, 11, 5)
#error "pikascript version must be greater than 1.11.5"
#if !PIKASCRIPT_VERSION_REQUIRE_MINIMUN(1, 11, 7)
#error "pikascript version must be greater than 1.11.7"
#endif
void pika_lvgl_STATE___init__(PikaObj* self) {
@ -195,7 +195,7 @@ void pika_lvgl_PALETTE___init__(PikaObj* self) {
}
PikaObj* pika_lvgl_scr_act(PikaObj* self) {
PikaObj* new_obj = newNormalObj(New_TinyObj);
PikaObj* new_obj = newNormalObj(New_pika_lvgl_lv_obj);
lv_obj_t* lv_obj = lv_scr_act();
obj_setPtr(new_obj, "lv_obj", lv_obj);
return new_obj;
@ -215,8 +215,8 @@ void pika_lvgl_obj___init__(PikaObj* self, PikaTuple* parent) {
class_defineConstructor(self, "FLAG", "", pika_lvgl_flag_tMethod);
return;
}
if (tuple_getSize(parent) == 1) {
parent_obj = tuple_getPtr(parent, 0);
if (pikaTuple_getSize(parent) == 1) {
parent_obj = pikaTuple_getPtr(parent, 0);
lv_obj_t* lv_parent = obj_getPtr(parent_obj, "lv_obj");
lv_obj_t* lv_obj = lv_obj_create(lv_parent);
obj_setPtr(self, "lv_obj", lv_obj);

View File

@ -389,6 +389,7 @@ class lv_obj:
def set_id(self, id: str): ...
def get_id(self) -> str: ...
def clean(self): ...
class indev_t:

View File

@ -328,4 +328,9 @@ void pika_lvgl_lv_obj_set_flex_grow(PikaObj *self, int value){
lv_obj_set_flex_grow(lv_obj, value);
}
void pika_lvgl_lv_obj_clean(PikaObj *self){
lv_obj_t* lv_obj = obj_getPtr(self, "lv_obj");
lv_obj_clean(lv_obj);
}
#endif

View File

@ -244,7 +244,8 @@ releases = [
"v0.3.2 ce221cf875ac5c533ceff3905313a8ef2906df75",
"v0.3.3 556b3cd6eb8fa1c100f29bd8556ee48a0a60b055",
"v0.3.4 fc7871f6ae32e6fd16c9e16587d02f8b93af1b5d",
"v0.4.0 e6a839810a5a98dd36a6436259a05ab3e9b8c6c0"
"v0.4.0 e6a839810a5a98dd36a6436259a05ab3e9b8c6c0",
"v0.4.1 6f5c4bfae50fc5ae347609e58650f2d185171f9f"
]
[[packages]]
@ -410,15 +411,11 @@ releases = [
[[packages]]
name = "mqtt"
releases = [
"v0.0.1 04a174a7d3e02d8861124214f5a3551eaab2bfee",
]
releases = [ "v0.0.1 04a174a7d3e02d8861124214f5a3551eaab2bfee" ]
[[packages]]
name = "requests"
releases = [
"v0.0.1 04a174a7d3e02d8861124214f5a3551eaab2bfee",
]
releases = [ "v0.0.1 04a174a7d3e02d8861124214f5a3551eaab2bfee" ]
[[packages]]
name = "hashlib"
@ -429,7 +426,4 @@ releases = [
[[packages]]
name = "hmac"
releases = [
"v1.0.0 ca8fe36d68be16722317860394fdf78c620e3e2d"
]
releases = [ "v1.0.0 ca8fe36d68be16722317860394fdf78c620e3e2d" ]