Kufar v3.2.0版本的 MD5 值为:6a4d203db1c561c7e3bcd50d23fed59f
以下内容为反编译后的 MenuVM.java 源代码,内容仅作参考
package by.kufar.menu.ui;
import androidx.lifecycle.MutableLiveData;
import by.kufar.core.android.arch.BaseViewModel;
import d80.q;
import java.util.HashSet;
import java.util.List;
import kotlin.Metadata;
import kotlin.Unit;
import kotlin.jvm.functions.Function2;
import kotlin.jvm.internal.s;
import kotlinx.coroutines.d2;
import kotlinx.coroutines.flow.i;
import kotlinx.coroutines.q0;
import l80.l;
import ob.b;
import ob.d;
import ob.e;
@Metadata(d1 = {"\u0000\u0088\u0001\n\u0002\u0018\u0002\n\u0002\u0018\u0002\n\u0002\u0010\u0002\n\u0002\b\u0003\n\u0002\u0018\u0002\n\u0002\b\u0002\n\u0002\u0018\u0002\n\u0002\b\u0002\n\u0002\u0018\u0002\n\u0002\b\u0006\n\u0002\u0018\u0002\n\u0002\b\u0003\n\u0002\u0018\u0002\n\u0002\b\u0002\n\u0002\u0018\u0002\n\u0002\b\u0002\n\u0002\u0018\u0002\n\u0002\b\u0002\n\u0002\u0018\u0002\n\u0002\b\u0002\n\u0002\u0018\u0002\n\u0002\b\u0002\n\u0002\u0018\u0002\n\u0002\u0010 \n\u0002\u0018\u0002\n\u0002\b\u0004\n\u0002\u0018\u0002\n\u0002\u0010\u000e\n\u0002\b\t\n\u0002\u0018\u0002\n\u0002\u0018\u0002\n\u0002\b\u0002\n\u0002\u0010\u000b\n\u0002\b\u0005\u0018\u00002\u00020\u0001B1\b\u0007\u0012\u0006\u0010\u0018\u001a\u00020\u0017\u0012\u0006\u0010\u001b\u001a\u00020\u001a\u0012\u0006\u0010\u001e\u001a\u00020\u001d\u0012\u0006\u0010!\u001a\u00020 \u0012\u0006\u0010$\u001a\u00020#¢\u0006\u0004\b?\u0010@J\b\u0010\u0003\u001a\u00020\u0002H\u0002J\b\u0010\u0004\u001a\u00020\u0002H\u0002J\u0006\u0010\u0005\u001a\u00020\u0002J\u0006\u0010\u0007\u001a\u00020\u0006J\u0006\u0010\b\u001a\u00020\u0002J\u000e\u0010\u000b\u001a\u00020\u00022\u0006\u0010\n\u001a\u00020\tJ\u000e\u0010\u000e\u001a\u00020\u00022\u0006\u0010\r\u001a\u00020\fJ\u0006\u0010\u000f\u001a\u00020\u0002J\u0006\u0010\u0010\u001a\u00020\u0002J\u0006\u0010\u0011\u001a\u00020\u0002J\u0006\u0010\u0012\u001a\u00020\u0002J\u000e\u0010\u0015\u001a\u00020\u00022\u0006\u0010\u0014\u001a\u00020\u0013J\b\u0010\u0016\u001a\u00020\u0002H\u0014R\u0014\u0010\u0018\u001a\u00020\u00178\u0002X\u0082\u0004¢\u0006\u0006\n\u0004\b\u0018\u0010\u0019R\u0014\u0010\u001b\u001a\u00020\u001a8\u0002X\u0082\u0004¢\u0006\u0006\n\u0004\b\u001b\u0010\u001cR\u0014\u0010\u001e\u001a\u00020\u001d8\u0002X\u0082\u0004¢\u0006\u0006\n\u0004\b\u001e\u0010\u001fR\u0014\u0010!\u001a\u00020 8\u0002X\u0082\u0004¢\u0006\u0006\n\u0004\b!\u0010\"R\u0014\u0010$\u001a\u00020#8\u0002X\u0082\u0004¢\u0006\u0006\n\u0004\b$\u0010%R#\u0010)\u001a\u000e\u0012\n\u0012\b\u0012\u0004\u0012\u00020(0'0&8\u0006¢\u0006\f\n\u0004\b)\u0010*\u001a\u0004\b+\u0010,R#\u0010/\u001a\u000e\u0012\n\u0012\b\u0012\u0004\u0012\u00020.0-0&8\u0006¢\u0006\f\n\u0004\b/\u0010*\u001a\u0004\b0\u0010,R#\u00101\u001a\u000e\u0012\n\u0012\b\u0012\u0004\u0012\u00020\u00020-0&8\u0006¢\u0006\f\n\u0004\b1\u0010*\u001a\u0004\b2\u0010,R#\u00103\u001a\u000e\u0012\n\u0012\b\u0012\u0004\u0012\u00020\u00020-0&8\u0006¢\u0006\f\n\u0004\b3\u0010*\u001a\u0004\b4\u0010,R#\u00105\u001a\u000e\u0012\n\u0012\b\u0012\u0004\u0012\u00020\u00020-0&8\u0006¢\u0006\f\n\u0004\b5\u0010*\u001a\u0004\b6\u0010,R\u0018\u0010\b\u001a\u0004\u0018\u00010\u00068\u0002@\u0002X\u0082\u000e¢\u0006\u0006\n\u0004\b\b\u00107R&\u0010:\u001a\u0012\u0012\u0004\u0012\u00020.08j\b\u0012\u0004\u0012\u00020.`98\u0002@\u0002X\u0082\u000e¢\u0006\u0006\n\u0004\b:\u0010;R\u0016\u0010=\u001a\u00020<8\u0002@\u0002X\u0082\u000e¢\u0006\u0006\n\u0004\b=\u0010>¨\u0006A"}, d2 = {"Lby/kufar/menu/ui/MenuVM;", "Lby/kufar/core/android/arch/BaseViewModel;", "", "loadVersion", "setUpMenuForm", "setUp", "Lkotlinx/coroutines/d2;", "onHidden", "refreshMenu", "Lob/d$c;", "option", "onItemClick", "Lob/e$a;", "promoItem", "onPromoShow", "onSettingsClick", "onHelpClick", "onPromotionClick", "onConnectClick", "Lob/d$a;", "menuItemAppVersion", "onUpdateButtonShown", "onCleared", "Lob/b;", "menuForm", "Lob/b;", "Lib/a;", "menuTracker", "Lib/a;", "Ljo/a;", "accountInfo", "Ljo/a;", "Lby/kufar/updatemanager/c;", "kufarAppUpdateManager", "Lby/kufar/updatemanager/c;", "Lk5/b;", "authorizationApi", "Lk5/b;", "Landroidx/lifecycle/MutableLiveData;", "", "Lob/d;", "menuItems", "Landroidx/lifecycle/MutableLiveData;", "getMenuItems", "()Landroidx/lifecycle/MutableLiveData;", "Lby/kufar/core/android/arch/a;", "", "openUrl", "getOpenUrl", "showConnectAction", "getShowConnectAction", "openSettings", "getOpenSettings", "openAppSettings", "getOpenAppSettings", "Lkotlinx/coroutines/d2;", "Ljava/util/HashSet;", "Lkotlin/collections/HashSet;", "viewedPromoIds", "Ljava/util/HashSet;", "", "isUpdateButtonTracked", "Z", "<init>", "(Lob/b;Lib/a;Ljo/a;Lby/kufar/updatemanager/c;Lk5/b;)V", "feature-menu_googleRelease"}, k = 1, mv = {1, 9, 0})
public final class MenuVM extends BaseViewModel {
private final jo.a accountInfo;
private final k5.b authorizationApi;
private boolean isUpdateButtonTracked;
private final by.kufar.updatemanager.c kufarAppUpdateManager;
private final ob.b menuForm;
private final MutableLiveData<List<ob.d>> menuItems;
private final ib.a menuTracker;
private final MutableLiveData<by.kufar.core.android.arch.a<Unit>> openAppSettings;
private final MutableLiveData<by.kufar.core.android.arch.a<Unit>> openSettings;
private final MutableLiveData<by.kufar.core.android.arch.a<String>> openUrl;
private d2 refreshMenu;
private final MutableLiveData<by.kufar.core.android.arch.a<Unit>> showConnectAction;
private HashSet<String> viewedPromoIds;
@Metadata(d1 = {"\u0000\n\n\u0002\u0018\u0002\n\u0002\u0010\u0002\n\u0000\u0010\u0002\u001a\u00020\u0001*\u00020\u0000H\u008a@"}, d2 = {"Lkotlinx/coroutines/q0;", "", "<anonymous>"}, k = 3, mv = {1, 9, 0})
@l80.f(c = "by.kufar.menu.ui.MenuVM$loadVersion$1", f = "MenuVM.kt", l = {50}, m = "invokeSuspend")
public static final class a extends l implements Function2<q0, j80.d<? super Unit>, Object> {
public Object f10552b;
public int f10553c;
public a(j80.d<? super a> dVar) {
super(2, dVar);
}
@Override
public final j80.d<Unit> create(Object obj, j80.d<?> dVar) {
return new a(dVar);
}
@Override
public final Object invokeSuspend(Object obj) {
ob.b bVar;
Object f11 = k80.c.f();
int i11 = this.f10553c;
if (i11 != 0) {
if (i11 == 1) {
bVar = (ob.b) this.f10552b;
q.b(obj);
} else {
throw new IllegalStateException("call to 'resume' before 'invoke' with coroutine");
}
} else {
q.b(obj);
ob.b bVar2 = MenuVM.this.menuForm;
by.kufar.updatemanager.c cVar = MenuVM.this.kufarAppUpdateManager;
this.f10552b = bVar2;
this.f10553c = 1;
Object i12 = cVar.i(this);
if (i12 == f11) {
return f11;
}
bVar = bVar2;
obj = i12;
}
bVar.C(((Boolean) obj).booleanValue());
MenuVM.this.refreshMenu();
return Unit.f82492a;
}
@Override
public final Object mo1invoke(q0 q0Var, j80.d<? super Unit> dVar) {
return ((a) create(q0Var, dVar)).invokeSuspend(Unit.f82492a);
}
}
@Metadata(d1 = {"\u0000\n\n\u0002\u0018\u0002\n\u0002\u0010\u0002\n\u0000\u0010\u0002\u001a\u00020\u0001*\u00020\u0000H\u008a@"}, d2 = {"Lkotlinx/coroutines/q0;", "", "<anonymous>"}, k = 3, mv = {1, 9, 0})
@l80.f(c = "by.kufar.menu.ui.MenuVM$onConnectClick$1", f = "MenuVM.kt", l = {}, m = "invokeSuspend")
public static final class b extends l implements Function2<q0, j80.d<? super Unit>, Object> {
public int f10555b;
@Metadata(k = 3, mv = {1, 9, 0}, xi = 48)
public class a {
public static final int[] $EnumSwitchMapping$0;
static {
int[] iArr = new int[by.kufar.userinfo.backend.entity.a.values().length];
try {
iArr[by.kufar.userinfo.backend.entity.a.f18930d.ordinal()] = 1;
} catch (NoSuchFieldError unused) {
}
try {
iArr[by.kufar.userinfo.backend.entity.a.f18929c.ordinal()] = 2;
} catch (NoSuchFieldError unused2) {
}
$EnumSwitchMapping$0 = iArr;
}
}
public b(j80.d<? super b> dVar) {
super(2, dVar);
}
@Override
public final j80.d<Unit> create(Object obj, j80.d<?> dVar) {
return new b(dVar);
}
@Override
public final Object invokeSuspend(Object obj) {
k80.c.f();
if (this.f10555b == 0) {
q.b(obj);
int i11 = a.$EnumSwitchMapping$0[MenuVM.this.accountInfo.c().ordinal()];
if (i11 != 1 && i11 != 2) {
MenuVM.this.getShowConnectAction().postValue(new by.kufar.core.android.arch.a<>(Unit.f82492a));
} else {
MenuVM.this.menuTracker.a();
MenuVM.this.getOpenUrl().postValue(new by.kufar.core.android.arch.a<>("https://support.kufar.by/hc/ru/requests/new?utm_source=Android&utm_medium=buttonWriteToDeveloper&utm_campaign=ProfileMenu"));
}
return Unit.f82492a;
}
throw new IllegalStateException("call to 'resume' before 'invoke' with coroutine");
}
@Override
public final Object mo1invoke(q0 q0Var, j80.d<? super Unit> dVar) {
return ((b) create(q0Var, dVar)).invokeSuspend(Unit.f82492a);
}
}
@Metadata(d1 = {"\u0000\n\n\u0002\u0018\u0002\n\u0002\u0010\u0002\n\u0000\u0010\u0002\u001a\u00020\u0001*\u00020\u0000H\u008a@"}, d2 = {"Lkotlinx/coroutines/q0;", "", "<anonymous>"}, k = 3, mv = {1, 9, 0})
@l80.f(c = "by.kufar.menu.ui.MenuVM$onHelpClick$1", f = "MenuVM.kt", l = {}, m = "invokeSuspend")
public static final class c extends l implements Function2<q0, j80.d<? super Unit>, Object> {
public int f10557b;
@Metadata(k = 3, mv = {1, 9, 0}, xi = 48)
public class a {
public static final int[] $EnumSwitchMapping$0;
static {
int[] iArr = new int[by.kufar.userinfo.backend.entity.a.values().length];
try {
iArr[by.kufar.userinfo.backend.entity.a.f18930d.ordinal()] = 1;
} catch (NoSuchFieldError unused) {
}
try {
iArr[by.kufar.userinfo.backend.entity.a.f18929c.ordinal()] = 2;
} catch (NoSuchFieldError unused2) {
}
$EnumSwitchMapping$0 = iArr;
}
}
public c(j80.d<? super c> dVar) {
super(2, dVar);
}
@Override
public final j80.d<Unit> create(Object obj, j80.d<?> dVar) {
return new c(dVar);
}
@Override
public final Object invokeSuspend(Object obj) {
k80.c.f();
if (this.f10557b == 0) {
q.b(obj);
if (!MenuVM.this.authorizationApi.a()) {
MenuVM.this.getOpenUrl().postValue(new by.kufar.core.android.arch.a<>("https://support.kufar.by/hc/ru"));
return Unit.f82492a;
}
int i11 = a.$EnumSwitchMapping$0[MenuVM.this.accountInfo.c().ordinal()];
if (i11 != 1 && i11 != 2) {
MenuVM.this.getOpenUrl().postValue(new by.kufar.core.android.arch.a<>("https://support.kufar.by/hc/ru/categories/360003732477"));
} else {
MenuVM.this.getOpenUrl().postValue(new by.kufar.core.android.arch.a<>("https://support.kufar.by/hc/ru"));
}
return Unit.f82492a;
}
throw new IllegalStateException("call to 'resume' before 'invoke' with coroutine");
}
@Override
public final Object mo1invoke(q0 q0Var, j80.d<? super Unit> dVar) {
return ((c) create(q0Var, dVar)).invokeSuspend(Unit.f82492a);
}
}
@Metadata(d1 = {"\u0000\n\n\u0002\u0018\u0002\n\u0002\u0010\u0002\n\u0000\u0010\u0002\u001a\u00020\u0001*\u00020\u0000H\u008a@"}, d2 = {"Lkotlinx/coroutines/q0;", "", "<anonymous>"}, k = 3, mv = {1, 9, 0})
@l80.f(c = "by.kufar.menu.ui.MenuVM$onHidden$1", f = "MenuVM.kt", l = {45}, m = "invokeSuspend")
public static final class d extends l implements Function2<q0, j80.d<? super Unit>, Object> {
public int f10559b;
public d(j80.d<? super d> dVar) {
super(2, dVar);
}
@Override
public final j80.d<Unit> create(Object obj, j80.d<?> dVar) {
return new d(dVar);
}
@Override
public final Object invokeSuspend(Object obj) {
Object f11 = k80.c.f();
int i11 = this.f10559b;
if (i11 != 0) {
if (i11 == 1) {
q.b(obj);
} else {
throw new IllegalStateException("call to 'resume' before 'invoke' with coroutine");
}
} else {
q.b(obj);
ob.b bVar = MenuVM.this.menuForm;
this.f10559b = 1;
if (bVar.I(this) == f11) {
return f11;
}
}
return Unit.f82492a;
}
@Override
public final Object mo1invoke(q0 q0Var, j80.d<? super Unit> dVar) {
return ((d) create(q0Var, dVar)).invokeSuspend(Unit.f82492a);
}
}
@Metadata(d1 = {"\u0000\n\n\u0002\u0018\u0002\n\u0002\u0010\u0002\n\u0000\u0010\u0002\u001a\u00020\u0001*\u00020\u0000H\u008a@"}, d2 = {"Lkotlinx/coroutines/q0;", "", "<anonymous>"}, k = 3, mv = {1, 9, 0})
@l80.f(c = "by.kufar.menu.ui.MenuVM$onItemClick$1", f = "MenuVM.kt", l = {65}, m = "invokeSuspend")
public static final class e extends l implements Function2<q0, j80.d<? super Unit>, Object> {
public int f10561b;
public final d.Option f10563d;
public e(d.Option option, j80.d<? super e> dVar) {
super(2, dVar);
this.f10563d = option;
}
@Override
public final j80.d<Unit> create(Object obj, j80.d<?> dVar) {
return new e(this.f10563d, dVar);
}
@Override
public final Object invokeSuspend(Object obj) {
Object f11 = k80.c.f();
int i11 = this.f10561b;
if (i11 != 0) {
if (i11 == 1) {
q.b(obj);
} else {
throw new IllegalStateException("call to 'resume' before 'invoke' with coroutine");
}
} else {
q.b(obj);
ob.b bVar = MenuVM.this.menuForm;
d.Option option = this.f10563d;
this.f10561b = 1;
if (bVar.x(option, this) == f11) {
return f11;
}
}
return Unit.f82492a;
}
@Override
public final Object mo1invoke(q0 q0Var, j80.d<? super Unit> dVar) {
return ((e) create(q0Var, dVar)).invokeSuspend(Unit.f82492a);
}
}
@Metadata(d1 = {"\u0000\n\n\u0002\u0018\u0002\n\u0002\u0010\u0002\n\u0000\u0010\u0002\u001a\u00020\u0001*\u00020\u0000H\u008a@"}, d2 = {"Lkotlinx/coroutines/q0;", "", "<anonymous>"}, k = 3, mv = {1, 9, 0})
@l80.f(c = "by.kufar.menu.ui.MenuVM$onPromotionClick$1", f = "MenuVM.kt", l = {}, m = "invokeSuspend")
public static final class f extends l implements Function2<q0, j80.d<? super Unit>, Object> {
public int f10564b;
public f(j80.d<? super f> dVar) {
super(2, dVar);
}
@Override
public final j80.d<Unit> create(Object obj, j80.d<?> dVar) {
return new f(dVar);
}
@Override
public final Object invokeSuspend(Object obj) {
k80.c.f();
if (this.f10564b == 0) {
q.b(obj);
MenuVM.this.getOpenUrl().postValue(new by.kufar.core.android.arch.a<>("https://www.kufar.by/account/promotion_services"));
return Unit.f82492a;
}
throw new IllegalStateException("call to 'resume' before 'invoke' with coroutine");
}
@Override
public final Object mo1invoke(q0 q0Var, j80.d<? super Unit> dVar) {
return ((f) create(q0Var, dVar)).invokeSuspend(Unit.f82492a);
}
}
@Metadata(d1 = {"\u0000\n\n\u0002\u0018\u0002\n\u0002\u0010\u0002\n\u0000\u0010\u0002\u001a\u00020\u0001*\u00020\u0000H\u008a@"}, d2 = {"Lkotlinx/coroutines/q0;", "", "<anonymous>"}, k = 3, mv = {1, 9, 0})
@l80.f(c = "by.kufar.menu.ui.MenuVM$refreshMenu$1", f = "MenuVM.kt", l = {59, 59}, m = "invokeSuspend")
public static final class g extends l implements Function2<q0, j80.d<? super Unit>, Object> {
public int f10566b;
@Metadata(d1 = {"\u0000\u0012\n\u0002\u0010 \n\u0002\u0018\u0002\n\u0000\n\u0002\u0010\u0002\n\u0002\b\u0002\u0010\u0004\u001a\u00020\u00032\f\u0010\u0002\u001a\b\u0012\u0004\u0012\u00020\u00010\u0000H\u008a@¢\u0006\u0004\b\u0004\u0010\u0005"}, d2 = {"", "Lob/d;", "data", "", "a", "(Ljava/util/List;Lj80/d;)Ljava/lang/Object;"}, k = 3, mv = {1, 9, 0})
public static final class a<T> implements kotlinx.coroutines.flow.h {
public final MenuVM f10568b;
public a(MenuVM menuVM) {
this.f10568b = menuVM;
}
@Override
public final Object emit(List<? extends ob.d> list, j80.d<? super Unit> dVar) {
this.f10568b.getMenuItems().setValue(list);
return Unit.f82492a;
}
}
public g(j80.d<? super g> dVar) {
super(2, dVar);
}
@Override
public final j80.d<Unit> create(Object obj, j80.d<?> dVar) {
return new g(dVar);
}
@Override
public final Object invokeSuspend(Object obj) {
Object f11 = k80.c.f();
int i11 = this.f10566b;
if (i11 != 0) {
if (i11 != 1) {
if (i11 == 2) {
q.b(obj);
return Unit.f82492a;
}
throw new IllegalStateException("call to 'resume' before 'invoke' with coroutine");
}
q.b(obj);
} else {
q.b(obj);
ob.b bVar = MenuVM.this.menuForm;
this.f10566b = 1;
obj = bVar.v(this);
if (obj == f11) {
return f11;
}
}
a aVar = new a(MenuVM.this);
this.f10566b = 2;
if (((kotlinx.coroutines.flow.g) obj).collect(aVar, this) == f11) {
return f11;
}
return Unit.f82492a;
}
@Override
public final Object mo1invoke(q0 q0Var, j80.d<? super Unit> dVar) {
return ((g) create(q0Var, dVar)).invokeSuspend(Unit.f82492a);
}
}
@Metadata(d1 = {"\u0000\f\n\u0002\u0018\u0002\n\u0000\n\u0002\u0010\u0002\n\u0000\u0010\u0003\u001a\u00020\u00022\u0006\u0010\u0001\u001a\u00020\u0000H\u008a@"}, d2 = {"Lob/b$a;", "it", "", "<anonymous>"}, k = 3, mv = {1, 9, 0})
@l80.f(c = "by.kufar.menu.ui.MenuVM$setUpMenuForm$1", f = "MenuVM.kt", l = {}, m = "invokeSuspend")
public static final class h extends l implements Function2<b.a, j80.d<? super Unit>, Object> {
public int f10569b;
public h(j80.d<? super h> dVar) {
super(2, dVar);
}
@Override
public final Object mo1invoke(b.a aVar, j80.d<? super Unit> dVar) {
return ((h) create(aVar, dVar)).invokeSuspend(Unit.f82492a);
}
@Override
public final j80.d<Unit> create(Object obj, j80.d<?> dVar) {
return new h(dVar);
}
@Override
public final Object invokeSuspend(Object obj) {
k80.c.f();
if (this.f10569b == 0) {
q.b(obj);
MenuVM.this.refreshMenu();
return Unit.f82492a;
}
throw new IllegalStateException("call to 'resume' before 'invoke' with coroutine");
}
}
public MenuVM(ob.b menuForm, ib.a menuTracker, jo.a accountInfo, by.kufar.updatemanager.c kufarAppUpdateManager, k5.b authorizationApi) {
s.j(menuForm, "menuForm");
s.j(menuTracker, "menuTracker");
s.j(accountInfo, "accountInfo");
s.j(kufarAppUpdateManager, "kufarAppUpdateManager");
s.j(authorizationApi, "authorizationApi");
this.menuForm = menuForm;
this.menuTracker = menuTracker;
this.accountInfo = accountInfo;
this.kufarAppUpdateManager = kufarAppUpdateManager;
this.authorizationApi = authorizationApi;
this.menuItems = new MutableLiveData<>();
this.openUrl = new MutableLiveData<>();
this.showConnectAction = new MutableLiveData<>();
this.openSettings = new MutableLiveData<>();
this.openAppSettings = new MutableLiveData<>();
this.viewedPromoIds = new HashSet<>();
}
private final void loadVersion() {
kotlinx.coroutines.l.d(getViewModelScope(), null, null, new a(null), 3, null);
}
private final void setUpMenuForm() {
this.menuForm.D(getViewModelScope());
i.M(i.R(this.menuForm.u(), new h(null)), getViewModelScope());
}
public final MutableLiveData<List<ob.d>> getMenuItems() {
return this.menuItems;
}
public final MutableLiveData<by.kufar.core.android.arch.a<Unit>> getOpenAppSettings() {
return this.openAppSettings;
}
public final MutableLiveData<by.kufar.core.android.arch.a<Unit>> getOpenSettings() {
return this.openSettings;
}
public final MutableLiveData<by.kufar.core.android.arch.a<String>> getOpenUrl() {
return this.openUrl;
}
public final MutableLiveData<by.kufar.core.android.arch.a<Unit>> getShowConnectAction() {
return this.showConnectAction;
}
@Override
public void onCleared() {
super.onCleared();
this.menuForm.F();
}
public final void onConnectClick() {
kotlinx.coroutines.l.d(getViewModelScope(), null, null, new b(null), 3, null);
}
public final void onHelpClick() {
kotlinx.coroutines.l.d(getViewModelScope(), null, null, new c(null), 3, null);
}
public final d2 onHidden() {
d2 d11;
d11 = kotlinx.coroutines.l.d(getViewModelScope(), null, null, new d(null), 3, null);
return d11;
}
public final void onItemClick(d.Option option) {
s.j(option, "option");
kotlinx.coroutines.l.d(getViewModelScope(), null, null, new e(option, null), 3, null);
}
public final void onPromoShow(e.Block promoItem) {
s.j(promoItem, "promoItem");
if (!this.viewedPromoIds.contains(promoItem.getId())) {
this.viewedPromoIds.add(promoItem.getId());
this.menuTracker.i(promoItem);
}
}
public final void onPromotionClick() {
kotlinx.coroutines.l.d(getViewModelScope(), null, null, new f(null), 3, null);
}
public final void onSettingsClick() {
if (this.authorizationApi.a()) {
this.openSettings.setValue(new by.kufar.core.android.arch.a<>(Unit.f82492a));
} else {
this.openAppSettings.setValue(new by.kufar.core.android.arch.a<>(Unit.f82492a));
}
}
public final void onUpdateButtonShown(d.AppVersion menuItemAppVersion) {
s.j(menuItemAppVersion, "menuItemAppVersion");
if (!this.isUpdateButtonTracked) {
this.isUpdateButtonTracked = true;
this.menuTracker.f(menuItemAppVersion);
}
}
public final void refreshMenu() {
d2 d11;
d2 d2Var = this.refreshMenu;
if (d2Var != null) {
d2.a.a(d2Var, null, 1, null);
}
this.menuForm.z();
d11 = kotlinx.coroutines.l.d(getViewModelScope(), null, null, new g(null), 3, null);
this.refreshMenu = d11;
}
public final void setUp() {
setUpMenuForm();
loadVersion();
refreshMenu();
}
}