Work fork of an Android Jabber client for bridge users git.sr.ht/~singpolyma/cheogram-android
sopranica sgx xmpp jabber
0

Configure Feed

Select the types of activity you want to include in your feed.

Nicer custom tab

Stephen Paul Weber (Sep 18, 2024, 12:40 AM -0500) 40b28c7f 2276ee00

+24 -1
+10 -1
src/cheogram/java/com/cheogram/android/BrowserHelper.java
··· 15 15 import java.util.Set; 16 16 import androidx.browser.customtabs.CustomTabsIntent; 17 17 18 + import eu.siacs.conversations.R; 19 + import eu.siacs.conversations.persistance.FileBackend; 18 20 import eu.siacs.conversations.ui.XmppActivity; 19 21 20 22 public class BrowserHelper { ··· 78 80 launchNativeBeforeApi30(context, uri); 79 81 80 82 if (!launched) { 81 - var builder = new CustomTabsIntent.Builder().setShowTitle(true); 83 + var builder = new CustomTabsIntent.Builder() 84 + .setShowTitle(true) 85 + .setShareState(CustomTabsIntent.SHARE_STATE_ON) 86 + .setBackgroundInteractionEnabled(true) 87 + .setStartAnimations(context, R.anim.slide_in_right, R.anim.slide_out_left) 88 + .setExitAnimations(context, android.R.anim.slide_in_left, android.R.anim.slide_out_right) 89 + .setCloseButtonIcon(FileBackend.drawDrawable(context.getDrawable(R.drawable.ic_arrow_back_24dp))) 90 + .setCloseButtonPosition(CustomTabsIntent.CLOSE_BUTTON_POSITION_START); 82 91 if (context instanceof XmppActivity) { 83 92 builder = builder.setColorScheme(((XmppActivity) context).isDark() ? CustomTabsIntent.COLOR_SCHEME_DARK : CustomTabsIntent.COLOR_SCHEME_LIGHT); 84 93 }
+7
src/cheogram/res/anim/slide_in_right.xml
··· 1 + <?xml version="1.0" encoding="utf-8"?> 2 + <set xmlns:android="http://schemas.android.com/apk/res/android"> 3 + <translate android:fromXDelta="50%p" android:toXDelta="0" 4 + android:duration="@android:integer/config_mediumAnimTime"/> 5 + <alpha android:fromAlpha="0.0" android:toAlpha="1.0" 6 + android:duration="@android:integer/config_mediumAnimTime" /> 7 + </set>
+7
src/cheogram/res/anim/slide_out_left.xml
··· 1 + <?xml version="1.0" encoding="utf-8"?> 2 + <set xmlns:android="http://schemas.android.com/apk/res/android"> 3 + <translate android:fromXDelta="0" android:toXDelta="-50%p" 4 + android:duration="@android:integer/config_mediumAnimTime"/> 5 + <alpha android:fromAlpha="1.0" android:toAlpha="0.0" 6 + android:duration="@android:integer/config_mediumAnimTime" /> 7 + </set>