提交 f982b9d9 编写于 作者: B Behdad Esfahbod

[name] Clean up serialize() API

上级 59ee61fd
...@@ -170,8 +170,8 @@ struct name ...@@ -170,8 +170,8 @@ struct name
{ return min_size + count * nameRecordZ.item_size; } { return min_size + count * nameRecordZ.item_size; }
bool serialize (hb_serialize_context_t *c, bool serialize (hb_serialize_context_t *c,
const name *source_name, const name *source_name,
const hb_subset_plan_t *plan) const hb_set_t *name_ids)
{ {
TRACE_SERIALIZE (this); TRACE_SERIALIZE (this);
...@@ -181,7 +181,7 @@ struct name ...@@ -181,7 +181,7 @@ struct name
auto it = auto it =
+ src_array + src_array
| hb_filter (plan->name_ids, &NameRecord::nameID) | hb_filter (name_ids, &NameRecord::nameID)
; ;
this->format = 0; this->format = 0;
...@@ -214,7 +214,7 @@ struct name ...@@ -214,7 +214,7 @@ struct name
hb_serialize_context_t *serializer = c->serializer; hb_serialize_context_t *serializer = c->serializer;
name *name_prime = serializer->start_embed<name> (); name *name_prime = serializer->start_embed<name> ();
if (unlikely (!name_prime)) return_trace (false); if (unlikely (!name_prime)) return_trace (false);
name_prime->serialize (serializer, this, plan); name_prime->serialize (serializer, this, plan->name_ids);
return_trace (name_prime->count); return_trace (name_prime->count);
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册