SharingLocationsAlert.smali
.class public Lim/tpelyyftgw/ui/components/SharingLocationsAlert;
.super Lim/tpelyyftgw/ui/actionbar/BottomSheet;
.source "SharingLocationsAlert.java"
# interfaces
.implements Lim/tpelyyftgw/messenger/NotificationCenter$NotificationCenterDelegate;
# annotations
.annotation system Ldalvik/annotation/MemberClasses;
value = {
Lim/tpelyyftgw/ui/components/SharingLocationsAlert$ListAdapter;,
Lim/tpelyyftgw/ui/components/SharingLocationsAlert$SharingLocationsAlertDelegate;
}
.end annotation
# instance fields
.field private adapter:Lim/tpelyyftgw/ui/components/SharingLocationsAlert$ListAdapter;
.field private delegate:Lim/tpelyyftgw/ui/components/SharingLocationsAlert$SharingLocationsAlertDelegate;
.field private ignoreLayout:Z
.field private listView:Lim/tpelyyftgw/ui/components/RecyclerListView;
.field private reqId:I
.field private scrollOffsetY:I
.field private shadowDrawable:Landroid/graphics/drawable/Drawable;
.field private textView:Landroid/widget/TextView;
.field private urlPattern:Ljava/util/regex/Pattern;
# direct methods
.method static constructor <clinit>()V
.registers 1
return-void
.end method
.method public constructor <init>(Landroid/content/Context;Lim/tpelyyftgw/ui/components/SharingLocationsAlert$SharingLocationsAlertDelegate;)V
.registers 14
.param p1, "context" # Landroid/content/Context;
.param p2, "sharingLocationsAlertDelegate" # Lim/tpelyyftgw/ui/components/SharingLocationsAlert$SharingLocationsAlertDelegate;
.line 56
const/4 v0, 0x0
invoke-direct {p0, p1, v0, v0}, Lim/tpelyyftgw/ui/actionbar/BottomSheet;-><init>(Landroid/content/Context;ZI)V
.line 57
invoke-static {}, Lim/tpelyyftgw/messenger/NotificationCenter;->getGlobalInstance()Lim/tpelyyftgw/messenger/NotificationCenter;
move-result-object v1
sget v2, Lim/tpelyyftgw/messenger/NotificationCenter;->liveLocationsChanged:I
invoke-virtual {v1, p0, v2}, Lim/tpelyyftgw/messenger/NotificationCenter;->addObserver(Ljava/lang/Object;I)V
.line 58
iput-object p2, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->delegate:Lim/tpelyyftgw/ui/components/SharingLocationsAlert$SharingLocationsAlertDelegate;
.line 60
invoke-virtual {p1}, Landroid/content/Context;->getResources()Landroid/content/res/Resources;
move-result-object v1
const v2, 0x7f081638
invoke-static {v2}, Lnp/NPFog;->d(I)I
move-result v2
invoke-virtual {v1, v2}, Landroid/content/res/Resources;->getDrawable(I)Landroid/graphics/drawable/Drawable;
move-result-object v1
invoke-virtual {v1}, Landroid/graphics/drawable/Drawable;->mutate()Landroid/graphics/drawable/Drawable;
move-result-object v1
iput-object v1, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->shadowDrawable:Landroid/graphics/drawable/Drawable;
.line 61
new-instance v2, Landroid/graphics/PorterDuffColorFilter;
const-string v3, "dialogBackground"
invoke-static {v3}, Lim/tpelyyftgw/ui/actionbar/Theme;->getColor(Ljava/lang/String;)I
move-result v4
sget-object v5, Landroid/graphics/PorterDuff$Mode;->MULTIPLY:Landroid/graphics/PorterDuff$Mode;
invoke-direct {v2, v4, v5}, Landroid/graphics/PorterDuffColorFilter;-><init>(ILandroid/graphics/PorterDuff$Mode;)V
invoke-virtual {v1, v2}, Landroid/graphics/drawable/Drawable;->setColorFilter(Landroid/graphics/ColorFilter;)V
.line 63
new-instance v1, Lim/tpelyyftgw/ui/components/SharingLocationsAlert$1;
invoke-direct {v1, p0, p1}, Lim/tpelyyftgw/ui/components/SharingLocationsAlert$1;-><init>(Lim/tpelyyftgw/ui/components/SharingLocationsAlert;Landroid/content/Context;)V
iput-object v1, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->containerView:Landroid/view/ViewGroup;
.line 126
iget-object v1, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->containerView:Landroid/view/ViewGroup;
invoke-virtual {v1, v0}, Landroid/view/ViewGroup;->setWillNotDraw(Z)V
.line 127
iget-object v1, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->containerView:Landroid/view/ViewGroup;
iget v2, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->backgroundPaddingLeft:I
iget v4, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->backgroundPaddingLeft:I
invoke-virtual {v1, v2, v0, v4, v0}, Landroid/view/ViewGroup;->setPadding(IIII)V
.line 129
new-instance v1, Lim/tpelyyftgw/ui/components/SharingLocationsAlert$2;
invoke-direct {v1, p0, p1}, Lim/tpelyyftgw/ui/components/SharingLocationsAlert$2;-><init>(Lim/tpelyyftgw/ui/components/SharingLocationsAlert;Landroid/content/Context;)V
iput-object v1, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->listView:Lim/tpelyyftgw/ui/components/RecyclerListView;
.line 144
new-instance v2, Landroidx/recyclerview/widget/LinearLayoutManager;
invoke-virtual {p0}, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->getContext()Landroid/content/Context;
move-result-object v4
const/4 v5, 0x1
invoke-direct {v2, v4, v5, v0}, Landroidx/recyclerview/widget/LinearLayoutManager;-><init>(Landroid/content/Context;IZ)V
invoke-virtual {v1, v2}, Lim/tpelyyftgw/ui/components/RecyclerListView;->setLayoutManager(Landroidx/recyclerview/widget/RecyclerView$LayoutManager;)V
.line 145
iget-object v1, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->listView:Lim/tpelyyftgw/ui/components/RecyclerListView;
new-instance v2, Lim/tpelyyftgw/ui/components/SharingLocationsAlert$ListAdapter;
invoke-direct {v2, p0, p1}, Lim/tpelyyftgw/ui/components/SharingLocationsAlert$ListAdapter;-><init>(Lim/tpelyyftgw/ui/components/SharingLocationsAlert;Landroid/content/Context;)V
iput-object v2, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->adapter:Lim/tpelyyftgw/ui/components/SharingLocationsAlert$ListAdapter;
invoke-virtual {v1, v2}, Lim/tpelyyftgw/ui/components/RecyclerListView;->setAdapter(Landroidx/recyclerview/widget/RecyclerView$Adapter;)V
.line 146
iget-object v1, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->listView:Lim/tpelyyftgw/ui/components/RecyclerListView;
invoke-virtual {v1, v0}, Lim/tpelyyftgw/ui/components/RecyclerListView;->setVerticalScrollBarEnabled(Z)V
.line 147
iget-object v1, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->listView:Lim/tpelyyftgw/ui/components/RecyclerListView;
invoke-virtual {v1, v0}, Lim/tpelyyftgw/ui/components/RecyclerListView;->setClipToPadding(Z)V
.line 148
iget-object v1, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->listView:Lim/tpelyyftgw/ui/components/RecyclerListView;
invoke-virtual {v1, v5}, Lim/tpelyyftgw/ui/components/RecyclerListView;->setEnabled(Z)V
.line 149
iget-object v1, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->listView:Lim/tpelyyftgw/ui/components/RecyclerListView;
const-string v2, "dialogScrollGlow"
invoke-static {v2}, Lim/tpelyyftgw/ui/actionbar/Theme;->getColor(Ljava/lang/String;)I
move-result v2
invoke-virtual {v1, v2}, Lim/tpelyyftgw/ui/components/RecyclerListView;->setGlowColor(I)V
.line 150
iget-object v1, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->listView:Lim/tpelyyftgw/ui/components/RecyclerListView;
new-instance v2, Lim/tpelyyftgw/ui/components/SharingLocationsAlert$3;
invoke-direct {v2, p0}, Lim/tpelyyftgw/ui/components/SharingLocationsAlert$3;-><init>(Lim/tpelyyftgw/ui/components/SharingLocationsAlert;)V
invoke-virtual {v1, v2}, Lim/tpelyyftgw/ui/components/RecyclerListView;->setOnScrollListener(Landroidx/recyclerview/widget/RecyclerView$OnScrollListener;)V
.line 156
iget-object v1, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->listView:Lim/tpelyyftgw/ui/components/RecyclerListView;
new-instance v2, Lim/tpelyyftgw/ui/components/-$$Lambda$SharingLocationsAlert$mEB36gXZTDqcdAstA09YK5-etn4;
invoke-direct {v2, p0}, Lim/tpelyyftgw/ui/components/-$$Lambda$SharingLocationsAlert$mEB36gXZTDqcdAstA09YK5-etn4;-><init>(Lim/tpelyyftgw/ui/components/SharingLocationsAlert;)V
invoke-virtual {v1, v2}, Lim/tpelyyftgw/ui/components/RecyclerListView;->setOnItemClickListener(Lim/tpelyyftgw/ui/components/RecyclerListView$OnItemClickListener;)V
.line 164
iget-object v1, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->containerView:Landroid/view/ViewGroup;
iget-object v2, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->listView:Lim/tpelyyftgw/ui/components/RecyclerListView;
const/high16 v4, -0x40800000 # -1.0f
const/high16 v5, -0x40800000 # -1.0f
const/16 v6, 0x33
const/4 v7, 0x0
const/4 v8, 0x0
const/4 v9, 0x0
const/high16 v10, 0x42400000 # 48.0f
invoke-static/range {v4 .. v10}, Lim/tpelyyftgw/ui/components/LayoutHelper;->createFrame(FFIFFFF)Landroid/widget/FrameLayout$LayoutParams;
move-result-object v4
invoke-virtual {v1, v2, v4}, Landroid/view/ViewGroup;->addView(Landroid/view/View;Landroid/view/ViewGroup$LayoutParams;)V
.line 166
new-instance v1, Landroid/view/View;
invoke-direct {v1, p1}, Landroid/view/View;-><init>(Landroid/content/Context;)V
.line 167
.local v1, "shadow":Landroid/view/View;
const v2, 0x7f08015e
invoke-virtual {v1, v2}, Landroid/view/View;->setBackgroundResource(I)V
.line 168
iget-object v2, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->containerView:Landroid/view/ViewGroup;
const/high16 v4, -0x40800000 # -1.0f
const/high16 v5, 0x40400000 # 3.0f
const/16 v6, 0x53
invoke-static/range {v4 .. v10}, Lim/tpelyyftgw/ui/components/LayoutHelper;->createFrame(FFIFFFF)Landroid/widget/FrameLayout$LayoutParams;
move-result-object v4
invoke-virtual {v2, v1, v4}, Landroid/view/ViewGroup;->addView(Landroid/view/View;Landroid/view/ViewGroup$LayoutParams;)V
.line 170
new-instance v2, Lim/tpelyyftgw/ui/components/PickerBottomLayout;
invoke-direct {v2, p1, v0}, Lim/tpelyyftgw/ui/components/PickerBottomLayout;-><init>(Landroid/content/Context;Z)V
.line 171
.local v2, "pickerBottomLayout":Lim/tpelyyftgw/ui/components/PickerBottomLayout;
invoke-static {v3}, Lim/tpelyyftgw/ui/actionbar/Theme;->getColor(Ljava/lang/String;)I
move-result v3
invoke-virtual {v2, v3}, Lim/tpelyyftgw/ui/components/PickerBottomLayout;->setBackgroundColor(I)V
.line 172
iget-object v3, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->containerView:Landroid/view/ViewGroup;
const/4 v4, -0x1
const/16 v5, 0x30
invoke-static {v4, v5, v6}, Lim/tpelyyftgw/ui/components/LayoutHelper;->createFrame(III)Landroid/widget/FrameLayout$LayoutParams;
move-result-object v4
invoke-virtual {v3, v2, v4}, Landroid/view/ViewGroup;->addView(Landroid/view/View;Landroid/view/ViewGroup$LayoutParams;)V
.line 173
iget-object v3, v2, Lim/tpelyyftgw/ui/components/PickerBottomLayout;->cancelButton:Landroid/widget/TextView;
const/high16 v4, 0x41900000 # 18.0f
invoke-static {v4}, Lim/tpelyyftgw/messenger/AndroidUtilities;->dp(F)I
move-result v5
invoke-static {v4}, Lim/tpelyyftgw/messenger/AndroidUtilities;->dp(F)I
move-result v6
invoke-virtual {v3, v5, v0, v6, v0}, Landroid/widget/TextView;->setPadding(IIII)V
.line 174
iget-object v3, v2, Lim/tpelyyftgw/ui/components/PickerBottomLayout;->cancelButton:Landroid/widget/TextView;
const-string v5, "dialogTextRed"
invoke-static {v5}, Lim/tpelyyftgw/ui/actionbar/Theme;->getColor(Ljava/lang/String;)I
move-result v5
invoke-virtual {v3, v5}, Landroid/widget/TextView;->setTextColor(I)V
.line 175
iget-object v3, v2, Lim/tpelyyftgw/ui/components/PickerBottomLayout;->cancelButton:Landroid/widget/TextView;
const-string v5, "StopAllLocationSharings"
const v6, 0x7f0f1005
invoke-static {v5, v6}, Lim/tpelyyftgw/messenger/LocaleController;->getString(Ljava/lang/String;I)Ljava/lang/String;
move-result-object v5
invoke-virtual {v3, v5}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V
.line 176
iget-object v3, v2, Lim/tpelyyftgw/ui/components/PickerBottomLayout;->cancelButton:Landroid/widget/TextView;
new-instance v5, Lim/tpelyyftgw/ui/components/-$$Lambda$SharingLocationsAlert$2o-tdfEHOOKLXfTH00cq5_CFe5w;
invoke-direct {v5, p0}, Lim/tpelyyftgw/ui/components/-$$Lambda$SharingLocationsAlert$2o-tdfEHOOKLXfTH00cq5_CFe5w;-><init>(Lim/tpelyyftgw/ui/components/SharingLocationsAlert;)V
invoke-virtual {v3, v5}, Landroid/widget/TextView;->setOnClickListener(Landroid/view/View$OnClickListener;)V
.line 182
iget-object v3, v2, Lim/tpelyyftgw/ui/components/PickerBottomLayout;->doneButtonTextView:Landroid/widget/TextView;
const-string v5, "dialogTextBlue2"
invoke-static {v5}, Lim/tpelyyftgw/ui/actionbar/Theme;->getColor(Ljava/lang/String;)I
move-result v5
invoke-virtual {v3, v5}, Landroid/widget/TextView;->setTextColor(I)V
.line 183
iget-object v3, v2, Lim/tpelyyftgw/ui/components/PickerBottomLayout;->doneButtonTextView:Landroid/widget/TextView;
const-string v5, "Close"
const v6, 0x7f0f042e
invoke-static {v5, v6}, Lim/tpelyyftgw/messenger/LocaleController;->getString(Ljava/lang/String;I)Ljava/lang/String;
move-result-object v5
invoke-virtual {v5}, Ljava/lang/String;->toUpperCase()Ljava/lang/String;
move-result-object v5
invoke-virtual {v3, v5}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V
.line 184
iget-object v3, v2, Lim/tpelyyftgw/ui/components/PickerBottomLayout;->doneButton:Landroid/widget/LinearLayout;
invoke-static {v4}, Lim/tpelyyftgw/messenger/AndroidUtilities;->dp(F)I
move-result v5
invoke-static {v4}, Lim/tpelyyftgw/messenger/AndroidUtilities;->dp(F)I
move-result v4
invoke-virtual {v3, v5, v0, v4, v0}, Landroid/widget/LinearLayout;->setPadding(IIII)V
.line 185
iget-object v0, v2, Lim/tpelyyftgw/ui/components/PickerBottomLayout;->doneButton:Landroid/widget/LinearLayout;
new-instance v3, Lim/tpelyyftgw/ui/components/-$$Lambda$SharingLocationsAlert$WxaeN-K5hD0ZQlJGugWx9Xz0cZw;
invoke-direct {v3, p0}, Lim/tpelyyftgw/ui/components/-$$Lambda$SharingLocationsAlert$WxaeN-K5hD0ZQlJGugWx9Xz0cZw;-><init>(Lim/tpelyyftgw/ui/components/SharingLocationsAlert;)V
invoke-virtual {v0, v3}, Landroid/widget/LinearLayout;->setOnClickListener(Landroid/view/View$OnClickListener;)V
.line 186
iget-object v0, v2, Lim/tpelyyftgw/ui/components/PickerBottomLayout;->doneButtonBadgeTextView:Landroid/widget/TextView;
const/16 v3, 0x8
invoke-virtual {v0, v3}, Landroid/widget/TextView;->setVisibility(I)V
.line 188
iget-object v0, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->adapter:Lim/tpelyyftgw/ui/components/SharingLocationsAlert$ListAdapter;
invoke-virtual {v0}, Lim/tpelyyftgw/ui/components/SharingLocationsAlert$ListAdapter;->notifyDataSetChanged()V
.line 189
return-void
.end method
.method static synthetic access$000(Lim/tpelyyftgw/ui/components/SharingLocationsAlert;)I
.registers 2
.param p0, "x0" # Lim/tpelyyftgw/ui/components/SharingLocationsAlert;
.line 37
iget v0, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->scrollOffsetY:I
return v0
.end method
.method static synthetic access$100(Lim/tpelyyftgw/ui/components/SharingLocationsAlert;)Lim/tpelyyftgw/ui/components/RecyclerListView;
.registers 2
.param p0, "x0" # Lim/tpelyyftgw/ui/components/SharingLocationsAlert;
.line 37
iget-object v0, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->listView:Lim/tpelyyftgw/ui/components/RecyclerListView;
return-object v0
.end method
.method static synthetic access$200(Lim/tpelyyftgw/ui/components/SharingLocationsAlert;)Z
.registers 2
.param p0, "x0" # Lim/tpelyyftgw/ui/components/SharingLocationsAlert;
.line 37
iget-boolean v0, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->ignoreLayout:Z
return v0
.end method
.method static synthetic access$202(Lim/tpelyyftgw/ui/components/SharingLocationsAlert;Z)Z
.registers 2
.param p0, "x0" # Lim/tpelyyftgw/ui/components/SharingLocationsAlert;
.param p1, "x1" # Z
.line 37
iput-boolean p1, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->ignoreLayout:Z
return p1
.end method
.method static synthetic access$300(Lim/tpelyyftgw/ui/components/SharingLocationsAlert;)V
.registers 1
.param p0, "x0" # Lim/tpelyyftgw/ui/components/SharingLocationsAlert;
.line 37
invoke-direct {p0}, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->updateLayout()V
return-void
.end method
.method static synthetic access$400(Lim/tpelyyftgw/ui/components/SharingLocationsAlert;)I
.registers 2
.param p0, "x0" # Lim/tpelyyftgw/ui/components/SharingLocationsAlert;
.line 37
iget v0, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->backgroundPaddingTop:I
return v0
.end method
.method static synthetic access$500(Lim/tpelyyftgw/ui/components/SharingLocationsAlert;)Landroid/graphics/drawable/Drawable;
.registers 2
.param p0, "x0" # Lim/tpelyyftgw/ui/components/SharingLocationsAlert;
.line 37
iget-object v0, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->shadowDrawable:Landroid/graphics/drawable/Drawable;
return-object v0
.end method
.method static synthetic access$600(Lim/tpelyyftgw/ui/components/SharingLocationsAlert;)Landroid/widget/TextView;
.registers 2
.param p0, "x0" # Lim/tpelyyftgw/ui/components/SharingLocationsAlert;
.line 37
iget-object v0, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->textView:Landroid/widget/TextView;
return-object v0
.end method
.method static synthetic access$602(Lim/tpelyyftgw/ui/components/SharingLocationsAlert;Landroid/widget/TextView;)Landroid/widget/TextView;
.registers 2
.param p0, "x0" # Lim/tpelyyftgw/ui/components/SharingLocationsAlert;
.param p1, "x1" # Landroid/widget/TextView;
.line 37
iput-object p1, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->textView:Landroid/widget/TextView;
return-object p1
.end method
.method static synthetic access$700(Lim/tpelyyftgw/ui/components/SharingLocationsAlert;I)Lim/tpelyyftgw/messenger/LocationController$SharingLocationInfo;
.registers 3
.param p0, "x0" # Lim/tpelyyftgw/ui/components/SharingLocationsAlert;
.param p1, "x1" # I
.line 37
invoke-direct {p0, p1}, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->getLocation(I)Lim/tpelyyftgw/messenger/LocationController$SharingLocationInfo;
move-result-object v0
return-object v0
.end method
.method private getLocation(I)Lim/tpelyyftgw/messenger/LocationController$SharingLocationInfo;
.registers 5
.param p1, "position" # I
.line 225
const/4 v0, 0x0
.local v0, "a":I
:goto_1
const/4 v1, 0x3
if-ge v0, v1, :cond_1f
.line 226
invoke-static {v0}, Lim/tpelyyftgw/messenger/LocationController;->getInstance(I)Lim/tpelyyftgw/messenger/LocationController;
move-result-object v1
iget-object v1, v1, Lim/tpelyyftgw/messenger/LocationController;->sharingLocationsUI:Ljava/util/ArrayList;
.line 227
.local v1, "infos":Ljava/util/ArrayList;, "Ljava/util/ArrayList<Lim/tpelyyftgw/messenger/LocationController$SharingLocationInfo;>;"
invoke-virtual {v1}, Ljava/util/ArrayList;->size()I
move-result v2
if-lt p1, v2, :cond_18
.line 228
invoke-virtual {v1}, Ljava/util/ArrayList;->size()I
move-result v2
sub-int/2addr p1, v2
.line 225
.end local v1 # "infos":Ljava/util/ArrayList;, "Ljava/util/ArrayList<Lim/tpelyyftgw/messenger/LocationController$SharingLocationInfo;>;"
add-int/lit8 v0, v0, 0x1
goto :goto_1
.line 230
.restart local v1 # "infos":Ljava/util/ArrayList;, "Ljava/util/ArrayList<Lim/tpelyyftgw/messenger/LocationController$SharingLocationInfo;>;"
:cond_18
invoke-virtual {v1, p1}, Ljava/util/ArrayList;->get(I)Ljava/lang/Object;
move-result-object v2
check-cast v2, Lim/tpelyyftgw/messenger/LocationController$SharingLocationInfo;
return-object v2
.line 233
.end local v0 # "a":I
.end local v1 # "infos":Ljava/util/ArrayList;, "Ljava/util/ArrayList<Lim/tpelyyftgw/messenger/LocationController$SharingLocationInfo;>;"
:cond_1f
const/4 v0, 0x0
return-object v0
.end method
.method private updateLayout()V
.registers 6
.line 198
iget-object v0, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->listView:Lim/tpelyyftgw/ui/components/RecyclerListView;
invoke-virtual {v0}, Lim/tpelyyftgw/ui/components/RecyclerListView;->getChildCount()I
move-result v0
if-gtz v0, :cond_19
.line 199
iget-object v0, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->listView:Lim/tpelyyftgw/ui/components/RecyclerListView;
invoke-virtual {v0}, Lim/tpelyyftgw/ui/components/RecyclerListView;->getPaddingTop()I
move-result v1
iput v1, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->scrollOffsetY:I
invoke-virtual {v0, v1}, Lim/tpelyyftgw/ui/components/RecyclerListView;->setTopGlowOffset(I)V
.line 200
iget-object v0, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->containerView:Landroid/view/ViewGroup;
invoke-virtual {v0}, Landroid/view/ViewGroup;->invalidate()V
.line 201
return-void
.line 203
:cond_19
iget-object v0, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->listView:Lim/tpelyyftgw/ui/components/RecyclerListView;
const/4 v1, 0x0
invoke-virtual {v0, v1}, Lim/tpelyyftgw/ui/components/RecyclerListView;->getChildAt(I)Landroid/view/View;
move-result-object v0
.line 204
.local v0, "child":Landroid/view/View;
iget-object v2, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->listView:Lim/tpelyyftgw/ui/components/RecyclerListView;
invoke-virtual {v2, v0}, Lim/tpelyyftgw/ui/components/RecyclerListView;->findContainingViewHolder(Landroid/view/View;)Landroidx/recyclerview/widget/RecyclerView$ViewHolder;
move-result-object v2
check-cast v2, Lim/tpelyyftgw/ui/components/RecyclerListView$Holder;
.line 205
.local v2, "holder":Lim/tpelyyftgw/ui/components/RecyclerListView$Holder;
invoke-virtual {v0}, Landroid/view/View;->getTop()I
move-result v3
const/high16 v4, 0x41000000 # 8.0f
invoke-static {v4}, Lim/tpelyyftgw/messenger/AndroidUtilities;->dp(F)I
move-result v4
sub-int/2addr v3, v4
.line 206
.local v3, "top":I
if-lez v3, :cond_3e
if-eqz v2, :cond_3e
invoke-virtual {v2}, Lim/tpelyyftgw/ui/components/RecyclerListView$Holder;->getAdapterPosition()I
move-result v4
if-nez v4, :cond_3e
move v1, v3
.line 207
.local v1, "newOffset":I
:cond_3e
iget v4, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->scrollOffsetY:I
if-eq v4, v1, :cond_4e
.line 208
iget-object v4, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->listView:Lim/tpelyyftgw/ui/components/RecyclerListView;
iput v1, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->scrollOffsetY:I
invoke-virtual {v4, v1}, Lim/tpelyyftgw/ui/components/RecyclerListView;->setTopGlowOffset(I)V
.line 209
iget-object v4, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->containerView:Landroid/view/ViewGroup;
invoke-virtual {v4}, Landroid/view/ViewGroup;->invalidate()V
.line 211
:cond_4e
return-void
.end method
# virtual methods
.method protected canDismissWithSwipe()Z
.registers 2
.line 193
const/4 v0, 0x0
return v0
.end method
.method public varargs didReceivedNotification(II[Ljava/lang/Object;)V
.registers 5
.param p1, "id" # I
.param p2, "account" # I
.param p3, "args" # [Ljava/lang/Object;
.line 215
sget v0, Lim/tpelyyftgw/messenger/NotificationCenter;->liveLocationsChanged:I
if-ne p1, v0, :cond_13
.line 216
invoke-static {}, Lim/tpelyyftgw/messenger/LocationController;->getLocationsCount()I
move-result v0
if-nez v0, :cond_e
.line 217
invoke-virtual {p0}, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->dismiss()V
goto :goto_13
.line 219
:cond_e
iget-object v0, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->adapter:Lim/tpelyyftgw/ui/components/SharingLocationsAlert$ListAdapter;
invoke-virtual {v0}, Lim/tpelyyftgw/ui/components/SharingLocationsAlert$ListAdapter;->notifyDataSetChanged()V
.line 222
:cond_13
:goto_13
return-void
.end method
.method public dismiss()V
.registers 3
.line 238
invoke-super {p0}, Lim/tpelyyftgw/ui/actionbar/BottomSheet;->dismiss()V
.line 239
invoke-static {}, Lim/tpelyyftgw/messenger/NotificationCenter;->getGlobalInstance()Lim/tpelyyftgw/messenger/NotificationCenter;
move-result-object v0
sget v1, Lim/tpelyyftgw/messenger/NotificationCenter;->liveLocationsChanged:I
invoke-virtual {v0, p0, v1}, Lim/tpelyyftgw/messenger/NotificationCenter;->removeObserver(Ljava/lang/Object;I)V
.line 240
return-void
.end method
.method public synthetic lambda$new$0$SharingLocationsAlert(Landroid/view/View;I)V
.registers 5
.param p1, "view" # Landroid/view/View;
.param p2, "position" # I
.line 157
add-int/lit8 p2, p2, -0x1
.line 158
if-ltz p2, :cond_18
invoke-static {}, Lim/tpelyyftgw/messenger/LocationController;->getLocationsCount()I
move-result v0
if-lt p2, v0, :cond_b
goto :goto_18
.line 161
:cond_b
iget-object v0, p0, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->delegate:Lim/tpelyyftgw/ui/components/SharingLocationsAlert$SharingLocationsAlertDelegate;
invoke-direct {p0, p2}, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->getLocation(I)Lim/tpelyyftgw/messenger/LocationController$SharingLocationInfo;
move-result-object v1
invoke-interface {v0, v1}, Lim/tpelyyftgw/ui/components/SharingLocationsAlert$SharingLocationsAlertDelegate;->didSelectLocation(Lim/tpelyyftgw/messenger/LocationController$SharingLocationInfo;)V
.line 162
invoke-virtual {p0}, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->dismiss()V
.line 163
return-void
.line 159
:cond_18
:goto_18
return-void
.end method
.method public synthetic lambda$new$1$SharingLocationsAlert(Landroid/view/View;)V
.registers 4
.param p1, "view" # Landroid/view/View;
.line 177
const/4 v0, 0x0
.local v0, "a":I
:goto_1
const/4 v1, 0x3
if-ge v0, v1, :cond_e
.line 178
invoke-static {v0}, Lim/tpelyyftgw/messenger/LocationController;->getInstance(I)Lim/tpelyyftgw/messenger/LocationController;
move-result-object v1
invoke-virtual {v1}, Lim/tpelyyftgw/messenger/LocationController;->removeAllLocationSharings()V
.line 177
add-int/lit8 v0, v0, 0x1
goto :goto_1
.line 180
.end local v0 # "a":I
:cond_e
invoke-virtual {p0}, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->dismiss()V
.line 181
return-void
.end method
.method public synthetic lambda$new$2$SharingLocationsAlert(Landroid/view/View;)V
.registers 2
.param p1, "view" # Landroid/view/View;
.line 185
invoke-virtual {p0}, Lim/tpelyyftgw/ui/components/SharingLocationsAlert;->dismiss()V
return-void
.end method