Lines Matching refs:ctx

62     lv_xml_component_ctx_t * ctx = lv_xml_component_get_ctx(name);  in lv_xml_component_process()  local
63 if(ctx == NULL) return NULL; in lv_xml_component_process()
64 lv_obj_t * item = lv_xml_create_from_ctx(state->parent, &state->ctx, ctx, attrs); in lv_xml_component_process()
72 ctx->root_widget->apply_cb(state, attrs); in lv_xml_component_process()
79 lv_xml_component_ctx_t * ctx; in lv_xml_component_get_ctx() local
80 LV_LL_READ(&component_ctx_ll, ctx) { in lv_xml_component_get_ctx()
81 if(lv_streq(ctx->name, component_name)) return ctx; in lv_xml_component_get_ctx()
92 state.ctx.name = name; in lv_xml_component_register_from_data()
110 lv_xml_component_ctx_t * ctx = lv_ll_ins_head(&component_ctx_ll); in lv_xml_component_register_from_data() local
111 lv_memzero(ctx, sizeof(lv_xml_component_ctx_t)); in lv_xml_component_register_from_data()
112 lv_memcpy(ctx, &state.ctx, sizeof(lv_xml_component_ctx_t)); in lv_xml_component_register_from_data()
115 ctx->view_def = extract_view_content(xml_def); in lv_xml_component_register_from_data()
116 ctx->name = lv_strdup(name); in lv_xml_component_register_from_data()
117 if(!ctx->view_def) { in lv_xml_component_register_from_data()
120 lv_free(ctx); in lv_xml_component_register_from_data()
187 lv_xml_component_ctx_t * ctx = lv_xml_component_get_ctx(name); in lv_xml_component_unregister() local
188 if(ctx == NULL) return LV_RESULT_INVALID; in lv_xml_component_unregister()
190 lv_ll_remove(&component_ctx_ll, ctx); in lv_xml_component_unregister()
192 lv_free((char *)ctx->name); in lv_xml_component_unregister()
193 lv_free((char *)ctx->view_def); in lv_xml_component_unregister()
194 lv_ll_clear(&ctx->param_ll); in lv_xml_component_unregister()
195 lv_ll_clear(&ctx->style_ll); in lv_xml_component_unregister()
196 lv_free(ctx); in lv_xml_component_unregister()
220 lv_xml_const_t * cnst = lv_ll_ins_tail(&state->ctx.const_ll); in process_const_element()
227 lv_xml_param_t * prop = lv_ll_ins_tail(&state->ctx.param_ll); in process_prop_element()
248 state->ctx.root_widget = lv_xml_widget_get_processor(extends); in start_metadata_handler()
249 if(state->ctx.root_widget == NULL) { in start_metadata_handler()
252 state->ctx.root_widget = extended_component->root_widget; in start_metadata_handler()
256 state->ctx.root_widget = lv_xml_widget_get_processor("lv_obj"); in start_metadata_handler()
261 if(lv_streq(name, "widget")) state->ctx.is_widget = 1; in start_metadata_handler()
277 lv_xml_style_register(&state->ctx, attrs); in start_metadata_handler()