Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b3b1c4c3 authored by Jerome Gaillard's avatar Jerome Gaillard Committed by Android (Google) Code Review
Browse files

Merge "Add arguments to native methods required for host builds" into sc-dev

parents 351250ae b71861cd
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -219,7 +219,7 @@ static jlong Font_getBufferAddress(CRITICAL_JNI_PARAMS_COMMA jlong fontPtr) {
}

// Critical Native
static jlong Font_getReleaseNativeFontFunc() {
static jlong Font_getReleaseNativeFontFunc(CRITICAL_JNI_PARAMS) {
    return reinterpret_cast<jlong>(releaseFont);
}

+2 −2
Original line number Diff line number Diff line
@@ -101,13 +101,13 @@ static jint FontFamily_getVariant(CRITICAL_JNI_PARAMS_COMMA jlong familyPtr) {
}

// CriticalNative
static jint FontFamily_getFontSize(jlong familyPtr) {
static jint FontFamily_getFontSize(CRITICAL_JNI_PARAMS_COMMA jlong familyPtr) {
    FontFamilyWrapper* family = reinterpret_cast<FontFamilyWrapper*>(familyPtr);
    return family->family->getNumFonts();
}

// CriticalNative
static jlong FontFamily_getFont(jlong familyPtr, jint index) {
static jlong FontFamily_getFont(CRITICAL_JNI_PARAMS_COMMA jlong familyPtr, jint index) {
    FontFamilyWrapper* family = reinterpret_cast<FontFamilyWrapper*>(familyPtr);
    std::shared_ptr<minikin::Font> font = family->family->getFontRef(index);
    return reinterpret_cast<jlong>(new FontWrapper(std::move(font)));