Don't unnecessarily construct gfxFontFeatureValueSet

If there is no font feature values inside document we should avoid creating
unnecessary objects.
This commit is contained in:
Nazım Can Altınova 2017-09-04 15:43:59 -07:00
parent 9b63fedf59
commit dd8af182c1
2 changed files with 18 additions and 11 deletions

View file

@ -913,6 +913,10 @@ extern "C" {
extern "C" {
pub fn Gecko_nsFont_Destroy(dst: *mut nsFont);
}
extern "C" {
pub fn Gecko_ConstructFontFeatureValueSet()
-> *mut gfxFontFeatureValueSet;
}
extern "C" {
pub fn Gecko_AppendFeatureValueHashEntry(value_set:
*mut gfxFontFeatureValueSet,
@ -2047,10 +2051,8 @@ extern "C" {
}
extern "C" {
pub fn Servo_StyleSet_BuildFontFeatureValueSet(set:
RawServoStyleSetBorrowed,
list:
*mut gfxFontFeatureValueSet)
-> bool;
RawServoStyleSetBorrowed)
-> *mut gfxFontFeatureValueSet;
}
extern "C" {
pub fn Servo_StyleSet_ResolveForDeclarations(set: