1
0
mirror of https://github.com/KokaKiwi/BarInsta synced 2024-11-21 22:27:29 +00:00
This commit is contained in:
Austin Huang 2020-07-25 19:12:13 -04:00
parent 71ac832059
commit da8cd6bc9e
No known key found for this signature in database
GPG Key ID: 84C23AA04587A91F
3 changed files with 13 additions and 0 deletions

View File

@ -214,6 +214,12 @@ public final class PostViewer extends BaseLanguageActivity {
if (Utils.isEmpty(settingsHelper.getString(Constants.COOKIE))) {
viewerBinding.btnLike.setVisibility(View.GONE);
viewerBinding.btnBookmark.setVisibility(View.GONE);
viewerBinding.postActions.setVisibility(View.GONE);
viewerBinding.postActions.setLayoutParams(new LinearLayout.LayoutParams(
LinearLayout.LayoutParams.MATCH_PARENT, 0, 0
));
containerLayoutParams.weight = 2.2f;
viewerBinding.container.setLayoutParams(containerLayoutParams);
}
else {
viewerBinding.btnLike.setOnClickListener(onClickListener);
@ -328,6 +334,7 @@ public final class PostViewer extends BaseLanguageActivity {
LinearLayout.LayoutParams.MATCH_PARENT, 0, 0.55f
));
containerLayoutParams.weight = 1.35f;
containerLayoutParams.weight += (Utils.isEmpty(settingsHelper.getString(Constants.COOKIE))) ? 0.3f : 0;
viewerBinding.container.setLayoutParams(containerLayoutParams);
viewerBinding.mediaList.setVisibility(View.VISIBLE);
}
@ -557,6 +564,10 @@ public final class PostViewer extends BaseLanguageActivity {
}
lastSlidePos = slidePos;
containerLayoutParams.weight = (viewerBinding.mediaList.getVisibility() == View.VISIBLE) ? 1.35f : 1.9f;
containerLayoutParams.weight += (Utils.isEmpty(settingsHelper.getString(Constants.COOKIE))) ? 0.3f : 0;
viewerBinding.container.setLayoutParams(containerLayoutParams);
postCaption = viewerPostModel.getPostCaption();
if (Utils.hasMentions(postCaption)) {

View File

@ -99,6 +99,7 @@
android:layout_weight="1"/>
<androidx.appcompat.widget.LinearLayoutCompat
android:id="@+id/postActions"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="0.3"

View File

@ -2,6 +2,7 @@
* Non-logged-in users now have an "add/remove from favorites" button on the profile/hashtag page, alongside Quick Access.
* Update checker will now have a F-Droid button
* Updated Italian and Simplified Chinese translations
* Crash reporter now directs to `instagrabber@austinhuang.me`
* Adjusted grid size threshold at popular request
* Adjusted post viewer component sizes (to prevent the buttons being squished downwards, but the exact outcome depends on device)
* Fixed a bug where highlights of the viewed user gets carried to other users