本文整理汇总了Java中org.telegram.ui.ActionBar.ActionBar.getCurrentActionBarHeight方法的典型用法代码示例。如果您正苦于以下问题:Java ActionBar.getCurrentActionBarHeight方法的具体用法?Java ActionBar.getCurrentActionBarHeight怎么用?Java ActionBar.getCurrentActionBarHeight使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.telegram.ui.ActionBar.ActionBar
的用法示例。
在下文中一共展示了ActionBar.getCurrentActionBarHeight方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: onLayout
import org.telegram.ui.ActionBar.ActionBar; //导入方法依赖的package包/类
@Override
protected void onLayout(boolean changed, int left, int top, int right, int bottom) {
int actionBarHeight = ActionBar.getCurrentActionBarHeight("CHAT");
int viewTop = (actionBarHeight - AndroidUtilities.dp(42)) / 2 + (Build.VERSION.SDK_INT >= 21 ? AndroidUtilities.statusBarHeight : 0);
avatarImageView.layout(AndroidUtilities.dp(8), viewTop, AndroidUtilities.dp(42 + 8), viewTop + AndroidUtilities.dp(42));
titleTextView.layout(AndroidUtilities.dp(8 + 54), viewTop + AndroidUtilities.dp(1.3f), AndroidUtilities.dp(8 + 54) + titleTextView.getMeasuredWidth(), viewTop + titleTextView.getTextHeight() + AndroidUtilities.dp(1.3f));
if (timeItem != null) {
timeItem.layout(AndroidUtilities.dp(8 + 16), viewTop + AndroidUtilities.dp(15), AndroidUtilities.dp(8 + 16 + 34), viewTop + AndroidUtilities.dp(15 + 34));
}
if (radioButton != null && radioButton.getVisibility() == VISIBLE) {
subtitleTextView.layout(AndroidUtilities.dp(8 + 54 + 20), viewTop + AndroidUtilities.dp(24), AndroidUtilities.dp(8 + 54 + 20) + subtitleTextView.getMeasuredWidth(), viewTop + subtitleTextView.getTextHeight() + AndroidUtilities.dp(24));
viewTop = viewTop + subtitleTextView.getTextHeight() / 2 + AndroidUtilities.dp(12);
radioButton.layout(AndroidUtilities.dp(8 + 50), viewTop, AndroidUtilities.dp(8 + 50 + 24), viewTop + AndroidUtilities.dp(24));
} else {
subtitleTextView.layout(AndroidUtilities.dp(8 + 54), viewTop + AndroidUtilities.dp(24), AndroidUtilities.dp(8 + 54) + subtitleTextView.getMeasuredWidth(), viewTop + subtitleTextView.getTextHeight() + AndroidUtilities.dp(24));
}
}
示例2: getSideCoord
import org.telegram.ui.ActionBar.ActionBar; //导入方法依赖的package包/类
private static int getSideCoord(boolean isX, int side, float p, int sideSize) {
int total;
if (isX) {
total = AndroidUtilities.displaySize.x - sideSize;
} else {
total = AndroidUtilities.displaySize.y - sideSize - ActionBar.getCurrentActionBarHeight();
}
int result;
if (side == 0) {
result = AndroidUtilities.dp(10);
} else if (side == 1) {
result = total - AndroidUtilities.dp(10);
} else {
result = Math.round((total - AndroidUtilities.dp(20)) * p) + AndroidUtilities.dp(10);
}
if (!isX) {
result += ActionBar.getCurrentActionBarHeight();
}
return result;
}
示例3: onWindowSizeChanged
import org.telegram.ui.ActionBar.ActionBar; //导入方法依赖的package包/类
private void onWindowSizeChanged() {
int size = sizeNotifierLayout.getHeight();
if (!keyboardVisible) {
size -= emojiPadding;
}
if (delegate != null) {
delegate.onWindowSizeChanged(size);
}
if (topView != null) {
if (size < AndroidUtilities.dp(72) + ActionBar.getCurrentActionBarHeight()) {
if (allowShowTopView) {
allowShowTopView = false;
if (needShowTopView) {
topView.setVisibility(GONE);
resizeForTopView(false);
topView.setTranslationY(topView.getLayoutParams().height);
}
}
} else {
if (!allowShowTopView) {
allowShowTopView = true;
if (needShowTopView) {
topView.setVisibility(VISIBLE);
resizeForTopView(true);
topView.setTranslationY(0);
}
}
}
}
}
示例4: onLayout
import org.telegram.ui.ActionBar.ActionBar; //导入方法依赖的package包/类
@Override
protected void onLayout(boolean changed, int left, int top, int right, int bottom) {
int actionBarHeight = ActionBar.getCurrentActionBarHeight();
int viewTop = (actionBarHeight - AndroidUtilities.dp(42)) / 2 + (Build.VERSION.SDK_INT >= 21 ? AndroidUtilities.statusBarHeight : 0);
avatarImageView.layout(AndroidUtilities.dp(8), viewTop, AndroidUtilities.dp(42 + 8), viewTop + AndroidUtilities.dp(42));
titleTextView.layout(AndroidUtilities.dp(8 + 54), viewTop + AndroidUtilities.dp(1.3f), AndroidUtilities.dp(8 + 54) + titleTextView.getMeasuredWidth(), viewTop + titleTextView.getTextHeight() + AndroidUtilities.dp(1.3f));
if (timeItem != null) {
timeItem.layout(AndroidUtilities.dp(8 + 16), viewTop + AndroidUtilities.dp(15), AndroidUtilities.dp(8 + 16 + 34), viewTop + AndroidUtilities.dp(15 + 34));
}
subtitleTextView.layout(AndroidUtilities.dp(8 + 54), viewTop + AndroidUtilities.dp(24), AndroidUtilities.dp(8 + 54) + subtitleTextView.getMeasuredWidth(), viewTop + subtitleTextView.getTextHeight() + AndroidUtilities.dp(24));
}
示例5: getAdditionY
import org.telegram.ui.ActionBar.ActionBar; //导入方法依赖的package包/类
private int getAdditionY() {
if (currentEditMode == 3) {
return ActionBar.getCurrentActionBarHeight() + (Build.VERSION.SDK_INT >= 21 ? AndroidUtilities.statusBarHeight : 0);
} else if (currentEditMode != 0) {
return AndroidUtilities.dp(14) + (Build.VERSION.SDK_INT >= 21 ? AndroidUtilities.statusBarHeight : 0);
}
return 0;
}
示例6: getContainerViewHeight
import org.telegram.ui.ActionBar.ActionBar; //导入方法依赖的package包/类
private int getContainerViewHeight(int mode) {
int height = AndroidUtilities.displaySize.y;
if (mode == 0 && Build.VERSION.SDK_INT >= 21) {
height += AndroidUtilities.statusBarHeight;
}
if (mode == 1) {
height -= AndroidUtilities.dp(76);
} else if (mode == 2) {
height -= AndroidUtilities.dp(154);
} else if (mode == 3) {
height -= AndroidUtilities.dp(48) + ActionBar.getCurrentActionBarHeight();
}
return height;
}
示例7: onMeasure
import org.telegram.ui.ActionBar.ActionBar; //导入方法依赖的package包/类
@Override
protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
int width = MeasureSpec.getSize(widthMeasureSpec);
int height = MeasureSpec.getSize(heightMeasureSpec);
setMeasuredDimension(width, height);
actionBar.measure(widthMeasureSpec, MeasureSpec.makeMeasureSpec(height, MeasureSpec.AT_MOST));
float bitmapW;
float bitmapH;
int fullHeight = AndroidUtilities.displaySize.y - ActionBar.getCurrentActionBarHeight();
int maxHeight = fullHeight - AndroidUtilities.dp(48);
if (bitmapToEdit != null) {
bitmapW = isSidewardOrientation() ? bitmapToEdit.getHeight() : bitmapToEdit.getWidth();
bitmapH = isSidewardOrientation() ? bitmapToEdit.getWidth() : bitmapToEdit.getHeight();
} else {
bitmapW = width;
bitmapH = height - ActionBar.getCurrentActionBarHeight() - AndroidUtilities.dp(48);
}
float renderWidth = width;
float renderHeight = (float) Math.floor(renderWidth * bitmapH / bitmapW);
if (renderHeight > maxHeight) {
renderHeight = maxHeight;
renderWidth = (float) Math.floor(renderHeight * bitmapW / bitmapH);
}
renderView.measure(MeasureSpec.makeMeasureSpec((int) renderWidth, MeasureSpec.EXACTLY), MeasureSpec.makeMeasureSpec((int) renderHeight, MeasureSpec.EXACTLY));
entitiesView.measure(MeasureSpec.makeMeasureSpec((int) paintingSize.width, MeasureSpec.EXACTLY), MeasureSpec.makeMeasureSpec((int) paintingSize.height, MeasureSpec.EXACTLY));
dimView.measure(widthMeasureSpec, MeasureSpec.makeMeasureSpec(maxHeight, MeasureSpec.AT_MOST));
selectionContainerView.measure(widthMeasureSpec, MeasureSpec.makeMeasureSpec(maxHeight, MeasureSpec.EXACTLY));
colorPicker.measure(MeasureSpec.makeMeasureSpec(width, MeasureSpec.EXACTLY), MeasureSpec.makeMeasureSpec(maxHeight, MeasureSpec.EXACTLY));
toolsView.measure(widthMeasureSpec, MeasureSpec.makeMeasureSpec(AndroidUtilities.dp(48), MeasureSpec.EXACTLY));
if (stickersView != null) {
stickersView.measure(widthMeasureSpec, MeasureSpec.makeMeasureSpec(fullHeight, MeasureSpec.EXACTLY));
}
}
示例8: getContainerViewHeight
import org.telegram.ui.ActionBar.ActionBar; //导入方法依赖的package包/类
private int getContainerViewHeight(int mode) {
int height = AndroidUtilities.displaySize.y;
if (mode == 0 && Build.VERSION.SDK_INT >= 21) {
height += AndroidUtilities.statusBarHeight;
}
if (mode == 1) {
height -= AndroidUtilities.dp(48 + 32 + 64);
} else if (mode == 2) {
height -= AndroidUtilities.dp(154 + 60);
} else if (mode == 3) {
height -= AndroidUtilities.dp(48) + ActionBar.getCurrentActionBarHeight();
}
return height;
}
示例9: onMeasure
import org.telegram.ui.ActionBar.ActionBar; //导入方法依赖的package包/类
@Override
protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
int totalHeight = MeasureSpec.getSize(heightMeasureSpec);
if (totalHeight == 0) {
totalHeight = AndroidUtilities.displaySize.y - ActionBar.getCurrentActionBarHeight() - (Build.VERSION.SDK_INT >= 21 ? AndroidUtilities.statusBarHeight : 0);
}
ArrayList<TLRPC.RecentMeUrl> arrayList = MessagesController.getInstance().hintDialogs;
if (!arrayList.isEmpty()) {
totalHeight -= AndroidUtilities.dp(72) * arrayList.size() + arrayList.size() - 1 + AndroidUtilities.dp(12 + 38);
}
super.onMeasure(MeasureSpec.makeMeasureSpec(MeasureSpec.getSize(widthMeasureSpec), MeasureSpec.EXACTLY), MeasureSpec.makeMeasureSpec(totalHeight, MeasureSpec.EXACTLY));
}
示例10: onLayout
import org.telegram.ui.ActionBar.ActionBar; //导入方法依赖的package包/类
@Override
protected void onLayout(boolean changed, int left, int top, int right, int bottom) {
int actionBarHeight = ActionBar.getCurrentActionBarHeight();
int viewTop = (actionBarHeight - AndroidUtilities.dp(42)) / 2 + (Build.VERSION.SDK_INT >= 21 ? AndroidUtilities.statusBarHeight : 0);
avatarImageView.layout(AndroidUtilities.dp(8), viewTop, AndroidUtilities.dp(42 + 8), viewTop + AndroidUtilities.dp(42));
if (subtitleTextView.getVisibility() == VISIBLE) {
titleTextView.layout(AndroidUtilities.dp(8 + 54), viewTop + AndroidUtilities.dp(1.3f), AndroidUtilities.dp(8 + 54) + titleTextView.getMeasuredWidth(), viewTop + titleTextView.getTextHeight() + AndroidUtilities.dp(1.3f));
} else {
titleTextView.layout(AndroidUtilities.dp(8 + 54), viewTop + AndroidUtilities.dp(11), AndroidUtilities.dp(8 + 54) + titleTextView.getMeasuredWidth(), viewTop + titleTextView.getTextHeight() + AndroidUtilities.dp(11));
}
if (timeItem != null) {
timeItem.layout(AndroidUtilities.dp(8 + 16), viewTop + AndroidUtilities.dp(15), AndroidUtilities.dp(8 + 16 + 34), viewTop + AndroidUtilities.dp(15 + 34));
}
subtitleTextView.layout(AndroidUtilities.dp(8 + 54), viewTop + AndroidUtilities.dp(24), AndroidUtilities.dp(8 + 54) + subtitleTextView.getMeasuredWidth(), viewTop + subtitleTextView.getTextHeight() + AndroidUtilities.dp(24));
}
示例11: onMeasure
import org.telegram.ui.ActionBar.ActionBar; //导入方法依赖的package包/类
@Override
protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
int width = MeasureSpec.getSize(widthMeasureSpec);
int height = MeasureSpec.getSize(heightMeasureSpec);
setMeasuredDimension(width, height);
float bitmapW;
float bitmapH;
int fullHeight = AndroidUtilities.displaySize.y - ActionBar.getCurrentActionBarHeight();
int maxHeight = fullHeight - AndroidUtilities.dp(48);
if (bitmapToEdit != null) {
bitmapW = isSidewardOrientation() ? bitmapToEdit.getHeight() : bitmapToEdit.getWidth();
bitmapH = isSidewardOrientation() ? bitmapToEdit.getWidth() : bitmapToEdit.getHeight();
} else {
bitmapW = width;
bitmapH = height - ActionBar.getCurrentActionBarHeight() - AndroidUtilities.dp(48);
}
float renderWidth = width;
float renderHeight = (float) Math.floor(renderWidth * bitmapH / bitmapW);
if (renderHeight > maxHeight) {
renderHeight = maxHeight;
renderWidth = (float) Math.floor(renderHeight * bitmapW / bitmapH);
}
renderView.measure(MeasureSpec.makeMeasureSpec((int) renderWidth, MeasureSpec.EXACTLY), MeasureSpec.makeMeasureSpec((int) renderHeight, MeasureSpec.EXACTLY));
entitiesView.measure(MeasureSpec.makeMeasureSpec((int) paintingSize.width, MeasureSpec.EXACTLY), MeasureSpec.makeMeasureSpec((int) paintingSize.height, MeasureSpec.EXACTLY));
dimView.measure(widthMeasureSpec, MeasureSpec.makeMeasureSpec(maxHeight, MeasureSpec.AT_MOST));
selectionContainerView.measure(widthMeasureSpec, MeasureSpec.makeMeasureSpec(maxHeight, MeasureSpec.EXACTLY));
colorPicker.measure(MeasureSpec.makeMeasureSpec(width, MeasureSpec.EXACTLY), MeasureSpec.makeMeasureSpec(maxHeight, MeasureSpec.EXACTLY));
toolsView.measure(widthMeasureSpec, MeasureSpec.makeMeasureSpec(AndroidUtilities.dp(48), MeasureSpec.EXACTLY));
if (stickersView != null) {
stickersView.measure(widthMeasureSpec, MeasureSpec.makeMeasureSpec(AndroidUtilities.displaySize.y, MeasureSpec.EXACTLY));
}
}
示例12: fixVideoSize
import org.telegram.ui.ActionBar.ActionBar; //导入方法依赖的package包/类
private void fixVideoSize() {
if (fragmentView == null || getParentActivity() == null) {
return;
}
int viewHeight;
if (AndroidUtilities.isTablet()) {
viewHeight = AndroidUtilities.dp(472);
} else {
viewHeight = AndroidUtilities.displaySize.y - AndroidUtilities.statusBarHeight - ActionBar.getCurrentActionBarHeight();
}
int width;
int height;
if (AndroidUtilities.isTablet()) {
width = AndroidUtilities.dp(490);
height = viewHeight - AndroidUtilities.dp(276 + (compressVideo.getVisibility() == View.VISIBLE ? 20 : 0));
} else {
if (getParentActivity().getResources().getConfiguration().orientation == Configuration.ORIENTATION_LANDSCAPE) {
width = AndroidUtilities.displaySize.x / 3 - AndroidUtilities.dp(24);
height = viewHeight - AndroidUtilities.dp(32);
} else {
width = AndroidUtilities.displaySize.x;
height = viewHeight - AndroidUtilities.dp(276 + (compressVideo.getVisibility() == View.VISIBLE ? 20 : 0));
}
}
int aWidth = width;
int aHeight = height;
int vwidth = rotationValue == 90 || rotationValue == 270 ? originalHeight : originalWidth;
int vheight = rotationValue == 90 || rotationValue == 270 ? originalWidth : originalHeight;
float wr = (float) width / (float) vwidth;
float hr = (float) height / (float) vheight;
float ar = (float) vwidth / (float) vheight;
if (wr > hr) {
width = (int) (height * ar);
} else {
height = (int) (width / ar);
}
if (textureView != null) {
FrameLayout.LayoutParams layoutParams = (FrameLayout.LayoutParams) textureView.getLayoutParams();
layoutParams.width = width;
layoutParams.height = height;
layoutParams.leftMargin = 0;
layoutParams.topMargin = 0;
textureView.setLayoutParams(layoutParams);
}
}
示例13: fixLayoutInternal
import org.telegram.ui.ActionBar.ActionBar; //导入方法依赖的package包/类
private void fixLayoutInternal(final boolean resume) {
if (listView != null) {
int height = (actionBar.getOccupyStatusBar() ? AndroidUtilities.statusBarHeight : 0) + ActionBar.getCurrentActionBarHeight();
int viewHeight = fragmentView.getMeasuredHeight();
if (viewHeight == 0) {
return;
}
overScrollHeight = viewHeight - AndroidUtilities.dp(66) - height;
FrameLayout.LayoutParams layoutParams = (FrameLayout.LayoutParams) listView.getLayoutParams();
layoutParams.topMargin = height;
listView.setLayoutParams(layoutParams);
layoutParams = (FrameLayout.LayoutParams) mapViewClip.getLayoutParams();
layoutParams.topMargin = height;
layoutParams.height = overScrollHeight;
mapViewClip.setLayoutParams(layoutParams);
layoutParams = (FrameLayout.LayoutParams) searchListView.getLayoutParams();
layoutParams.topMargin = height;
searchListView.setLayoutParams(layoutParams);
adapter.setOverScrollHeight(overScrollHeight);
layoutParams = (FrameLayout.LayoutParams) mapView.getLayoutParams();
if (layoutParams != null) {
layoutParams.height = overScrollHeight + AndroidUtilities.dp(10);
if (googleMap != null) {
googleMap.setPadding(0, 0, 0, AndroidUtilities.dp(10));
}
mapView.setLayoutParams(layoutParams);
}
adapter.notifyDataSetChanged();
if (resume) {
listView.setSelectionFromTop(0, -(int) (AndroidUtilities.dp(56) * 2.5f + AndroidUtilities.dp(36 + 66)));
updateClipView(listView.getFirstVisiblePosition());
listView.post(new Runnable() {
@Override
public void run() {
listView.setSelectionFromTop(0, -(int) (AndroidUtilities.dp(56) * 2.5f + AndroidUtilities.dp(36 + 66)));
updateClipView(listView.getFirstVisiblePosition());
}
});
} else {
updateClipView(listView.getFirstVisiblePosition());
}
}
}
示例14: needLayout
import org.telegram.ui.ActionBar.ActionBar; //导入方法依赖的package包/类
private void needLayout() {
FrameLayout.LayoutParams layoutParams;
int newTop = (actionBar.getOccupyStatusBar() ? AndroidUtilities.statusBarHeight : 0) + ActionBar.getCurrentActionBarHeight();
if (listView != null) {
layoutParams = (FrameLayout.LayoutParams) listView.getLayoutParams();
if (layoutParams.topMargin != newTop) {
layoutParams.topMargin = newTop;
listView.setLayoutParams(layoutParams);
ViewProxy.setTranslationY(extraHeightView, newTop);
}
}
if (avatarImage != null) {
float diff = extraHeight / (float) AndroidUtilities.dp(88);
ViewProxy.setScaleY(extraHeightView, diff);
ViewProxy.setTranslationY(shadowView, newTop + extraHeight);
final boolean setVisible = diff > 0.2f;
SharedPreferences themePrefs = ApplicationLoader.applicationContext.getSharedPreferences(AndroidUtilities.THEME_PREFS, AndroidUtilities.THEME_PREFS_MODE);
int aSize = themePrefs.getInt("prefAvatarSize", 42);
//ViewProxy.setScaleX(avatarImage, (42 + 18 * diff) / 42.0f);
//ViewProxy.setScaleY(avatarImage, (42 + 18 * diff) / 42.0f);
ViewProxy.setScaleX(avatarImage, (aSize + 18 * diff) / (aSize * 1.0f));
ViewProxy.setScaleY(avatarImage, (aSize + 18 * diff) / (aSize * 1.0f));
float avatarY = (actionBar.getOccupyStatusBar() ? AndroidUtilities.statusBarHeight : 0) + ActionBar.getCurrentActionBarHeight() / 2.0f * (1.0f + diff) - 21 * AndroidUtilities.density + 27 * AndroidUtilities.density * diff;
ViewProxy.setTranslationX(avatarImage, -AndroidUtilities.dp(47) * diff);
ViewProxy.setTranslationY(avatarImage, (float) Math.ceil(avatarY));
ViewProxy.setTranslationX(nameTextView, -21 * AndroidUtilities.density * diff);
ViewProxy.setTranslationY(nameTextView, (float) Math.floor(avatarY) - (float) Math.ceil(AndroidUtilities.density) + (float) Math.floor(7 * AndroidUtilities.density * diff));
ViewProxy.setTranslationX(onlineTextView, -21 * AndroidUtilities.density * diff);
ViewProxy.setTranslationY(onlineTextView, (float) Math.floor(avatarY) + AndroidUtilities.dp(22) + (float) Math.floor(11 * AndroidUtilities.density) * diff);
//ViewProxy.setTranslationX(statusTextView, -21 * AndroidUtilities.density * diff);
//ViewProxy.setTranslationY(statusTextView, (float) Math.floor(avatarY) + AndroidUtilities.dp(32) + (float) Math.floor(22 * AndroidUtilities.density) * diff);
ViewProxy.setScaleX(nameTextView, 1.0f + 0.12f * diff);
ViewProxy.setScaleY(nameTextView, 1.0f + 0.12f * diff);
//if (diff > 0.85) {
// statusTextView.setVisibility(View.VISIBLE);
//} else {
// statusTextView.setVisibility(View.GONE);
//}
}
}
示例15: fixLayoutInternal
import org.telegram.ui.ActionBar.ActionBar; //导入方法依赖的package包/类
private void fixLayoutInternal(final boolean resume) {
if (listView != null) {
int height = (actionBar.getOccupyStatusBar() ? AndroidUtilities.statusBarHeight : 0) + ActionBar.getCurrentActionBarHeight();
int viewHeight = fragmentView.getMeasuredHeight();
if (viewHeight == 0) {
return;
}
overScrollHeight = viewHeight - AndroidUtilities.dp(66) - height;
FrameLayout.LayoutParams layoutParams = (FrameLayout.LayoutParams) listView.getLayoutParams();
layoutParams.topMargin = height;
listView.setLayoutParams(layoutParams);
layoutParams = (FrameLayout.LayoutParams) mapViewClip.getLayoutParams();
layoutParams.topMargin = height;
layoutParams.height = overScrollHeight;
mapViewClip.setLayoutParams(layoutParams);
if (searchListView != null) {
layoutParams = (FrameLayout.LayoutParams) searchListView.getLayoutParams();
layoutParams.topMargin = height;
searchListView.setLayoutParams(layoutParams);
}
adapter.setOverScrollHeight(overScrollHeight);
layoutParams = (FrameLayout.LayoutParams) mapView.getLayoutParams();
if (layoutParams != null) {
layoutParams.height = overScrollHeight + AndroidUtilities.dp(10);
if (googleMap != null) {
googleMap.setPadding(0, 0, AndroidUtilities.dp(70), AndroidUtilities.dp(10));
}
mapView.setLayoutParams(layoutParams);
}
adapter.notifyDataSetChanged();
if (resume) {
layoutManager.scrollToPositionWithOffset(0, -AndroidUtilities.dp(32 + (liveLocationType == 1 || liveLocationType == 2 ? 66 : 0)));
updateClipView(layoutManager.findFirstVisibleItemPosition());
listView.post(new Runnable() {
@Override
public void run() {
layoutManager.scrollToPositionWithOffset(0, -AndroidUtilities.dp(32 + (liveLocationType == 1 || liveLocationType == 2 ? 66 : 0)));
updateClipView(layoutManager.findFirstVisibleItemPosition());
}
});
} else {
updateClipView(layoutManager.findFirstVisibleItemPosition());
}
}
}