File tree Expand file tree Collapse file tree
java/org/schabi/newpipe/fragments/list/comments Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -85,8 +85,13 @@ protected Supplier<View> getListHeaderSupplier() {
8585
8686 // load the author avatar
8787 PicassoHelper .loadAvatar (item .getUploaderAvatars ()).into (binding .authorAvatar );
88- binding .authorAvatar .setVisibility (ImageStrategy .shouldLoadImages ()
89- ? View .VISIBLE : View .GONE );
88+ if (ImageStrategy .shouldLoadImages ()) {
89+ binding .authorAvatar .setVisibility (View .VISIBLE );
90+ } else {
91+ binding .authorAvatar .setVisibility (View .GONE );
92+ ((ConstraintLayout .LayoutParams ) binding .authorName .getLayoutParams ())
93+ .setMarginStart (DeviceUtils .dpToPx (16 , requireContext ()));
94+ }
9095
9196 // setup author name and comment date
9297 binding .authorName .setText (item .getUploaderName ());
Original file line number Diff line number Diff line change 2424 android : layout_height =" wrap_content"
2525 android : layout_marginStart =" 8dp"
2626 android : layout_marginEnd =" 8dp"
27+ android : layout_marginTop =" 16dp"
2728 android : ellipsize =" end"
2829 android : lines =" 1"
2930 android : textAppearance =" ?android:attr/textAppearanceLarge"
3031 android : textSize =" 16sp"
3132 app : layout_constraintBottom_toTopOf =" @+id/uploadDate"
3233 app : layout_constraintEnd_toStartOf =" @+id/thumbsUpImage"
3334 app : layout_constraintStart_toEndOf =" @+id/authorAvatar"
34- app : layout_constraintTop_toTopOf =" @+id/authorAvatar "
35+ app : layout_constraintTop_toTopOf =" parent "
3536 tools : text =" @tools:sample/lorem/random" />
3637
3738 <org .schabi.newpipe.views.NewPipeTextView
3839 android : id =" @+id/uploadDate"
3940 android : layout_width =" 0dp"
4041 android : layout_height =" wrap_content"
41- android : layout_marginStart =" 8dp"
4242 android : layout_marginEnd =" 8dp"
4343 android : ellipsize =" end"
4444 android : lines =" 1"
4545 android : textAppearance =" ?android:attr/textAppearanceSmall"
4646 android : textSize =" 14sp"
47- app : layout_constraintBottom_toBottomOf =" @+id/authorAvatar"
4847 app : layout_constraintEnd_toStartOf =" @+id/thumbsUpImage"
49- app : layout_constraintStart_toEndOf =" @+id/authorAvatar "
48+ app : layout_constraintStart_toStartOf =" @+id/authorName "
5049 app : layout_constraintTop_toBottomOf =" @+id/authorName"
5150 tools : text =" 5 months ago" />
5251
You can’t perform that action at this time.
0 commit comments