导航菜单

页面标题

页面副标题

Plus 12 v10.13.1.1 - PlusSettingsActivity.java 源代码

正在查看: Plus 12 v10.13.1.1 应用的 PlusSettingsActivity.java JAVA 源代码文件

本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。


package org.telegram.ui;

import android.app.AlertDialog;
import android.app.Dialog;
import android.content.ClipData;
import android.content.ClipboardManager;
import android.content.Context;
import android.content.DialogInterface;
import android.content.Intent;
import android.content.SharedPreferences;
import android.content.res.Configuration;
import android.graphics.Paint;
import android.graphics.PorterDuff;
import android.graphics.drawable.Drawable;
import android.os.AsyncTask;
import android.os.Build;
import android.os.Bundle;
import android.os.Environment;
import android.text.TextUtils;
import android.view.View;
import android.view.ViewGroup;
import android.view.ViewTreeObserver;
import android.widget.Filter;
import android.widget.Filterable;
import android.widget.FrameLayout;
import android.widget.LinearLayout;
import android.widget.ScrollView;
import android.widget.Toast;
import androidx.core.view.inputmethod.InputContentInfoCompat;
import androidx.recyclerview.widget.LinearLayoutManager;
import androidx.recyclerview.widget.RecyclerView;
import java.io.File;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Iterator;
import org.telegram.db.PlusRoomDatabase;
import org.telegram.db.entity.DialogEntity;
import org.telegram.messenger.AccountInstance;
import org.telegram.messenger.AndroidUtilities;
import org.telegram.messenger.ApplicationLoader;
import org.telegram.messenger.BuildVars;
import org.telegram.messenger.FileLoadOperation;
import org.telegram.messenger.FileLoader;
import org.telegram.messenger.FileLog;
import org.telegram.messenger.FileUploadOperation;
import org.telegram.messenger.FilesMigrationService;
import org.telegram.messenger.ImageLoader;
import org.telegram.messenger.LocaleController;
import org.telegram.messenger.MessageObject;
import org.telegram.messenger.MessagesController;
import org.telegram.messenger.NotificationCenter;
import org.telegram.messenger.PlusRepository;
import org.telegram.messenger.PlusUtils;
import org.telegram.messenger.R;
import org.telegram.messenger.SendMessagesHelper;
import org.telegram.messenger.SharedConfig;
import org.telegram.messenger.UserConfig;
import org.telegram.messenger.Utilities;
import org.telegram.tgnet.TLRPC;
import org.telegram.tgnet.tl.TL_stories;
import org.telegram.ui.ActionBar.ActionBar;
import org.telegram.ui.ActionBar.ActionBarMenuItem;
import org.telegram.ui.ActionBar.AlertDialog;
import org.telegram.ui.ActionBar.BaseFragment;
import org.telegram.ui.ActionBar.BottomSheet;
import org.telegram.ui.ActionBar.PlusSettings;
import org.telegram.ui.ActionBar.Theme;
import org.telegram.ui.ActionBar.ThemeDescription;
import org.telegram.ui.Adapters.PlusSettingsSearchAdapter;
import org.telegram.ui.Cells.EmptyCell;
import org.telegram.ui.Cells.HeaderCell;
import org.telegram.ui.Cells.ShadowSectionCell;
import org.telegram.ui.Cells.SharedDocumentCell;
import org.telegram.ui.Cells.TextCheckCell;
import org.telegram.ui.Cells.TextDetailSettingsCell;
import org.telegram.ui.Cells.TextInfoCell;
import org.telegram.ui.Cells.TextInfoPrivacyCell;
import org.telegram.ui.Cells.TextSettingsCell;
import org.telegram.ui.ChatActivity;
import org.telegram.ui.Components.EditTextBoldCursor;
import org.telegram.ui.Components.EmptyTextProgressView;
import org.telegram.ui.Components.LayoutHelper;
import org.telegram.ui.Components.NumberPicker;
import org.telegram.ui.Components.PasscodeView;
import org.telegram.ui.Components.RecyclerListView;
import org.telegram.ui.DocumentSelectActivity;
import org.telegram.ui.PlusSettingsActivity;

public class PlusSettingsActivity extends BaseFragment implements NotificationCenter.NotificationCenterDelegate {
    public static boolean previousShowHiddenDialogsIcon;
    public int addAppFolderToSaveToOptionRow;
    public boolean catEnabled;
    public int categoriesHideTabsRow;
    public int categoriesLoadLastCategoryOnStartRow;
    public int categoriesShowAddCategoryRow;
    public int categoriesShowCategoriesIconRow;
    public int changeEmojiToIconRow;
    public int changeHiddenDialogsPasswordRow;
    public int chatActionModeButtonsRow;
    public int chatAddDateToEventRow;
    public int chatAddDateToForwardedMessagesRow;
    public int chatAddSecondsToTimeInChatRow;
    public int chatAddTranslateToSendButtonRow;
    public int chatAlwaysBackToMainRow;
    public int chatAlwaysShowMediaSpoilersRow;
    public int chatAlwaysShowSpoilersRow;
    public int chatCenterQuickBarBtnRow;
    public int chatChangePlayerSpeedRangeRow;
    public int chatChangeTranslateLanguageRow;
    public int chatConfirmAudioVideoBeforeSendingRow;
    public int chatCopyLinkOnLongClickRow;
    public int chatDeleteSharedMediaCaptionRow;
    public int chatDirectShareButtonActionRow;
    public int chatDirectShareFavsFirst;
    public int chatDirectShareReplies;
    public int chatDisableActionsVibrationsRow;
    public int chatDisableAvatarAnimationRow;
    public int chatDisableJumpingToNextChannelRow;
    public int chatDisableLinkPreviewRow;
    public int chatDisableLoadingNextMediaRow;
    public int chatDisablePremiumStickersAnimationRow;
    public int chatDisableReactionAnimationRow;
    public int chatDisableRestriction;
    public int chatDisableShortNumberFormatRow;
    public int chatDisableSwipeToReplyVibrationRow;
    public int chatDisableUsersThemeModificationsRow;
    public int chatDoNotCloseQuickBarRow;
    public int chatDoNotHideSearchBottomRow;
    public int chatDoNotHideStickersTabRow;
    public int chatDoNotPlayNextMediaRow;
    public int chatDoNotShowDialogOnCacheDeletingRow;
    public int chatDrawSingleBigEmojiRow;
    public int chatEnableBlurInChatRow;
    public int chatEnableConfirmBeforeSendingRow;
    public int chatEnableReturnToMessageStackRow;
    public int chatEnableSwipeActionInChannelsRow;
    public int chatForceSmallReactionsLayoutRow;
    public int chatHideBotKeyboardRow;
    public int chatHideBottomLayoutInChannelsRow;
    public int chatHideChatGreetingRow;
    public int chatHideImageSizeRow;
    public int chatHideInstantCameraRow;
    public int chatHideJoinedGroupRow;
    public int chatHideKeyboardOnScrollRow;
    public int chatHideLeftGroupRow;
    public int chatHidePremiumEmojisTabsRow;
    public int chatHidePremiumStickersRow;
    public int chatHideQuickBarOnScrollRow;
    public int chatHideReactionsButtonsInMessagesRow;
    public int chatHideSenderNameRow;
    public int chatHideSenderSelectorRow;
    public int chatHideSlashBotButtonRow;
    public int chatHideTimeInStickersRow;
    public int chatHideVoiceTranscriptionButtonRow;
    public int chatIgnoreBlockedUsersRow;
    public int chatImproveVoiceRecordingQualityRow;
    public int chatIncreaseInstantVideoQualityRow;
    public int chatMakeTitleScrollableRow;
    public int chatMarkdownParseLinksRow;
    public int chatMarkdownRow;
    public int chatPhotoQualityRow;
    public int chatPhotoViewerHideStatusBarRow;
    public int chatPlayGifAsVideoRow;
    public int chatSaveToCloudQuoteRow;
    public int chatSearchUserOnTwitterRow;
    public int chatSelectDoubleTapActionRow;
    public int chatSelectTapAndHoldAvatarActionRow;
    public int chatSelectTapAvatarActionRow;
    public int chatSetCustomDateAndTime;
    public int chatShowAllRecentStickersRow;
    public int chatShowAnimatedStickersFirstRow;
    public int chatShowBackForwardMusicPlayerButtonsRow;
    public int chatShowCallButtonRow;
    public int chatShowDateToastRow;
    public int chatShowDirectShareBtnRow;
    public int chatShowDownloadProgressRow;
    public int chatShowEditedMarkRow;
    public int chatShowHideOptionsRow;
    public int chatShowMembersQuickBarRow;
    public int chatShowPhotoQualityBarRow;
    public int chatShowQuickBarRow;
    public int chatShowSearchIconRow;
    public int chatShowSendWithoutSoundButtonRow;
    public int chatShowUserBioRow;
    public int chatShowUserStatusCircleOnlyIfOnlineRow;
    public int chatStartRoundVideoUsingMainCameraRow;
    public int chatStickerCellRow;
    public int chatSwipeLeftActionRow;
    public int chatSwipeRightActionRow;
    public int chatTranslationProviderRow;
    public int chatVerticalQuickBarRow;
    public int chatsToLoadRow;
    public boolean click;
    public int counter;
    public int currentAccount;
    public int dialogsAllowChangingSortingOnDoubleClick;
    public int dialogsArchiveChatBySwipingToLeftRow;
    public int dialogsCloseAppOnBackPressedRow;
    public int dialogsCountArchivedRow;
    public int dialogsCountMentionAsUnmutedRow;
    public int dialogsDisableAvatarAnimationRow;
    public int dialogsDisableTabsAnimationCheckRow;
    public int dialogsDisableTabsScrollingRow;
    public int dialogsDoNotChangeHeaderTitleRow;
    public int dialogsDoNotClosePreviewOnReleaseRow;
    public int dialogsDrawDialogIconBeforeNameRow;
    public int dialogsExpandTabsRow;
    public int dialogsFloatingButtonOpensSavedMessagesRow;
    public int dialogsForceShowDownloadsButtonRow;
    public int dialogsGroupPicClickRow;
    public int dialogsHideCloudFoldersRow;
    public int dialogsHideMainTabRow;
    public int dialogsHidePlusPromoDialogRow;
    public int dialogsHidePreviewMenuRow;
    public int dialogsHideProxySponsorRow;
    public int dialogsHideSelectedTabIndicator;
    public int dialogsHideTabsCheckRow;
    public int dialogsHideTabsCounters;
    public int dialogsIncreasePinnedDialogsLimitRow;
    public int dialogsInfiniteTabsSwipe;
    public int dialogsLimitTabsCountersRow;
    public int dialogsManageTabsRow;
    public int dialogsOpenArchiveOnPullDownRow;
    public int dialogsOpenMenuBySwipingToRightRow;
    public int dialogsPicClickRow;
    public int dialogsRemoveArchiveFromListRow;
    public int dialogsResumeLastTabRow;
    public int dialogsSectionRow;
    public int dialogsSectionRow2;
    public int dialogsShowAllInAdminTabDetailRow;
    public int dialogsShowAllInAdminTabRow;
    public int dialogsShowArchivedChatOnItsTabRow;
    public int dialogsShowArchivedDialogsInTabsRow;
    public int dialogsShowFoldersIfForwardingRow;
    public int dialogsShowLastReactionRow;
    public int dialogsShowMoreByDefaultInGlobalSearchRow;
    public int dialogsShowPinDialogButtonRow;
    public int dialogsShowPinnedChatsFirstRow;
    public int dialogsShowSelectChatsOptionRow;
    public int dialogsShowSetDefaultFolderRow;
    public int dialogsShowSortingInSubtitleIfNotDefaultRow;
    public int dialogsShowSortingInSubtitleRow;
    public int dialogsShowUnmutedFirstIfUnreadRow;
    public int dialogsShowUserStatusCircleOnlyIfOnlineRow;
    public int dialogsTabsCountersCountChats;
    public int dialogsTabsCountersCountNotMuted;
    public int dialogsTabsHeightRow;
    public int dialogsTabsRow;
    public int dialogsTabsSwipeSensitivityRow;
    public int dialogsTabsTextModeRow;
    public int dialogsTabsTextSizeRow;
    public int dialogsTabsToBottomRow;
    public int disableAudioStopRow;
    public boolean disableForceSmallReactionsLayout;
    public int disableMessageClickRow;
    public int disableMusicStopRow;
    public int discardMediaTapRow;
    public int doNotMarkStoriesAsReadRow;
    public int downloadsHideScheduledDownloadReminderRow;
    public int downloadsIncludePendingDownloadsRow;
    public int downloadsSectionRow;
    public int downloadsSectionRow2;
    public int downloadsShowDownloadsOnlyIfActiveRow;
    public int downloadsSimultaneousDownloadsRow;
    public int downloadsSpeedBoostRow;
    public int drawerHideSavedMessagesButtonRow;
    public int drawerOpenAvatarInsteadOfSettingsRow;
    public int drawerSectionRow;
    public int drawerSectionRow2;
    public int drawerShowOnlineContactsRow;
    public int drawerShowOptionsRow;
    public int drawerShowPlusOptionsRow;
    public int emojiPopupSize;
    public EmptyTextProgressView emptyView;
    public int enableDirectReplyRow;
    public int enableHiddenDialogsRow;
    public int folderId;
    public ActionBarMenuItem headerItem;
    public boolean headerItemVisible;
    public int hiddenDialogsHideTabsRow;
    public int hiddenDialogsInfoSectionRow;
    public int hiddenDialogsSectionRow;
    public int hiddenDialogsSectionRow2;
    public int hiddenDialogsUseFingerprintRow;
    public int hideChannelsStoriesRow;
    public int hideCreateStoryButtonRow;
    public int hideMobileNumberRow;
    public int hideMsgDeletedHintRow;
    public int hideNotificationsIfPlayingRow;
    public int hideSeenStoriesRow;
    public int hideStoriesRow;
    public int keepFilenameEqualRow;
    public int keepOriginalFilenameDetailRow;
    public int keepOriginalFilenameRow;
    public LinearLayoutManager layoutManager;
    public ListAdapter listAdapter;
    public RecyclerListView listView;
    public int mediaDownloadSection;
    public int mediaDownloadSection2;
    public int messagesSectionRow;
    public int messagesSectionRow2;
    public int migrateFilesRow;
    public int moveVersionToSettingsRow;
    public int notificationInvertMessagesOrderRow;
    public int notificationSection2Row;
    public int notificationSectionRow;
    public int openHiddenDialogsWithoutPasscodeRow;
    public int openProfilePicsInsteadOfStoriesRow;
    public boolean passcodeEntered;
    public PasscodeView passcodeView;
    public int plusSettingsSectionRow;
    public int plusSettingsSectionRow2;
    public File previousPath;
    public int privacySectionRow;
    public int privacySectionRow2;
    public int profileDisableAvatarAnimationRow;
    public int profileEnableGoToMsgRow;
    public int profileOpenProfilePicsInsteadOfStoriesRow;
    public int profileSectionRow;
    public int profileSectionRow2;
    public int profileSharedOptionsRow;
    public int profileShowFullBioRow;
    public int profileShowIdRow;
    public int profileShowProfilePicDateInsteadOfStatusRow;
    public int resetPlusSettingsRow;
    public boolean reseting;
    public int restorePlusSettingsRow;
    public int rowCount;
    public int savePlusSettingsRow;
    public boolean saving;
    public int scrollToPosition;
    public PlusSettingsSearchAdapter searchAdapter;
    public int selectStorageRow;
    public int settingsSectionRow2;
    public int settings_type;
    public int showAndroidEmojiRow;
    public int showFullScreenAvatarOnSingleTapRow;
    public int showHiddenDialogsIconRow;
    public int showHiddenDialogsNotificationsRow;
    public int showHiddenDialogsWhenSearchingRow;
    public int showMuteInNotificationRow;
    public int showOfflineToastNotificationRow;
    public int showOldMediaRowsRow;
    public int showOnlineToastNotificationDetailRow;
    public int showOnlineToastNotificationRow;
    public boolean showPrefix;
    public int showToastErrorsRow;
    public int showToastOnlyIfContactFavRow;
    public int showTypingToastNotificationRow;
    public int showTypingToastOnlyIfContactFavRow;
    public int showUsernameRow;
    public int storiesSectionRow;
    public int storiesSectionRow2;
    public int toastNotificationPaddingRow;
    public int toastNotificationPositionRow;
    public int toastNotificationSection2Row;
    public int toastNotificationSectionRow;
    public int toastNotificationSizeRow;
    public int toastNotificationToBottomRow;
    public int topicsAllowPinTopicsRow;
    public int topicsDisableHideTopicOnSwipeRow;
    public int topicsOpenTopicsAsNormalGroupsRow;
    public int topicsSaveViewTopicsAsMessagesOptionRow;
    public int topicsSectionRow;
    public int topicsSectionRow2;
    public int topicsShowOnlyGroupsWithTopicsRow;
    public int topicsViewAllTopicsAsMessagesRow;
    public int totalFilesCount;
    public int updateAppMethodRow;
    public int uploadSpeedBoostRow;
    public int useAvatarAsBackgroundRow;
    public int useDeviceFontRow;
    public int useExternalStorageRow;
    public int usePlusFolderRow;
    public int useTelegramDataPathRow;

    public PlusSettingsActivity() {
        this.disableForceSmallReactionsLayout = true;
        this.reseting = false;
        this.saving = false;
        this.currentAccount = UserConfig.selectedAccount;
        this.catEnabled = false;
        this.folderId = 0;
        this.settings_type = -1;
    }

    public PlusSettingsActivity(Bundle args) {
        super(args);
        this.disableForceSmallReactionsLayout = true;
        this.reseting = false;
        this.saving = false;
        this.currentAccount = UserConfig.selectedAccount;
        this.catEnabled = false;
        this.folderId = 0;
        this.settings_type = -1;
    }

    public boolean onFragmentCreate() {
        int i;
        int i2;
        int i3;
        int i4;
        int i5;
        int i6;
        int i7;
        int i8;
        int i9;
        int i10;
        int i11;
        int i12;
        super.onFragmentCreate();
        Bundle bundle = ((BaseFragment) this).arguments;
        int i13 = -1;
        if (bundle != null) {
            this.scrollToPosition = bundle.getInt("scroll_to_position", 0);
            this.click = ((BaseFragment) this).arguments.getBoolean("click", false);
            int i14 = ((BaseFragment) this).arguments.getInt("type", -1);
            this.settings_type = i14;
            int i15 = this.scrollToPosition;
            if (i15 > 0 && i14 < 0) {
                if (i15 < 200) {
                    this.settings_type = i15 / 10;
                } else {
                    this.settings_type = i15 / 100;
                }
            }
        }
        NotificationCenter.getGlobalInstance().addObserver(this, NotificationCenter.refreshTabs);
        this.showPrefix = ApplicationLoader.applicationContext.getSharedPreferences("plusconfig", 0).getBoolean("plusShowPrefix", true);
        this.rowCount = 0;
        countOldFiles();
        int i16 = this.settings_type;
        if (i16 < 0 || i16 == 0) {
            int i17 = this.rowCount;
            int i18 = i17 + 1;
            this.rowCount = i18;
            this.settingsSectionRow2 = i17;
            int i19 = i18 + 1;
            this.rowCount = i19;
            this.useDeviceFontRow = i18;
            if (Build.VERSION.SDK_INT >= 19) {
                this.rowCount = i19 + 1;
                this.showAndroidEmojiRow = i19;
            } else {
                this.showAndroidEmojiRow = -1;
            }
            int i20 = this.rowCount;
            int i21 = i20 + 1;
            this.rowCount = i21;
            this.updateAppMethodRow = i20;
            if (BuildVars.LOGS_ENABLED) {
                this.rowCount = i21 + 1;
            } else {
                i21 = -1;
            }
            this.showToastErrorsRow = i21;
            if (BuildVars.BETA_2) {
                i = this.rowCount;
                this.rowCount = i + 1;
            } else {
                i = -1;
            }
            this.chatsToLoadRow = i;
        }
        if (i16 < 0 || i16 == 1) {
            int i22 = this.rowCount;
            int i23 = i22 + 1;
            this.rowCount = i23;
            this.dialogsSectionRow = i22;
            if (i16 < 0) {
                this.rowCount = i23 + 1;
                this.dialogsSectionRow2 = i23;
            }
            int i24 = this.rowCount;
            int i25 = i24 + 1;
            this.rowCount = i25;
            this.dialogsHideTabsCheckRow = i24;
            this.dialogsManageTabsRow = -1;
            int i26 = i25 + 1;
            this.rowCount = i26;
            this.dialogsCloseAppOnBackPressedRow = i25;
            int i27 = i26 + 1;
            this.rowCount = i27;
            this.dialogsResumeLastTabRow = i26;
            int i28 = i27 + 1;
            this.rowCount = i28;
            this.dialogsTabsHeightRow = i27;
            int i29 = i28 + 1;
            this.rowCount = i29;
            this.dialogsTabsTextModeRow = i28;
            int i30 = i29 + 1;
            this.rowCount = i30;
            this.dialogsTabsTextSizeRow = i29;
            int i31 = i30 + 1;
            this.rowCount = i31;
            this.changeEmojiToIconRow = i30;
            int i32 = i31 + 1;
            this.rowCount = i32;
            this.dialogsHideMainTabRow = i31;
            int i33 = i32 + 1;
            this.rowCount = i33;
            this.dialogsHideCloudFoldersRow = i32;
            this.dialogsExpandTabsRow = -1;
            int i34 = i33 + 1;
            this.rowCount = i34;
            this.dialogsTabsToBottomRow = i33;
            int i35 = i34 + 1;
            this.rowCount = i35;
            this.dialogsDisableTabsScrollingRow = i34;
            this.dialogsDisableTabsAnimationCheckRow = -1;
            int i36 = i35 + 1;
            this.rowCount = i36;
            this.dialogsInfiniteTabsSwipe = i35;
            int i37 = i36 + 1;
            this.rowCount = i37;
            this.dialogsTabsSwipeSensitivityRow = i36;
            int i38 = i37 + 1;
            this.rowCount = i38;
            this.dialogsAllowChangingSortingOnDoubleClick = i37;
            int i39 = i38 + 1;
            this.rowCount = i39;
            this.dialogsHideTabsCounters = i38;
            int i40 = i39 + 1;
            this.rowCount = i40;
            this.dialogsTabsCountersCountNotMuted = i39;
            this.dialogsCountArchivedRow = -1;
            this.dialogsCountMentionAsUnmutedRow = -1;
            int i41 = i40 + 1;
            this.rowCount = i41;
            this.dialogsTabsCountersCountChats = i40;
            int i42 = i41 + 1;
            this.rowCount = i42;
            this.dialogsLimitTabsCountersRow = i41;
            this.dialogsHideSelectedTabIndicator = -1;
            int i43 = i42 + 1;
            this.rowCount = i43;
            this.dialogsDoNotChangeHeaderTitleRow = i42;
            int i44 = i43 + 1;
            this.rowCount = i44;
            this.dialogsShowSortingInSubtitleRow = i43;
            int i45 = i44 + 1;
            this.rowCount = i45;
            this.dialogsShowSortingInSubtitleIfNotDefaultRow = i44;
            int i46 = i45 + 1;
            this.rowCount = i46;
            this.dialogsShowSetDefaultFolderRow = i45;
            int i47 = i46 + 1;
            this.rowCount = i47;
            this.dialogsShowPinnedChatsFirstRow = i46;
            int i48 = i47 + 1;
            this.rowCount = i48;
            this.dialogsShowUnmutedFirstIfUnreadRow = i47;
            int i49 = i48 + 1;
            this.rowCount = i49;
            this.dialogsShowAllInAdminTabRow = i48;
            int i50 = i49 + 1;
            this.rowCount = i50;
            this.dialogsShowAllInAdminTabDetailRow = i49;
            int i51 = i50 + 1;
            this.rowCount = i51;
            this.dialogsShowFoldersIfForwardingRow = i50;
            int i52 = i51 + 1;
            this.rowCount = i52;
            this.dialogsShowArchivedDialogsInTabsRow = i51;
            this.dialogsShowArchivedChatOnItsTabRow = -1;
            int i53 = i52 + 1;
            this.rowCount = i53;
            this.dialogsShowSelectChatsOptionRow = i52;
            int i54 = i53 + 1;
            this.rowCount = i54;
            this.categoriesShowCategoriesIconRow = i53;
            int i55 = i54 + 1;
            this.rowCount = i55;
            this.dialogsPicClickRow = i54;
            int i56 = i55 + 1;
            this.rowCount = i56;
            this.dialogsGroupPicClickRow = i55;
            int i57 = i56 + 1;
            this.rowCount = i57;
            this.categoriesShowAddCategoryRow = i56;
            int i58 = i57 + 1;
            this.rowCount = i58;
            this.dialogsArchiveChatBySwipingToLeftRow = i57;
            int i59 = i58 + 1;
            this.rowCount = i59;
            this.dialogsOpenMenuBySwipingToRightRow = i58;
            int i60 = i59 + 1;
            this.rowCount = i60;
            this.dialogsRemoveArchiveFromListRow = i59;
            int i61 = i60 + 1;
            this.rowCount = i61;
            this.dialogsDoNotClosePreviewOnReleaseRow = i60;
            int i62 = i61 + 1;
            this.rowCount = i62;
            this.dialogsFloatingButtonOpensSavedMessagesRow = i61;
            int i63 = i62 + 1;
            this.rowCount = i63;
            this.dialogsShowMoreByDefaultInGlobalSearchRow = i62;
            int i64 = i63 + 1;
            this.rowCount = i64;
            this.dialogsForceShowDownloadsButtonRow = i63;
            int i65 = i64 + 1;
            this.rowCount = i65;
            this.dialogsShowPinDialogButtonRow = i64;
            int i66 = i65 + 1;
            this.rowCount = i66;
            this.dialogsShowLastReactionRow = i65;
            int i67 = i66 + 1;
            this.rowCount = i67;
            this.dialogsHidePreviewMenuRow = i66;
            int i68 = i67 + 1;
            this.rowCount = i68;
            this.dialogsDisableAvatarAnimationRow = i67;
            int i69 = i68 + 1;
            this.rowCount = i69;
            this.dialogsDrawDialogIconBeforeNameRow = i68;
            int i70 = i69 + 1;
            this.rowCount = i70;
            this.dialogsOpenArchiveOnPullDownRow = i69;
            this.rowCount = i70 + 1;
            this.dialogsShowUserStatusCircleOnlyIfOnlineRow = i70;
            if (PlusSettings.isPlusPromoDialogHideOptionEnabled()) {
                i2 = this.rowCount;
                this.rowCount = i2 + 1;
            } else {
                i2 = -1;
            }
            this.dialogsHidePlusPromoDialogRow = i2;
            if (BuildVars.BETA_2) {
                i3 = this.rowCount;
                this.rowCount = i3 + 1;
            } else {
                i3 = -1;
            }
            this.dialogsHideProxySponsorRow = i3;
            boolean z = BuildVars.BETA;
            if (z) {
                i4 = this.rowCount;
                this.rowCount = i4 + 1;
            } else {
                i4 = -1;
            }
            this.categoriesHideTabsRow = i4;
            if (z) {
                i5 = this.rowCount;
                this.rowCount = i5 + 1;
            } else {
                i5 = -1;
            }
            this.categoriesLoadLastCategoryOnStartRow = i5;
            if (z) {
                i6 = this.rowCount;
                this.rowCount = i6 + 1;
            } else {
                i6 = -1;
            }
            this.dialogsIncreasePinnedDialogsLimitRow = i6;
        }
        int i71 = this.settings_type;
        if (i71 < 0 || i71 == 2) {
            int i72 = this.rowCount;
            int i73 = i72 + 1;
            this.rowCount = i73;
            this.storiesSectionRow = i72;
            if (i71 < 0) {
                this.rowCount = i73 + 1;
                this.storiesSectionRow2 = i73;
            }
            int i74 = this.rowCount;
            int i75 = i74 + 1;
            this.rowCount = i75;
            this.hideStoriesRow = i74;
            int i76 = i75 + 1;
            this.rowCount = i76;
            this.hideCreateStoryButtonRow = i75;
            int i77 = i76 + 1;
            this.rowCount = i77;
            this.hideSeenStoriesRow = i76;
            int i78 = i77 + 1;
            this.rowCount = i78;
            this.hideChannelsStoriesRow = i77;
            int i79 = i78 + 1;
            this.rowCount = i79;
            this.openProfilePicsInsteadOfStoriesRow = i78;
            if (BuildVars.BETA_DIRECT) {
                this.rowCount = i79 + 1;
            } else {
                i79 = -1;
            }
            this.doNotMarkStoriesAsReadRow = i79;
        }
        if (i71 < 0 || i71 == 3) {
            int i80 = this.rowCount;
            int i81 = i80 + 1;
            this.rowCount = i81;
            this.messagesSectionRow = i80;
            if (i71 < 0) {
                this.rowCount = i81 + 1;
                this.messagesSectionRow2 = i81;
            }
            int i82 = this.rowCount;
            int i83 = i82 + 1;
            this.rowCount = i83;
            this.emojiPopupSize = i82;
            int i84 = i83 + 1;
            this.rowCount = i84;
            this.disableAudioStopRow = i83;
            this.disableMessageClickRow = -1;
            int i85 = i84 + 1;
            this.rowCount = i85;
            this.chatShowDirectShareBtnRow = i84;
            int i86 = i85 + 1;
            this.rowCount = i86;
            this.chatDirectShareReplies = i85;
            int i87 = i86 + 1;
            this.rowCount = i87;
            this.chatShowHideOptionsRow = i86;
            int i88 = i87 + 1;
            this.rowCount = i88;
            this.chatDirectShareFavsFirst = i87;
            int i89 = i88 + 1;
            this.rowCount = i89;
            this.chatHideLeftGroupRow = i88;
            int i90 = i89 + 1;
            this.rowCount = i90;
            this.chatHideBotKeyboardRow = i89;
            int i91 = i90 + 1;
            this.rowCount = i91;
            this.chatSearchUserOnTwitterRow = i90;
            int i92 = i91 + 1;
            this.rowCount = i92;
            this.chatShowPhotoQualityBarRow = i91;
            int i93 = i92 + 1;
            this.rowCount = i93;
            this.chatPhotoQualityRow = i92;
            int i94 = i93 + 1;
            this.rowCount = i94;
            this.chatShowQuickBarRow = i93;
            int i95 = i94 + 1;
            this.rowCount = i95;
            this.chatVerticalQuickBarRow = i94;
            int i96 = i95 + 1;
            this.rowCount = i96;
            this.chatAlwaysBackToMainRow = i95;
            int i97 = i96 + 1;
            this.rowCount = i97;
            this.chatDoNotCloseQuickBarRow = i96;
            int i98 = i97 + 1;
            this.rowCount = i98;
            this.chatHideQuickBarOnScrollRow = i97;
            int i99 = i98 + 1;
            this.rowCount = i99;
            this.chatCenterQuickBarBtnRow = i98;
            int i100 = i99 + 1;
            this.rowCount = i100;
            this.chatShowMembersQuickBarRow = i99;
            int i101 = i100 + 1;
            this.rowCount = i101;
            this.chatSaveToCloudQuoteRow = i100;
            int i102 = i101 + 1;
            this.rowCount = i102;
            this.chatHideInstantCameraRow = i101;
            this.chatDoNotHideStickersTabRow = -1;
            this.chatMarkdownRow = -1;
            int i103 = i102 + 1;
            this.rowCount = i103;
            this.chatDrawSingleBigEmojiRow = i102;
            int i104 = i103 + 1;
            this.rowCount = i104;
            this.chatShowUserBioRow = i103;
            int i105 = i104 + 1;
            this.rowCount = i105;
            this.chatShowCallButtonRow = i104;
            int i106 = i105 + 1;
            this.rowCount = i106;
            this.chatSetCustomDateAndTime = i105;
            int i107 = i106 + 1;
            this.rowCount = i107;
            this.chatDisableSwipeToReplyVibrationRow = i106;
            int i108 = i107 + 1;
            this.rowCount = i108;
            this.chatHideImageSizeRow = i107;
            int i109 = i108 + 1;
            this.rowCount = i109;
            this.chatHideSenderNameRow = i108;
            int i110 = i109 + 1;
            this.rowCount = i110;
            this.chatDeleteSharedMediaCaptionRow = i109;
            int i111 = i110 + 1;
            this.rowCount = i111;
            this.chatStartRoundVideoUsingMainCameraRow = i110;
            int i112 = i111 + 1;
            this.rowCount = i112;
            this.chatChangePlayerSpeedRangeRow = i111;
            int i113 = i112 + 1;
            this.rowCount = i113;
            this.chatShowDownloadProgressRow = i112;
            int i114 = i113 + 1;
            this.rowCount = i114;
            this.chatMakeTitleScrollableRow = i113;
            int i115 = i114 + 1;
            this.rowCount = i115;
            this.chatHideBottomLayoutInChannelsRow = i114;
            this.chatDoNotHideSearchBottomRow = -1;
            int i116 = i115 + 1;
            this.rowCount = i116;
            this.chatShowSearchIconRow = i115;
            int i117 = i116 + 1;
            this.rowCount = i117;
            this.chatDisableShortNumberFormatRow = i116;
            int i118 = i117 + 1;
            this.rowCount = i118;
            this.disableMusicStopRow = i117;
            int i119 = i118 + 1;
            this.rowCount = i119;
            this.chatPlayGifAsVideoRow = i118;
            int i120 = i119 + 1;
            this.rowCount = i120;
            this.chatChangeTranslateLanguageRow = i119;
            int i121 = i120 + 1;
            this.rowCount = i121;
            this.chatAddDateToEventRow = i120;
            int i122 = i121 + 1;
            this.rowCount = i122;
            this.hideMsgDeletedHintRow = i121;
            int i123 = i122 + 1;
            this.rowCount = i123;
            this.chatTranslationProviderRow = i122;
            int i124 = i123 + 1;
            this.rowCount = i124;
            this.chatDisableActionsVibrationsRow = i123;
            int i125 = i124 + 1;
            this.rowCount = i125;
            this.chatAddTranslateToSendButtonRow = i124;
            int i126 = i125 + 1;
            this.rowCount = i126;
            this.chatShowAnimatedStickersFirstRow = i125;
            int i127 = i126 + 1;
            this.rowCount = i127;
            this.chatDisableJumpingToNextChannelRow = i126;
            int i128 = i127 + 1;
            this.rowCount = i128;
            this.chatHideChatGreetingRow = i127;
            int i129 = i128 + 1;
            this.rowCount = i129;
            this.chatEnableConfirmBeforeSendingRow = i128;
            int i130 = i129 + 1;
            this.rowCount = i130;
            this.chatHideKeyboardOnScrollRow = i129;
            int i131 = i130 + 1;
            this.rowCount = i131;
            this.chatDisableLoadingNextMediaRow = i130;
            int i132 = i131 + 1;
            this.rowCount = i132;
            this.chatDoNotPlayNextMediaRow = i131;
            int i133 = i132 + 1;
            this.rowCount = i133;
            this.chatStickerCellRow = i132;
            int i134 = i133 + 1;
            this.rowCount = i134;
            this.chatHideSenderSelectorRow = i133;
            int i135 = i134 + 1;
            this.rowCount = i135;
            this.chatShowSendWithoutSoundButtonRow = i134;
            int i136 = i135 + 1;
            this.rowCount = i136;
            this.chatAlwaysShowSpoilersRow = i135;
            int i137 = i136 + 1;
            this.rowCount = i137;
            this.chatDisableReactionAnimationRow = i136;
            int i138 = i137 + 1;
            this.rowCount = i138;
            this.chatSelectDoubleTapActionRow = i137;
            int i139 = i138 + 1;
            this.rowCount = i139;
            this.chatSwipeLeftActionRow = i138;
            int i140 = i139 + 1;
            this.rowCount = i140;
            this.chatSwipeRightActionRow = i139;
            int i141 = i140 + 1;
            this.rowCount = i141;
            this.chatEnableSwipeActionInChannelsRow = i140;
            int i142 = i141 + 1;
            this.rowCount = i142;
            this.chatDirectShareButtonActionRow = i141;
            int i143 = i142 + 1;
            this.rowCount = i143;
            this.chatDoNotShowDialogOnCacheDeletingRow = i142;
            int i144 = i143 + 1;
            this.rowCount = i144;
            this.chatEnableBlurInChatRow = i143;
            int i145 = i144 + 1;
            this.rowCount = i145;
            this.chatEnableReturnToMessageStackRow = i144;
            int i146 = i145 + 1;
            this.rowCount = i146;
            this.chatAddSecondsToTimeInChatRow = i145;
            int i147 = i146 + 1;
            this.rowCount = i147;
            this.chatHideReactionsButtonsInMessagesRow = i146;
            int i148 = i147 + 1;
            this.rowCount = i148;
            this.chatShowAllRecentStickersRow = i147;
            int i149 = i148 + 1;
            this.rowCount = i149;
            this.chatDisableLinkPreviewRow = i148;
            int i150 = i149 + 1;
            this.rowCount = i150;
            this.chatHideTimeInStickersRow = i149;
            int i151 = i150 + 1;
            this.rowCount = i151;
            this.chatSelectTapAvatarActionRow = i150;
            int i152 = i151 + 1;
            this.rowCount = i152;
            this.chatSelectTapAndHoldAvatarActionRow = i151;
            int i153 = i152 + 1;
            this.rowCount = i153;
            this.chatDisableAvatarAnimationRow = i152;
            int i154 = i153 + 1;
            this.rowCount = i154;
            this.chatDisablePremiumStickersAnimationRow = i153;
            int i155 = i154 + 1;
            this.rowCount = i155;
            this.chatIncreaseInstantVideoQualityRow = i154;
            int i156 = i155 + 1;
            this.rowCount = i156;
            this.chatActionModeButtonsRow = i155;
            int i157 = i156 + 1;
            this.rowCount = i157;
            this.chatConfirmAudioVideoBeforeSendingRow = i156;
            int i158 = i157 + 1;
            this.rowCount = i158;
            this.chatHidePremiumEmojisTabsRow = i157;
            int i159 = i158 + 1;
            this.rowCount = i159;
            this.chatHidePremiumStickersRow = i158;
            int i160 = i159 + 1;
            this.rowCount = i160;
            this.chatForceSmallReactionsLayoutRow = i159;
            int i161 = i160 + 1;
            this.rowCount = i161;
            this.chatShowBackForwardMusicPlayerButtonsRow = i160;
            int i162 = i161 + 1;
            this.rowCount = i162;
            this.chatCopyLinkOnLongClickRow = i161;
            int i163 = i162 + 1;
            this.rowCount = i163;
            this.chatAlwaysShowMediaSpoilersRow = i162;
            int i164 = i163 + 1;
            this.rowCount = i164;
            this.chatImproveVoiceRecordingQualityRow = i163;
            int i165 = i164 + 1;
            this.rowCount = i165;
            this.chatMarkdownParseLinksRow = i164;
            int i166 = i165 + 1;
            this.rowCount = i166;
            this.chatAddDateToForwardedMessagesRow = i165;
            int i167 = i166 + 1;
            this.rowCount = i167;
            this.chatHideVoiceTranscriptionButtonRow = i166;
            int i168 = i167 + 1;
            this.rowCount = i168;
            this.chatShowUserStatusCircleOnlyIfOnlineRow = i167;
            int i169 = i168 + 1;
            this.rowCount = i169;
            this.chatHideSlashBotButtonRow = i168;
            this.rowCount = i169 + 1;
            this.chatDisableUsersThemeModificationsRow = i169;
            if (PlusUtils.verifyInstallerId()) {
                i7 = -1;
            } else {
                i7 = this.rowCount;
                this.rowCount = i7 + 1;
            }
            this.chatDisableRestriction = i7;
            if (BuildVars.BETA_DIRECT) {
                i8 = this.rowCount;
                this.rowCount = i8 + 1;
            } else {
                i8 = -1;
            }
            this.chatIgnoreBlockedUsersRow = i8;
        }
        int i170 = this.settings_type;
        if (i170 < 0 || i170 == 4) {
            int i171 = this.rowCount;
            int i172 = i171 + 1;
            this.rowCount = i172;
            this.topicsSectionRow = i171;
            if (i170 < 0) {
                this.rowCount = i172 + 1;
                this.topicsSectionRow2 = i172;
            }
            int i173 = this.rowCount;
            int i174 = i173 + 1;
            this.rowCount = i174;
            this.topicsViewAllTopicsAsMessagesRow = i173;
            int i175 = i174 + 1;
            this.rowCount = i175;
            this.topicsSaveViewTopicsAsMessagesOptionRow = i174;
            int i176 = i175 + 1;
            this.rowCount = i176;
            this.topicsAllowPinTopicsRow = i175;
            int i177 = i176 + 1;
            this.rowCount = i177;
            this.topicsOpenTopicsAsNormalGroupsRow = i176;
            int i178 = i177 + 1;
            this.rowCount = i178;
            this.topicsShowOnlyGroupsWithTopicsRow = i177;
            this.rowCount = i178 + 1;
            this.topicsDisableHideTopicOnSwipeRow = i178;
        }
        if (i170 < 0 || i170 == 5) {
            int i179 = this.rowCount;
            int i180 = i179 + 1;
            this.rowCount = i180;
            this.drawerSectionRow = i179;
            if (i170 < 0) {
                this.rowCount = i180 + 1;
                this.drawerSectionRow2 = i180;
            }
            int i181 = this.rowCount;
            int i182 = i181 + 1;
            this.rowCount = i182;
            this.useAvatarAsBackgroundRow = i181;
            int i183 = i182 + 1;
            this.rowCount = i183;
            this.showUsernameRow = i182;
            int i184 = i183 + 1;
            this.rowCount = i184;
            this.drawerHideSavedMessagesButtonRow = i183;
            int i185 = i184 + 1;
            this.rowCount = i185;
            this.drawerShowOptionsRow = i184;
            int i186 = i185 + 1;
            this.rowCount = i186;
            this.drawerShowPlusOptionsRow = i185;
            int i187 = i186 + 1;
            this.rowCount = i187;
            this.drawerShowOnlineContactsRow = i186;
            int i188 = i187 + 1;
            this.rowCount = i188;
            this.moveVersionToSettingsRow = i187;
            this.rowCount = i188 + 1;
            this.drawerOpenAvatarInsteadOfSettingsRow = i188;
        }
        if (i170 < 0 || i170 == 6) {
            int i189 = this.rowCount;
            int i190 = i189 + 1;
            this.rowCount = i190;
            this.profileSectionRow = i189;
            if (i170 < 0) {
                this.rowCount = i190 + 1;
                this.profileSectionRow2 = i190;
            }
            int i191 = this.rowCount;
            int i192 = i191 + 1;
            this.rowCount = i192;
            this.profileShowFullBioRow = i191;
            int i193 = i192 + 1;
            this.rowCount = i193;
            this.profileSharedOptionsRow = i192;
            int i194 = i193 + 1;
            this.rowCount = i194;
            this.profileEnableGoToMsgRow = i193;
            int i195 = i194 + 1;
            this.rowCount = i195;
            this.showOldMediaRowsRow = i194;
            int i196 = i195 + 1;
            this.rowCount = i196;
            this.showFullScreenAvatarOnSingleTapRow = i195;
            int i197 = i196 + 1;
            this.rowCount = i197;
            this.profileDisableAvatarAnimationRow = i196;
            int i198 = i197 + 1;
            this.rowCount = i198;
            this.profileShowIdRow = i197;
            int i199 = i198 + 1;
            this.rowCount = i199;
            this.profileOpenProfilePicsInsteadOfStoriesRow = i198;
            this.rowCount = i199 + 1;
            this.profileShowProfilePicDateInsteadOfStatusRow = i199;
        }
        if (i170 < 0 || i170 == 7) {
            int i200 = this.rowCount;
            int i201 = i200 + 1;
            this.rowCount = i201;
            this.notificationSectionRow = i200;
            if (i170 < 0) {
                this.rowCount = i201 + 1;
                this.notificationSection2Row = i201;
            }
            int i202 = this.rowCount;
            int i203 = i202 + 1;
            this.rowCount = i203;
            this.hideNotificationsIfPlayingRow = i202;
            int i204 = i203 + 1;
            this.rowCount = i204;
            this.showMuteInNotificationRow = i203;
            int i205 = i204 + 1;
            this.rowCount = i205;
            this.toastNotificationSectionRow = i204;
            int i206 = i205 + 1;
            this.rowCount = i206;
            this.toastNotificationSection2Row = i205;
            int i207 = i206 + 1;
            this.rowCount = i207;
            this.showTypingToastNotificationRow = i206;
            int i208 = i207 + 1;
            this.rowCount = i208;
            this.showOnlineToastNotificationRow = i207;
            int i209 = i208 + 1;
            this.rowCount = i209;
            this.showOnlineToastNotificationDetailRow = i208;
            int i210 = i209 + 1;
            this.rowCount = i210;
            this.toastNotificationToBottomRow = i209;
            int i211 = i210 + 1;
            this.rowCount = i211;
            this.toastNotificationPositionRow = i210;
            int i212 = i211 + 1;
            this.rowCount = i212;
            this.toastNotificationSizeRow = i211;
            int i213 = i212 + 1;
            this.rowCount = i213;
            this.toastNotificationPaddingRow = i212;
            int i214 = i213 + 1;
            this.rowCount = i214;
            this.showToastOnlyIfContactFavRow = i213;
            int i215 = i214 + 1;
            this.rowCount = i215;
            this.showTypingToastOnlyIfContactFavRow = i214;
            this.rowCount = i215 + 1;
            this.showOfflineToastNotificationRow = i215;
        }
        if (i170 < 0 || i170 == 8) {
            int i216 = this.rowCount;
            int i217 = i216 + 1;
            this.rowCount = i217;
            this.privacySectionRow = i216;
            if (i170 < 0) {
                this.rowCount = i217 + 1;
                this.privacySectionRow2 = i217;
            }
            int i218 = this.rowCount;
            int i219 = i218 + 1;
            this.rowCount = i219;
            this.hideMobileNumberRow = i218;
            int i220 = i219 + 1;
            this.rowCount = i220;
            this.hiddenDialogsSectionRow = i219;
            int i221 = i220 + 1;
            this.rowCount = i221;
            this.hiddenDialogsSectionRow2 = i220;
            int i222 = i221 + 1;
            this.rowCount = i222;
            this.hiddenDialogsInfoSectionRow = i221;
            int i223 = i222 + 1;
            this.rowCount = i223;
            this.enableHiddenDialogsRow = i222;
            int i224 = i223 + 1;
            this.rowCount = i224;
            this.showHiddenDialogsIconRow = i223;
            int i225 = i224 + 1;
            this.rowCount = i225;
            this.changeHiddenDialogsPasswordRow = i224;
            int i226 = i225 + 1;
            this.rowCount = i226;
            this.hiddenDialogsHideTabsRow = i225;
            int i227 = i226 + 1;
            this.rowCount = i227;
            this.hiddenDialogsUseFingerprintRow = i226;
            int i228 = i227 + 1;
            this.rowCount = i228;
            this.openHiddenDialogsWithoutPasscodeRow = i227;
            int i229 = i228 + 1;
            this.rowCount = i229;
            this.showHiddenDialogsWhenSearchingRow = i228;
            this.rowCount = i229 + 1;
            this.showHiddenDialogsNotificationsRow = i229;
        }
        if (i170 < 0 || i170 == 9) {
            int i230 = this.rowCount;
            int i231 = i230 + 1;
            this.rowCount = i231;
            this.mediaDownloadSection = i230;
            if (i170 < 0) {
                this.rowCount = i231 + 1;
                this.mediaDownloadSection2 = i231;
            }
            int i232 = this.rowCount;
            int i233 = i232 + 1;
            this.rowCount = i233;
            this.discardMediaTapRow = i232;
            int i234 = i233 + 1;
            this.rowCount = i234;
            this.keepOriginalFilenameRow = i233;
            int i235 = i234 + 1;
            this.rowCount = i235;
            this.keepOriginalFilenameDetailRow = i234;
            int i236 = i235 + 1;
            this.rowCount = i236;
            this.keepFilenameEqualRow = i235;
            int i237 = i236 + 1;
            this.rowCount = i237;
            this.selectStorageRow = i236;
            int i238 = i237 + 1;
            this.rowCount = i238;
            this.usePlusFolderRow = i237;
            this.rowCount = i238 + 1;
            this.addAppFolderToSaveToOptionRow = i238;
            int i239 = Build.VERSION.SDK_INT;
            if (i239 < 30 || PlusUtils.verifyInstallerId()) {
                i9 = -1;
            } else {
                i9 = this.rowCount;
                this.rowCount = i9 + 1;
            }
            this.useExternalStorageRow = i9;
            if (i239 < 30 || PlusUtils.verifyInstallerId()) {
                i10 = -1;
            } else {
                i10 = this.rowCount;
                this.rowCount = i10 + 1;
            }
            this.useTelegramDataPathRow = i10;
            if (i239 < 30 || PlusUtils.verifyInstallerId()) {
                i11 = -1;
            } else {
                i11 = this.rowCount;
                this.rowCount = i11 + 1;
            }
            this.migrateFilesRow = i11;
        }
        int i240 = this.settings_type;
        if (i240 < 0 || i240 == 10) {
            int i241 = this.rowCount;
            int i242 = i241 + 1;
            this.rowCount = i242;
            this.downloadsSectionRow = i241;
            if (i240 < 0) {
                this.rowCount = i242 + 1;
                this.downloadsSectionRow2 = i242;
            }
            int i243 = this.rowCount;
            int i244 = i243 + 1;
            this.rowCount = i244;
            this.downloadsShowDownloadsOnlyIfActiveRow = i243;
            int i245 = i244 + 1;
            this.rowCount = i245;
            this.downloadsIncludePendingDownloadsRow = i244;
            int i246 = i245 + 1;
            this.rowCount = i246;
            this.downloadsHideScheduledDownloadReminderRow = i245;
            boolean z2 = BuildVars.BETA_2;
            if (z2) {
                this.rowCount = i246 + 1;
            } else {
                i246 = -1;
            }
            this.downloadsSimultaneousDownloadsRow = i246;
            if (z2) {
                i12 = this.rowCount;
                this.rowCount = i12 + 1;
            } else {
                i12 = -1;
            }
            this.downloadsSpeedBoostRow = i12;
            if (z2) {
                i13 = this.rowCount;
                this.rowCount = i13 + 1;
            }
            this.uploadSpeedBoostRow = i13;
        }
        if (i240 < 0) {
            int i247 = this.rowCount;
            int i248 = i247 + 1;
            this.rowCount = i248;
            this.plusSettingsSectionRow = i247;
            int i249 = i248 + 1;
            this.rowCount = i249;
            this.plusSettingsSectionRow2 = i248;
            int i250 = i249 + 1;
            this.rowCount = i250;
            this.savePlusSettingsRow = i249;
            int i251 = i250 + 1;
            this.rowCount = i251;
            this.restorePlusSettingsRow = i250;
            this.rowCount = i251 + 1;
            this.resetPlusSettingsRow = i251;
        }
        return true;
    }

    public final String getPrefix(int position) {
        int i = this.settings_type;
        int i2 = 3;
        if (i >= 0) {
            if (i == 0) {
                return "P" + this.settings_type + "." + position + " ";
            }
            if (i == 1) {
                StringBuilder sb = new StringBuilder();
                sb.append("P");
                sb.append(this.settings_type);
                sb.append(".");
                sb.append((position - 1) - (position <= this.dialogsShowAllInAdminTabDetailRow ? 0 : 1));
                sb.append(" ");
                return sb.toString();
            }
            if (i == 2) {
                return "P" + this.settings_type + "." + position + " ";
            }
            if (i == 3) {
                return "P" + this.settings_type + "." + position + " ";
            }
            if (i == 4) {
                return "P" + this.settings_type + "." + position + " ";
            }
            if (i == 5) {
                return "P" + this.settings_type + "." + position + " ";
            }
            if (i == 6) {
                return "P" + this.settings_type + "." + position + " ";
            }
            if (i == 7) {
                StringBuilder sb2 = new StringBuilder();
                sb2.append("P");
                sb2.append(this.settings_type);
                sb2.append(".");
                sb2.append((position - (position <= this.toastNotificationSection2Row ? 0 : 2)) - (position <= this.showOnlineToastNotificationDetailRow ? 0 : 1));
                sb2.append(" ");
                return sb2.toString();
            }
            if (i == 8) {
                StringBuilder sb3 = new StringBuilder();
                sb3.append("P");
                sb3.append(this.settings_type);
                sb3.append(".");
                if (position <= this.hiddenDialogsSectionRow2) {
                    i2 = 0;
                } else if (this.hiddenDialogsSectionRow <= 0) {
                    i2 = 2;
                }
                sb3.append(position - i2);
                sb3.append(" ");
                return sb3.toString();
            }
            if (i == 9) {
                StringBuilder sb4 = new StringBuilder();
                sb4.append("P");
                sb4.append(this.settings_type);
                sb4.append(".");
                sb4.append(position - (position <= this.keepOriginalFilenameDetailRow ? 0 : 1));
                sb4.append(" ");
                return sb4.toString();
            }
            if (i != 10) {
                return "P";
            }
            return "P" + this.settings_type + "." + position + " ";
        }
        if (position == this.settingsSectionRow2) {
            return "P0 ";
        }
        int i3 = this.dialogsSectionRow2;
        if (position < i3) {
            return "P0." + position + " ";
        }
        if (position == i3) {
            return "P1 ";
        }
        if (position > i3 && position < this.storiesSectionRow2) {
            StringBuilder sb5 = new StringBuilder();
            sb5.append("P");
            sb5.append("1.");
            sb5.append(((position - this.dialogsSectionRow2) - 1) - (position <= this.dialogsShowAllInAdminTabDetailRow ? 0 : 1));
            sb5.append(" ");
            return sb5.toString();
        }
        int i4 = this.storiesSectionRow2;
        if (position == i4) {
            return "P2 ";
        }
        if (position > i4 && position < this.messagesSectionRow2) {
            return "P2." + (position - this.storiesSectionRow2) + " ";
        }
        int i5 = this.messagesSectionRow2;
        if (position == i5) {
            return "P3 ";
        }
        if (position > i5 && position < this.topicsSectionRow2) {
            return "P3." + (position - this.messagesSectionRow2) + " ";
        }
        int i6 = this.topicsSectionRow2;
        if (position == i6) {
            return "P4 ";
        }
        if (position > i6 && position < this.drawerSectionRow2) {
            return "P4." + (position - this.topicsSectionRow2) + " ";
        }
        int i7 = this.drawerSectionRow2;
        if (position == i7) {
            return "P5 ";
        }
        if (position > i7 && position < this.profileSectionRow2) {
            return "P5." + (position - this.drawerSectionRow2) + " ";
        }
        int i8 = this.profileSectionRow2;
        if (position == i8) {
            return "P6 ";
        }
        if (position > i8 && position < this.notificationSection2Row) {
            return "P6." + (position - this.profileSectionRow2) + " ";
        }
        int i9 = this.notificationSection2Row;
        if (position == i9) {
            return "P7 ";
        }
        if (position > i9 && position < this.privacySectionRow2) {
            StringBuilder sb6 = new StringBuilder();
            sb6.append("P");
            sb6.append("7.");
            sb6.append(((position - this.notificationSection2Row) - (position <= this.toastNotificationSection2Row ? 0 : 2)) - (position <= this.showOnlineToastNotificationDetailRow ? 0 : 1));
            sb6.append(" ");
            return sb6.toString();
        }
        int i10 = this.privacySectionRow2;
        if (position == i10) {
            return "P8 ";
        }
        if (position > i10 && position < this.mediaDownloadSection2) {
            StringBuilder sb7 = new StringBuilder();
            sb7.append("P");
            sb7.append("8.");
            int i11 = position - this.privacySectionRow2;
            if (position <= this.hiddenDialogsSectionRow2) {
                i2 = 0;
            } else if (this.hiddenDialogsSectionRow <= 0) {
                i2 = 2;
            }
            sb7.append(i11 - i2);
            sb7.append(" ");
            return sb7.toString();
        }
        int i12 = this.mediaDownloadSection2;
        if (position == i12) {
            return "P9 ";
        }
        if (position > i12 && position < this.downloadsSectionRow2) {
            StringBuilder sb8 = new StringBuilder();
            sb8.append("P");
            sb8.append("9.");
            sb8.append((position - this.mediaDownloadSection2) - (position <= this.keepOriginalFilenameDetailRow ? 0 : 1));
            sb8.append(" ");
            return sb8.toString();
        }
        int i13 = this.downloadsSectionRow2;
        if (position == i13) {
            return "P10 ";
        }
        if (position <= i13 || position >= this.plusSettingsSectionRow2) {
            return "P";
        }
        return "P10." + (position - this.downloadsSectionRow2) + " ";
    }

    public void onFragmentDestroy() {
        super.onFragmentDestroy();
        NotificationCenter.getGlobalInstance().removeObserver(this, NotificationCenter.refreshTabs);
    }

    public final void clearMigratePreferences() {
        SharedPreferences sharedPreferences = ApplicationLoader.applicationContext.getSharedPreferences("systemConfig", 0);
        sharedPreferences.edit().putBoolean("migration_to_scoped_storage_finished", false).apply();
        sharedPreferences.edit().putInt("migration_to_scoped_storage_count", 0).apply();
    }

    public void countOldFiles() {
        if (Build.VERSION.SDK_INT < 30 || PlusUtils.verifyInstallerId()) {
            return;
        }
        Utilities.globalQueue.postRunnable(new Runnable() {
            @Override
            public final void run() {
                PlusSettingsActivity.this.lambda$countOldFiles$0();
            }
        });
    }

    public void lambda$countOldFiles$0() {
        ArrayList rootDirs;
        File externalStorageDirectory = Environment.getExternalStorageDirectory();
        if (!TextUtils.isEmpty(SharedConfig.storageCacheDir) && (rootDirs = AndroidUtilities.getRootDirs()) != null) {
            int size = rootDirs.size();
            int i = 0;
            while (true) {
                if (i >= size) {
                    break;
                }
                File file = (File) rootDirs.get(i);
                if (file.getAbsolutePath().startsWith(SharedConfig.storageCacheDir)) {
                    externalStorageDirectory = file;
                    break;
                }
                i++;
            }
        }
        if (PlusSettings.useExternalStorage()) {
            externalStorageDirectory = ApplicationLoader.applicationContext.getExternalFilesDir(null);
        }
        File file2 = new File(externalStorageDirectory, PlusSettings.usePlusFolder() ? "Plus" : "Telegram");
        File file3 = this.previousPath;
        if (file3 != null) {
            file2 = file3;
        }
        int filesCount = getFilesCount(file2);
        this.totalFilesCount = filesCount;
        this.totalFilesCount = filesCount > 5 ? filesCount : 0;
        AndroidUtilities.runOnUIThread(new Runnable() {
            @Override
            public void run() {
                if (PlusSettingsActivity.this.listAdapter != null) {
                    PlusSettingsActivity.this.listAdapter.notifyItemChanged(PlusSettingsActivity.this.migrateFilesRow);
                }
                PlusSettingsActivity.this.previousPath = null;
            }
        });
    }

    public final void migrateOldFolder() {
        if (this.totalFilesCount > 0) {
            this.totalFilesCount = 0;
            ListAdapter listAdapter = this.listAdapter;
            if (listAdapter != null) {
                listAdapter.notifyItemChanged(this.migrateFilesRow);
            }
            if (PlusSettings.useExternalStorage()) {
                FilesMigrationService.startService(this);
                return;
            } else {
                FilesMigrationService.showBottomSheet(this);
                return;
            }
        }
        PlusUtils.showToast(LocaleController.getString("CacheEmpty", R.string.CacheEmpty));
    }

    public final int getFilesCount(File source) {
        File[] listFiles;
        if (!source.exists() || (listFiles = source.listFiles()) == null) {
            return 0;
        }
        int i = 0;
        for (int i2 = 0; i2 < listFiles.length; i2++) {
            i = listFiles[i2].isDirectory() ? i + getFilesCount(listFiles[i2]) : i + 1;
        }
        return i;
    }

    public final String getHeaderTitle() {
        switch (this.settings_type) {
            case 0:
                return LocaleController.getString("General", R.string.General);
            case 1:
                return LocaleController.getString("DialogsSettings", R.string.DialogsSettings);
            case 2:
                return LocaleController.getString("FilterStories", R.string.FilterStories);
            case 3:
                return LocaleController.getString("MessagesSettings", R.string.MessagesSettings);
            case 4:
                return LocaleController.getString("Topics", R.string.Topics);
            case 5:
                return LocaleController.getString("NavigationDrawer", R.string.NavigationDrawer);
            case 6:
                return LocaleController.getString("ProfileScreen", R.string.ProfileScreen);
            case 7:
                return LocaleController.getString("Notifications", R.string.Notifications);
            case 8:
                return LocaleController.getString("PrivacySettings", R.string.PrivacySettings);
            case 9:
                return LocaleController.getString("SharedMedia", R.string.SharedMedia);
            case 10:
                return LocaleController.getString("Downloads", R.string.Downloads);
            default:
                return LocaleController.getString("PlusSettings", R.string.PlusSettings);
        }
    }

    public android.view.View createView(final android.content.Context r11) {
        throw new UnsupportedOperationException("Method not decompiled: org.telegram.ui.PlusSettingsActivity.createView(android.content.Context):android.view.View");
    }

    public void lambda$createView$14(android.content.Context r33, android.view.View r34, final int r35) {
        throw new UnsupportedOperationException("Method not decompiled: org.telegram.ui.PlusSettingsActivity.lambda$createView$14(android.content.Context, android.view.View, int):void");
    }

    public void lambda$createView$1() {
        ListAdapter listAdapter = this.listAdapter;
        if (listAdapter != null) {
            listAdapter.notifyDataSetChanged();
        }
    }

    public void lambda$createView$2() {
        ListAdapter listAdapter = this.listAdapter;
        if (listAdapter != null) {
            listAdapter.notifyItemChanged(this.useExternalStorageRow);
            this.listAdapter.notifyItemChanged(this.addAppFolderToSaveToOptionRow);
        }
        countOldFiles();
    }

    public void lambda$createView$3() {
        ListAdapter listAdapter = this.listAdapter;
        if (listAdapter != null) {
            listAdapter.notifyItemChanged(this.useExternalStorageRow);
            this.listAdapter.notifyItemChanged(this.useTelegramDataPathRow);
        }
        countOldFiles();
    }

    public void lambda$createView$4() {
        ListAdapter listAdapter = this.listAdapter;
        if (listAdapter != null) {
            listAdapter.notifyItemChanged(this.useExternalStorageRow);
        }
        countOldFiles();
    }

    public void lambda$createView$5(SharedPreferences.Editor editor, DialogInterface dialogInterface, int i) {
        PlusSettings.tapAvatarAction = i;
        editor.putInt("tapAvatarAction", i);
        editor.apply();
        ListAdapter listAdapter = this.listAdapter;
        if (listAdapter != null) {
            listAdapter.notifyItemChanged(this.chatSelectTapAvatarActionRow);
        }
    }

    public void lambda$createView$6(SharedPreferences.Editor editor, DialogInterface dialogInterface, int i) {
        PlusSettings.tapAndHoldAvatarAction = i;
        editor.putInt("tapAndHoldAvatarAction", i);
        editor.apply();
        ListAdapter listAdapter = this.listAdapter;
        if (listAdapter != null) {
            listAdapter.notifyItemChanged(this.chatSelectTapAndHoldAvatarActionRow);
        }
    }

    public void lambda$createView$7(SharedPreferences.Editor editor, SharedPreferences sharedPreferences, DialogInterface dialogInterface, int i) {
        PlusSettings.doubleTapAction = i;
        editor.putInt("doubleTapAction", i);
        editor.apply();
        if (!sharedPreferences.contains("doubleTapActionOut")) {
            PlusSettings.doubleTapActionOut = i;
        }
        ListAdapter listAdapter = this.listAdapter;
        if (listAdapter != null) {
            listAdapter.notifyItemChanged(this.chatSelectDoubleTapActionRow);
        }
    }

    public void lambda$createView$8(SharedPreferences.Editor editor, SharedPreferences sharedPreferences, int i, DialogInterface dialogInterface, int i2) {
        PlusSettings.swipeLeftAction = i2;
        editor.putInt("swipeLeftAction", i2);
        editor.apply();
        if (!sharedPreferences.contains("swipeLeftActionOut")) {
            PlusSettings.swipeLeftActionOut = i2;
        }
        ListAdapter listAdapter = this.listAdapter;
        if (listAdapter != null) {
            listAdapter.notifyItemChanged(i);
        }
    }

    public void lambda$createView$9(SharedPreferences.Editor editor, SharedPreferences sharedPreferences, int i, DialogInterface dialogInterface, int i2) {
        PlusSettings.swipeRightAction = i2;
        editor.putInt("swipeRightAction", i2);
        editor.apply();
        if (!sharedPreferences.contains("swipeRightActionOut")) {
            PlusSettings.swipeRightActionOut = i2;
        }
        ListAdapter listAdapter = this.listAdapter;
        if (listAdapter != null) {
            listAdapter.notifyItemChanged(i);
        }
    }

    public void lambda$createView$10(SharedPreferences.Editor editor, SharedPreferences sharedPreferences, int i, DialogInterface dialogInterface, int i2) {
        PlusSettings.directShareButtonAction = i2;
        editor.putInt("directShareButtonAction", i2);
        editor.apply();
        if (!sharedPreferences.contains("directShareButtonLongClickAction")) {
            PlusSettings.directShareButtonLongClickAction = i2;
        }
        ListAdapter listAdapter = this.listAdapter;
        if (listAdapter != null) {
            listAdapter.notifyItemChanged(i);
        }
    }

    public void lambda$createView$11(NumberPicker numberPicker, int i, DialogInterface dialogInterface, int i2) {
        PlusSettings.tabsSwipeSensitivity = numberPicker.getValue();
        SharedPreferences.Editor edit = ApplicationLoader.applicationContext.getSharedPreferences("plusconfig", 0).edit();
        edit.putInt("tabsSwipeSensitivity", PlusSettings.tabsSwipeSensitivity);
        edit.apply();
        ListAdapter listAdapter = this.listAdapter;
        if (listAdapter != null) {
            listAdapter.notifyItemChanged(i);
        }
    }

    public class AnonymousClass23 implements PlusUtils.GetStoragePathsDelegate {
        public AnonymousClass23() {
        }

        public void onCompleted() {
            PlusSettingsActivity.this.listAdapter.notifyItemChanged(PlusSettingsActivity.this.selectStorageRow);
            AndroidUtilities.runOnUIThread(new Runnable() {
                @Override
                public final void run() {
                    PlusSettingsActivity.AnonymousClass23.this.lambda$onCompleted$0();
                }
            }, 100L);
        }

        public void lambda$onCompleted$0() {
            if (PlusSettingsActivity.this.listAdapter != null) {
                PlusSettingsActivity.this.listAdapter.notifyItemChanged(PlusSettingsActivity.this.useExternalStorageRow);
            }
        }
    }

    public class AnonymousClass30 implements DialogInterface.OnClickListener {
        public final EditTextBoldCursor val$userInput;

        public AnonymousClass30(final EditTextBoldCursor val$userInput) {
            this.val$userInput = val$userInput;
        }

        @Override
        public void onClick(DialogInterface dialogInterface, int i) {
            if (PlusSettingsActivity.this.saving) {
                return;
            }
            String obj = this.val$userInput.getText().toString();
            if (obj.length() < 1) {
                Toast.makeText(PlusSettingsActivity.this.getParentActivity(), LocaleController.getString("NameTooShort", R.string.NameTooShort), 0).show();
                return;
            }
            PlusSettingsActivity.this.saving = true;
            PlusSettingsActivity.this.removeBeforeSaving();
            AndroidUtilities.runOnUIThread(new AnonymousClass1(obj));
        }

        public class AnonymousClass1 implements Runnable {
            public final String val$pName;

            public AnonymousClass1(final String val$pName) {
                this.val$pName = val$pName;
            }

            @Override
            public void run() {
                PlusSettingsActivity.this.saving = false;
                final String str = this.val$pName;
                new saveSettingsAsyncTask(new saveSettingsAsyncTask.SaveAsyncTaskDelegate() {
                    @Override
                    public final void onSaved(String str2) {
                        PlusSettingsActivity.AnonymousClass30.AnonymousClass1.this.lambda$run$2(str, str2);
                    }
                }).execute(this.val$pName);
            }

            public void lambda$run$2(final String str, final String str2) {
                AlertDialog.Builder builder = new AlertDialog.Builder(PlusSettingsActivity.this.getParentActivity());
                builder.setTitle(LocaleController.getString("AppName", R.string.AppName));
                builder.setMessage(LocaleController.getString("SaveToCloud", R.string.SaveToCloud));
                builder.setPositiveButton(LocaleController.getString("Yes", R.string.Yes).toUpperCase(), new DialogInterface.OnClickListener() {
                    @Override
                    public final void onClick(DialogInterface dialogInterface, int i) {
                        PlusSettingsActivity.AnonymousClass30.AnonymousClass1.this.lambda$run$0(str2, dialogInterface, i);
                    }
                });
                builder.setNeutralButton(LocaleController.getString("No", R.string.No).toUpperCase(), new DialogInterface.OnClickListener() {
                    @Override
                    public final void onClick(DialogInterface dialogInterface, int i) {
                        PlusSettingsActivity.AnonymousClass30.AnonymousClass1.this.lambda$run$1(str, str2, dialogInterface, i);
                    }
                });
                builder.show();
                PlusSettingsActivity.this.showDialog(builder.create());
            }

            public void lambda$run$0(final String str, DialogInterface dialogInterface, int i) {
                ArrayList arrayList = new ArrayList();
                arrayList.add(str);
                SendMessagesHelper.prepareSendingDocuments(AccountInstance.getInstance(PlusSettingsActivity.this.currentAccount), arrayList, arrayList, (ArrayList) null, (String) null, (String) null, PlusSettingsActivity.this.getUserConfig().getClientUserId(), (MessageObject) null, (MessageObject) null, (TL_stories.StoryItem) null, (ChatActivity.ReplyQuote) null, (MessageObject) null, false, 0, (InputContentInfoCompat) null, (String) null, 0, 0L, false);
                AndroidUtilities.runOnUIThread(new Runnable() {
                    @Override
                    public void run() {
                        if (PlusSettingsActivity.this.getParentActivity() != null) {
                            Toast.makeText(PlusSettingsActivity.this.getParentActivity(), LocaleController.formatString("SavedTo", R.string.SavedTo, new Object[]{str, LocaleController.getString("SavedMessages", R.string.SavedMessages)}), 1).show();
                        }
                    }
                });
            }

            public void lambda$run$1(final String str, final String str2, DialogInterface dialogInterface, int i) {
                AndroidUtilities.runOnUIThread(new Runnable() {
                    @Override
                    public void run() {
                        if (PlusSettingsActivity.this.getParentActivity() != null) {
                            Toast.makeText(PlusSettingsActivity.this.getParentActivity(), LocaleController.formatString("SavedTo", R.string.SavedTo, new Object[]{str + ".data", str2.replace(str + ".data", "")}), 1).show();
                        }
                    }
                });
            }
        }
    }

    public void lambda$createView$12(DialogInterface dialogInterface, int i) {
        loadSettingsFromCloud();
    }

    public void lambda$createView$13(DialogInterface dialogInterface, int i) {
        DocumentSelectActivity documentSelectActivity = new DocumentSelectActivity(false);
        documentSelectActivity.fileFilter = ".xml";
        documentSelectActivity.arrayFilter = new String[]{".data", ".db"};
        documentSelectActivity.setDelegate(new DocumentSelectActivity.DocumentSelectActivityDelegate() {
            @Override
            public void didSelectPhotos(ArrayList<SendMessagesHelper.SendingMediaInfo> photos, boolean notify, int scheduleDate) {
            }

            @Override
            public void startDocumentSelectActivity() {
            }

            @Override
            public void startMusicSelectActivity(BaseFragment baseFragment) {
                DocumentSelectActivity.DocumentSelectActivityDelegate.CC.$default$startMusicSelectActivity(this, baseFragment);
            }

            @Override
            public void didSelectFiles(final DocumentSelectActivity activity, ArrayList<String> files, String caption, boolean notify, int scheduleDate) {
                PlusSettingsActivity.this.restoreSettings(files.get(0), false, null);
            }
        });
        presentFragment(documentSelectActivity);
    }

    public int lambda$createView$15(int i) {
        try {
            this.layoutManager.scrollToPositionWithOffset(i, 0);
        } catch (Throwable unused) {
        }
        return i;
    }

    public void lambda$createView$16(int i) {
        this.listView.findViewHolderForAdapterPosition(i).itemView.performClick();
    }

    public class AnonymousClass46 implements RecyclerListView.OnItemLongClickListener {
        public final Context val$context;

        public AnonymousClass46(final Context val$context) {
            this.val$context = val$context;
        }

        public boolean onItemClick(View view, final int position) {
            if (position == 0 || (view instanceof ShadowSectionCell)) {
                return false;
            }
            if (PlusSettingsActivity.this.listView.getAdapter() == PlusSettingsActivity.this.searchAdapter) {
                AlertDialog.Builder builder = new AlertDialog.Builder(PlusSettingsActivity.this.getParentActivity());
                builder.setTitle(LocaleController.getString("AppName", R.string.AppName));
                builder.setMessage(LocaleController.getString("ClearSearch", R.string.ClearSearch));
                builder.setPositiveButton(LocaleController.getString("ClearButton", R.string.ClearButton).toUpperCase(), new DialogInterface.OnClickListener() {
                    @Override
                    public final void onClick(DialogInterface dialogInterface, int i) {
                        PlusSettingsActivity.AnonymousClass46.this.lambda$onItemClick$0(dialogInterface, i);
                    }
                });
                builder.setNegativeButton(LocaleController.getString("Cancel", R.string.Cancel), null);
                PlusSettingsActivity.this.showDialog(builder.create());
                return true;
            }
            if (PlusSettingsActivity.this.getParentActivity() == null) {
                return false;
            }
            String obj = view.getTag() != null ? view.getTag().toString() : "";
            String lowerCase = PlusSettingsActivity.this.getPrefix(position).toLowerCase();
            Object[] objArr = new Object[1];
            objArr[0] = TextUtils.isEmpty(obj) ? lowerCase : obj;
            final String format = String.format("https://t.me/plusmods/%s", objArr);
            final String format2 = String.format("https://t.me/plusmods/%s", lowerCase);
            final SharedPreferences.Editor edit = ApplicationLoader.applicationContext.getSharedPreferences("plusconfig", 0).edit();
            if (position == PlusSettingsActivity.this.chatChangeTranslateLanguageRow) {
                PlusUtils.showLanguageSelector(PlusSettingsActivity.this.getParentActivity(), (String) null, new PlusUtils.TranslateCallBack() {
                    public void onProviderChanged(int i) {
                        PlusUtils.TranslateCallBack.-CC.$default$onProviderChanged(this, i);
                    }

                    public void onSuccess(String translation) {
                    }

                    public void onChanged(String toLang) {
                        if (TextUtils.isEmpty(toLang)) {
                            return;
                        }
                        PlusSettings.translationLanguage = toLang;
                        PlusSettings.saveTranslationLanguage();
                        if (PlusSettingsActivity.this.listAdapter != null) {
                            PlusSettingsActivity.this.listAdapter.notifyItemChanged(PlusSettingsActivity.this.chatChangeTranslateLanguageRow);
                        }
                    }
                }, true);
                return true;
            }
            if (position == PlusSettingsActivity.this.migrateFilesRow) {
                PlusSettingsActivity.this.clearMigratePreferences();
                return true;
            }
            if (position == PlusSettingsActivity.this.chatSelectDoubleTapActionRow) {
                final AlertDialog.Builder builder2 = new AlertDialog.Builder(this.val$context);
                builder2.setTitle(LocaleController.getString("SelectDoubleTapAction", R.string.SelectDoubleTapAction));
                builder2.setItems(PlusSettings.doubleTapActionList, new DialogInterface.OnClickListener() {
                    @Override
                    public final void onClick(DialogInterface dialogInterface, int i) {
                        PlusSettingsActivity.AnonymousClass46.this.lambda$onItemClick$1(edit, dialogInterface, i);
                    }
                });
                builder2.setNegativeButton(LocaleController.getString("Cancel", R.string.Cancel), null);
                builder2.setNeutralButton(LocaleController.getString("CopyLink", R.string.CopyLink), new DialogInterface.OnClickListener() {
                    @Override
                    public final void onClick(DialogInterface dialogInterface, int i) {
                        PlusSettingsActivity.AnonymousClass46.this.lambda$onItemClick$2(format2, dialogInterface, i);
                    }
                });
                builder2.show().getButton(-3).setOnLongClickListener(new View.OnLongClickListener() {
                    @Override
                    public final boolean onLongClick(View view2) {
                        boolean lambda$onItemClick$3;
                        lambda$onItemClick$3 = PlusSettingsActivity.AnonymousClass46.this.lambda$onItemClick$3(format, builder2, view2);
                        return lambda$onItemClick$3;
                    }
                });
                return true;
            }
            if (position == PlusSettingsActivity.this.chatSwipeLeftActionRow) {
                final AlertDialog.Builder builder3 = new AlertDialog.Builder(this.val$context);
                builder3.setTitle(LocaleController.getString("SwipeLeftAction", R.string.SwipeLeftAction));
                builder3.setItems(PlusSettings.swipeLeftActionList, new DialogInterface.OnClickListener() {
                    @Override
                    public final void onClick(DialogInterface dialogInterface, int i) {
                        PlusSettingsActivity.AnonymousClass46.this.lambda$onItemClick$4(edit, dialogInterface, i);
                    }
                });
                builder3.setNegativeButton(LocaleController.getString("Cancel", R.string.Cancel), null);
                builder3.setNeutralButton(LocaleController.getString("CopyLink", R.string.CopyLink), new DialogInterface.OnClickListener() {
                    @Override
                    public final void onClick(DialogInterface dialogInterface, int i) {
                        PlusSettingsActivity.AnonymousClass46.this.lambda$onItemClick$5(format2, dialogInterface, i);
                    }
                });
                builder3.show().getButton(-3).setOnLongClickListener(new View.OnLongClickListener() {
                    @Override
                    public final boolean onLongClick(View view2) {
                        boolean lambda$onItemClick$6;
                        lambda$onItemClick$6 = PlusSettingsActivity.AnonymousClass46.this.lambda$onItemClick$6(format, builder3, view2);
                        return lambda$onItemClick$6;
                    }
                });
                return true;
            }
            if (position == PlusSettingsActivity.this.chatSwipeRightActionRow) {
                final AlertDialog.Builder builder4 = new AlertDialog.Builder(this.val$context);
                builder4.setTitle(LocaleController.getString("SwipeRightAction", R.string.SwipeRightAction));
                builder4.setItems(PlusSettings.swipeRightActionList, new DialogInterface.OnClickListener() {
                    @Override
                    public final void onClick(DialogInterface dialogInterface, int i) {
                        PlusSettingsActivity.AnonymousClass46.this.lambda$onItemClick$7(edit, dialogInterface, i);
                    }
                });
                builder4.setNegativeButton(LocaleController.getString("Cancel", R.string.Cancel), null);
                builder4.setNeutralButton(LocaleController.getString("CopyLink", R.string.CopyLink), new DialogInterface.OnClickListener() {
                    @Override
                    public final void onClick(DialogInterface dialogInterface, int i) {
                        PlusSettingsActivity.AnonymousClass46.this.lambda$onItemClick$8(format2, dialogInterface, i);
                    }
                });
                builder4.show().getButton(-3).setOnLongClickListener(new View.OnLongClickListener() {
                    @Override
                    public final boolean onLongClick(View view2) {
                        boolean lambda$onItemClick$9;
                        lambda$onItemClick$9 = PlusSettingsActivity.AnonymousClass46.this.lambda$onItemClick$9(format, builder4, view2);
                        return lambda$onItemClick$9;
                    }
                });
                return true;
            }
            if (position == PlusSettingsActivity.this.chatDirectShareButtonActionRow) {
                final AlertDialog.Builder builder5 = new AlertDialog.Builder(this.val$context);
                builder5.setTitle(LocaleController.getString("SelectDirectShareButtonAction", R.string.SelectDirectShareButtonAction));
                builder5.setItems(PlusSettings.directShareButtonActionList, new DialogInterface.OnClickListener() {
                    @Override
                    public final void onClick(DialogInterface dialogInterface, int i) {
                        PlusSettingsActivity.AnonymousClass46.this.lambda$onItemClick$10(edit, position, dialogInterface, i);
                    }
                });
                builder5.setNegativeButton(LocaleController.getString("Cancel", R.string.Cancel), null);
                builder5.setNeutralButton(LocaleController.getString("CopyLink", R.string.CopyLink), new DialogInterface.OnClickListener() {
                    @Override
                    public final void onClick(DialogInterface dialogInterface, int i) {
                        PlusSettingsActivity.AnonymousClass46.this.lambda$onItemClick$11(format2, dialogInterface, i);
                    }
                });
                builder5.show().getButton(-3).setOnLongClickListener(new View.OnLongClickListener() {
                    @Override
                    public final boolean onLongClick(View view2) {
                        boolean lambda$onItemClick$12;
                        lambda$onItemClick$12 = PlusSettingsActivity.AnonymousClass46.this.lambda$onItemClick$12(format, builder5, view2);
                        return lambda$onItemClick$12;
                    }
                });
                return true;
            }
            AlertDialog.Builder builder6 = new AlertDialog.Builder(PlusSettingsActivity.this.getParentActivity());
            ArrayList arrayList = new ArrayList();
            ArrayList arrayList2 = new ArrayList();
            if (obj != null && !obj.isEmpty()) {
                builder6.setTitle(obj);
            }
            arrayList.add(LocaleController.getString("CopyLink", R.string.CopyLink));
            arrayList2.add(0);
            arrayList.add(LocaleController.getString("ShareLink", R.string.ShareLink));
            arrayList2.add(2);
            arrayList.add(LocaleController.getString("CopyKey", R.string.CopyKey));
            arrayList2.add(4);
            if (position == PlusSettingsActivity.this.enableHiddenDialogsRow) {
                arrayList.add(LocaleController.getString("Delete", R.string.Delete));
                arrayList2.add(3);
            }
            if (obj != null && !obj.isEmpty()) {
                arrayList.add(LocaleController.getString("Reset", R.string.Reset));
                arrayList2.add(1);
            }
            if (position == PlusSettingsActivity.this.topicsAllowPinTopicsRow) {
                arrayList.add(LocaleController.getString("ResetPinnedSettings", R.string.ResetPinnedSettings));
                arrayList2.add(6);
            }
            builder6.setItems((CharSequence[]) arrayList.toArray(new CharSequence[arrayList.size()]), new AnonymousClass2(arrayList2, lowerCase, obj, position));
            PlusSettingsActivity.this.showDialog(builder6.create());
            return true;
        }

        public void lambda$onItemClick$0(DialogInterface dialogInterface, int i) {
            PlusSettingsActivity.this.searchAdapter.clearRecent();
        }

        public void lambda$onItemClick$1(SharedPreferences.Editor editor, DialogInterface dialogInterface, int i) {
            PlusSettings.doubleTapActionOut = i;
            editor.putInt("doubleTapActionOut", i);
            editor.apply();
            if (PlusSettingsActivity.this.listAdapter != null) {
                PlusSettingsActivity.this.listAdapter.notifyItemChanged(PlusSettingsActivity.this.chatSelectDoubleTapActionRow);
            }
        }

        public void lambda$onItemClick$2(String str, DialogInterface dialogInterface, int i) {
            PlusSettingsActivity.this.copyToClipboard(str);
        }

        public boolean lambda$onItemClick$3(String str, AlertDialog.Builder builder, View view) {
            PlusSettingsActivity.this.copyToClipboard(str);
            builder.getDismissRunnable().run();
            return true;
        }

        public void lambda$onItemClick$4(SharedPreferences.Editor editor, DialogInterface dialogInterface, int i) {
            PlusSettings.swipeLeftActionOut = i;
            editor.putInt("swipeLeftActionOut", i);
            editor.apply();
            if (PlusSettingsActivity.this.listAdapter != null) {
                PlusSettingsActivity.this.listAdapter.notifyItemChanged(PlusSettingsActivity.this.chatSwipeLeftActionRow);
            }
        }

        public void lambda$onItemClick$5(String str, DialogInterface dialogInterface, int i) {
            PlusSettingsActivity.this.copyToClipboard(str);
        }

        public boolean lambda$onItemClick$6(String str, AlertDialog.Builder builder, View view) {
            PlusSettingsActivity.this.copyToClipboard(str);
            builder.getDismissRunnable().run();
            return true;
        }

        public void lambda$onItemClick$7(SharedPreferences.Editor editor, DialogInterface dialogInterface, int i) {
            PlusSettings.swipeRightActionOut = i;
            editor.putInt("swipeRightActionOut", i);
            editor.apply();
            if (PlusSettingsActivity.this.listAdapter != null) {
                PlusSettingsActivity.this.listAdapter.notifyItemChanged(PlusSettingsActivity.this.chatSwipeRightActionRow);
            }
        }

        public void lambda$onItemClick$8(String str, DialogInterface dialogInterface, int i) {
            PlusSettingsActivity.this.copyToClipboard(str);
        }

        public boolean lambda$onItemClick$9(String str, AlertDialog.Builder builder, View view) {
            PlusSettingsActivity.this.copyToClipboard(str);
            builder.getDismissRunnable().run();
            return true;
        }

        public void lambda$onItemClick$10(SharedPreferences.Editor editor, int i, DialogInterface dialogInterface, int i2) {
            PlusSettings.directShareButtonLongClickAction = i2;
            editor.putInt("directShareButtonLongClickAction", i2);
            editor.apply();
            if (PlusSettingsActivity.this.listAdapter != null) {
                PlusSettingsActivity.this.listAdapter.notifyItemChanged(i);
            }
        }

        public void lambda$onItemClick$11(String str, DialogInterface dialogInterface, int i) {
            PlusSettingsActivity.this.copyToClipboard(str);
        }

        public boolean lambda$onItemClick$12(String str, AlertDialog.Builder builder, View view) {
            PlusSettingsActivity.this.copyToClipboard(str);
            builder.getDismissRunnable().run();
            return true;
        }

        public class AnonymousClass2 implements DialogInterface.OnClickListener {
            public final ArrayList val$actions;
            public final String val$key;
            public final int val$position;
            public final String val$prefix;

            public AnonymousClass2(final ArrayList val$actions, final String val$prefix, final String val$key, final int val$position) {
                this.val$actions = val$actions;
                this.val$prefix = val$prefix;
                this.val$key = val$key;
                this.val$position = val$position;
            }

            @Override
            public void onClick(DialogInterface dialogInterface, int i) {
                int intValue = ((Integer) this.val$actions.get(i)).intValue();
                Object[] objArr = new Object[1];
                objArr[0] = intValue == 0 ? this.val$prefix : this.val$key;
                final String format = String.format("https://t.me/plusmods/%s", objArr);
                if (intValue == 0 || intValue == 4) {
                    try {
                        ((ClipboardManager) ApplicationLoader.applicationContext.getSystemService("clipboard")).setPrimaryClip(ClipData.newPlainText("label", format));
                        AndroidUtilities.runOnUIThread(new Runnable() {
                            @Override
                            public void run() {
                                if (PlusSettingsActivity.this.getParentActivity() != null) {
                                    Toast.makeText(PlusSettingsActivity.this.getParentActivity(), format, 0).show();
                                }
                            }
                        });
                        return;
                    } catch (Exception e) {
                        FileLog.e(e);
                        return;
                    }
                }
                if (intValue == 1) {
                    PlusSettingsActivity.this.resetPref(this.val$key, this.val$position);
                    return;
                }
                if (intValue == 2) {
                    try {
                        Intent intent = new Intent("android.intent.action.SEND");
                        intent.setType("text/plain");
                        intent.putExtra("android.intent.extra.TEXT", format);
                        PlusSettingsActivity.this.getParentActivity().startActivityForResult(Intent.createChooser(intent, LocaleController.getString("ShareLink", R.string.ShareLink)), 500);
                        return;
                    } catch (Exception e2) {
                        FileLog.e(e2);
                        return;
                    }
                }
                if (intValue == 3) {
                    PlusSettings.deleteHiddenPasscode();
                    PlusSettingsActivity.this.listAdapter.notifyItemChanged(this.val$position);
                    AndroidUtilities.runOnUIThread(new Runnable() {
                        @Override
                        public final void run() {
                            PlusSettingsActivity.AnonymousClass46.AnonymousClass2.this.lambda$onClick$0();
                        }
                    });
                } else if (intValue == 6) {
                    PlusSettingsActivity.this.resetPinned();
                }
            }

            public void lambda$onClick$0() {
                if (PlusSettingsActivity.this.getParentActivity() != null) {
                    PlusRoomDatabase.deletePlusDbFile();
                    Toast.makeText(PlusSettingsActivity.this.getParentActivity(), "PASSCODE deleted", 0).show();
                }
            }
        }
    }

    public final void createMenu() {
        ActionBarMenuItem addItem = ((BaseFragment) this).actionBar.createMenu().addItem(1, R.drawable.ic_ab_other);
        this.headerItem = addItem;
        addItem.setVisibility(8);
        this.headerItem.addSubItem(100, R.drawable.msg_reset, LocaleController.getString("ThemeResetToDefaults", R.string.ThemeResetToDefaults));
        if (this.settings_type == 3) {
            this.headerItemVisible = true;
            this.headerItem.setVisibility(0);
        }
    }

    public final void resetToDefaults() {
        AlertDialog.Builder builder = new AlertDialog.Builder(getParentActivity());
        builder.setTitle(getHeaderTitle());
        builder.setMessage(LocaleController.getString("AreYouSure", R.string.AreYouSure));
        builder.setPositiveButton(LocaleController.getString("Yes", R.string.Yes), new DialogInterface.OnClickListener() {
            @Override
            public void onClick(DialogInterface dialogInterface, int i) {
                if (PlusSettingsActivity.this.reseting) {
                    return;
                }
                PlusSettingsActivity.this.reseting = true;
                AndroidUtilities.runOnUIThread(new Runnable() {
                    @Override
                    public void run() {
                        PlusSettingsActivity.this.reseting = false;
                        SharedPreferences.Editor edit = ApplicationLoader.applicationContext.getSharedPreferences("plusconfig", 0).edit();
                        PlusSettings.viewAllTopicsAsMessages = false;
                        edit.remove("viewAllTopicsAsMessages");
                        PlusSettings.saveViewTopicsAsMessagesOption = false;
                        edit.remove("saveViewTopicsAsMessagesOption");
                        PlusSettings.allowPinTopics = false;
                        edit.remove("allowPinTopics");
                        edit.apply();
                        if (PlusSettingsActivity.this.listAdapter != null) {
                            PlusSettingsActivity.this.listAdapter.notifyItemRangeChanged(PlusSettingsActivity.this.topicsViewAllTopicsAsMessagesRow, 3);
                        }
                    }
                });
            }
        });
        builder.setNegativeButton(LocaleController.getString("Cancel", R.string.Cancel), null);
        showDialog(builder.create());
    }

    public final void resetPinned() {
        PlusSettings.resetPinnedDialog(this, 0L, new PlusSettings.Callback(this) {
            @Override
            public void onCompleted() {
            }
        });
    }

    public final void copyToClipboard(final String link) {
        try {
            ((ClipboardManager) ApplicationLoader.applicationContext.getSystemService("clipboard")).setPrimaryClip(ClipData.newPlainText("label", link));
            AndroidUtilities.runOnUIThread(new Runnable() {
                @Override
                public void run() {
                    if (PlusSettingsActivity.this.getParentActivity() != null) {
                        Toast.makeText(PlusSettingsActivity.this.getParentActivity(), link, 0).show();
                    }
                }
            });
        } catch (Exception e) {
            FileLog.e(e);
        }
    }

    public final void askIfRestoreHiddenDialogs() {
        int size = getMessagesController().hiddenDialogs.size();
        if (PlusSettings.enableHiddenDialogs || size <= 0) {
            return;
        }
        AlertDialog.Builder builder = new AlertDialog.Builder(getParentActivity());
        builder.setTitle(LocaleController.getString("AppName", R.string.AppName));
        builder.setMessage(LocaleController.getString("HiddenChats", R.string.HiddenChats) + ": " + size + "\n\n" + LocaleController.getString("ShowHiddenChatsAgain", R.string.ShowHiddenChatsAgain));
        builder.setPositiveButton(LocaleController.getString("Show", R.string.Show).toUpperCase(), new DialogInterface.OnClickListener() {
            @Override
            public final void onClick(DialogInterface dialogInterface, int i) {
                PlusSettingsActivity.this.lambda$askIfRestoreHiddenDialogs$17(dialogInterface, i);
            }
        });
        builder.setNegativeButton(LocaleController.getString("Cancel", R.string.Cancel), null);
        showDialog(builder.create());
    }

    public void lambda$askIfRestoreHiddenDialogs$17(DialogInterface dialogInterface, int i) {
        AndroidUtilities.runOnUIThread(new Runnable() {
            @Override
            public void run() {
                Iterator it = new ArrayList(PlusSettingsActivity.this.getMessagesController().hiddenDialogs).iterator();
                while (it.hasNext()) {
                    long longValue = ((Long) it.next()).longValue();
                    PlusSettingsActivity plusSettingsActivity = PlusSettingsActivity.this;
                    plusSettingsActivity.insertOrUpdateHidden((TLRPC.Dialog) plusSettingsActivity.getMessagesController().dialogs_dict.get(longValue), false, 0);
                }
            }
        });
    }

    public final void insertOrUpdateHidden(TLRPC.Dialog dialog, boolean hidden, int folder) {
        if (dialog != null) {
            dialog.hidden = hidden;
            dialog.folder_id = folder;
            long j = dialog.id;
            boolean contains = getMessagesController().favsDialogs.contains(Long.valueOf(j));
            DialogEntity dialogEntity = new DialogEntity(getUserConfig().clientUserId, j, contains, hidden);
            if (contains || hidden) {
                PlusRepository.getInstance(this.currentAccount).insertOrUpdateHidden(dialogEntity);
            } else {
                PlusRepository.getInstance(this.currentAccount).deleteHiddenDialog(dialogEntity);
            }
            if (MessagesController.getInstance(this.currentAccount).getUser(Long.valueOf(j)) != null) {
                getMediaDataController().loadHints(true, true);
            }
            getMessagesController().addDialogToFolder(j, folder, -1, 0L);
        }
    }

    public boolean onBackPressed() {
        PasscodeView passcodeView = this.passcodeView;
        if (passcodeView != null && passcodeView.getVisibility() == 0) {
            SharedConfig.isWaitingForPasscodeEnter = false;
            this.passcodeView.setVisibility(8);
            this.passcodeView.setOnTouchListener(null);
            return false;
        }
        this.passcodeEntered = false;
        return super.onBackPressed();
    }

    public final void showPasscodeView(final View view) {
        PasscodeView passcodeView = this.passcodeView;
        if (passcodeView == null) {
            return;
        }
        final int i = SharedConfig.passcodeType;
        SharedConfig.passcodeType = 0;
        passcodeView.isHiddenPass();
        this.passcodeView.onShow(SharedConfig.hiddenUseFingerprint, false);
        SharedConfig.isWaitingForPasscodeEnter = true;
        this.passcodeView.setDelegate(new PasscodeView.PasscodeViewDelegate() {
            public final void didAcceptedPassword(PasscodeView passcodeView2) {
                PlusSettingsActivity.this.lambda$showPasscodeView$18(i, view, passcodeView2);
            }
        });
    }

    public void lambda$showPasscodeView$18(int i, View view, PasscodeView passcodeView) {
        this.passcodeEntered = true;
        SharedConfig.passcodeType = i;
        SharedConfig.isWaitingForPasscodeEnter = false;
        SharedPreferences.Editor edit = ApplicationLoader.applicationContext.getSharedPreferences("plusconfig", 0).edit();
        int intValue = ((Integer) view.getTag()).intValue();
        if (intValue == this.enableHiddenDialogsRow) {
            PlusSettings.enableHiddenDialogs = false;
            ((TextCheckCell) view).setChecked(false);
            edit.putBoolean("enableHiddenDialogs", false).apply();
            boolean z = PlusSettings.showHiddenDialogsIcon;
            if (z) {
                previousShowHiddenDialogsIcon = z;
                PlusSettings.showHiddenDialogsIcon = false;
                edit.putBoolean("showHiddenDialogsIcon", false).apply();
                this.listAdapter.notifyItemChanged(this.showHiddenDialogsIconRow);
                NotificationCenter.getGlobalInstance().postNotificationName(NotificationCenter.plusSettingsChanged, new Object[]{1});
            }
            askIfRestoreHiddenDialogs();
            return;
        }
        if (intValue == this.changeHiddenDialogsPasswordRow) {
            presentFragment(new PasscodeActivity(5));
        } else if (intValue == this.openHiddenDialogsWithoutPasscodeRow) {
            PlusSettings.openHiddenDialogsWithoutPasscode = true;
            ((TextCheckCell) view).setChecked(true);
            edit.putBoolean("openHiddenDialogsWithoutPasscode", true).apply();
        }
    }

    public final void removeBeforeSaving() {
        SharedPreferences.Editor edit = ApplicationLoader.applicationContext.getSharedPreferences("plusconfig", 0).edit();
        edit.remove("silentMode");
        edit.commit();
    }

    public final void resetPref(java.lang.String r9, final int r10) {
        throw new UnsupportedOperationException("Method not decompiled: org.telegram.ui.PlusSettingsActivity.resetPref(java.lang.String, int):void");
    }

    public void lambda$resetPref$19(int i) {
        ListAdapter listAdapter = this.listAdapter;
        if (listAdapter != null) {
            listAdapter.notifyItemChanged(i);
        }
    }

    public final void restoreSettings(final String f, final boolean restart, String dataName) {
        File file = new File(f);
        String name = file.getName();
        AlertDialog.Builder builder = new AlertDialog.Builder(getParentActivity());
        builder.setTitle(LocaleController.getString("RestoreSettings", R.string.RestoreSettings));
        if (dataName == null) {
            dataName = name;
        }
        builder.setMessage(dataName);
        builder.setPositiveButton(LocaleController.getString("Yes", R.string.Yes), new AnonymousClass53(name, f, file));
        builder.setNegativeButton(LocaleController.getString("No", R.string.No), null);
        builder.setOnCancelListener(new DialogInterface.OnCancelListener() {
            @Override
            public final void onCancel(DialogInterface dialogInterface) {
                PlusSettingsActivity.this.lambda$restoreSettings$20(restart, dialogInterface);
            }
        });
        showDialog(builder.create());
    }

    public class AnonymousClass53 implements DialogInterface.OnClickListener {
        public final String val$f;
        public final File val$file;
        public final String val$name;

        public AnonymousClass53(final String val$name, final String val$f, final File val$file) {
            this.val$name = val$name;
            this.val$f = val$f;
            this.val$file = val$file;
        }

        @Override
        public void onClick(DialogInterface dialogInterface, int i) {
            AndroidUtilities.runOnUIThread(new Runnable() {
                @Override
                public void run() {
                    String str = AnonymousClass53.this.val$name.split("\\.")[1];
                    if (str != null) {
                        String str2 = AnonymousClass53.this.val$name.replaceFirst("[.][^.]+$", "") + ".data";
                        if (str.contains("xml")) {
                            if (Utilities.loadPrefFromSD(AnonymousClass53.this.val$f, "plusconfig") == 4) {
                                File file = new File(AnonymousClass53.this.val$file.getParentFile() + "/" + str2);
                                if (file.exists()) {
                                    PlusSettingsActivity.this.restoreSettings(file.getAbsolutePath(), true, null);
                                    return;
                                } else {
                                    PlusSettingsActivity.this.showRestartDialog();
                                    return;
                                }
                            }
                            return;
                        }
                        if (str.contains("data")) {
                            new PlusUtils.restoreAsyncTask(new PlusUtils.restoreAsyncTask.RestoreAsyncTaskDelegate() {
                                public void onError(String error) {
                                }

                                public void onRestart() {
                                    PlusSettingsActivity.this.showRestartDialog();
                                }
                            }).execute(AnonymousClass53.this.val$file);
                            return;
                        }
                        if (str.contains("db") && Utilities.loadDBFromSD(AnonymousClass53.this.val$f, "favourites") == 4) {
                            for (int i2 = 0; i2 < UserConfig.MAX_ACCOUNT_COUNT; i2++) {
                                if (UserConfig.getInstance(i2).isClientActivated()) {
                                    MessagesController.getMainSettings(i2).edit().putBoolean("oldFavsLoaded", false).apply();
                                }
                            }
                            PlusSettingsActivity.this.showRestartDialog();
                        }
                    }
                }
            });
        }
    }

    public void lambda$restoreSettings$20(boolean z, DialogInterface dialogInterface) {
        if (z) {
            showRestartDialog();
        }
    }

    public class AnonymousClass54 implements PlusUtils.SearchSettingsOnCloud.SearchSettingsOnCloudDelegate {
        public AnonymousClass54() {
        }

        public void onCompleted(final ArrayList<MessageObject> list) {
            final BottomSheet.Builder builder = new BottomSheet.Builder(PlusSettingsActivity.this.getParentActivity());
            builder.setApplyTopPadding(false);
            builder.setApplyBottomPadding(false);
            ScrollView scrollView = new ScrollView(PlusSettingsActivity.this.getParentActivity());
            scrollView.setFillViewport(true);
            int i = Theme.key_windowBackgroundGray;
            scrollView.setTag(Integer.valueOf(i));
            scrollView.setBackgroundColor(Theme.usePlusTheme ? Theme.prefShadowColor : Theme.getColor(i));
            LinearLayout linearLayout = new LinearLayout(PlusSettingsActivity.this.getParentActivity());
            linearLayout.setOrientation(1);
            scrollView.addView(linearLayout, new FrameLayout.LayoutParams(-1, -2));
            for (int i2 = 0; i2 < list.size(); i2++) {
                MessageObject messageObject = list.get(i2);
                final TLRPC.Document document = messageObject.getDocument();
                if (document != null) {
                    SharedDocumentCell sharedDocumentCell = new SharedDocumentCell(PlusSettingsActivity.this.getParentActivity());
                    sharedDocumentCell.setDocument(messageObject, true);
                    sharedDocumentCell.setChecked(false, false);
                    sharedDocumentCell.setTag(Integer.valueOf(i2));
                    linearLayout.addView(sharedDocumentCell, LayoutHelper.createLinear(-1, -2));
                    sharedDocumentCell.setOnClickListener(new View.OnClickListener() {
                        @Override
                        public final void onClick(View view) {
                            PlusSettingsActivity.AnonymousClass54.this.lambda$onCompleted$0(list, document, view);
                        }
                    });
                }
            }
            BottomSheet.BottomSheetCell bottomSheetCell = new BottomSheet.BottomSheetCell(PlusSettingsActivity.this.getParentActivity(), 1);
            bottomSheetCell.setBackgroundDrawable(Theme.getSelectorDrawable(false));
            bottomSheetCell.setTextAndIcon(LocaleController.getString("Close", R.string.Close).toUpperCase(), 0);
            bottomSheetCell.setTextColor(Theme.getColor(Theme.key_dialogTextBlue2));
            bottomSheetCell.setOnClickListener(new View.OnClickListener() {
                @Override
                public final void onClick(View view) {
                    PlusSettingsActivity.AnonymousClass54.this.lambda$onCompleted$1(builder, view);
                }
            });
            linearLayout.addView(bottomSheetCell, LayoutHelper.createLinear(-1, -2));
            builder.setCustomView(scrollView);
            PlusSettingsActivity.this.showDialog(builder.create());
        }

        public void lambda$onCompleted$0(ArrayList arrayList, TLRPC.Document document, View view) {
            SharedDocumentCell sharedDocumentCell = (SharedDocumentCell) view;
            MessageObject messageObject = (MessageObject) arrayList.get(((Integer) sharedDocumentCell.getTag()).intValue());
            TLRPC.Document document2 = messageObject.getDocument();
            if (sharedDocumentCell.isLoaded()) {
                File file = null;
                String str = messageObject.messageOwner.attachPath;
                if (str != null && str.length() != 0) {
                    file = new File(messageObject.messageOwner.attachPath);
                }
                if (file == null || !file.exists()) {
                    file = FileLoader.getInstance(PlusSettingsActivity.this.currentAccount).getPathToMessage(messageObject.messageOwner);
                }
                if (file.exists()) {
                    PlusSettingsActivity.this.restoreSettings(file.getAbsolutePath(), false, FileLoader.getDocumentFileName(document2));
                    return;
                }
                return;
            }
            if (!sharedDocumentCell.isLoading()) {
                FileLoader.getInstance(PlusSettingsActivity.this.currentAccount).loadFile(document2, sharedDocumentCell.getMessage(), 0, 0);
                final String documentFileName = FileLoader.getDocumentFileName(document2);
                FileLoader.getInstance(PlusSettingsActivity.this.currentAccount).setDelegate(new FileLoader.FileLoaderDelegate() {
                    public void fileDidFailedLoad(String location, int state) {
                    }

                    public void fileDidFailedUpload(String location, boolean isEncrypted) {
                    }

                    public void fileDidUploaded(String location, TLRPC.InputFile inputFile, TLRPC.InputEncryptedFile inputEncryptedFile, byte[] key, byte[] iv, long totalFileSize) {
                    }

                    public void fileLoadProgressChanged(FileLoadOperation operation, String location, long uploadedSize, long totalSize) {
                    }

                    public void fileUploadProgressChanged(FileUploadOperation operation, String location, long uploadedSize, long totalSize, boolean isEncrypted) {
                    }

                    public void fileDidLoaded(String location, File finalFile, Object parentObject, int type) {
                        if (finalFile.getName().contains(".data")) {
                            PlusSettingsActivity.this.restoreSettings(finalFile.getAbsolutePath(), false, documentFileName);
                        }
                    }
                });
                sharedDocumentCell.updateFileExistIcon(false);
                return;
            }
            FileLoader.getInstance(PlusSettingsActivity.this.currentAccount).cancelLoadFile(document);
            sharedDocumentCell.updateFileExistIcon(false);
        }

        public void lambda$onCompleted$1(BottomSheet.Builder builder, View view) {
            Dialog dialog = ((BaseFragment) PlusSettingsActivity.this).visibleDialog;
            if (dialog != null) {
                dialog.dismiss();
            }
            builder.create().dismiss();
        }
    }

    public final void loadSettingsFromCloud() {
        new PlusUtils.SearchSettingsOnCloud(this, new AnonymousClass54());
    }

    public final void showRestartDialog() {
        if (getParentActivity() == null) {
            return;
        }
        AlertDialog.Builder builder = new AlertDialog.Builder(getParentActivity());
        builder.setTitle(LocaleController.getString("AppName", R.string.AppName));
        builder.setMessage(LocaleController.getString("AppWillRestart", R.string.AppWillRestart));
        builder.setPositiveButton(LocaleController.getString("OK", R.string.OK).toUpperCase(), new DialogInterface.OnClickListener() {
            @Override
            public final void onClick(DialogInterface dialogInterface, int i) {
                Utilities.restartApp();
            }
        });
        builder.setOnCancelListener(new DialogInterface.OnCancelListener() {
            @Override
            public final void onCancel(DialogInterface dialogInterface) {
                Utilities.restartApp();
            }
        });
        showDialog(builder.create());
    }

    public final AlertDialog.Builder createTabsDialog(AlertDialog.Builder builder) {
        builder.setTitle(LocaleController.getString("HideShowTabs", R.string.HideShowTabs));
        builder.setMultiChoiceItems(new CharSequence[]{LocaleController.getString("All", R.string.All), LocaleController.getString("Users", R.string.Users), LocaleController.getString("Groups", R.string.Groups), LocaleController.getString("SuperGroups", R.string.SuperGroups), LocaleController.getString("Channels", R.string.Channels), LocaleController.getString("Bots", R.string.Bots), LocaleController.getString("Favorites", R.string.Favorites)}, new boolean[]{!Theme.plusHideAllTab, !Theme.plusHideUsersTab, !Theme.plusHideGroupsTab, !Theme.plusHideSuperGroupsTab, !Theme.plusHideChannelsTab, !Theme.plusHideBotsTab, !Theme.plusHideFavsTab}, new DialogInterface.OnMultiChoiceClickListener(this) {
            @Override
            public void onClick(DialogInterface dialog, int which, boolean isChecked) {
                NotificationCenter.getGlobalInstance().postNotificationName(NotificationCenter.refreshTabs, new Object[]{Integer.valueOf(which)});
            }
        });
        return builder;
    }

    public final void updateTheme() {
        ((BaseFragment) this).actionBar.setBackgroundColor(Theme.prefActionbarColor);
        ((BaseFragment) this).actionBar.setTitleColor(Theme.prefActionbarTitleColor);
        Drawable drawable = getParentActivity().getResources().getDrawable(R.drawable.ic_ab_back);
        drawable.setColorFilter(Theme.prefActionbarIconsColor, PorterDuff.Mode.MULTIPLY);
        ((BaseFragment) this).actionBar.setBackButtonDrawable(drawable);
        getParentActivity().getResources().getDrawable(R.drawable.ic_ab_other).setColorFilter(Theme.prefActionbarIconsColor, PorterDuff.Mode.MULTIPLY);
        ((BaseFragment) this).actionBar.setItemsColor(Theme.prefActionbarIconsColor, false);
    }

    public void onResume() {
        super.onResume();
        ListAdapter listAdapter = this.listAdapter;
        if (listAdapter != null) {
            listAdapter.notifyDataSetChanged();
        }
        fixLayout();
    }

    public void didReceivedNotification(int id, int account, Object... args) {
        RecyclerListView recyclerListView;
        if (id == NotificationCenter.refreshTabs && ((Integer) args[0]).intValue() == 15 && (recyclerListView = this.listView) != null) {
            recyclerListView.invalidateViews();
        }
    }

    public void onConfigurationChanged(Configuration newConfig) {
        super.onConfigurationChanged(newConfig);
        fixLayout();
    }

    public final void fixLayout() {
        View view = ((BaseFragment) this).fragmentView;
        if (view == null) {
            return;
        }
        view.getViewTreeObserver().addOnPreDrawListener(new ViewTreeObserver.OnPreDrawListener() {
            @Override
            public boolean onPreDraw() {
                View view2 = ((BaseFragment) PlusSettingsActivity.this).fragmentView;
                if (view2 == null) {
                    return true;
                }
                view2.getViewTreeObserver().removeOnPreDrawListener(this);
                return true;
            }
        });
    }

    public ArrayList<ThemeDescription> getThemeDescriptions() {
        ActionBar actionBar = ((BaseFragment) this).actionBar;
        int i = ThemeDescription.FLAG_BACKGROUND;
        int i2 = Theme.key_avatar_backgroundActionBarBlue;
        int i3 = Theme.key_windowBackgroundWhiteBlackText;
        int i4 = Theme.key_windowBackgroundWhiteGrayText2;
        return new ArrayList<>(Arrays.asList(new ThemeDescription(this.listView, ThemeDescription.FLAG_CELLBACKGROUNDCOLOR, new Class[]{EmptyCell.class, TextSettingsCell.class, TextCheckCell.class, HeaderCell.class, TextInfoCell.class, TextDetailSettingsCell.class}, null, null, null, Theme.key_windowBackgroundWhite), new ThemeDescription(((BaseFragment) this).fragmentView, ThemeDescription.FLAG_BACKGROUND, null, null, null, null, Theme.key_windowBackgroundGray), new ThemeDescription(actionBar, i, null, null, null, null, i2), new ThemeDescription(this.listView, ThemeDescription.FLAG_LISTGLOWCOLOR, null, null, null, null, i2), new ThemeDescription(((BaseFragment) this).actionBar, ThemeDescription.FLAG_AB_ITEMSCOLOR, null, null, null, null, Theme.key_avatar_actionBarIconBlue), new ThemeDescription(((BaseFragment) this).actionBar, ThemeDescription.FLAG_AB_TITLECOLOR, null, null, null, null, Theme.key_actionBarDefaultTitle), new ThemeDescription(((BaseFragment) this).actionBar, ThemeDescription.FLAG_AB_SELECTORCOLOR, null, null, null, null, Theme.key_avatar_actionBarSelectorBlue), new ThemeDescription(((BaseFragment) this).actionBar, ThemeDescription.FLAG_AB_SUBMENUBACKGROUND, null, null, null, null, Theme.key_actionBarDefaultSubmenuBackground), new ThemeDescription(((BaseFragment) this).actionBar, ThemeDescription.FLAG_AB_SUBMENUITEM, null, null, null, null, Theme.key_actionBarDefaultSubmenuItem), new ThemeDescription(this.listView, ThemeDescription.FLAG_SELECTOR, null, null, null, null, Theme.key_listSelector), new ThemeDescription(this.listView, 0, new Class[]{View.class}, Theme.dividerPaint, null, null, Theme.key_divider), new ThemeDescription(this.listView, ThemeDescription.FLAG_BACKGROUNDFILTER, new Class[]{ShadowSectionCell.class}, null, null, null, Theme.key_windowBackgroundGrayShadow), new ThemeDescription((View) this.listView, 0, new Class[]{TextSettingsCell.class}, new String[]{"textView"}, (Paint[]) null, (Drawable[]) null, (ThemeDescription.ThemeDescriptionDelegate) null, i3), new ThemeDescription((View) this.listView, 0, new Class[]{TextSettingsCell.class}, new String[]{"valueTextView"}, (Paint[]) null, (Drawable[]) null, (ThemeDescription.ThemeDescriptionDelegate) null, Theme.key_windowBackgroundWhiteValueText), new ThemeDescription((View) this.listView, 0, new Class[]{TextCheckCell.class}, new String[]{"textView"}, (Paint[]) null, (Drawable[]) null, (ThemeDescription.ThemeDescriptionDelegate) null, i3), new ThemeDescription((View) this.listView, 0, new Class[]{TextCheckCell.class}, new String[]{"valueTextView"}, (Paint[]) null, (Drawable[]) null, (ThemeDescription.ThemeDescriptionDelegate) null, i4), new ThemeDescription((View) this.listView, 0, new Class[]{TextCheckCell.class}, new String[]{"checkBox"}, (Paint[]) null, (Drawable[]) null, (ThemeDescription.ThemeDescriptionDelegate) null, Theme.key_switchTrack), new ThemeDescription((View) this.listView, 0, new Class[]{TextCheckCell.class}, new String[]{"checkBox"}, (Paint[]) null, (Drawable[]) null, (ThemeDescription.ThemeDescriptionDelegate) null, Theme.key_switchTrackChecked), new ThemeDescription((View) this.listView, 0, new Class[]{HeaderCell.class}, new String[]{"textView"}, (Paint[]) null, (Drawable[]) null, (ThemeDescription.ThemeDescriptionDelegate) null, Theme.key_windowBackgroundWhiteBlueHeader), new ThemeDescription((View) this.listView, 0, new Class[]{TextDetailSettingsCell.class}, new String[]{"textView"}, (Paint[]) null, (Drawable[]) null, (ThemeDescription.ThemeDescriptionDelegate) null, i3), new ThemeDescription((View) this.listView, 0, new Class[]{TextDetailSettingsCell.class}, new String[]{"valueTextView"}, (Paint[]) null, (Drawable[]) null, (ThemeDescription.ThemeDescriptionDelegate) null, i4), new ThemeDescription((View) this.listView, 0, new Class[]{TextInfoCell.class}, new String[]{"textView"}, (Paint[]) null, (Drawable[]) null, (ThemeDescription.ThemeDescriptionDelegate) null, Theme.key_windowBackgroundWhiteGrayText5), new ThemeDescription(null, 0, null, null, null, null, Theme.key_dialogBackground), new ThemeDescription(null, 0, null, null, null, null, Theme.key_dialogBackgroundGray), new ThemeDescription(null, 0, null, null, null, null, Theme.key_dialogTextBlack), new ThemeDescription(null, 0, null, null, null, null, Theme.key_dialogTextLink), new ThemeDescription(null, 0, null, null, null, null, Theme.key_dialogLinkSelection), new ThemeDescription(null, 0, null, null, null, null, Theme.key_dialogTextBlue), new ThemeDescription(null, 0, null, null, null, null, Theme.key_dialogTextBlue2), new ThemeDescription(null, 0, null, null, null, null, Theme.key_dialogTextBlue4), new ThemeDescription(null, 0, null, null, null, null, Theme.key_text_RedBold), new ThemeDescription(null, 0, null, null, null, null, Theme.key_dialogTextGray), new ThemeDescription(null, 0, null, null, null, null, Theme.key_dialogTextGray2), new ThemeDescription(null, 0, null, null, null, null, Theme.key_dialogTextGray3), new ThemeDescription(null, 0, null, null, null, null, Theme.key_dialogTextGray4), new ThemeDescription(null, 0, null, null, null, null, Theme.key_dialogIcon), new ThemeDescription(null, 0, null, null, null, null, Theme.key_dialogTextHint), new ThemeDescription(null, 0, null, null, null, null, Theme.key_dialogInputField), new ThemeDescription(null, 0, null, null, null, null, Theme.key_dialogInputFieldActivated), new ThemeDescription(null, 0, null, null, null, null, Theme.key_dialogCheckboxSquareBackground), new ThemeDescription(null, 0, null, null, null, null, Theme.key_dialogCheckboxSquareCheck), new ThemeDescription(null, 0, null, null, null, null, Theme.key_dialogCheckboxSquareUnchecked), new ThemeDescription(null, 0, null, null, null, null, Theme.key_dialogCheckboxSquareDisabled), new ThemeDescription(null, 0, null, null, null, null, Theme.key_dialogRadioBackground), new ThemeDescription(null, 0, null, null, null, null, Theme.key_dialogRadioBackgroundChecked), new ThemeDescription(null, 0, null, null, null, null, Theme.key_dialogButton), new ThemeDescription(null, 0, null, null, null, null, Theme.key_dialogButtonSelector), new ThemeDescription(null, 0, null, null, null, null, Theme.key_dialogScrollGlow), new ThemeDescription(null, 0, null, null, null, null, Theme.key_dialogRoundCheckBox), new ThemeDescription(null, 0, null, null, null, null, Theme.key_dialogRoundCheckBoxCheck), new ThemeDescription(null, 0, null, null, null, null, Theme.key_dialogLineProgress), new ThemeDescription(null, 0, null, null, null, null, Theme.key_dialogLineProgressBackground), new ThemeDescription(null, 0, null, null, null, null, Theme.key_dialogGrayLine)));
    }

    public static class saveSettingsAsyncTask extends AsyncTask<String, Void, String> {
        public SaveAsyncTaskDelegate delegate;

        public interface SaveAsyncTaskDelegate {
            void onSaved(String path);
        }

        public saveSettingsAsyncTask(SaveAsyncTaskDelegate delegate) {
            this.delegate = delegate;
        }

        @Override
        public String doInBackground(String... name) {
            String str;
            String str2;
            String str3 = PlusSettings.usePlusFolder() ? "/Plus" : "/Telegram";
            Utilities.savePreferencesToSD(str3, "plusconfig.xml", name[0] + ".xml", false);
            Utilities.savePreferencesToSD(str3, "theme.xml", name[0] + "_theme.xml", false);
            Utilities.saveDBToCache("plus", "plus");
            Utilities.saveDBToCache("plus-shm", "plus1");
            Utilities.saveDBToCache("plus-wal", "plus2");
            Utilities.savePreferencesToCache("plusconfig.xml", "plusconfig");
            Utilities.savePreferencesToCache("theme.xml", "theme");
            int i = UserConfig.selectedAccount;
            if (i == 0) {
                str = "categories";
            } else {
                str = "categories" + i;
            }
            int savePreferencesToCache = Utilities.savePreferencesToCache(str + ".xml", "categories");
            int i2 = savePreferencesToCache == 4 ? 5 : 4;
            if (i == 0) {
                str2 = "mark";
            } else {
                str2 = "mark" + i;
            }
            int savePreferencesToCache2 = Utilities.savePreferencesToCache(str2 + ".xml", "mark");
            if (savePreferencesToCache2 == 4) {
                i2++;
            }
            String telegramPath = ImageLoader.getInstance().getTelegramPath();
            if (telegramPath.endsWith(str3)) {
                telegramPath = telegramPath.replace(str3, "");
            }
            File file = new File(telegramPath, str3);
            String[] strArr = new String[i2];
            String absolutePath = ApplicationLoader.applicationContext.getCacheDir().getAbsolutePath();
            strArr[0] = absolutePath + "/plus";
            strArr[1] = absolutePath + "/plus1";
            strArr[2] = absolutePath + "/plus2";
            strArr[3] = absolutePath + "/plusconfig";
            strArr[4] = absolutePath + "/theme";
            if (savePreferencesToCache == 4) {
                strArr[4] = absolutePath + "/categories";
            }
            if (savePreferencesToCache2 == 4) {
                strArr[i2 - 1] = absolutePath + "/mark";
            }
            new PlusUtils.ZipManager().zip(strArr, file.getPath() + "/" + name[0] + ".data");
            return file.getAbsolutePath();
        }

        @Override
        public void onPostExecute(String path) {
            SaveAsyncTaskDelegate saveAsyncTaskDelegate = this.delegate;
            if (saveAsyncTaskDelegate != null) {
                saveAsyncTaskDelegate.onSaved(path);
            }
        }
    }

    public class ListAdapter extends RecyclerListView.SelectionAdapter implements Filterable {
        public Context mContext;

        @Override
        public Filter getFilter() {
            return null;
        }

        public ListAdapter(Context context) {
            this.mContext = context;
        }

        public int getItemCount() {
            return PlusSettingsActivity.this.rowCount;
        }

        public void onBindViewHolder(RecyclerView.ViewHolder holder, int position) {
            String str;
            String string;
            String string2;
            String string3;
            String string4;
            String string5;
            int i;
            String str2;
            boolean z;
            boolean z2;
            boolean z3;
            boolean z4;
            String str3;
            String str4;
            str = "";
            String prefix = PlusSettingsActivity.this.showPrefix ? PlusSettingsActivity.this.getPrefix(position) : "";
            int itemViewType = holder.getItemViewType();
            if (itemViewType == 1) {
                if (position == PlusSettingsActivity.this.settingsSectionRow2) {
                    ((HeaderCell) holder.itemView).setText(prefix + LocaleController.getString("General", R.string.General));
                    return;
                }
                if (position == PlusSettingsActivity.this.storiesSectionRow2) {
                    ((HeaderCell) holder.itemView).setText(prefix + LocaleController.getString("FilterStories", R.string.FilterStories));
                    return;
                }
                if (position == PlusSettingsActivity.this.messagesSectionRow2) {
                    ((HeaderCell) holder.itemView).setText(prefix + LocaleController.getString("MessagesSettings", R.string.MessagesSettings));
                    return;
                }
                if (position == PlusSettingsActivity.this.topicsSectionRow2) {
                    ((HeaderCell) holder.itemView).setText(prefix + LocaleController.getString("Topics", R.string.Topics));
                    return;
                }
                if (position == PlusSettingsActivity.this.profileSectionRow2) {
                    ((HeaderCell) holder.itemView).setText(prefix + LocaleController.getString("ProfileScreen", R.string.ProfileScreen));
                    return;
                }
                if (position == PlusSettingsActivity.this.drawerSectionRow2) {
                    ((HeaderCell) holder.itemView).setText(prefix + LocaleController.getString("NavigationDrawer", R.string.NavigationDrawer));
                    return;
                }
                if (position == PlusSettingsActivity.this.privacySectionRow2) {
                    ((HeaderCell) holder.itemView).setText(prefix + LocaleController.getString("PrivacySettings", R.string.PrivacySettings));
                    return;
                }
                if (position == PlusSettingsActivity.this.mediaDownloadSection2) {
                    ((HeaderCell) holder.itemView).setText(prefix + LocaleController.getString("SharedMedia", R.string.SharedMedia));
                    return;
                }
                if (position == PlusSettingsActivity.this.downloadsSectionRow2) {
                    ((HeaderCell) holder.itemView).setText(prefix + LocaleController.getString("Downloads", R.string.Downloads));
                    return;
                }
                if (position == PlusSettingsActivity.this.dialogsSectionRow2) {
                    ((HeaderCell) holder.itemView).setText(prefix + LocaleController.getString("DialogsSettings", R.string.DialogsSettings));
                    return;
                }
                if (position == PlusSettingsActivity.this.notificationSection2Row) {
                    ((HeaderCell) holder.itemView).setText(prefix + LocaleController.getString("Notifications", R.string.Notifications));
                    return;
                }
                if (position == PlusSettingsActivity.this.toastNotificationSection2Row) {
                    ((HeaderCell) holder.itemView).setText(LocaleController.getString("ToastNotification", R.string.ToastNotification));
                    return;
                } else if (position == PlusSettingsActivity.this.plusSettingsSectionRow2) {
                    ((HeaderCell) holder.itemView).setText(LocaleController.getString("PlusSettings", R.string.PlusSettings));
                    return;
                } else {
                    if (position == PlusSettingsActivity.this.hiddenDialogsSectionRow2) {
                        ((HeaderCell) holder.itemView).setText(LocaleController.getString("HiddenChats", R.string.HiddenChats));
                        return;
                    }
                    return;
                }
            }
            if (itemViewType == 2) {
                TextSettingsCell textSettingsCell = (TextSettingsCell) holder.itemView;
                SharedPreferences sharedPreferences = ApplicationLoader.applicationContext.getSharedPreferences("plusconfig", 0);
                if (position == PlusSettingsActivity.this.emojiPopupSize) {
                    textSettingsCell.setTag("emojiPopupSize");
                    textSettingsCell.setTextAndValue(prefix + LocaleController.getString("EmojiPopupSize", R.string.EmojiPopupSize), String.format("%d", Integer.valueOf(sharedPreferences.getInt("emojiPopupSize", AndroidUtilities.isTablet() ? 65 : 60))), true);
                    return;
                }
                if (position == PlusSettingsActivity.this.chatStickerCellRow) {
                    textSettingsCell.setTag("stickerSize");
                    textSettingsCell.setTextAndValue(prefix + LocaleController.getString("StickerSize", R.string.StickerSize), String.format("%d", Integer.valueOf((int) PlusSettings.stickerSize)), true);
                    return;
                }
                if (position == PlusSettingsActivity.this.chatPhotoQualityRow) {
                    textSettingsCell.setTag("photoQuality");
                    textSettingsCell.setTextAndValue(prefix + LocaleController.getString("PhotoQuality", R.string.PhotoQuality), String.format("%d", Integer.valueOf(Theme.plusPhotoQuality)), true);
                    return;
                }
                if (position == PlusSettingsActivity.this.dialogsTabsTextSizeRow) {
                    textSettingsCell.setTag("tabsTextSize");
                    textSettingsCell.setTextAndValue(prefix + LocaleController.getString("TabsTextSize", R.string.TabsTextSize), String.format("%d", Integer.valueOf(Theme.plusTabsTextSize)), true);
                    return;
                }
                if (position == PlusSettingsActivity.this.dialogsTabsSwipeSensitivityRow) {
                    textSettingsCell.setTag("tabsSwipeSensitivity");
                    textSettingsCell.setTextAndValue(prefix + LocaleController.getString("TabsSwipeSensitivity", R.string.TabsSwipeSensitivity), String.format("%d", Integer.valueOf(PlusSettings.tabsSwipeSensitivity)), true);
                    textSettingsCell.setMultilineText();
                    return;
                }
                if (position == PlusSettingsActivity.this.dialogsTabsHeightRow) {
                    textSettingsCell.setTag("tabsHeight");
                    textSettingsCell.setTextAndValue(prefix + LocaleController.getString("TabsHeight", R.string.TabsHeight), String.format("%d", Integer.valueOf(Theme.plusTabsHeight)), true);
                    return;
                }
                if (position == PlusSettingsActivity.this.chatChangeTranslateLanguageRow) {
                    textSettingsCell.setTag("changeTranslateLanguage");
                    textSettingsCell.setTextAndValue(prefix + LocaleController.getString("ChangeTranslationLanguage", R.string.ChangeTranslationLanguage), PlusSettings.translationLanguage, true);
                    textSettingsCell.setMultilineText();
                    return;
                }
                if (position == PlusSettingsActivity.this.chatTranslationProviderRow) {
                    textSettingsCell.setTag("translationProvider");
                    if (PlusSettings.translationProvider == 0) {
                        i = R.string.ProviderGoogleTranslate;
                        str2 = "ProviderGoogleTranslate";
                    } else {
                        i = R.string.ProviderYandex;
                        str2 = "ProviderYandex";
                    }
                    textSettingsCell.setTextAndValue(prefix + LocaleController.getString("TranslationProvider", R.string.TranslationProvider), LocaleController.getString(str2, i).split(" ")[0], true);
                    textSettingsCell.setMultilineText();
                    return;
                }
                if (position == PlusSettingsActivity.this.chatSelectTapAvatarActionRow) {
                    textSettingsCell.setTag("tapAvatarAction");
                    textSettingsCell.setTextAndValue(prefix + LocaleController.getString("TapAvatarAction", R.string.TapAvatarAction), PlusSettings.tapAvatarActionList[PlusSettings.tapAvatarAction].toString(), true);
                    textSettingsCell.setMultilineText();
                    return;
                }
                if (position == PlusSettingsActivity.this.chatSelectTapAndHoldAvatarActionRow) {
                    textSettingsCell.setTag("tapAndHoldAvatarAction");
                    textSettingsCell.setTextAndValue(prefix + LocaleController.getString("TapAndHoldAvatarAction", R.string.TapAndHoldAvatarAction), PlusSettings.tapAndHoldAvatarActionList[PlusSettings.tapAndHoldAvatarAction].toString(), true);
                    textSettingsCell.setMultilineText();
                    return;
                }
                if (position == PlusSettingsActivity.this.chatSelectDoubleTapActionRow) {
                    textSettingsCell.setTag("doubleTapAction");
                    String charSequence = PlusSettings.doubleTapActionList[PlusSettings.doubleTapAction].toString();
                    if (PlusSettings.doubleTapActionOut != PlusSettings.doubleTapAction) {
                        if (charSequence.length() != 0) {
                            charSequence = charSequence + ", ";
                        }
                        charSequence = charSequence + PlusSettings.doubleTapActionList[PlusSettings.doubleTapActionOut].toString();
                    }
                    textSettingsCell.setTextAndValue(prefix + LocaleController.getString("SelectDoubleTapAction", R.string.SelectDoubleTapAction), charSequence, true);
                    textSettingsCell.setMultilineText();
                    return;
                }
                if (position == PlusSettingsActivity.this.chatSwipeLeftActionRow) {
                    textSettingsCell.setTag("swipeLeftAction");
                    String charSequence2 = PlusSettings.swipeLeftActionList[PlusSettings.swipeLeftAction].toString();
                    if (PlusSettings.swipeLeftActionOut != PlusSettings.swipeLeftAction) {
                        if (charSequence2.length() != 0) {
                            charSequence2 = charSequence2 + ", ";
                        }
                        charSequence2 = charSequence2 + PlusSettings.swipeLeftActionList[PlusSettings.swipeLeftActionOut].toString();
                    }
                    textSettingsCell.setTextAndValue(prefix + LocaleController.getString("SwipeLeftAction", R.string.SwipeLeftAction), charSequence2, true);
                    textSettingsCell.setMultilineText();
                    return;
                }
                if (position == PlusSettingsActivity.this.chatSwipeRightActionRow) {
                    textSettingsCell.setTag("swipeRightAction");
                    String charSequence3 = PlusSettings.swipeRightActionList[PlusSettings.swipeRightAction].toString();
                    if (PlusSettings.swipeRightActionOut != PlusSettings.swipeRightAction) {
                        if (charSequence3.length() != 0) {
                            charSequence3 = charSequence3 + ", ";
                        }
                        charSequence3 = charSequence3 + PlusSettings.swipeRightActionList[PlusSettings.swipeRightActionOut].toString();
                    }
                    textSettingsCell.setTextAndValue(prefix + LocaleController.getString("SwipeRightAction", R.string.SwipeRightAction), charSequence3, true);
                    textSettingsCell.setMultilineText();
                    return;
                }
                if (position == PlusSettingsActivity.this.chatDirectShareButtonActionRow) {
                    textSettingsCell.setTag("directShareButtonAction");
                    String charSequence4 = PlusSettings.directShareButtonActionList[PlusSettings.directShareButtonAction].toString();
                    if (PlusSettings.directShareButtonLongClickAction != PlusSettings.directShareButtonAction) {
                        if (charSequence4.length() != 0) {
                            charSequence4 = charSequence4 + ", ";
                        }
                        charSequence4 = charSequence4 + PlusSettings.directShareButtonActionList[PlusSettings.directShareButtonLongClickAction].toString();
                    }
                    textSettingsCell.setTextAndValue(prefix + LocaleController.getString("SelectDirectShareButtonAction", R.string.SelectDirectShareButtonAction), charSequence4, true);
                    textSettingsCell.setMultilineText();
                    return;
                }
                if (position == PlusSettingsActivity.this.updateAppMethodRow) {
                    textSettingsCell.setTag("updateAppMethod");
                    int intValue = PlusSettings.updateAppMethod.intValue();
                    if (intValue == 0) {
                        string5 = LocaleController.getString("AlwaysShowPopup", R.string.AlwaysShowPopup);
                    } else if (intValue == 1) {
                        string5 = LocaleController.getString("WhenConnectedOnWiFi", R.string.WhenConnectedOnWiFi);
                    } else {
                        string5 = LocaleController.getString("NeverAllow", R.string.NeverAllow);
                    }
                    textSettingsCell.setTextAndValue(prefix + LocaleController.getString("DebugMenuCheckAppUpdate", R.string.DebugMenuCheckAppUpdate), string5, true);
                    textSettingsCell.setMultilineText();
                    return;
                }
                if (position == PlusSettingsActivity.this.dialogsPicClickRow) {
                    textSettingsCell.setTag("dialogsClickOnPic");
                    int i2 = PlusSettings.dialogsClickOnPic;
                    if (i2 == 0) {
                        string4 = LocaleController.getString("RowGradientDisabled", R.string.RowGradientDisabled);
                    } else if (i2 == 1) {
                        string4 = LocaleController.getString("ShowPics", R.string.ShowPics);
                    } else {
                        string4 = LocaleController.getString("ShowProfile", R.string.ShowProfile);
                    }
                    textSettingsCell.setTextAndValue(prefix + LocaleController.getString("ClickOnContactPic", R.string.ClickOnContactPic), string4, true);
                    textSettingsCell.setMultilineText();
                    return;
                }
                if (position == PlusSettingsActivity.this.dialogsGroupPicClickRow) {
                    textSettingsCell.setTag("dialogsClickOnGroupPic");
                    int i3 = PlusSettings.dialogsClickOnGroupPic;
                    if (i3 == 0) {
                        string3 = LocaleController.getString("RowGradientDisabled", R.string.RowGradientDisabled);
                    } else if (i3 == 1) {
                        string3 = LocaleController.getString("ShowPics", R.string.ShowPics);
                    } else {
                        string3 = LocaleController.getString("ShowProfile", R.string.ShowProfile);
                    }
                    textSettingsCell.setTextAndValue(prefix + LocaleController.getString("ClickOnGroupPic", R.string.ClickOnGroupPic), string3, true);
                    textSettingsCell.setMultilineText();
                    return;
                }
                if (position == PlusSettingsActivity.this.toastNotificationSizeRow) {
                    textSettingsCell.setTag("toastNotificationSize");
                    textSettingsCell.setTextAndValue(prefix + LocaleController.getString("ToastNotificationSize", R.string.ToastNotificationSize), String.format("%d", Integer.valueOf(Theme.plusToastNotificationSize)), true);
                    return;
                }
                if (position == PlusSettingsActivity.this.downloadsSimultaneousDownloadsRow) {
                    textSettingsCell.setTag("simultaneousDownloads");
                    textSettingsCell.setTextAndValue(prefix + LocaleController.getString("SimultaneousDownloads", R.string.SimultaneousDownloads), String.format("%d", Integer.valueOf(PlusSettings.simultaneousDownloads)), true);
                    return;
                }
                if (position == PlusSettingsActivity.this.downloadsSpeedBoostRow) {
                    textSettingsCell.setTag("downloadSpeedBoost");
                    int i4 = PlusSettings.downloadSpeedBoost;
                    if (i4 == 0) {
                        string2 = LocaleController.getString("DownloadSpeedBoostNone", R.string.DownloadSpeedBoostNone);
                    } else if (i4 == 1) {
                        string2 = LocaleController.getString("DownloadSpeedBoostFast", R.string.DownloadSpeedBoostFast);
                    } else {
                        string2 = LocaleController.getString("DownloadSpeedBoostExtreme", R.string.DownloadSpeedBoostExtreme);
                    }
                    textSettingsCell.setTextAndValue(prefix + LocaleController.getString("DownloadSpeedBoost", R.string.DownloadSpeedBoost), string2, true);
                    textSettingsCell.setMultilineText();
                    return;
                }
                if (position == PlusSettingsActivity.this.toastNotificationPaddingRow) {
                    textSettingsCell.setTag("toastNotificationPadding");
                    textSettingsCell.setTextAndValue(prefix + LocaleController.getString("ToastNotificationPadding", R.string.ToastNotificationPadding), String.format("%d", Integer.valueOf(Theme.plusToastNotificationPadding)), true);
                    return;
                }
                if (position == PlusSettingsActivity.this.toastNotificationPositionRow) {
                    textSettingsCell.setTag("toastNotificationPosition");
                    int i5 = Theme.plusToastNotificationPosition;
                    if (i5 == 0) {
                        string = LocaleController.getString("Left", R.string.Left);
                    } else if (i5 == 1) {
                        string = LocaleController.getString("Center", R.string.Center);
                    } else {
                        string = LocaleController.getString("Right", R.string.Right);
                    }
                    textSettingsCell.setTextAndValue(prefix + LocaleController.getString("ToastNotificationPosition", R.string.ToastNotificationPosition), string, true);
                    return;
                }
                if (position == PlusSettingsActivity.this.chatsToLoadRow) {
                    textSettingsCell.setTag("chatsToLoad");
                    String str5 = prefix + "Chats to load";
                    int i6 = sharedPreferences.getInt("chatsToLoad", 100);
                    if (i6 == 50) {
                        textSettingsCell.setTextAndValue(str5, "50", true);
                        return;
                    }
                    if (i6 == 100) {
                        textSettingsCell.setTextAndValue(str5, "100", true);
                        return;
                    }
                    if (i6 == 200) {
                        textSettingsCell.setTextAndValue(str5, "200", true);
                        return;
                    }
                    if (i6 == 300) {
                        textSettingsCell.setTextAndValue(str5, "300", true);
                        return;
                    }
                    if (i6 == 400) {
                        textSettingsCell.setTextAndValue(str5, "400", true);
                        return;
                    }
                    if (i6 == 500) {
                        textSettingsCell.setTextAndValue(str5, "500", true);
                        return;
                    }
                    if (i6 == 750) {
                        textSettingsCell.setTextAndValue(str5, "750", true);
                        return;
                    }
                    if (i6 == 1000) {
                        textSettingsCell.setTextAndValue(str5, "1000", true);
                        return;
                    }
                    if (i6 == 1500) {
                        textSettingsCell.setTextAndValue(str5, "1500", true);
                        return;
                    } else if (i6 == 2000) {
                        textSettingsCell.setTextAndValue(str5, "2000", true);
                        return;
                    } else {
                        if (i6 == 1000000) {
                            textSettingsCell.setTextAndValue(str5, "All", true);
                            return;
                        }
                        return;
                    }
                }
                if (position == PlusSettingsActivity.this.dialogsManageTabsRow) {
                    textSettingsCell.setTag("dialogsManageTabs");
                    textSettingsCell.setText(prefix + LocaleController.getString("SortTabs", R.string.SortTabs), true);
                    return;
                }
                if (position == PlusSettingsActivity.this.drawerShowOptionsRow) {
                    textSettingsCell.setTag("drawerShowOptions");
                    textSettingsCell.setText(prefix + LocaleController.getString("ShowMenuOptions", R.string.ShowMenuOptions), true);
                    return;
                }
                if (position == PlusSettingsActivity.this.drawerShowPlusOptionsRow) {
                    textSettingsCell.setTag("drawerShowPlusOptions");
                    textSettingsCell.setText(prefix + LocaleController.getString("ShowMenuPlusOptions", R.string.ShowMenuPlusOptions), true);
                    return;
                }
                if (position == PlusSettingsActivity.this.changeHiddenDialogsPasswordRow) {
                    textSettingsCell.setTag("changeHiddenDialogsPassword");
                    textSettingsCell.setText(prefix + LocaleController.getString("ChangePasscode", R.string.ChangePasscode), true);
                    return;
                }
                return;
            }
            if (itemViewType != 3) {
                if (itemViewType != 6) {
                    if (itemViewType != 7) {
                        return;
                    }
                    TextInfoPrivacyCell textInfoPrivacyCell = (TextInfoPrivacyCell) holder.itemView;
                    if (position == PlusSettingsActivity.this.keepOriginalFilenameDetailRow) {
                        textInfoPrivacyCell.setText(LocaleController.getString("KeepOriginalFilenameHelp", R.string.KeepOriginalFilenameHelp));
                    } else if (position == PlusSettingsActivity.this.showOnlineToastNotificationDetailRow) {
                        textInfoPrivacyCell.setText(LocaleController.getString("OnlineToastHelp", R.string.OnlineToastHelp));
                    } else if (position == PlusSettingsActivity.this.dialogsShowAllInAdminTabDetailRow) {
                        textInfoPrivacyCell.setText(LocaleController.getString("ShowAllInAdminTabHelp", R.string.ShowAllInAdminTabHelp));
                    }
                    if (position == PlusSettingsActivity.this.hiddenDialogsInfoSectionRow) {
                        textInfoPrivacyCell.setText(LocaleController.getString("HiddenChatsInfo", R.string.HiddenChatsInfo));
                        return;
                    }
                    return;
                }
                TextDetailSettingsCell textDetailSettingsCell = (TextDetailSettingsCell) holder.itemView;
                if (position == PlusSettingsActivity.this.dialogsTabsRow) {
                    textDetailSettingsCell.setTag("dialogsTabs");
                    String str6 = prefix + LocaleController.getString("HideShowTabs", R.string.HideShowTabs);
                    if (Theme.plusHideAllTab) {
                        str4 = "";
                    } else {
                        str4 = "" + LocaleController.getString("All", R.string.All);
                    }
                    if (!Theme.plusHideUsersTab) {
                        if (str4.length() != 0) {
                            str4 = str4 + ", ";
                        }
                        str4 = str4 + LocaleController.getString("Users", R.string.Users);
                    }
                    if (!Theme.plusHideGroupsTab) {
                        if (str4.length() != 0) {
                            str4 = str4 + ", ";
                        }
                        str4 = str4 + LocaleController.getString("Groups", R.string.Groups);
                    }
                    if (!Theme.plusHideSuperGroupsTab) {
                        if (str4.length() != 0) {
                            str4 = str4 + ", ";
                        }
                        str4 = str4 + LocaleController.getString("SuperGroups", R.string.SuperGroups);
                    }
                    if (!Theme.plusHideChannelsTab) {
                        if (str4.length() != 0) {
                            str4 = str4 + ", ";
                        }
                        str4 = str4 + LocaleController.getString("Channels", R.string.Channels);
                    }
                    if (!Theme.plusHideBotsTab) {
                        if (str4.length() != 0) {
                            str4 = str4 + ", ";
                        }
                        str4 = str4 + LocaleController.getString("Bots", R.string.Bots);
                    }
                    if (!Theme.plusHideFavsTab) {
                        if (str4.length() != 0) {
                            str4 = str4 + ", ";
                        }
                        str4 = str4 + LocaleController.getString("Favorites", R.string.Favorites);
                    }
                    textDetailSettingsCell.setTextAndValue(str6, str4.length() != 0 ? str4 : "", true);
                    return;
                }
                if (position == PlusSettingsActivity.this.chatShowDirectShareBtnRow) {
                    textDetailSettingsCell.setTag("chatShowDirectShareBtn");
                    SharedPreferences sharedPreferences2 = ApplicationLoader.applicationContext.getSharedPreferences("plusconfig", 0);
                    boolean z5 = sharedPreferences2.getBoolean("showDSBtnUsers", false);
                    boolean z6 = sharedPreferences2.getBoolean("showDSBtnGroups", true);
                    boolean z7 = sharedPreferences2.getBoolean("showDSBtnSGroups", true);
                    boolean z8 = sharedPreferences2.getBoolean("showDSBtnChannels", true);
                    boolean z9 = sharedPreferences2.getBoolean("showDSBtnBots", true);
                    String str7 = prefix + LocaleController.getString("ShowDirectShareButton", R.string.ShowDirectShareButton);
                    if (z5) {
                        str = "" + LocaleController.getString("Users", R.string.Users);
                    }
                    if (z6) {
                        if (str.length() != 0) {
                            str = str + ", ";
                        }
                        str = str + LocaleController.getString("Groups", R.string.Groups);
                    }
                    if (z7) {
                        if (str.length() != 0) {
                            str = str + ", ";
                        }
                        str = str + LocaleController.getString("SuperGroups", R.string.SuperGroups);
                    }
                    if (z8) {
                        if (str.length() != 0) {
                            str = str + ", ";
                        }
                        str = str + LocaleController.getString("Channels", R.string.Channels);
                    }
                    if (z9) {
                        if (str.length() != 0) {
                            str = str + ", ";
                        }
                        str = str + LocaleController.getString("Bots", R.string.Bots);
                    }
                    if (str.length() == 0) {
                        str = LocaleController.getString("Channels", R.string.UsernameEmpty);
                    }
                    textDetailSettingsCell.setTextAndValue(str7, str, true);
                    return;
                }
                if (position == PlusSettingsActivity.this.profileSharedOptionsRow) {
                    textDetailSettingsCell.setTag("profileSharedOptions");
                    SharedPreferences sharedPreferences3 = ApplicationLoader.applicationContext.getSharedPreferences("plusconfig", 0);
                    boolean z10 = sharedPreferences3.getBoolean("hideSharedMedia", false);
                    boolean z11 = sharedPreferences3.getBoolean("hideSharedPhotos", false);
                    boolean z12 = sharedPreferences3.getBoolean("hideSharedVideos", false);
                    boolean z13 = sharedPreferences3.getBoolean("hideSharedGifs", false);
                    boolean z14 = sharedPreferences3.getBoolean("hideSharedFiles", false);
                    boolean z15 = sharedPreferences3.getBoolean("hideSharedMusic", false);
                    boolean z16 = sharedPreferences3.getBoolean("hideSharedAudios", false);
                    boolean z17 = sharedPreferences3.getBoolean("hideSharedLinks", false);
                    String str8 = prefix + LocaleController.getString("SharedMedia", R.string.SharedMedia);
                    if (z10) {
                        str3 = "";
                    } else {
                        str3 = "" + LocaleController.getString("SharedMediaTab2", R.string.SharedMediaTab2);
                    }
                    if (!z11) {
                        if (str3.length() != 0) {
                            str3 = str3 + ", ";
                        }
                        str3 = str3 + LocaleController.getString("LocalPhotoCache", R.string.LocalPhotoCache);
                    }
                    if (!z12) {
                        if (str3.length() != 0) {
                            str3 = str3 + ", ";
                        }
                        str3 = str3 + LocaleController.getString("LocalVideoCache", R.string.LocalVideoCache);
                    }
                    if (!z13) {
                        if (str3.length() != 0) {
                            str3 = str3 + ", ";
                        }
                        str3 = str3 + LocaleController.getString("Gifs", R.string.Gifs);
                    }
                    if (!z14) {
                        if (str3.length() != 0) {
                            str3 = str3 + ", ";
                        }
                        str3 = str3 + LocaleController.getString("DocumentsTitle", R.string.DocumentsTitle);
                    }
                    if (!z15) {
                        if (str3.length() != 0) {
                            str3 = str3 + ", ";
                        }
                        str3 = str3 + LocaleController.getString("AudioTitle", R.string.AudioTitle);
                    }
                    if (!z16) {
                        if (str3.length() != 0) {
                            str3 = str3 + ", ";
                        }
                        str3 = str3 + LocaleController.getString("AudioAutodownload", R.string.AudioAutodownload);
                    }
                    if (!z17) {
                        if (str3.length() != 0) {
                            str3 = str3 + ", ";
                        }
                        str3 = str3 + LocaleController.getString("LinksTitle", R.string.LinksTitle);
                    }
                    textDetailSettingsCell.setTextAndValue(str8, str3.length() != 0 ? str3 : "", true);
                    return;
                }
                if (position == PlusSettingsActivity.this.savePlusSettingsRow) {
                    textDetailSettingsCell.setMultilineDetail(true);
                    textDetailSettingsCell.setTextAndValue(LocaleController.getString("SaveSettings", R.string.SaveSettings), LocaleController.getString("SaveSettingsSum", R.string.SaveSettingsSum) + " (" + LocaleController.getString("AlsoFavorites", R.string.AlsoFavorites) + ")", true);
                    return;
                }
                if (position == PlusSettingsActivity.this.restorePlusSettingsRow) {
                    textDetailSettingsCell.setMultilineDetail(true);
                    textDetailSettingsCell.setTextAndValue(LocaleController.getString("RestoreSettings", R.string.RestoreSettings), LocaleController.getString("RestoreSettingsSum", R.string.RestoreSettingsSum), true);
                    return;
                }
                if (position == PlusSettingsActivity.this.resetPlusSettingsRow) {
                    textDetailSettingsCell.setMultilineDetail(true);
                    textDetailSettingsCell.setTextAndValue(LocaleController.getString("ResetSettings", R.string.ResetSettings), LocaleController.getString("ResetSettingsSum", R.string.ResetSettingsSum), false);
                    return;
                }
                if (position == PlusSettingsActivity.this.chatShowHideOptionsRow) {
                    textDetailSettingsCell.setTag("chatShowHideOptions");
                    if (!Theme.plusHideMsgDetailsOption) {
                        str = "" + LocaleController.getString("MessageDetails", R.string.MessageDetails);
                    }
                    if (Theme.plusDirectShareToMenu) {
                        if (str.length() != 0) {
                            str = str + ", ";
                        }
                        str = str + LocaleController.getString("DirectShare", R.string.DirectShare);
                    }
                    if (!Theme.plusHideSaveToCloudOption) {
                        if (str.length() != 0) {
                            str = str + ", ";
                        }
                        str = str + LocaleController.getString("SaveToCloud", R.string.SaveToCloud);
                    }
                    if (!PlusSettings.hideForwardOption) {
                        if (str.length() != 0) {
                            str = str + ", ";
                        }
                        str = str + LocaleController.getString("Forward", R.string.Forward);
                    }
                    if (!Theme.plusHideForwardNoQuoteOption) {
                        if (str.length() != 0) {
                            str = str + ", ";
                        }
                        str = str + LocaleController.getString("ForwardNoQuote", R.string.ForwardNoQuote);
                    }
                    if (!PlusSettings.hideEditOption) {
                        if (str.length() != 0) {
                            str = str + ", ";
                        }
                        str = str + LocaleController.getString("Edit", R.string.Edit);
                    }
                    if (!PlusSettings.hideTranslateOption) {
                        if (str.length() != 0) {
                            str = str + ", ";
                        }
                        str = str + LocaleController.getString("Translate", R.string.Translate);
                    }
                    if (!PlusSettings.hideMarkOption) {
                        if (str.length() != 0) {
                            str = str + ", ";
                        }
                        str = str + LocaleController.getString("MarkMessage", R.string.MarkMessage);
                    }
                    if (!PlusSettings.hideReplyOption) {
                        if (str.length() != 0) {
                            str = str + ", ";
                        }
                        str = str + LocaleController.getString("Reply", R.string.Reply);
                    }
                    if (!PlusSettings.hideReportOption) {
                        if (str.length() != 0) {
                            str = str + ", ";
                        }
                        str = str + LocaleController.getString("ReportChat", R.string.ReportChat);
                    }
                    if (!PlusSettings.hideReactions) {
                        if (str.length() != 0) {
                            str = str + ", ";
                        }
                        str = str + LocaleController.getString("Reactions", R.string.Reactions);
                    }
                    if (!PlusSettings.hideStickerSize) {
                        if (str.length() != 0) {
                            str = str + ", ";
                        }
                        str = str + LocaleController.getString("StickerSize", R.string.StickerSize);
                    }
                    if (!PlusSettings.hideScheduleDownloadOption) {
                        if (str.length() != 0) {
                            str = str + ", ";
                        }
                        str = str + LocaleController.getString("ScheduleDownload", R.string.ScheduleDownload);
                    }
                    if (!PlusSettings.hideAutoPlayGifs) {
                        if (str.length() != 0) {
                            str = str + ", ";
                        }
                        str = str + LocaleController.getString("AutoplayGifs", R.string.AutoplayGifs);
                    }
                    if (!PlusSettings.hideReplyPrivately) {
                        if (str.length() != 0) {
                            str = str + ", ";
                        }
                        str = str + LocaleController.getString("ReplyPrivately2", R.string.ReplyPrivately2);
                    }
                    if (!PlusSettings.hideViewStatistic) {
                        if (str.length() != 0) {
                            str = str + ", ";
                        }
                        str = str + LocaleController.getString("ViewMessageStatistic", R.string.ViewMessageStatistic);
                    }
                    if (str.length() == 0) {
                        str = LocaleController.getString("UsernameEmpty", R.string.UsernameEmpty);
                    }
                    textDetailSettingsCell.setTextAndValue(prefix + LocaleController.getString("ShowMenuOptions", R.string.ShowMenuOptions), str, true);
                    return;
                }
                if (position == PlusSettingsActivity.this.chatActionModeButtonsRow) {
                    textDetailSettingsCell.setTag("chatActionModeButtons");
                    if (!PlusSettings.hideDirectShareActionModeButton) {
                        str = "" + LocaleController.getString("DirectShare", R.string.DirectShare);
                    }
                    if (!PlusSettings.hideBackupActionModeButton) {
                        if (str.length() != 0) {
                            str = str + ", ";
                        }
                        str = str + LocaleController.getString("SaveToCloud", R.string.SaveToCloud);
                    }
                    if (!PlusSettings.hideForwardActionModeButton) {
                        if (str.length() != 0) {
                            str = str + ", ";
                        }
                        str = str + LocaleController.getString("Forward", R.string.Forward);
                    }
                    if (!PlusSettings.hideForwardWithoutQuotingActionModeButton) {
                        if (str.length() != 0) {
                            str = str + ", ";
                        }
                        str = str + LocaleController.getString("ForwardNoQuote", R.string.ForwardNoQuote);
                    }
                    if (!PlusSettings.hideEditActionModeButton) {
                        if (str.length() != 0) {
                            str = str + ", ";
                        }
                        str = str + LocaleController.getString("Edit", R.string.Edit);
                    }
                    if (!PlusSettings.hideCopyActionModeButton) {
                        if (str.length() != 0) {
                            str = str + ", ";
                        }
                        str = str + LocaleController.getString("Copy", R.string.Copy);
                    }
                    if (!PlusSettings.hideDeleteActionModeButton) {
                        if (str.length() != 0) {
                            str = str + ", ";
                        }
                        str = str + LocaleController.getString("Delete", R.string.Delete);
                    }
                    if (!PlusSettings.hideSelectMessagesActionModeButton) {
                        if (str.length() != 0) {
                            str = str + ", ";
                        }
                        str = str + LocaleController.getString("ReportSelectMessages", R.string.ReportSelectMessages);
                    }
                    if (!PlusSettings.hideAddTagsActionModeButton) {
                        if (str.length() != 0) {
                            str = str + ", ";
                        }
                        str = str + LocaleController.getString("AddTagsToYourSavedMessages1", R.string.AddTagsToYourSavedMessages1);
                    }
                    if (str.length() == 0) {
                        str = LocaleController.getString("UsernameEmpty", R.string.UsernameEmpty);
                    }
                    textDetailSettingsCell.setTextAndValue(prefix + LocaleController.getString("ActionModeButtons", R.string.ActionModeButtons), str, true);
                    return;
                }
                if (position == PlusSettingsActivity.this.selectStorageRow) {
                    textDetailSettingsCell.setTag("selectStorage");
                    textDetailSettingsCell.setTextAndValue(prefix + LocaleController.getString("SelectStorage", R.string.SelectStorage), PlusUtils.getStoragePath().getPath(), true);
                    textDetailSettingsCell.setMultilineDetail(true);
                    return;
                }
                if (position == PlusSettingsActivity.this.migrateFilesRow) {
                    textDetailSettingsCell.setTag("migrateFiles");
                    StringBuilder sb = new StringBuilder();
                    sb.append(LocaleController.getString("MigrateOldFolderButton", R.string.MigrateOldFolderButton));
                    if (PlusSettingsActivity.this.totalFilesCount > 0) {
                        str = " (" + PlusSettingsActivity.this.totalFilesCount + ")";
                    }
                    sb.append(str);
                    textDetailSettingsCell.setTextAndValue(sb.toString(), null, true);
                    textDetailSettingsCell.setMultilineDetail(true);
                    return;
                }
                return;
            }
            TextCheckCell textCheckCell = (TextCheckCell) holder.itemView;
            SharedPreferences sharedPreferences4 = ApplicationLoader.applicationContext.getSharedPreferences("plusconfig", 0);
            if (position == PlusSettingsActivity.this.disableAudioStopRow) {
                textCheckCell.setTag("disableAudioStop");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DisableAudioStop", R.string.DisableAudioStop), PlusSettings.disableAudioStop, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.showToastErrorsRow) {
                textCheckCell.setTag("showToastOnErrors");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowToastOnErrors", R.string.ShowToastOnErrors), PlusSettings.showToastOnErrors, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.disableMusicStopRow) {
                textCheckCell.setTag("disableMusicStop");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DoNoStopMusicWhenRecordingAudio", R.string.DoNoStopMusicWhenRecordingAudio), PlusSettings.disableMusicStop, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.disableMessageClickRow) {
                textCheckCell.setTag("disableMessageClick");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DisableMessageClick", R.string.DisableMessageClick), sharedPreferences4.getBoolean("disableMessageClick", false), true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatDirectShareReplies) {
                textCheckCell.setTag("directShareReplies");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DirectShareReplies", R.string.DirectShareReplies), sharedPreferences4.getBoolean("directShareReplies", false), true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatDirectShareFavsFirst) {
                textCheckCell.setTag("directShareFavsFirst");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DirectShareShowFavsFirst", R.string.DirectShareShowFavsFirst), sharedPreferences4.getBoolean("directShareFavsFirst", false), true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatShowEditedMarkRow) {
                textCheckCell.setTag("showEditedMark");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowEditedMark", R.string.ShowEditedMark), sharedPreferences4.getBoolean("showEditedMark", true), true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatShowDateToastRow) {
                textCheckCell.setTag("showDateToast");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowDateToast", R.string.ShowDateToast), sharedPreferences4.getBoolean("showDateToast", true), true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatHideLeftGroupRow) {
                textCheckCell.setTag("hideLeftGroup");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HideLeftGroup", R.string.HideLeftGroup), sharedPreferences4.getBoolean("hideLeftGroup", false), true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatHideJoinedGroupRow) {
                textCheckCell.setTag("hideJoinedGroup");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HideJoinedGroup", R.string.HideJoinedGroup), sharedPreferences4.getBoolean("hideJoinedGroup", false), true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatHideBotKeyboardRow) {
                textCheckCell.setTag("hideBotKeyboard");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HideBotKeyboard", R.string.HideBotKeyboard), PlusSettings.hideBotKeyboard, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatStartRoundVideoUsingMainCameraRow) {
                textCheckCell.setTag("startRoundVideoUsingMainCamera");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("StartRoundVideoUsingMainCamera", R.string.StartRoundVideoUsingMainCamera), Theme.plusStartRoundVideoUsingMainCamera, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatChangePlayerSpeedRangeRow) {
                textCheckCell.setTag("changePlayerSpeed");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ChangeAudioPlayerSpeedRange", R.string.ChangeAudioPlayerSpeedRange), Theme.plusChangePlayerSpeed, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatDeleteSharedMediaCaptionRow) {
                textCheckCell.setTag("deleteSharedMediaCaption");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DeleteSharedMediaCaption", R.string.DeleteSharedMediaCaption), PlusSettings.deleteSharedMediaCaption, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatShowDownloadProgressRow) {
                textCheckCell.setTag("showDownloadProgress");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowDownloadProgress", R.string.ShowDownloadProgress), Theme.plusShowDownloadProgress, true);
                return;
            }
            if (position == PlusSettingsActivity.this.chatMakeTitleScrollableRow) {
                textCheckCell.setTag("makeTitleScrollableRow");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("MakeTitleScrollable", R.string.MakeTitleScrollable), Theme.plusMakeTitleScrollable, true);
                return;
            }
            if (position == PlusSettingsActivity.this.chatDisableShortNumberFormatRow) {
                textCheckCell.setTag("disableShortNumberFormat");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DisableShortNumberFormat", R.string.DisableShortNumberFormat), Theme.plusDisableShortNumberFormat, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatEnableBlurInChatRow) {
                textCheckCell.setTag("forceEnableBlurInChat");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("EnableBlurInChat", R.string.EnableBlurInChat), PlusSettings.forceEnableBlurInChat, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatEnableReturnToMessageStackRow) {
                textCheckCell.setTag("enableReturnToMessageStack");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("EnableReturnToMessageStackInChat", R.string.EnableReturnToMessageStackInChat), PlusSettings.enableReturnToMessageStack, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatAddSecondsToTimeInChatRow) {
                textCheckCell.setTag("addSecondsToTime");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("AddSecondsToTimeInChat", R.string.AddSecondsToTimeInChat), PlusSettings.addSecondsToTime, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatHideReactionsButtonsInMessagesRow) {
                textCheckCell.setTag("hideReactionsButtonsInMessages");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HideReactionsButtonsInMessages", R.string.HideReactionsButtonsInMessages), PlusSettings.hideReactionsButtonsInMessages, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatShowAllRecentStickersRow) {
                textCheckCell.setTag("showAllRecentStickers");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowAllRecentStickers", R.string.ShowAllRecentStickers), PlusSettings.showAllRecentStickers, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatDisableLinkPreviewRow) {
                textCheckCell.setTag("disableLinkPreview");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DisableLinkPreview", R.string.DisableLinkPreview), PlusSettings.disableLinkPreview, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatHideTimeInStickersRow) {
                textCheckCell.setTag("hideTimeInStickers");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HideTimeInStickers", R.string.HideTimeInStickers), PlusSettings.hideTimeInStickers, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatIncreaseInstantVideoQualityRow) {
                textCheckCell.setTag("increaseInstantVideoQuality");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("IncreaseInstantVideoQuality", R.string.IncreaseInstantVideoQuality), PlusSettings.increaseInstantVideoQuality, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatConfirmAudioVideoBeforeSendingRow) {
                textCheckCell.setTag("confirmAudioVideoBeforeSending");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ConfirmAudioVideoBeforeSending", R.string.ConfirmAudioVideoBeforeSending), PlusSettings.confirmAudioVideoBeforeSending, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatHidePremiumEmojisTabsRow) {
                textCheckCell.setTag("hidePremiumEmojisTabs");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HidePremiumEmojisTabs", R.string.HidePremiumEmojisTabs), PlusSettings.hidePremiumEmojisTabs, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatHidePremiumStickersRow) {
                textCheckCell.setTag("hidePremiumStickers");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HidePremiumStickers", R.string.HidePremiumStickers), PlusSettings.hidePremiumStickers, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatForceSmallReactionsLayoutRow) {
                textCheckCell.setTag("forceSmallReactionsLayout");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ForceSmallReactionsLayout", R.string.ForceSmallReactionsLayout), PlusSettings.forceSmallReactionsLayout, false);
                textCheckCell.setMultilineText();
                textCheckCell.setEnabled(PlusSettingsActivity.this.disableForceSmallReactionsLayout ^ true, null);
                return;
            }
            if (position == PlusSettingsActivity.this.chatShowBackForwardMusicPlayerButtonsRow) {
                textCheckCell.setTag("showBackForwardAudioPlayerButtons");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowBackwardForwardAudioPlayerButtons", R.string.ShowBackwardForwardAudioPlayerButtons), PlusSettings.showBackForwardAudioPlayerButtons, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatCopyLinkOnLongClickRow) {
                textCheckCell.setTag("copyLinkOnLongClick");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("CopyLinkOnLongClick", R.string.CopyLinkOnLongClick), PlusSettings.copyLinkOnLongClick, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.topicsViewAllTopicsAsMessagesRow) {
                textCheckCell.setTag("viewAllTopicsAsMessages");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ViewAllTopicsAsMessages", R.string.ViewAllTopicsAsMessages), PlusSettings.viewAllTopicsAsMessages, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.topicsAllowPinTopicsRow) {
                textCheckCell.setTag("allowPinTopics");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("AllowPinUnpinTopics", R.string.AllowPinUnpinTopics), PlusSettings.allowPinTopics, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.topicsOpenTopicsAsNormalGroupsRow) {
                textCheckCell.setTag("openTopicsAsNormalGroups");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("OpenTopicsAsNormalGroups", R.string.OpenTopicsAsNormalGroups), PlusSettings.openTopicsAsNormalGroups, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.topicsShowOnlyGroupsWithTopicsRow) {
                textCheckCell.setTag("showOnlyGroupsWithTopics");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowOnlyGroupsWithTopics", R.string.ShowOnlyGroupsWithTopics), PlusSettings.showOnlyGroupsWithTopics, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.topicsDisableHideTopicOnSwipeRow) {
                textCheckCell.setTag("disableHideTopicOnSwipe");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DisableHideTopicOnSwipe", R.string.DisableHideTopicOnSwipe), PlusSettings.disableHideTopicOnSwipe, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.topicsSaveViewTopicsAsMessagesOptionRow) {
                textCheckCell.setTag("saveViewTopicsAsMessagesOption");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("SaveViewTopicsAsMessagesOption", R.string.SaveViewTopicsAsMessagesOption), PlusSettings.saveViewTopicsAsMessagesOption, false);
                textCheckCell.setMultilineText();
                textCheckCell.setDisabled(PlusSettings.viewAllTopicsAsMessages);
                return;
            }
            if (position == PlusSettingsActivity.this.chatEnableConfirmBeforeSendingRow) {
                textCheckCell.setTag("confirmBeforeSending");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("EnableConfirmBeforeSending", R.string.EnableConfirmBeforeSending), PlusSettings.confirmBeforeSending, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatHideChatGreetingRow) {
                textCheckCell.setTag("hideChatGreeting");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HideChatGreeting", R.string.HideChatGreeting), PlusSettings.hideChatGreeting, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatHideKeyboardOnScrollRow) {
                textCheckCell.setTag("HideKeyboardOnScroll");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HideKeyboardOnScroll", R.string.HideKeyboardOnScroll), PlusSettings.hideKeyboardOnScroll, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatDisableLoadingNextMediaRow) {
                textCheckCell.setTag("disableLoadingNextMedia");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DisableAutoDownloadNextMedia", R.string.DisableAutoDownloadNextMedia), PlusSettings.disableLoadingNextMedia, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatDoNotPlayNextMediaRow) {
                textCheckCell.setTag("dontPlayNextMedia");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DoNotPlayNextMedia", R.string.DoNotPlayNextMedia), PlusSettings.dontPlayNextMedia, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatHideSenderSelectorRow) {
                textCheckCell.setTag("hideSenderSelector");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HideSenderSelector", R.string.HideSenderSelector), PlusSettings.hideSenderSelector, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatAlwaysShowSpoilersRow) {
                textCheckCell.setTag("alwaysShowSpoilers");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("AlwaysShowSpoilers", R.string.AlwaysShowSpoilers), PlusSettings.alwaysShowSpoilers, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatAlwaysShowMediaSpoilersRow) {
                textCheckCell.setTag("alwaysShowMediaSpoilers");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("AlwaysShowMediaSpoilers", R.string.AlwaysShowMediaSpoilers), PlusSettings.alwaysShowMediaSpoilers, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatMarkdownParseLinksRow) {
                textCheckCell.setTag("markdownParseLinks");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("MarkdownParseLinks", R.string.MarkdownParseLinks), PlusSettings.markdownParseLinks, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatAddDateToForwardedMessagesRow) {
                textCheckCell.setTag("addDateToForwardedMessages");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("AddDateAndTimeToForwardedMessages", R.string.AddDateAndTimeToForwardedMessages), PlusSettings.addDateToForwardedMessages, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatImproveVoiceRecordingQualityRow) {
                textCheckCell.setTag("improveVoiceRecordingQuality");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ImproveVoiceRecordingQuality", R.string.ImproveVoiceRecordingQuality), PlusSettings.improveVoiceRecordingQuality, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatHideVoiceTranscriptionButtonRow) {
                textCheckCell.setTag("hideVoiceTranscriptionButton");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HideVoiceTranscriptionButton", R.string.HideVoiceTranscriptionButton), PlusSettings.hideVoiceTranscriptionButton, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatHideSlashBotButtonRow) {
                textCheckCell.setTag("hideSlashBotButton");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HideSlashBotButton", R.string.HideSlashBotButton), PlusSettings.hideSlashBotButton, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatDisableUsersThemeModificationsRow) {
                textCheckCell.setTag("disableUsersThemeModifications");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DisableUsersThemeModifications", R.string.DisableUsersThemeModifications), PlusSettings.disableUsersThemeModifications, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatShowUserStatusCircleOnlyIfOnlineRow) {
                textCheckCell.setTag("showUserStatusCircleInChatOnlyIfOnline");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowUserStatusCircleOnlyIfOnline", R.string.ShowUserStatusCircleOnlyIfOnline), PlusSettings.showUserStatusCircleInChatOnlyIfOnline, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsShowUserStatusCircleOnlyIfOnlineRow) {
                textCheckCell.setTag("showUserStatusCircleInMainOnlyIfOnline");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowUserStatusCircleOnlyIfOnline", R.string.ShowUserStatusCircleOnlyIfOnline), PlusSettings.showUserStatusCircleInMainOnlyIfOnline, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.hideStoriesRow) {
                textCheckCell.setTag("hideStories");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ArchivePeerStories", R.string.ArchivePeerStories), PlusSettings.hideStories, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.hideSeenStoriesRow) {
                textCheckCell.setTag("hideSeenStories");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HideSeenStories", R.string.HideSeenStories), PlusSettings.hideSeenStories.booleanValue(), true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.hideChannelsStoriesRow) {
                textCheckCell.setTag("hideChannelsStories");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HideChannelsStories", R.string.HideChannelsStories), PlusSettings.hideChannelsStories, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.doNotMarkStoriesAsReadRow) {
                textCheckCell.setTag("doNotMarkStoriesAsRead");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DoNotMarkStoriesAsRead", R.string.DoNotMarkStoriesAsRead), PlusSettings.doNotMarkStoriesAsRead, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.hideCreateStoryButtonRow) {
                textCheckCell.setTag("hideCreateStoryButton");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HideCreateStoryButton", R.string.HideCreateStoryButton), PlusSettings.hideCreateStoryButton, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatDisableReactionAnimationRow) {
                textCheckCell.setTag("disableReactionAnimation");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DisableReactionAnimation", R.string.DisableReactionAnimation), PlusSettings.disableReactionAnimation, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatEnableSwipeActionInChannelsRow) {
                textCheckCell.setTag("enableSwipeInChannels");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("EnableSwipeActionInChannels", R.string.EnableSwipeActionInChannels), PlusSettings.enableSwipeInChannels, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatDoNotShowDialogOnCacheDeletingRow) {
                textCheckCell.setTag("doNotShowDialogOnCacheDeleting");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DoNotShowDialogOnCacheDeleting", R.string.DoNotShowDialogOnCacheDeleting), PlusSettings.doNotShowDialogOnCacheDeleting, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatIgnoreBlockedUsersRow) {
                textCheckCell.setTag("ignoreBlocked");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("IgnoreBlockedUsers", R.string.IgnoreBlockedUsers), PlusSettings.ignoreBlocked.booleanValue(), true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatShowSendWithoutSoundButtonRow) {
                textCheckCell.setTag("showSendWithoutSound");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowSendWithoutSoundButton", R.string.ShowSendWithoutSoundButton), PlusSettings.showSendWithoutSound, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatHideBottomLayoutInChannelsRow) {
                textCheckCell.setTag("hideBottomLayoutInChannels");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HideBottomLayout", R.string.HideBottomLayout), Theme.plusHideBottomLayoutInChannels, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatDoNotHideSearchBottomRow) {
                textCheckCell.setTag("doNotHideSearchBottom");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DoNotHideSearchBottom", R.string.DoNotHideSearchBottom), Theme.plusDoNotHideSearchBottom, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatShowSearchIconRow) {
                textCheckCell.setTag("showSearchIcon");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowSearchIconInHeader", R.string.ShowSearchIconInHeader), PlusSettings.showSearchIcon, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.hideMsgDeletedHintRow) {
                textCheckCell.setTag("hideMsgDeletedHint");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HideMessageDeletedHint", R.string.HideMessageDeletedHint), PlusSettings.hideMsgDeletedHint, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatAddDateToEventRow) {
                textCheckCell.setTag("addDateToEventLogMessages");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("AddDateToEventLogMessages", R.string.AddDateToEventLogMessages), PlusSettings.addDateToEventLogMessages, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatDisableActionsVibrationsRow) {
                textCheckCell.setTag("disableActionsVibrations");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DisableVibrationInActions", R.string.DisableVibrationInActions), PlusSettings.disableActionsVibrations, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatAddTranslateToSendButtonRow) {
                textCheckCell.setTag("addTranslateToSendButton");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("AddTranslateToSendButton", R.string.AddTranslateToSendButton), PlusSettings.addTranslateToSendButton, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatShowAnimatedStickersFirstRow) {
                textCheckCell.setTag("showAnimatedStickersFirst");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowAnimatedStickersFirst", R.string.ShowAnimatedStickersFirst), PlusSettings.showAnimatedStickersFirst, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatDisableJumpingToNextChannelRow) {
                textCheckCell.setTag("disableJumpingToNextChannel");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DisableJumpingToNextChannel", R.string.DisableJumpingToNextChannel), PlusSettings.disableJumpingToNextChannel, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatDisableRestriction) {
                textCheckCell.setTag("disableRestriction");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DiscardRestriction", R.string.DiscardRestriction), Theme.plusDisableRestriction, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatHideImageSizeRow) {
                textCheckCell.setTag("hideImageSize");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HideImageSize", R.string.HideImageSize), PlusSettings.plusHideImageSize, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatHideSenderNameRow) {
                textCheckCell.setTag("hideSenderName");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HideSenderName", R.string.HideSenderName), PlusSettings.plusHideSenderName, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.keepOriginalFilenameRow) {
                textCheckCell.setTag("keepOriginalFilename");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("KeepOriginalFilename", R.string.KeepOriginalFilename), sharedPreferences4.getBoolean("keepOriginalFilename", false), false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.keepFilenameEqualRow) {
                textCheckCell.setTag("keepFilenameEqual");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("KeepFilenameIdentical", R.string.KeepFilenameIdentical), PlusSettings.keepFilenameEqual, false);
                textCheckCell.setMultilineText();
                textCheckCell.setDisabled(PlusSettings.keepOriginalFileName ^ true);
                return;
            }
            if (position == PlusSettingsActivity.this.usePlusFolderRow) {
                textCheckCell.setTag("usePlusFolder");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("UsePlusFolder", R.string.UsePlusFolder), PlusSettings.usePlusFolder(), false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.useExternalStorageRow) {
                textCheckCell.setTag("useExternalStorage");
                textCheckCell.setTextAndValueAndCheck(prefix + LocaleController.getString("UseExternalStorage", R.string.UseExternalStorage), ImageLoader.getInstance().getTelegramPath(), PlusSettings.useExternalStorage(), true, false);
                return;
            }
            if (position == PlusSettingsActivity.this.useTelegramDataPathRow) {
                textCheckCell.setTag("useTelegramDataPath");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("UseTelegramDataPath", R.string.UseTelegramDataPath), PlusSettings.useTelegramDataPath(), true);
                textCheckCell.setEnabled(PlusSettings.useExternalStorage() ^ true, null);
                return;
            }
            if (position == PlusSettingsActivity.this.addAppFolderToSaveToOptionRow) {
                textCheckCell.setTag("addAppFolderToSaveToOption");
                StringBuilder sb2 = new StringBuilder();
                sb2.append(prefix);
                int i7 = R.string.AddAppFolderToSaveToOption;
                Object[] objArr = new Object[1];
                objArr[0] = PlusSettings.usePlusFolder() ? "Plus" : "Telegram";
                sb2.append(LocaleController.formatString("AddAppFolderToSaveToOption", i7, objArr));
                textCheckCell.setTextAndCheck(sb2.toString(), PlusSettings.addAppFolderToSaveToOption, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.discardMediaTapRow) {
                textCheckCell.setTag("discardMediaTap");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DiscardMediaTap", R.string.DiscardMediaTap), PlusSettings.discardMediaTap, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.showFullScreenAvatarOnSingleTapRow) {
                textCheckCell.setTag("showFullScreenAvatarOnSingleTap");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowFullScreenAvatarOnSingleTap", R.string.ShowFullScreenAvatarOnSingleTap), PlusSettings.showFullScreenAvatarOnSingleTap, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.profileOpenProfilePicsInsteadOfStoriesRow) {
                textCheckCell.setTag("openProfilePicsInsteadOfStories");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("OpenProfilePicsInsteadOfStories", R.string.OpenProfilePicsInsteadOfStories), PlusSettings.openProfilePicsInsteadOfStories, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.openProfilePicsInsteadOfStoriesRow) {
                textCheckCell.setTag("openProfilePicsInsteadOfStories");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("OpenProfilePicsInsteadOfStories", R.string.OpenProfilePicsInsteadOfStories), PlusSettings.openProfilePicsInsteadOfStories, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.profileShowProfilePicDateInsteadOfStatusRow) {
                textCheckCell.setTag("showProfilePicDateInsteadOfStatus");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowProfilePicDateInsteadOfStatus", R.string.ShowProfilePicDateInsteadOfStatus), PlusSettings.showProfilePicDateInsteadOfStatus, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.showOldMediaRowsRow) {
                textCheckCell.setTag("showOldMediaRows");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowOldMediaRows", R.string.ShowOldMediaRows), PlusSettings.showOldMediaRows, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.showMuteInNotificationRow) {
                textCheckCell.setTag("showMuteInNotification");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowMuteOptionInNotification", R.string.ShowMuteOptionInNotification), PlusSettings.showMuteInNotification, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.showAndroidEmojiRow) {
                textCheckCell.setTag("showAndroidEmoji");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowAndroidEmoji", R.string.ShowAndroidEmoji), sharedPreferences4.getBoolean("showAndroidEmoji", false), true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.useDeviceFontRow) {
                textCheckCell.setTag("useDeviceFont");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("UseDeviceFont", R.string.UseDeviceFont), sharedPreferences4.getBoolean("useDeviceFont", false), true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsHideTabsCheckRow) {
                textCheckCell.setTag("hideTabs");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HideTabs", R.string.HideTabs), Theme.plusHideTabs, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsHideMainTabRow) {
                textCheckCell.setTag("hideAllTab");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HideMainTab", R.string.HideMainTab), Theme.plusHideAllTab, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsHideCloudFoldersRow) {
                textCheckCell.setTag("hideCloudFolders");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HideCloudFolders", R.string.HideCloudFolders), PlusSettings.hideCloudFolders, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsDoNotClosePreviewOnReleaseRow) {
                textCheckCell.setTag("doNotClosePreviewOnRelease");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("AllowMorePreviewActions", R.string.AllowMorePreviewActions), PlusSettings.doNotClosePreviewOnRelease, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsShowMoreByDefaultInGlobalSearchRow) {
                textCheckCell.setTag("showMoreByDefaultInGlobalSearch");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowMoreByDefaultInGlobalSearch", R.string.ShowMoreByDefaultInGlobalSearch), PlusSettings.showMoreByDefaultInGlobalSearch, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsForceShowDownloadsButtonRow) {
                textCheckCell.setTag("forceShowDownloadsButton");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowDownloadsButtonAlways", R.string.ShowDownloadsButtonAlways), PlusSettings.forceShowDownloadsButton, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsShowPinDialogButtonRow) {
                textCheckCell.setTag("showPinDialogAlways");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowPinDialogAlways", R.string.ShowPinDialogAlways), PlusSettings.showPinDialogAlways, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsShowLastReactionRow) {
                textCheckCell.setTag("changeDialogReaction");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowLastReactionInMainScreen", R.string.ShowLastReactionInMainScreen), PlusSettings.changeDialogReaction, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsHidePreviewMenuRow) {
                textCheckCell.setTag("hideChatPreviewMenu");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HidePreviewMenu", R.string.HidePreviewMenu), PlusSettings.hideChatPreviewMenu, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsDisableAvatarAnimationRow) {
                textCheckCell.setTag("disableAvatarAnimationInMain");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DisableAvatarAnimation", R.string.DisableAvatarAnimation), PlusSettings.disableAvatarAnimationInMain, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsDrawDialogIconBeforeNameRow) {
                textCheckCell.setTag("drawDialogIcons");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DrawDialogIconBeforeName", R.string.DrawDialogIconBeforeName), PlusSettings.drawDialogIcons, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsOpenArchiveOnPullDownRow) {
                textCheckCell.setTag("openArchiveOnPullDown");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("OpenArchiveOnPullDown", R.string.OpenArchiveOnPullDown), PlusSettings.openArchiveOnPullDown, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.profileDisableAvatarAnimationRow) {
                textCheckCell.setTag("disableAvatarAnimationInProfile");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DisableAvatarAnimation", R.string.DisableAvatarAnimation), PlusSettings.disableAvatarAnimationInProfile, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.profileShowIdRow) {
                textCheckCell.setTag("showIdInProfile");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowIdInProfile", R.string.ShowIdInProfile), PlusSettings.showIdInProfile, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatDisableAvatarAnimationRow) {
                textCheckCell.setTag("disableAvatarAnimationInChat");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DisableAvatarAnimation", R.string.DisableAvatarAnimation), PlusSettings.disableAvatarAnimationInChat, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatDisablePremiumStickersAnimationRow) {
                textCheckCell.setTag("disablePremiumStickersAnimation");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DisablePremiumStickersAnimation", R.string.DisablePremiumStickersAnimation), PlusSettings.disablePremiumStickersAnimation, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsFloatingButtonOpensSavedMessagesRow) {
                textCheckCell.setTag("floatingButtonOpensSavedMessages");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("FloatingButtonOpensSavedMessages", R.string.FloatingButtonOpensSavedMessages), PlusSettings.floatingButtonOpensSavedMessages, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsAllowChangingSortingOnDoubleClick) {
                textCheckCell.setTag("allowChangingSortingOnDoubleClick");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("AllowChangingSortingOnDoubleClick", R.string.AllowChangingSortingOnDoubleClick), PlusSettings.allowChangingSortingOnDoubleClick, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsDisableTabsAnimationCheckRow) {
                textCheckCell.setTag("disableTabsAnimation");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DisableTabsAnimation", R.string.DisableTabsAnimation), Theme.plusDisableTabsAnimation, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsTabsTextModeRow) {
                textCheckCell.setTag("tabTitlesMode");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowTabTitle", R.string.ShowTabTitle), Theme.plusTabTitlesMode, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.changeEmojiToIconRow) {
                textCheckCell.setTag("changeEmojiToIcon");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ChangeEmojiToIcon", R.string.ChangeEmojiToIcon), PlusSettings.changeEmojiToIcon, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsExpandTabsRow) {
                textCheckCell.setTag("tabsShouldExpand");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("FitTabsToScreen", R.string.FitTabsToScreen), Theme.plusTabsShouldExpand, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsTabsToBottomRow) {
                textCheckCell.setTag("tabsToBottom");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("TabsToBottom", R.string.TabsToBottom), Theme.plusTabsToBottom, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsDisableTabsScrollingRow) {
                textCheckCell.setTag("disableTabsScrolling");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DisableTabsScrolling", R.string.DisableTabsScrolling), Theme.plusDisableTabsScrolling, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsHideSelectedTabIndicator) {
                textCheckCell.setTag("hideSelectedTabIndicator");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HideSelectedTabIndicator", R.string.HideSelectedTabIndicator), sharedPreferences4.getBoolean("hideSelectedTabIndicator", false), true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsInfiniteTabsSwipe) {
                textCheckCell.setTag("infiniteTabsSwipe");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("InfiniteSwipe", R.string.InfiniteSwipe), Theme.plusInfiniteTabsSwipe, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsHideTabsCounters) {
                textCheckCell.setTag("hideTabsCounters");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HideTabsCounters", R.string.HideTabsCounters), Theme.plusHideTabsCounters, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsTabsCountersCountChats) {
                textCheckCell.setTag("tabsCountersCountChats");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HeaderTabCounterCountChats", R.string.HeaderTabCounterCountChats), PlusSettings.countChats, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsTabsCountersCountNotMuted) {
                textCheckCell.setTag("tabsCountersCountNotMuted");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HeaderTabCounterCountNotMuted", R.string.HeaderTabCounterCountNotMuted), PlusSettings.countUnmuted, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsCountArchivedRow) {
                textCheckCell.setTag("countArchivedChats");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("CountArchivedChats", R.string.CountArchivedChats), PlusSettings.countArchivedChats, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsCountMentionAsUnmutedRow) {
                textCheckCell.setTag("countMentionAsUnmuted");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("CountMentionAsUnmutedChat", R.string.CountMentionAsUnmutedChat), PlusSettings.countMentionAsUnmuted, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsShowFoldersIfForwardingRow) {
                textCheckCell.setTag("showFoldersIfForwarding");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowFoldersIfForwarding", R.string.ShowFoldersIfForwarding), PlusSettings.showFoldersIfForwarding, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsShowSetDefaultFolderRow) {
                textCheckCell.setTag("showSetDefaultFolder");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowSetDefaultFolder", R.string.ShowSetDefaultFolder), PlusSettings.showSetDefaultFolder, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.hideMobileNumberRow) {
                textCheckCell.setTag("hideMobile");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HideMobile", R.string.HideMobile), Theme.plusHideMobile, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.showUsernameRow) {
                textCheckCell.setTag("showUsername");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowUsernameInMenu", R.string.ShowUsernameInMenu), Theme.plusShowUsername, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.drawerHideSavedMessagesButtonRow) {
                textCheckCell.setTag("hideSavedMessagesButton");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HideSavedMessagesButton", R.string.HideSavedMessagesButton), PlusSettings.hideSavedMessagesButton, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.useAvatarAsBackgroundRow) {
                textCheckCell.setTag("useAvatarAsBackground");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("UseAvatarAsBackground", R.string.UseAvatarAsBackground), PlusSettings.useAvatarAsBackground, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.notificationInvertMessagesOrderRow) {
                textCheckCell.setTag("invertMessagesOrder");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("InvertMessageOrder", R.string.InvertMessageOrder), sharedPreferences4.getBoolean("invertMessagesOrder", false), false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatSearchUserOnTwitterRow) {
                textCheckCell.setTag("searchOnTwitter");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("SearchUserOnTwitter", R.string.SearchUserOnTwitter), sharedPreferences4.getBoolean("searchOnTwitter", false), true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatShowPhotoQualityBarRow) {
                textCheckCell.setTag("showPhotoQualityBar");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowPhotoQualityBar", R.string.ShowPhotoQualityBar), Theme.plusShowPhotoQualityBar, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.showTypingToastNotificationRow) {
                textCheckCell.setTag("showTypingToast");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowTypingToast", R.string.ShowTypingToast), Theme.plusShowTypingToast, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.toastNotificationToBottomRow) {
                textCheckCell.setTag("toastNotificationToBottom");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ToastNotificationToBottom", R.string.ToastNotificationToBottom), Theme.plusToastNotificationToBottom, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.showOnlineToastNotificationRow) {
                textCheckCell.setTag("plusShowOnlineToast");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowOnlineToast", R.string.ShowOnlineToast), Theme.plusShowOnlineToast, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.showToastOnlyIfContactFavRow) {
                textCheckCell.setTag("showTypingOnlyIfContactFav");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowOnlyIfContactFav", R.string.ShowOnlyIfContactFav), Theme.plusShowOnlyIfContactFav, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.showTypingToastOnlyIfContactFavRow) {
                textCheckCell.setTag("showTypingOnlyIfContactFav");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowTypingOnlyIfContactFav", R.string.ShowTypingOnlyIfContactFav), Theme.plusShowTypingOnlyIfContactFav, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.showOfflineToastNotificationRow) {
                textCheckCell.setTag("showOfflineToast");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowOfflineToast", R.string.ShowOfflineToast), Theme.plusShowOfflineToast, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.hideNotificationsIfPlayingRow) {
                textCheckCell.setTag("plusHideNotificationsIfPlaying");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("OverrideNotificationsIfPlaying", R.string.OverrideNotificationsIfPlaying), Theme.plusHideNotificationsIfPlaying, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.enableDirectReplyRow) {
                textCheckCell.setTag("enableDirectReply");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("EnableDirectReply", R.string.EnableDirectReply), Theme.plusEnableDirectReply, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatShowQuickBarRow) {
                textCheckCell.setTag("showQuickBar");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowQuickBar", R.string.ShowQuickBar), Theme.plusShowQuickBar, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatVerticalQuickBarRow) {
                textCheckCell.setTag("verticalQuickBar");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("VerticalQuickBar", R.string.VerticalQuickBar), Theme.plusVerticalQuickBar, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatAlwaysBackToMainRow) {
                textCheckCell.setTag("alwaysBackToMain");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("AlwaysBackToMain", R.string.AlwaysBackToMain), Theme.plusAlwaysBackToMain, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatDoNotCloseQuickBarRow) {
                textCheckCell.setTag("doNotCloseQuickBar");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DoNotCloseQuickBar", R.string.DoNotCloseQuickBar), Theme.plusDoNotCloseQuickBar, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatHideQuickBarOnScrollRow) {
                textCheckCell.setTag("hideQuickBarOnScroll");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HideQuickBarOnScroll", R.string.HideQuickBarOnScroll), Theme.plusHideQuickBarOnScroll, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatCenterQuickBarBtnRow) {
                textCheckCell.setTag("centerQuickBarBtn");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("CenterQuickBarButton", R.string.CenterQuickBarButton), Theme.plusCenterQuickBarBtn, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatShowMembersQuickBarRow) {
                textCheckCell.setTag("quickBarShowMembers");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowMembersOnQuickBar", R.string.ShowMembersOnQuickBar), Theme.plusQuickBarShowMembers, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatSaveToCloudQuoteRow) {
                textCheckCell.setTag("saveToCloudQuote");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("SaveToCloudQuote", R.string.SaveToCloudQuote), Theme.plusSaveToCloudQuote, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatDisableSwipeToReplyVibrationRow) {
                textCheckCell.setTag("plusDisableSwipeToReplyVibration");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DisableSwipeToReplyVibration", R.string.DisableSwipeToReplyVibration), Theme.plusDisableSwipeToReplyVibration, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatHideInstantCameraRow) {
                textCheckCell.setTag("hideInstantCamera");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HideInstantCamera", R.string.HideInstantCamera), Theme.plusHideInstantCamera, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatPlayGifAsVideoRow) {
                textCheckCell.setTag("playGifAsVideo");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("PlayGifAsVideo", R.string.PlayGifAsVideo), PlusSettings.playGifAsVideo, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatDoNotHideStickersTabRow) {
                textCheckCell.setTag("doNotHideStickersTab");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DoNotHideStickersTab", R.string.DoNotHideStickersTab), Theme.plusDoNotHideStickersTab, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatPhotoViewerHideStatusBarRow) {
                textCheckCell.setTag("photoViewerHideStatusBar");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HideStatusBar", R.string.HideStatusBar), Theme.plusPhotoViewerHideStatusBar, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.profileShowFullBioRow) {
                textCheckCell.setTag("showFullBio");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowFullBio", R.string.ShowFullBio), PlusSettings.showFullBio, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.profileEnableGoToMsgRow) {
                textCheckCell.setTag("profileEnableGoToMsg");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("EnableGoToMessage", R.string.EnableGoToMessage), Theme.plusProfileEnableGoToMsg, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsDoNotChangeHeaderTitleRow) {
                textCheckCell.setTag("doNotChangeHeaderTitle");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("DoNotChangeHeaderTitle", R.string.DoNotChangeHeaderTitle), Theme.plusDoNotChangeHeaderTitle, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatDrawSingleBigEmojiRow) {
                textCheckCell.setTag("plusDrawSingleBigEmoji");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("EmojiBigSize", R.string.EmojiBigSize), Theme.plusDrawSingleBigEmoji, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsLimitTabsCountersRow) {
                textCheckCell.setTag("plusLimitTabsCounters");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("LimitTabsCounter", R.string.LimitTabsCounter), Theme.plusLimitTabsCounters, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatMarkdownRow) {
                textCheckCell.setTag("enableMarkdown");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("Markdown", R.string.Markdown), Theme.plusEnableMarkdown, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.moveVersionToSettingsRow) {
                textCheckCell.setTag("moveVersionToSettings");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("MoveVersionToSettings", R.string.MoveVersionToSettings), Theme.plusMoveVersionToSettings, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.drawerOpenAvatarInsteadOfSettingsRow) {
                textCheckCell.setTag("openAvatarInsteadOfSettings");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("OpenAvatarInsteadOfSettings", R.string.OpenAvatarInsteadOfSettings), PlusSettings.openAvatarInsteadOfSettings, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.drawerShowOnlineContactsRow) {
                textCheckCell.setTag("showOnlineContacts");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowOnlineContacts", R.string.ShowOnlineContacts), PlusSettings.showOnlineContacts, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.downloadsShowDownloadsOnlyIfActiveRow) {
                textCheckCell.setTag("showDownloadsOnlyIfActive");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowDownloadsOnlyIfActive", R.string.ShowDownloadsOnlyIfActive), PlusSettings.showDownloadsOnlyIfActive, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.downloadsIncludePendingDownloadsRow) {
                textCheckCell.setTag("includePendingDownloads");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowPendingDownloads", R.string.ShowPendingDownloads), PlusSettings.includePendingDownloads, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.downloadsHideScheduledDownloadReminderRow) {
                textCheckCell.setTag("hideScheduledDownloadReminder");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HideScheduledDownloadReminder", R.string.HideScheduledDownloadReminder), PlusSettings.hideScheduledDownloadReminder, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.uploadSpeedBoostRow) {
                textCheckCell.setTag("uploadSpeedBoost");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("UploadSpeedBoost", R.string.UploadSpeedBoost), PlusSettings.uploadSpeedBoost, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.enableHiddenDialogsRow) {
                textCheckCell.setTag("enableHiddenDialogs");
                String str9 = prefix + LocaleController.getString("EnableHiddenChats", R.string.EnableHiddenChats);
                if (!PlusSettings.enableHiddenDialogs || SharedConfig.hiddenPasscodeHash.length() <= 0) {
                    z3 = true;
                    z4 = false;
                } else {
                    z3 = true;
                    z4 = true;
                }
                textCheckCell.setTextAndCheck(str9, z4, z3);
                return;
            }
            if (position == PlusSettingsActivity.this.showHiddenDialogsIconRow) {
                textCheckCell.setTag("showHiddenDialogsIcon");
                String str10 = prefix + LocaleController.getString("ShowHiddenDialogsIcon", R.string.ShowHiddenDialogsIcon);
                if (PlusSettings.enableHiddenDialogs && sharedPreferences4.getBoolean("showHiddenDialogsIcon", PlusSettings.showHiddenDialogsIcon)) {
                    z = true;
                    z2 = true;
                } else {
                    z = true;
                    z2 = false;
                }
                textCheckCell.setTextAndCheck(str10, z2, z);
                textCheckCell.setMultilineText();
                textCheckCell.setDisabled(z ^ PlusSettings.enableHiddenDialogs);
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsShowSelectChatsOptionRow) {
                textCheckCell.setTag("showSelectChatsOption");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowSelectChatsOption", R.string.ShowSelectChatsOption), Theme.plusShowSelectChatsOption, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsShowArchivedDialogsInTabsRow) {
                textCheckCell.setTag("showArchivedDialogsInTabs");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowArchivedChatsInAnyTab", R.string.ShowArchivedChatsInAnyTab), PlusSettings.plusShowArchivedDialogsInTabs, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsShowArchivedChatOnItsTabRow) {
                textCheckCell.setTag("showArchivedChatOnItsTab");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowArchivedChatOnItsTab", R.string.ShowArchivedChatOnItsTab), PlusSettings.plusShowArchivedChatOnItsTab, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsArchiveChatBySwipingToLeftRow) {
                textCheckCell.setTag("archiveChatBySwipingToLeft");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ArchiveChatBySwipingToLeft", R.string.ArchiveChatBySwipingToLeft), Theme.plusArchiveChatBySwipingToLeft, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsOpenMenuBySwipingToRightRow) {
                textCheckCell.setTag("openMenuBySwipingToRight");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("OpenMenuBySwipingToRight", R.string.OpenMenuBySwipingToRight), Theme.plusOpenMenuBySwipingToRight, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsRemoveArchiveFromListRow) {
                textCheckCell.setTag("removeArchiveFromList");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("RemoveArchiveFromList", R.string.RemoveArchiveFromList), PlusSettings.removeArchiveFromList, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsShowPinnedChatsFirstRow) {
                textCheckCell.setTag("pinnedFirst");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowPinnedChatsFirst", R.string.ShowPinnedChatsFirst), PlusSettings.pinnedFirst, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsShowUnmutedFirstIfUnreadRow) {
                textCheckCell.setTag("showUnmutedFirstIfUnread");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowUnmutedFirstIfUnread", R.string.ShowUnmutedFirstIfUnread), PlusSettings.showUnmutedFirstIfUnread, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsCloseAppOnBackPressedRow) {
                textCheckCell.setTag("closeAppOnBackPressed");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("CloseAppOnBackPressed", R.string.CloseAppOnBackPressed), PlusSettings.closeAppOnBackPressed, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsResumeLastTabRow) {
                textCheckCell.setTag("resumeLastTab");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowLastTab", R.string.ShowLastTab), PlusSettings.resumeLastTab, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsHidePlusPromoDialogRow) {
                textCheckCell.setTag("hidePlusPromoDialog");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HidePlusPromoDialog", R.string.HidePlusPromoDialog), PlusSettings.hidePlusPromoDialog, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsHideProxySponsorRow) {
                textCheckCell.setTag("hideProxySponsor");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HideProxySponsor", R.string.HideProxySponsor), PlusSettings.hideProxySponsor, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsIncreasePinnedDialogsLimitRow) {
                textCheckCell.setTag("increasePinnedDialogsLimit");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("IncreasePinnedDialogsLimit", R.string.IncreasePinnedDialogsLimit), Theme.plusIncreasePinnedDialogsLimit, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsShowAllInAdminTabRow) {
                textCheckCell.setTag("showAllInAdminTab");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowAllInAdminTab", R.string.ShowAllInAdminTab), Theme.plusShowAllInAdminTab, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatShowUserBioRow) {
                textCheckCell.setTag("showUserBio");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowUserBio", R.string.ShowUserBio), Theme.plusShowUserBio, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatShowCallButtonRow) {
                textCheckCell.setTag("showCallButton");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowCallButton", R.string.ShowCallButton), Theme.plusChatShowCallButton, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.chatSetCustomDateAndTime) {
                textCheckCell.setTag("setCustomDateAndTime");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("AddTimeToFloatingDate", R.string.AddTimeToFloatingDate), Theme.plusChatSetCustomDateAndTime, false);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsShowSortingInSubtitleRow) {
                textCheckCell.setTag("showSortingInSubtitle");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowSortingMethodInHeader", R.string.ShowSortingMethodInHeader), Theme.plusShowSortingInSubtitle, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.dialogsShowSortingInSubtitleIfNotDefaultRow) {
                textCheckCell.setTag("showSortingInSubtitleIfNotDefault");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowSortingMethodInHeaderIfNotDefault", R.string.ShowSortingMethodInHeaderIfNotDefault), Theme.plusShowSortingInSubtitleIfNotDefault, false);
                textCheckCell.setDisabled(Theme.plusShowSortingInSubtitle ^ true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.categoriesHideTabsRow) {
                textCheckCell.setTag("categoriesHideTabs");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HideTabsInCategories", R.string.HideTabsInCategories), Theme.plusCategoriesHideTabs, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.categoriesShowCategoriesIconRow) {
                textCheckCell.setTag("showCategoriesIcon");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowCategoriesIcon", R.string.ShowCategoriesIcon), Theme.plusShowCategoriesIcon, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.categoriesShowAddCategoryRow) {
                textCheckCell.setTag("showAddCategoryOption");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowAddCategoryInCategoryList", R.string.ShowAddCategoryInCategoryList), Theme.plusShowAddCategoryOption, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.categoriesLoadLastCategoryOnStartRow) {
                textCheckCell.setTag("loadLastCategoryOnStart");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("LoadLastCategoryOnStart", R.string.LoadLastCategoryOnStart), Theme.plusLoadLastCategoryOnStart, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.hiddenDialogsHideTabsRow) {
                textCheckCell.setTag("hiddenDialogsHideTabs");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("HiddenChatsHideTabs", R.string.HiddenChatsHideTabs), PlusSettings.hiddenDialogsHideTabs, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.hiddenDialogsUseFingerprintRow) {
                textCheckCell.setTag("hiddenUseFingerprint");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("UnlockFingerprint", R.string.UnlockFingerprint), SharedConfig.hiddenUseFingerprint, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.openHiddenDialogsWithoutPasscodeRow) {
                textCheckCell.setTag("openHiddenDialogsWithoutPasscode");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("OpenHiddenChatsWithoutPassCode", R.string.OpenHiddenChatsWithoutPassCode), PlusSettings.openHiddenDialogsWithoutPasscode, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.showHiddenDialogsWhenSearchingRow) {
                textCheckCell.setTag("showHiddenDialogsWhenSearching");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowHiddenDialogsWhenSearching", R.string.ShowHiddenDialogsWhenSearching), PlusSettings.showHiddenDialogsWhenSearching, true);
                textCheckCell.setMultilineText();
                return;
            }
            if (position == PlusSettingsActivity.this.showHiddenDialogsNotificationsRow) {
                textCheckCell.setTag("showHiddenDialogsNotifications");
                textCheckCell.setTextAndCheck(prefix + LocaleController.getString("ShowHiddenDialogsNotifications", R.string.ShowHiddenDialogsNotifications), PlusSettings.showHiddenDialogsNotifications, true);
                textCheckCell.setMultilineText();
            }
        }

        public boolean isEnabled(RecyclerView.ViewHolder holder) {
            int adapterPosition = holder.getAdapterPosition();
            return adapterPosition == PlusSettingsActivity.this.showAndroidEmojiRow || adapterPosition == PlusSettingsActivity.this.useDeviceFontRow || adapterPosition == PlusSettingsActivity.this.emojiPopupSize || adapterPosition == PlusSettingsActivity.this.chatStickerCellRow || adapterPosition == PlusSettingsActivity.this.dialogsTabsTextSizeRow || adapterPosition == PlusSettingsActivity.this.dialogsTabsHeightRow || adapterPosition == PlusSettingsActivity.this.dialogsTabsRow || adapterPosition == PlusSettingsActivity.this.dialogsManageTabsRow || adapterPosition == PlusSettingsActivity.this.chatShowDirectShareBtnRow || adapterPosition == PlusSettingsActivity.this.profileSharedOptionsRow || adapterPosition == PlusSettingsActivity.this.disableAudioStopRow || adapterPosition == PlusSettingsActivity.this.disableMusicStopRow || adapterPosition == PlusSettingsActivity.this.disableMessageClickRow || adapterPosition == PlusSettingsActivity.this.chatDirectShareReplies || adapterPosition == PlusSettingsActivity.this.chatDirectShareFavsFirst || adapterPosition == PlusSettingsActivity.this.chatShowEditedMarkRow || adapterPosition == PlusSettingsActivity.this.chatShowDateToastRow || adapterPosition == PlusSettingsActivity.this.chatHideLeftGroupRow || adapterPosition == PlusSettingsActivity.this.chatHideJoinedGroupRow || adapterPosition == PlusSettingsActivity.this.chatHideBotKeyboardRow || adapterPosition == PlusSettingsActivity.this.dialogsHideTabsCheckRow || adapterPosition == PlusSettingsActivity.this.dialogsDisableTabsAnimationCheckRow || adapterPosition == PlusSettingsActivity.this.dialogsInfiniteTabsSwipe || adapterPosition == PlusSettingsActivity.this.dialogsHideTabsCounters || adapterPosition == PlusSettingsActivity.this.dialogsTabsCountersCountChats || adapterPosition == PlusSettingsActivity.this.dialogsTabsCountersCountNotMuted || adapterPosition == PlusSettingsActivity.this.chatSearchUserOnTwitterRow || adapterPosition == PlusSettingsActivity.this.keepOriginalFilenameRow || (adapterPosition == PlusSettingsActivity.this.keepFilenameEqualRow && PlusSettings.keepOriginalFileName) || adapterPosition == PlusSettingsActivity.this.dialogsPicClickRow || adapterPosition == PlusSettingsActivity.this.dialogsGroupPicClickRow || adapterPosition == PlusSettingsActivity.this.hideMobileNumberRow || adapterPosition == PlusSettingsActivity.this.showUsernameRow || adapterPosition == PlusSettingsActivity.this.notificationInvertMessagesOrderRow || adapterPosition == PlusSettingsActivity.this.savePlusSettingsRow || adapterPosition == PlusSettingsActivity.this.restorePlusSettingsRow || adapterPosition == PlusSettingsActivity.this.resetPlusSettingsRow || adapterPosition == PlusSettingsActivity.this.chatPhotoQualityRow || adapterPosition == PlusSettingsActivity.this.chatShowPhotoQualityBarRow || adapterPosition == PlusSettingsActivity.this.dialogsTabsTextModeRow || adapterPosition == PlusSettingsActivity.this.dialogsExpandTabsRow || adapterPosition == PlusSettingsActivity.this.dialogsDisableTabsScrollingRow || adapterPosition == PlusSettingsActivity.this.dialogsDoNotChangeHeaderTitleRow || adapterPosition == PlusSettingsActivity.this.dialogsTabsToBottomRow || adapterPosition == PlusSettingsActivity.this.dialogsHideSelectedTabIndicator || adapterPosition == PlusSettingsActivity.this.showTypingToastNotificationRow || adapterPosition == PlusSettingsActivity.this.toastNotificationSizeRow || adapterPosition == PlusSettingsActivity.this.toastNotificationPaddingRow || adapterPosition == PlusSettingsActivity.this.toastNotificationToBottomRow || adapterPosition == PlusSettingsActivity.this.toastNotificationPositionRow || adapterPosition == PlusSettingsActivity.this.showOnlineToastNotificationRow || adapterPosition == PlusSettingsActivity.this.showOfflineToastNotificationRow || adapterPosition == PlusSettingsActivity.this.showToastOnlyIfContactFavRow || adapterPosition == PlusSettingsActivity.this.showTypingToastOnlyIfContactFavRow || adapterPosition == PlusSettingsActivity.this.enableDirectReplyRow || adapterPosition == PlusSettingsActivity.this.chatShowQuickBarRow || adapterPosition == PlusSettingsActivity.this.chatVerticalQuickBarRow || adapterPosition == PlusSettingsActivity.this.chatAlwaysBackToMainRow || adapterPosition == PlusSettingsActivity.this.chatDoNotCloseQuickBarRow || adapterPosition == PlusSettingsActivity.this.chatHideQuickBarOnScrollRow || adapterPosition == PlusSettingsActivity.this.chatCenterQuickBarBtnRow || adapterPosition == PlusSettingsActivity.this.chatShowMembersQuickBarRow || adapterPosition == PlusSettingsActivity.this.chatSaveToCloudQuoteRow || adapterPosition == PlusSettingsActivity.this.hideNotificationsIfPlayingRow || adapterPosition == PlusSettingsActivity.this.chatHideInstantCameraRow || adapterPosition == PlusSettingsActivity.this.chatDoNotHideStickersTabRow || adapterPosition == PlusSettingsActivity.this.chatPhotoViewerHideStatusBarRow || adapterPosition == PlusSettingsActivity.this.chatsToLoadRow || adapterPosition == PlusSettingsActivity.this.profileEnableGoToMsgRow || adapterPosition == PlusSettingsActivity.this.chatDrawSingleBigEmojiRow || adapterPosition == PlusSettingsActivity.this.dialogsLimitTabsCountersRow || adapterPosition == PlusSettingsActivity.this.chatMarkdownRow || adapterPosition == PlusSettingsActivity.this.moveVersionToSettingsRow || adapterPosition == PlusSettingsActivity.this.dialogsShowAllInAdminTabRow || adapterPosition == PlusSettingsActivity.this.chatShowUserBioRow || adapterPosition == PlusSettingsActivity.this.chatShowCallButtonRow || adapterPosition == PlusSettingsActivity.this.chatSetCustomDateAndTime || adapterPosition == PlusSettingsActivity.this.chatShowHideOptionsRow || adapterPosition == PlusSettingsActivity.this.chatDisableSwipeToReplyVibrationRow || adapterPosition == PlusSettingsActivity.this.chatHideImageSizeRow || adapterPosition == PlusSettingsActivity.this.chatHideSenderNameRow || adapterPosition == PlusSettingsActivity.this.chatDeleteSharedMediaCaptionRow || adapterPosition == PlusSettingsActivity.this.dialogsShowSortingInSubtitleRow || ((adapterPosition == PlusSettingsActivity.this.dialogsShowSortingInSubtitleIfNotDefaultRow && Theme.plusShowSortingInSubtitle) || adapterPosition == PlusSettingsActivity.this.chatStartRoundVideoUsingMainCameraRow || adapterPosition == PlusSettingsActivity.this.chatChangePlayerSpeedRangeRow || adapterPosition == PlusSettingsActivity.this.chatShowDownloadProgressRow || adapterPosition == PlusSettingsActivity.this.chatDisableRestriction || adapterPosition == PlusSettingsActivity.this.chatMakeTitleScrollableRow || adapterPosition == PlusSettingsActivity.this.categoriesHideTabsRow || adapterPosition == PlusSettingsActivity.this.categoriesShowCategoriesIconRow || adapterPosition == PlusSettingsActivity.this.categoriesShowAddCategoryRow || adapterPosition == PlusSettingsActivity.this.categoriesLoadLastCategoryOnStartRow || adapterPosition == PlusSettingsActivity.this.usePlusFolderRow || adapterPosition == PlusSettingsActivity.this.dialogsShowSelectChatsOptionRow || adapterPosition == PlusSettingsActivity.this.dialogsShowArchivedDialogsInTabsRow || adapterPosition == PlusSettingsActivity.this.dialogsShowArchivedChatOnItsTabRow || adapterPosition == PlusSettingsActivity.this.dialogsIncreasePinnedDialogsLimitRow || adapterPosition == PlusSettingsActivity.this.drawerShowOptionsRow || adapterPosition == PlusSettingsActivity.this.drawerShowPlusOptionsRow || adapterPosition == PlusSettingsActivity.this.chatHideBottomLayoutInChannelsRow || adapterPosition == PlusSettingsActivity.this.chatDoNotHideSearchBottomRow || adapterPosition == PlusSettingsActivity.this.dialogsArchiveChatBySwipingToLeftRow || adapterPosition == PlusSettingsActivity.this.dialogsOpenMenuBySwipingToRightRow || adapterPosition == PlusSettingsActivity.this.chatShowSearchIconRow || adapterPosition == PlusSettingsActivity.this.chatDisableShortNumberFormatRow || adapterPosition == PlusSettingsActivity.this.selectStorageRow || adapterPosition == PlusSettingsActivity.this.dialogsRemoveArchiveFromListRow || adapterPosition == PlusSettingsActivity.this.dialogsHideProxySponsorRow || adapterPosition == PlusSettingsActivity.this.drawerShowOnlineContactsRow || adapterPosition == PlusSettingsActivity.this.enableHiddenDialogsRow || adapterPosition == PlusSettingsActivity.this.changeHiddenDialogsPasswordRow || adapterPosition == PlusSettingsActivity.this.hiddenDialogsUseFingerprintRow || adapterPosition == PlusSettingsActivity.this.hiddenDialogsHideTabsRow || adapterPosition == PlusSettingsActivity.this.openHiddenDialogsWithoutPasscodeRow || adapterPosition == PlusSettingsActivity.this.showHiddenDialogsWhenSearchingRow || adapterPosition == PlusSettingsActivity.this.showHiddenDialogsNotificationsRow || adapterPosition == PlusSettingsActivity.this.showHiddenDialogsIconRow || adapterPosition == PlusSettingsActivity.this.discardMediaTapRow || adapterPosition == PlusSettingsActivity.this.showOldMediaRowsRow || adapterPosition == PlusSettingsActivity.this.showFullScreenAvatarOnSingleTapRow || adapterPosition == PlusSettingsActivity.this.showMuteInNotificationRow || adapterPosition == PlusSettingsActivity.this.useAvatarAsBackgroundRow || adapterPosition == PlusSettingsActivity.this.changeEmojiToIconRow || adapterPosition == PlusSettingsActivity.this.dialogsShowPinnedChatsFirstRow || adapterPosition == PlusSettingsActivity.this.dialogsCloseAppOnBackPressedRow || adapterPosition == PlusSettingsActivity.this.dialogsResumeLastTabRow || adapterPosition == PlusSettingsActivity.this.dialogsCountArchivedRow || adapterPosition == PlusSettingsActivity.this.dialogsShowFoldersIfForwardingRow || adapterPosition == PlusSettingsActivity.this.dialogsShowSetDefaultFolderRow || adapterPosition == PlusSettingsActivity.this.dialogsShowUnmutedFirstIfUnreadRow || adapterPosition == PlusSettingsActivity.this.dialogsHideMainTabRow || adapterPosition == PlusSettingsActivity.this.dialogsAllowChangingSortingOnDoubleClick || adapterPosition == PlusSettingsActivity.this.dialogsCountMentionAsUnmutedRow || adapterPosition == PlusSettingsActivity.this.dialogsHideCloudFoldersRow || adapterPosition == PlusSettingsActivity.this.chatChangeTranslateLanguageRow || adapterPosition == PlusSettingsActivity.this.chatTranslationProviderRow || adapterPosition == PlusSettingsActivity.this.chatAddDateToEventRow || adapterPosition == PlusSettingsActivity.this.dialogsTabsSwipeSensitivityRow || adapterPosition == PlusSettingsActivity.this.chatPlayGifAsVideoRow || adapterPosition == PlusSettingsActivity.this.dialogsDoNotClosePreviewOnReleaseRow || adapterPosition == PlusSettingsActivity.this.hideMsgDeletedHintRow || adapterPosition == PlusSettingsActivity.this.chatDisableActionsVibrationsRow || adapterPosition == PlusSettingsActivity.this.chatAddTranslateToSendButtonRow || adapterPosition == PlusSettingsActivity.this.chatShowAnimatedStickersFirstRow || adapterPosition == PlusSettingsActivity.this.chatDisableJumpingToNextChannelRow || adapterPosition == PlusSettingsActivity.this.updateAppMethodRow || adapterPosition == PlusSettingsActivity.this.chatHideChatGreetingRow || adapterPosition == PlusSettingsActivity.this.chatEnableConfirmBeforeSendingRow || adapterPosition == PlusSettingsActivity.this.chatHideKeyboardOnScrollRow || adapterPosition == PlusSettingsActivity.this.chatDisableLoadingNextMediaRow || adapterPosition == PlusSettingsActivity.this.chatHideSenderSelectorRow || adapterPosition == PlusSettingsActivity.this.useExternalStorageRow || adapterPosition == PlusSettingsActivity.this.migrateFilesRow || adapterPosition == PlusSettingsActivity.this.chatShowSendWithoutSoundButtonRow || adapterPosition == PlusSettingsActivity.this.chatAlwaysShowSpoilersRow || adapterPosition == PlusSettingsActivity.this.chatDisableReactionAnimationRow || adapterPosition == PlusSettingsActivity.this.chatIgnoreBlockedUsersRow || adapterPosition == PlusSettingsActivity.this.chatSelectDoubleTapActionRow || adapterPosition == PlusSettingsActivity.this.addAppFolderToSaveToOptionRow || adapterPosition == PlusSettingsActivity.this.chatSwipeLeftActionRow || adapterPosition == PlusSettingsActivity.this.chatSwipeRightActionRow || adapterPosition == PlusSettingsActivity.this.dialogsFloatingButtonOpensSavedMessagesRow || adapterPosition == PlusSettingsActivity.this.chatEnableSwipeActionInChannelsRow || adapterPosition == PlusSettingsActivity.this.profileShowFullBioRow || adapterPosition == PlusSettingsActivity.this.chatDirectShareButtonActionRow || adapterPosition == PlusSettingsActivity.this.chatDoNotShowDialogOnCacheDeletingRow || adapterPosition == PlusSettingsActivity.this.downloadsShowDownloadsOnlyIfActiveRow || adapterPosition == PlusSettingsActivity.this.downloadsIncludePendingDownloadsRow || adapterPosition == PlusSettingsActivity.this.downloadsSimultaneousDownloadsRow || adapterPosition == PlusSettingsActivity.this.downloadsHideScheduledDownloadReminderRow || adapterPosition == PlusSettingsActivity.this.dialogsShowMoreByDefaultInGlobalSearchRow || adapterPosition == PlusSettingsActivity.this.chatEnableBlurInChatRow || adapterPosition == PlusSettingsActivity.this.chatEnableReturnToMessageStackRow || adapterPosition == PlusSettingsActivity.this.chatAddSecondsToTimeInChatRow || adapterPosition == PlusSettingsActivity.this.dialogsForceShowDownloadsButtonRow || adapterPosition == PlusSettingsActivity.this.chatHideReactionsButtonsInMessagesRow || adapterPosition == PlusSettingsActivity.this.chatShowAllRecentStickersRow || adapterPosition == PlusSettingsActivity.this.chatDisableLinkPreviewRow || adapterPosition == PlusSettingsActivity.this.chatHideTimeInStickersRow || ((adapterPosition == PlusSettingsActivity.this.useTelegramDataPathRow && !PlusSettings.useExternalStorage()) || adapterPosition == PlusSettingsActivity.this.chatSelectTapAvatarActionRow || adapterPosition == PlusSettingsActivity.this.chatSelectTapAndHoldAvatarActionRow || adapterPosition == PlusSettingsActivity.this.dialogsShowPinDialogButtonRow || adapterPosition == PlusSettingsActivity.this.dialogsShowLastReactionRow || adapterPosition == PlusSettingsActivity.this.dialogsHidePreviewMenuRow || adapterPosition == PlusSettingsActivity.this.dialogsDisableAvatarAnimationRow || adapterPosition == PlusSettingsActivity.this.chatDisableAvatarAnimationRow || adapterPosition == PlusSettingsActivity.this.profileDisableAvatarAnimationRow || adapterPosition == PlusSettingsActivity.this.chatDisablePremiumStickersAnimationRow || adapterPosition == PlusSettingsActivity.this.chatIncreaseInstantVideoQualityRow || adapterPosition == PlusSettingsActivity.this.chatActionModeButtonsRow || adapterPosition == PlusSettingsActivity.this.drawerOpenAvatarInsteadOfSettingsRow || adapterPosition == PlusSettingsActivity.this.dialogsDrawDialogIconBeforeNameRow || adapterPosition == PlusSettingsActivity.this.chatDoNotPlayNextMediaRow || adapterPosition == PlusSettingsActivity.this.chatConfirmAudioVideoBeforeSendingRow || adapterPosition == PlusSettingsActivity.this.chatHidePremiumEmojisTabsRow || adapterPosition == PlusSettingsActivity.this.chatHidePremiumStickersRow || ((adapterPosition == PlusSettingsActivity.this.chatForceSmallReactionsLayoutRow && !PlusSettingsActivity.this.disableForceSmallReactionsLayout) || adapterPosition == PlusSettingsActivity.this.chatShowBackForwardMusicPlayerButtonsRow || adapterPosition == PlusSettingsActivity.this.chatCopyLinkOnLongClickRow || adapterPosition == PlusSettingsActivity.this.topicsViewAllTopicsAsMessagesRow || ((adapterPosition == PlusSettingsActivity.this.topicsSaveViewTopicsAsMessagesOptionRow && !PlusSettings.viewAllTopicsAsMessages) || adapterPosition == PlusSettingsActivity.this.topicsAllowPinTopicsRow || adapterPosition == PlusSettingsActivity.this.topicsOpenTopicsAsNormalGroupsRow || adapterPosition == PlusSettingsActivity.this.topicsShowOnlyGroupsWithTopicsRow || adapterPosition == PlusSettingsActivity.this.downloadsSpeedBoostRow || adapterPosition == PlusSettingsActivity.this.uploadSpeedBoostRow || adapterPosition == PlusSettingsActivity.this.chatAlwaysShowMediaSpoilersRow || adapterPosition == PlusSettingsActivity.this.dialogsOpenArchiveOnPullDownRow || adapterPosition == PlusSettingsActivity.this.chatMarkdownParseLinksRow || adapterPosition == PlusSettingsActivity.this.profileShowIdRow || adapterPosition == PlusSettingsActivity.this.topicsDisableHideTopicOnSwipeRow || adapterPosition == PlusSettingsActivity.this.chatImproveVoiceRecordingQualityRow || adapterPosition == PlusSettingsActivity.this.showToastErrorsRow || adapterPosition == PlusSettingsActivity.this.chatAddDateToForwardedMessagesRow || adapterPosition == PlusSettingsActivity.this.chatHideVoiceTranscriptionButtonRow || adapterPosition == PlusSettingsActivity.this.chatShowUserStatusCircleOnlyIfOnlineRow || adapterPosition == PlusSettingsActivity.this.dialogsShowUserStatusCircleOnlyIfOnlineRow || adapterPosition == PlusSettingsActivity.this.chatHideSlashBotButtonRow || adapterPosition == PlusSettingsActivity.this.drawerHideSavedMessagesButtonRow || adapterPosition == PlusSettingsActivity.this.hideStoriesRow || adapterPosition == PlusSettingsActivity.this.hideCreateStoryButtonRow || adapterPosition == PlusSettingsActivity.this.profileOpenProfilePicsInsteadOfStoriesRow || adapterPosition == PlusSettingsActivity.this.profileShowProfilePicDateInsteadOfStatusRow || adapterPosition == PlusSettingsActivity.this.hideSeenStoriesRow || adapterPosition == PlusSettingsActivity.this.hideChannelsStoriesRow || adapterPosition == PlusSettingsActivity.this.openProfilePicsInsteadOfStoriesRow || adapterPosition == PlusSettingsActivity.this.doNotMarkStoriesAsReadRow || adapterPosition == PlusSettingsActivity.this.chatDisableUsersThemeModificationsRow || adapterPosition == PlusSettingsActivity.this.dialogsHidePlusPromoDialogRow))));
        }

        public RecyclerView.ViewHolder onCreateViewHolder(ViewGroup parent, int viewType) {
            View shadowSectionCell;
            if (viewType == 0) {
                shadowSectionCell = new ShadowSectionCell(this.mContext);
            } else if (viewType == 1) {
                shadowSectionCell = new HeaderCell(this.mContext);
                shadowSectionCell.setBackgroundColor(Theme.usePlusTheme ? Theme.prefBGColor : Theme.getColor(Theme.key_windowBackgroundWhite));
            } else if (viewType == 2) {
                shadowSectionCell = new TextSettingsCell(this.mContext);
                shadowSectionCell.setBackgroundColor(Theme.usePlusTheme ? Theme.prefBGColor : Theme.getColor(Theme.key_windowBackgroundWhite));
            } else if (viewType == 3) {
                shadowSectionCell = new TextCheckCell(this.mContext);
                shadowSectionCell.setBackgroundColor(Theme.usePlusTheme ? Theme.prefBGColor : Theme.getColor(Theme.key_windowBackgroundWhite));
            } else if (viewType == 6) {
                shadowSectionCell = new TextDetailSettingsCell(this.mContext);
                shadowSectionCell.setBackgroundColor(Theme.usePlusTheme ? Theme.prefBGColor : Theme.getColor(Theme.key_windowBackgroundWhite));
            } else if (viewType != 7) {
                shadowSectionCell = null;
            } else {
                shadowSectionCell = new TextInfoPrivacyCell(this.mContext);
                shadowSectionCell.setBackgroundDrawable(Theme.getThemedDrawable(this.mContext, R.drawable.greydivider, Theme.key_windowBackgroundGrayShadow));
                if (Theme.usePlusTheme) {
                    shadowSectionCell.getBackground().setColorFilter(Theme.prefBGColor, PorterDuff.Mode.SRC_IN);
                }
            }
            shadowSectionCell.setLayoutParams(new RecyclerView.LayoutParams(-1, -2));
            return new RecyclerListView.Holder(shadowSectionCell);
        }

        public int getItemViewType(int i) {
            if (i == PlusSettingsActivity.this.messagesSectionRow || i == PlusSettingsActivity.this.storiesSectionRow || i == PlusSettingsActivity.this.topicsSectionRow || i == PlusSettingsActivity.this.profileSectionRow || i == PlusSettingsActivity.this.drawerSectionRow || i == PlusSettingsActivity.this.privacySectionRow || i == PlusSettingsActivity.this.mediaDownloadSection || i == PlusSettingsActivity.this.dialogsSectionRow || i == PlusSettingsActivity.this.notificationSectionRow || i == PlusSettingsActivity.this.toastNotificationSectionRow || i == PlusSettingsActivity.this.plusSettingsSectionRow || i == PlusSettingsActivity.this.hiddenDialogsSectionRow || i == PlusSettingsActivity.this.downloadsSectionRow) {
                return 0;
            }
            if (i == PlusSettingsActivity.this.settingsSectionRow2 || i == PlusSettingsActivity.this.messagesSectionRow2 || i == PlusSettingsActivity.this.storiesSectionRow2 || i == PlusSettingsActivity.this.topicsSectionRow2 || i == PlusSettingsActivity.this.profileSectionRow2 || i == PlusSettingsActivity.this.drawerSectionRow2 || i == PlusSettingsActivity.this.privacySectionRow2 || i == PlusSettingsActivity.this.mediaDownloadSection2 || i == PlusSettingsActivity.this.dialogsSectionRow2 || i == PlusSettingsActivity.this.notificationSection2Row || i == PlusSettingsActivity.this.toastNotificationSection2Row || i == PlusSettingsActivity.this.plusSettingsSectionRow2 || i == PlusSettingsActivity.this.hiddenDialogsSectionRow2 || i == PlusSettingsActivity.this.downloadsSectionRow2) {
                return 1;
            }
            if (i == PlusSettingsActivity.this.disableAudioStopRow || i == PlusSettingsActivity.this.disableMusicStopRow || i == PlusSettingsActivity.this.disableMessageClickRow || i == PlusSettingsActivity.this.dialogsHideTabsCheckRow || i == PlusSettingsActivity.this.dialogsDisableTabsAnimationCheckRow || i == PlusSettingsActivity.this.dialogsInfiniteTabsSwipe || i == PlusSettingsActivity.this.dialogsHideTabsCounters || i == PlusSettingsActivity.this.dialogsTabsCountersCountChats || i == PlusSettingsActivity.this.dialogsTabsCountersCountNotMuted || i == PlusSettingsActivity.this.showAndroidEmojiRow || i == PlusSettingsActivity.this.useDeviceFontRow || i == PlusSettingsActivity.this.keepOriginalFilenameRow || i == PlusSettingsActivity.this.keepFilenameEqualRow || i == PlusSettingsActivity.this.hideMobileNumberRow || i == PlusSettingsActivity.this.showUsernameRow || i == PlusSettingsActivity.this.chatDirectShareReplies || i == PlusSettingsActivity.this.chatDirectShareFavsFirst || i == PlusSettingsActivity.this.chatShowEditedMarkRow || i == PlusSettingsActivity.this.chatShowDateToastRow || i == PlusSettingsActivity.this.chatHideLeftGroupRow || i == PlusSettingsActivity.this.chatHideJoinedGroupRow || i == PlusSettingsActivity.this.chatHideBotKeyboardRow || i == PlusSettingsActivity.this.notificationInvertMessagesOrderRow || i == PlusSettingsActivity.this.chatSearchUserOnTwitterRow || i == PlusSettingsActivity.this.chatShowPhotoQualityBarRow || i == PlusSettingsActivity.this.dialogsTabsTextModeRow || i == PlusSettingsActivity.this.dialogsExpandTabsRow || i == PlusSettingsActivity.this.dialogsDisableTabsScrollingRow || i == PlusSettingsActivity.this.dialogsTabsToBottomRow || i == PlusSettingsActivity.this.dialogsHideSelectedTabIndicator || i == PlusSettingsActivity.this.showTypingToastNotificationRow || i == PlusSettingsActivity.this.toastNotificationToBottomRow || i == PlusSettingsActivity.this.showOnlineToastNotificationRow || i == PlusSettingsActivity.this.showOfflineToastNotificationRow || i == PlusSettingsActivity.this.showToastOnlyIfContactFavRow || i == PlusSettingsActivity.this.showTypingToastOnlyIfContactFavRow || i == PlusSettingsActivity.this.enableDirectReplyRow || i == PlusSettingsActivity.this.chatShowQuickBarRow || i == PlusSettingsActivity.this.chatVerticalQuickBarRow || i == PlusSettingsActivity.this.chatAlwaysBackToMainRow || i == PlusSettingsActivity.this.chatDoNotCloseQuickBarRow || i == PlusSettingsActivity.this.chatHideQuickBarOnScrollRow || i == PlusSettingsActivity.this.chatCenterQuickBarBtnRow || i == PlusSettingsActivity.this.chatShowMembersQuickBarRow || i == PlusSettingsActivity.this.chatSaveToCloudQuoteRow || i == PlusSettingsActivity.this.hideNotificationsIfPlayingRow || i == PlusSettingsActivity.this.chatHideInstantCameraRow || i == PlusSettingsActivity.this.chatDoNotHideStickersTabRow || i == PlusSettingsActivity.this.chatPhotoViewerHideStatusBarRow || i == PlusSettingsActivity.this.profileEnableGoToMsgRow || i == PlusSettingsActivity.this.dialogsDoNotChangeHeaderTitleRow || i == PlusSettingsActivity.this.chatDrawSingleBigEmojiRow || i == PlusSettingsActivity.this.dialogsLimitTabsCountersRow || i == PlusSettingsActivity.this.chatMarkdownRow || i == PlusSettingsActivity.this.moveVersionToSettingsRow || i == PlusSettingsActivity.this.dialogsShowAllInAdminTabRow || i == PlusSettingsActivity.this.chatShowUserBioRow || i == PlusSettingsActivity.this.chatShowCallButtonRow || i == PlusSettingsActivity.this.chatSetCustomDateAndTime || i == PlusSettingsActivity.this.chatDisableSwipeToReplyVibrationRow || i == PlusSettingsActivity.this.chatHideImageSizeRow || i == PlusSettingsActivity.this.chatHideSenderNameRow || i == PlusSettingsActivity.this.chatDeleteSharedMediaCaptionRow || i == PlusSettingsActivity.this.dialogsShowSortingInSubtitleRow || i == PlusSettingsActivity.this.dialogsShowSortingInSubtitleIfNotDefaultRow || i == PlusSettingsActivity.this.chatStartRoundVideoUsingMainCameraRow || i == PlusSettingsActivity.this.chatChangePlayerSpeedRangeRow || i == PlusSettingsActivity.this.chatShowDownloadProgressRow || i == PlusSettingsActivity.this.chatDisableRestriction || i == PlusSettingsActivity.this.chatMakeTitleScrollableRow || i == PlusSettingsActivity.this.categoriesHideTabsRow || i == PlusSettingsActivity.this.categoriesShowCategoriesIconRow || i == PlusSettingsActivity.this.categoriesShowAddCategoryRow || i == PlusSettingsActivity.this.categoriesLoadLastCategoryOnStartRow || i == PlusSettingsActivity.this.usePlusFolderRow || i == PlusSettingsActivity.this.dialogsShowSelectChatsOptionRow || i == PlusSettingsActivity.this.dialogsShowArchivedDialogsInTabsRow || i == PlusSettingsActivity.this.dialogsShowArchivedChatOnItsTabRow || i == PlusSettingsActivity.this.dialogsIncreasePinnedDialogsLimitRow || i == PlusSettingsActivity.this.chatHideBottomLayoutInChannelsRow || i == PlusSettingsActivity.this.chatDoNotHideSearchBottomRow || i == PlusSettingsActivity.this.dialogsArchiveChatBySwipingToLeftRow || i == PlusSettingsActivity.this.dialogsOpenMenuBySwipingToRightRow || i == PlusSettingsActivity.this.chatShowSearchIconRow || i == PlusSettingsActivity.this.chatDisableShortNumberFormatRow || i == PlusSettingsActivity.this.dialogsRemoveArchiveFromListRow || i == PlusSettingsActivity.this.dialogsHideProxySponsorRow || i == PlusSettingsActivity.this.drawerShowOnlineContactsRow || i == PlusSettingsActivity.this.enableHiddenDialogsRow || i == PlusSettingsActivity.this.hiddenDialogsUseFingerprintRow || i == PlusSettingsActivity.this.hiddenDialogsHideTabsRow || i == PlusSettingsActivity.this.openHiddenDialogsWithoutPasscodeRow || i == PlusSettingsActivity.this.showHiddenDialogsWhenSearchingRow || i == PlusSettingsActivity.this.showHiddenDialogsNotificationsRow || i == PlusSettingsActivity.this.showHiddenDialogsIconRow || i == PlusSettingsActivity.this.discardMediaTapRow || i == PlusSettingsActivity.this.showOldMediaRowsRow || i == PlusSettingsActivity.this.showFullScreenAvatarOnSingleTapRow || i == PlusSettingsActivity.this.showMuteInNotificationRow || i == PlusSettingsActivity.this.useAvatarAsBackgroundRow || i == PlusSettingsActivity.this.changeEmojiToIconRow || i == PlusSettingsActivity.this.dialogsShowPinnedChatsFirstRow || i == PlusSettingsActivity.this.dialogsCloseAppOnBackPressedRow || i == PlusSettingsActivity.this.dialogsResumeLastTabRow || i == PlusSettingsActivity.this.dialogsCountArchivedRow || i == PlusSettingsActivity.this.dialogsShowFoldersIfForwardingRow || i == PlusSettingsActivity.this.dialogsShowSetDefaultFolderRow || i == PlusSettingsActivity.this.dialogsShowUnmutedFirstIfUnreadRow || i == PlusSettingsActivity.this.dialogsHideMainTabRow || i == PlusSettingsActivity.this.dialogsAllowChangingSortingOnDoubleClick || i == PlusSettingsActivity.this.dialogsCountMentionAsUnmutedRow || i == PlusSettingsActivity.this.dialogsHideCloudFoldersRow || i == PlusSettingsActivity.this.chatAddDateToEventRow || i == PlusSettingsActivity.this.chatPlayGifAsVideoRow || i == PlusSettingsActivity.this.dialogsDoNotClosePreviewOnReleaseRow || i == PlusSettingsActivity.this.hideMsgDeletedHintRow || i == PlusSettingsActivity.this.chatDisableActionsVibrationsRow || i == PlusSettingsActivity.this.chatAddTranslateToSendButtonRow || i == PlusSettingsActivity.this.chatShowAnimatedStickersFirstRow || i == PlusSettingsActivity.this.chatDisableJumpingToNextChannelRow || i == PlusSettingsActivity.this.chatHideChatGreetingRow || i == PlusSettingsActivity.this.chatEnableConfirmBeforeSendingRow || i == PlusSettingsActivity.this.chatHideKeyboardOnScrollRow || i == PlusSettingsActivity.this.chatDisableLoadingNextMediaRow || i == PlusSettingsActivity.this.chatHideSenderSelectorRow || i == PlusSettingsActivity.this.useExternalStorageRow || i == PlusSettingsActivity.this.chatShowSendWithoutSoundButtonRow || i == PlusSettingsActivity.this.chatAlwaysShowSpoilersRow || i == PlusSettingsActivity.this.chatDisableReactionAnimationRow || i == PlusSettingsActivity.this.chatIgnoreBlockedUsersRow || i == PlusSettingsActivity.this.addAppFolderToSaveToOptionRow || i == PlusSettingsActivity.this.dialogsFloatingButtonOpensSavedMessagesRow || i == PlusSettingsActivity.this.chatEnableSwipeActionInChannelsRow || i == PlusSettingsActivity.this.profileShowFullBioRow || i == PlusSettingsActivity.this.chatDoNotShowDialogOnCacheDeletingRow || i == PlusSettingsActivity.this.downloadsShowDownloadsOnlyIfActiveRow || i == PlusSettingsActivity.this.downloadsIncludePendingDownloadsRow || i == PlusSettingsActivity.this.downloadsHideScheduledDownloadReminderRow || i == PlusSettingsActivity.this.dialogsShowMoreByDefaultInGlobalSearchRow || i == PlusSettingsActivity.this.chatEnableBlurInChatRow || i == PlusSettingsActivity.this.chatEnableReturnToMessageStackRow || i == PlusSettingsActivity.this.chatAddSecondsToTimeInChatRow || i == PlusSettingsActivity.this.dialogsForceShowDownloadsButtonRow || i == PlusSettingsActivity.this.chatHideReactionsButtonsInMessagesRow || i == PlusSettingsActivity.this.chatShowAllRecentStickersRow || i == PlusSettingsActivity.this.chatDisableLinkPreviewRow || i == PlusSettingsActivity.this.chatHideTimeInStickersRow || i == PlusSettingsActivity.this.useTelegramDataPathRow || i == PlusSettingsActivity.this.dialogsShowPinDialogButtonRow || i == PlusSettingsActivity.this.dialogsShowLastReactionRow || i == PlusSettingsActivity.this.dialogsHidePreviewMenuRow || i == PlusSettingsActivity.this.dialogsDisableAvatarAnimationRow || i == PlusSettingsActivity.this.chatDisableAvatarAnimationRow || i == PlusSettingsActivity.this.profileDisableAvatarAnimationRow || i == PlusSettingsActivity.this.chatDisablePremiumStickersAnimationRow || i == PlusSettingsActivity.this.chatIncreaseInstantVideoQualityRow || i == PlusSettingsActivity.this.drawerOpenAvatarInsteadOfSettingsRow || i == PlusSettingsActivity.this.dialogsDrawDialogIconBeforeNameRow || i == PlusSettingsActivity.this.chatDoNotPlayNextMediaRow || i == PlusSettingsActivity.this.chatConfirmAudioVideoBeforeSendingRow || i == PlusSettingsActivity.this.chatHidePremiumEmojisTabsRow || i == PlusSettingsActivity.this.chatHidePremiumStickersRow || i == PlusSettingsActivity.this.chatForceSmallReactionsLayoutRow || i == PlusSettingsActivity.this.chatShowBackForwardMusicPlayerButtonsRow || i == PlusSettingsActivity.this.chatCopyLinkOnLongClickRow || i == PlusSettingsActivity.this.topicsViewAllTopicsAsMessagesRow || i == PlusSettingsActivity.this.topicsSaveViewTopicsAsMessagesOptionRow || i == PlusSettingsActivity.this.topicsAllowPinTopicsRow || i == PlusSettingsActivity.this.topicsOpenTopicsAsNormalGroupsRow || i == PlusSettingsActivity.this.topicsShowOnlyGroupsWithTopicsRow || i == PlusSettingsActivity.this.uploadSpeedBoostRow || i == PlusSettingsActivity.this.chatAlwaysShowMediaSpoilersRow || i == PlusSettingsActivity.this.dialogsOpenArchiveOnPullDownRow || i == PlusSettingsActivity.this.chatMarkdownParseLinksRow || i == PlusSettingsActivity.this.profileShowIdRow || i == PlusSettingsActivity.this.topicsDisableHideTopicOnSwipeRow || i == PlusSettingsActivity.this.chatImproveVoiceRecordingQualityRow || i == PlusSettingsActivity.this.showToastErrorsRow || i == PlusSettingsActivity.this.chatAddDateToForwardedMessagesRow || i == PlusSettingsActivity.this.chatHideVoiceTranscriptionButtonRow || i == PlusSettingsActivity.this.chatShowUserStatusCircleOnlyIfOnlineRow || i == PlusSettingsActivity.this.dialogsShowUserStatusCircleOnlyIfOnlineRow || i == PlusSettingsActivity.this.chatHideSlashBotButtonRow || i == PlusSettingsActivity.this.drawerHideSavedMessagesButtonRow || i == PlusSettingsActivity.this.hideStoriesRow || i == PlusSettingsActivity.this.hideCreateStoryButtonRow || i == PlusSettingsActivity.this.profileOpenProfilePicsInsteadOfStoriesRow || i == PlusSettingsActivity.this.profileShowProfilePicDateInsteadOfStatusRow || i == PlusSettingsActivity.this.hideSeenStoriesRow || i == PlusSettingsActivity.this.hideChannelsStoriesRow || i == PlusSettingsActivity.this.openProfilePicsInsteadOfStoriesRow || i == PlusSettingsActivity.this.doNotMarkStoriesAsReadRow || i == PlusSettingsActivity.this.chatDisableUsersThemeModificationsRow || i == PlusSettingsActivity.this.dialogsHidePlusPromoDialogRow) {
                return 3;
            }
            if (i == PlusSettingsActivity.this.emojiPopupSize || i == PlusSettingsActivity.this.dialogsTabsTextSizeRow || i == PlusSettingsActivity.this.dialogsTabsHeightRow || i == PlusSettingsActivity.this.dialogsPicClickRow || i == PlusSettingsActivity.this.dialogsGroupPicClickRow || i == PlusSettingsActivity.this.chatPhotoQualityRow || i == PlusSettingsActivity.this.toastNotificationSizeRow || i == PlusSettingsActivity.this.toastNotificationPaddingRow || i == PlusSettingsActivity.this.toastNotificationPositionRow || i == PlusSettingsActivity.this.chatsToLoadRow || i == PlusSettingsActivity.this.dialogsManageTabsRow || i == PlusSettingsActivity.this.drawerShowOptionsRow || i == PlusSettingsActivity.this.drawerShowPlusOptionsRow || i == PlusSettingsActivity.this.changeHiddenDialogsPasswordRow || i == PlusSettingsActivity.this.chatChangeTranslateLanguageRow || i == PlusSettingsActivity.this.chatTranslationProviderRow || i == PlusSettingsActivity.this.dialogsTabsSwipeSensitivityRow || i == PlusSettingsActivity.this.updateAppMethodRow || i == PlusSettingsActivity.this.chatStickerCellRow || i == PlusSettingsActivity.this.chatSelectDoubleTapActionRow || i == PlusSettingsActivity.this.chatSwipeLeftActionRow || i == PlusSettingsActivity.this.chatSwipeRightActionRow || i == PlusSettingsActivity.this.chatDirectShareButtonActionRow || i == PlusSettingsActivity.this.downloadsSimultaneousDownloadsRow || i == PlusSettingsActivity.this.chatSelectTapAvatarActionRow || i == PlusSettingsActivity.this.chatSelectTapAndHoldAvatarActionRow || i == PlusSettingsActivity.this.downloadsSpeedBoostRow) {
                return 2;
            }
            if (i == PlusSettingsActivity.this.dialogsTabsRow || i == PlusSettingsActivity.this.chatShowDirectShareBtnRow || i == PlusSettingsActivity.this.profileSharedOptionsRow || i == PlusSettingsActivity.this.savePlusSettingsRow || i == PlusSettingsActivity.this.restorePlusSettingsRow || i == PlusSettingsActivity.this.resetPlusSettingsRow || i == PlusSettingsActivity.this.chatShowHideOptionsRow || i == PlusSettingsActivity.this.selectStorageRow || i == PlusSettingsActivity.this.migrateFilesRow || i == PlusSettingsActivity.this.chatActionModeButtonsRow) {
                return 6;
            }
            return (i == PlusSettingsActivity.this.keepOriginalFilenameDetailRow || i == PlusSettingsActivity.this.showOnlineToastNotificationDetailRow || i == PlusSettingsActivity.this.dialogsShowAllInAdminTabDetailRow || i == PlusSettingsActivity.this.hiddenDialogsInfoSectionRow) ? 7 : 2;
        }
    }
}