After hours of looking at the code, i found how to fix it

This commit is contained in:
LucasGGamerM 2022-12-29 13:56:18 -03:00
parent 014398e050
commit e4340f5015
6 changed files with 14 additions and 12 deletions

View File

@ -299,11 +299,9 @@ public class ComposeFragment extends MastodonToolbarFragment implements OnBackPr
sensitiveItem=view.findViewById(R.id.sensitive_item); sensitiveItem=view.findViewById(R.id.sensitive_item);
replyText=view.findViewById(R.id.reply_text); replyText=view.findViewById(R.id.reply_text);
boolean smallStyle = getContext().getResources().getBoolean(R.bool.show_small_publish_button);
if(GlobalUserPreferences.relocatePublishButton){ if(GlobalUserPreferences.relocatePublishButton){
publishButton=view.findViewById(R.id.publish); publishButton=view.findViewById(R.id.publish);
publishButton.setText(editingStatus==null || redraftStatus ? R.string.publish : R.string.save); // publishButton.setText(editingStatus==null || redraftStatus ? R.string.publish : R.string.save);
publishButton.setEllipsize(TextUtils.TruncateAt.END); publishButton.setEllipsize(TextUtils.TruncateAt.END);
publishButton.setOnClickListener(this::onPublishClick); publishButton.setOnClickListener(this::onPublishClick);
publishButton.setSingleLine(true); publishButton.setSingleLine(true);

View File

@ -0,0 +1,3 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android" android:width="24dp" android:height="24dp" android:viewportWidth="24" android:viewportHeight="24">
<path android:pathData="M5.694 12L2.299 3.27C2.063 2.664 2.655 2.083 3.241 2.29l0.093 0.039 18 9c0.518 0.259 0.55 0.968 0.097 1.284l-0.097 0.058-18 9c-0.583 0.291-1.216-0.245-1.065-0.848l0.03-0.095L5.694 12 2.299 3.27 5.694 12zM4.402 4.54l2.61 6.71h6.627c0.38 0 0.693 0.282 0.743 0.648L14.389 12c0 0.38-0.282 0.693-0.649 0.743l-0.1 0.007H7.01l-2.609 6.71L19.322 12 4.401 4.54z" android:fillColor="?colorButtonText"/>
</vector>

View File

@ -0,0 +1,8 @@
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:drawable="@drawable/ic_fluent_send_24_enabled" android:state_activated="true"/>
<item android:drawable="@drawable/ic_fluent_send_24_enabled" android:state_checked="true"/>
<item android:drawable="@drawable/ic_fluent_send_24_enabled" android:state_selected="true"/>
<item android:drawable="@drawable/ic_fluent_send_24_enabled" android:state_enabled="true"/>
<item android:drawable="@drawable/ic_fluent_send_24_regular"/>
</selector>

View File

@ -322,7 +322,8 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginStart="8dp" android:layout_marginStart="8dp"
android:visibility="gone" android:visibility="gone"
android:autoSizeTextType="uniform" android:tooltipText="@string/publish"
android:drawableStart="@drawable/ic_fluent_send_24_selector"
/> />
</LinearLayout> </LinearLayout>

View File

@ -1,4 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<bool name="show_small_publish_button">false</bool>
</resources>

View File

@ -1,4 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<bool name="show_small_publish_button">true</bool>
</resources>