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

Commit 7d3df7b6 authored by Nadav Bar's avatar Nadav Bar Committed by Android (Google) Code Review
Browse files

Merge "CaptioningManager: handle a case where caption calls enabled resource is not defined"

parents 24784d33 67851334
Loading
Loading
Loading
Loading
+7 −1
Original line number Diff line number Diff line
@@ -254,7 +254,13 @@ public class CaptioningManager {
     * Returns true if system wide call captioning is enabled for this device.
     */
    public boolean isCallCaptioningEnabled() {
        return mResources.getBoolean(R.bool.config_systemCaptionsServiceCallsEnabled);
        try {
            return mResources.getBoolean(
                R.bool.config_systemCaptionsServiceCallsEnabled);
        } catch (Resources.NotFoundException e) {
            // The resource may not be defined, return false in that case
            return false;
        }
    }

    private void notifyEnabledChanged() {