package com.ss.android.ugc.aweme.commercialize.e_commerce.wishlist.manager;

import X.0CB;
import X.0CH;
import X.1Bj;
import X.C3114L8v;
import X.CvK;
import X.KVN;
import X.L87;
import X.M12;
import com.bytedance.covode.number.Covode;
import com.bytedance.ies.bullet.service.base.IResourceLoaderService;

public final class WishListManager$lifecycleEventObserver$1 implements 1Bj {
    public static final WishListManager$lifecycleEventObserver$1 LIZ = new WishListManager$lifecycleEventObserver$1();

    static {
        Covode.recordClassIndex(58487);
    }

    public final void onStateChanged(0CH r4, 0CB r5) {
        IResourceLoaderService iResourceLoaderService;
        M12.LIZ((Object) r4, (Object) r5);
        int i = CvK.LIZ[r5.ordinal()];
        if (i == 1) {
            IResourceLoaderService iResourceLoaderService2 = (IResourceLoaderService) KVN.LIZIZ.LIZ().LIZ(IResourceLoaderService.class);
            if (iResourceLoaderService2 != null) {
                iResourceLoaderService2.registerCustomLoader(L87.class, C3114L8v.HIGH);
            }
        } else if (i == 2 && (iResourceLoaderService = (IResourceLoaderService) KVN.LIZIZ.LIZ().LIZ(IResourceLoaderService.class)) != null) {
            iResourceLoaderService.unregisterCustomLoader(L87.class, C3114L8v.HIGH);
        }
    }
}
