Merge branch 'develop'
This commit is contained in:
commit
3f2164ce46
|
@ -7,8 +7,8 @@ android {
|
|||
applicationId "fr.gouv.etalab.mastodon"
|
||||
minSdkVersion 15
|
||||
targetSdkVersion 28
|
||||
versionCode 147
|
||||
versionName "1.14.2"
|
||||
versionCode 148
|
||||
versionName "1.14.3"
|
||||
}
|
||||
flavorDimensions "default"
|
||||
buildTypes {
|
||||
|
|
|
@ -784,6 +784,7 @@ public class TootActivity extends BaseActivity implements OnRetrieveSearcAccount
|
|||
WeakReference<Activity> activityWeakReference;
|
||||
android.net.Uri uriFile;
|
||||
Account accountReply;
|
||||
|
||||
asyncPicture(Activity activity, Account accountReply, android.net.Uri uri){
|
||||
this.activityWeakReference = new WeakReference<>(activity);
|
||||
this.uriFile = uri;
|
||||
|
|
|
@ -559,7 +559,7 @@ public class API {
|
|||
List<HowToVideo> howToVideos = new ArrayList<>();
|
||||
try {
|
||||
HttpsConnection httpsConnection = new HttpsConnection(context);
|
||||
String response = httpsConnection.get("https://peertube.fr/api/v1/video-channels/bb32394a-a6d2-4f41-9b8e-ad9514a66009/videos", 60, null, null);
|
||||
String response = httpsConnection.get("https://peertube.social/api/v1/video-channels/mastalab_channel/videos", 60, null, null);
|
||||
JSONArray jsonArray = new JSONObject(response).getJSONArray("data");
|
||||
howToVideos = parseHowTos(jsonArray);
|
||||
} catch (HttpsConnection.HttpsConnectionException e) {
|
||||
|
|
|
@ -118,14 +118,14 @@ public class HowToVideosAdapter extends BaseAdapter implements OnListActionInter
|
|||
next.setBounds(0,0,(int) (30 * scale + 0.5f),(int) (30 * scale + 0.5f));
|
||||
holder.how_to_description.setCompoundDrawables(null, null, next, null);
|
||||
Glide.with(holder.how_to_image.getContext())
|
||||
.load("https://peertube.fr" + howToVideo.getThumbnailPath())
|
||||
.load("https://peertube.social" + howToVideo.getThumbnailPath())
|
||||
.into(holder.how_to_image);
|
||||
holder.how_to_container.setOnClickListener(new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
Intent intent = new Intent(context, WebviewActivity.class);
|
||||
Bundle b = new Bundle();
|
||||
String finalUrl = "https://peertube.fr" + howToVideo.getEmbedPath();
|
||||
String finalUrl = "https://peertube.social" + howToVideo.getEmbedPath();
|
||||
b.putString("url", finalUrl);
|
||||
b.putBoolean("peertubeLink", true);
|
||||
Pattern link = Pattern.compile("(https?:\\/\\/[\\da-z\\.-]+\\.[a-z\\.]{2,10})\\/videos\\/embed\\/(\\w{8}-\\w{4}-\\w{4}-\\w{4}-\\w{12})$");
|
||||
|
|
|
@ -20,7 +20,6 @@ import android.database.sqlite.SQLiteDatabase;
|
|||
import android.graphics.Bitmap;
|
||||
import android.os.Handler;
|
||||
import android.support.annotation.NonNull;
|
||||
import android.support.design.widget.FloatingActionButton;
|
||||
import android.support.v7.app.AlertDialog;
|
||||
import android.content.ClipData;
|
||||
import android.content.ClipboardManager;
|
||||
|
@ -82,7 +81,6 @@ import java.util.regex.Pattern;
|
|||
|
||||
import fr.gouv.etalab.mastodon.R;
|
||||
import fr.gouv.etalab.mastodon.activities.BaseMainActivity;
|
||||
import fr.gouv.etalab.mastodon.activities.MainActivity;
|
||||
import fr.gouv.etalab.mastodon.activities.MediaActivity;
|
||||
import fr.gouv.etalab.mastodon.activities.ShowAccountActivity;
|
||||
import fr.gouv.etalab.mastodon.activities.ShowConversationActivity;
|
||||
|
@ -97,7 +95,6 @@ import fr.gouv.etalab.mastodon.client.Entities.Attachment;
|
|||
import fr.gouv.etalab.mastodon.client.Entities.Card;
|
||||
import fr.gouv.etalab.mastodon.client.Entities.Emojis;
|
||||
import fr.gouv.etalab.mastodon.client.Entities.Error;
|
||||
import fr.gouv.etalab.mastodon.client.Entities.Filters;
|
||||
import fr.gouv.etalab.mastodon.client.Entities.Status;
|
||||
import fr.gouv.etalab.mastodon.fragments.DisplayStatusFragment;
|
||||
import fr.gouv.etalab.mastodon.helper.CrossActions;
|
||||
|
@ -105,7 +102,6 @@ import fr.gouv.etalab.mastodon.helper.CustomTextView;
|
|||
import fr.gouv.etalab.mastodon.helper.Helper;
|
||||
import fr.gouv.etalab.mastodon.interfaces.OnPostActionInterface;
|
||||
import fr.gouv.etalab.mastodon.interfaces.OnRetrieveCardInterface;
|
||||
import fr.gouv.etalab.mastodon.interfaces.OnRetrieveEmojiAccountInterface;
|
||||
import fr.gouv.etalab.mastodon.interfaces.OnRetrieveEmojiInterface;
|
||||
import fr.gouv.etalab.mastodon.interfaces.OnRetrieveFeedsInterface;
|
||||
import fr.gouv.etalab.mastodon.interfaces.OnRetrieveRepliesInterface;
|
||||
|
@ -115,9 +111,7 @@ import fr.gouv.etalab.mastodon.sqlite.StatusCacheDAO;
|
|||
import fr.gouv.etalab.mastodon.sqlite.StatusStoredDAO;
|
||||
import fr.gouv.etalab.mastodon.sqlite.TempMuteDAO;
|
||||
|
||||
import static fr.gouv.etalab.mastodon.activities.BaseMainActivity.filters;
|
||||
import static fr.gouv.etalab.mastodon.activities.MainActivity.currentLocale;
|
||||
import static fr.gouv.etalab.mastodon.helper.Helper.HOME_TIMELINE_INTENT;
|
||||
import static fr.gouv.etalab.mastodon.helper.Helper.THEME_BLACK;
|
||||
import static fr.gouv.etalab.mastodon.helper.Helper.THEME_DARK;
|
||||
import static fr.gouv.etalab.mastodon.helper.Helper.changeDrawableColor;
|
||||
|
@ -145,22 +139,8 @@ public class StatusListAdapter extends RecyclerView.Adapter implements OnPostAct
|
|||
private int conversationPosition;
|
||||
private List<String> timedMute;
|
||||
private boolean redraft;
|
||||
private Status status;
|
||||
private Status toot;
|
||||
public StatusListAdapter(Context context, List<String> timedMute, RetrieveFeedsAsyncTask.Type type, String targetedId, boolean isOnWifi, int behaviorWithAttachments, int translator, List<Status> statuses){
|
||||
super();
|
||||
this.context = context;
|
||||
this.statuses = statuses;
|
||||
this.isOnWifi = isOnWifi;
|
||||
this.behaviorWithAttachments = behaviorWithAttachments;
|
||||
layoutInflater = LayoutInflater.from(this.context);
|
||||
statusListAdapter = this;
|
||||
this.type = type;
|
||||
this.targetedId = targetedId;
|
||||
this.translator = translator;
|
||||
this.timedMute = timedMute;
|
||||
redraft = false;
|
||||
}
|
||||
|
||||
|
||||
public StatusListAdapter(Context context, RetrieveFeedsAsyncTask.Type type, String targetedId, boolean isOnWifi, int behaviorWithAttachments, int translator, List<Status> statuses){
|
||||
super();
|
||||
|
@ -377,7 +357,6 @@ public class StatusListAdapter extends RecyclerView.Adapter implements OnPostAct
|
|||
@Override
|
||||
public int getItemViewType(int position) {
|
||||
|
||||
status = statuses.get(position);
|
||||
SharedPreferences sharedpreferences = context.getSharedPreferences(Helper.APP_PREFS, Context.MODE_PRIVATE);
|
||||
boolean isCompactMode = sharedpreferences.getBoolean(Helper.SET_COMPACT_MODE, true);
|
||||
if( type == RetrieveFeedsAsyncTask.Type.CONTEXT && position == conversationPosition)
|
||||
|
|
|
@ -2413,7 +2413,7 @@ public class Helper {
|
|||
ArrayList<String> filterContext = mfilter.getContext();
|
||||
if(
|
||||
(type == RetrieveFeedsAsyncTask.Type.HOME && filterContext.contains("home")) ||
|
||||
(type == RetrieveFeedsAsyncTask.Type.LOCAL && filterContext.contains("local")) ||
|
||||
(type == RetrieveFeedsAsyncTask.Type.LOCAL && filterContext.contains("public")) ||
|
||||
(type == RetrieveFeedsAsyncTask.Type.PUBLIC && filterContext.contains("public"))
|
||||
|
||||
) {
|
||||
|
|
|
@ -113,7 +113,6 @@
|
|||
android:orientation="vertical">
|
||||
<TextView
|
||||
android:id="@+id/status_account_displayname"
|
||||
android:visibility="gone"
|
||||
android:maxLines="1"
|
||||
android:drawablePadding="2dp"
|
||||
android:layout_width="wrap_content"
|
||||
|
|
|
@ -123,7 +123,7 @@
|
|||
<item>Mututu kontu hau?</item>
|
||||
<item>Blokeatu kontu hau?</item>
|
||||
<item>Salatu toot hau?</item>
|
||||
<item>Block this domain?</item>
|
||||
<item>Blokeatu domeinu hau?</item>
|
||||
</string-array>
|
||||
<string-array name="more_action_owner_confirm">
|
||||
<item>Kendu toot hau?</item>
|
||||
|
@ -563,17 +563,17 @@ Eskerrik asko Stéphane logoagatik. </string>
|
|||
<string name="select_sound">Hautatu doinua</string>
|
||||
<string name="set_enable_time_slot">Gaitu denbora-tartea</string>
|
||||
<string name="how_to_videos">Laguntza bideoak</string>
|
||||
<string name="retrieve_remote_conversation">Fetching remote thread!</string>
|
||||
<string name="no_blocked_domain">No blocked domains!</string>
|
||||
<string name="unblock_domain_confirm">Unblock domain</string>
|
||||
<string name="unblock_domain_confirm_message">Are you sure to unblock %s?</string>
|
||||
<string name="block_domain_confirm_message">Are you sure to block %s?</string>
|
||||
<string name="blocked_domains">Blocked domains</string>
|
||||
<string name="block_domain">Block domain</string>
|
||||
<string name="toast_block_domain">The domain is blocked</string>
|
||||
<string name="toast_unblock_domain">The domain is no longer blocked!</string>
|
||||
<string name="retrieve_remote_status">Fetching remote status</string>
|
||||
<string name="comment">Comment</string>
|
||||
<string name="retrieve_remote_conversation">Urruneko haria eskuratzen!</string>
|
||||
<string name="no_blocked_domain">Ez dago blokeatutako domeinurik!</string>
|
||||
<string name="unblock_domain_confirm">Desblokeatu domeinua</string>
|
||||
<string name="unblock_domain_confirm_message">Ziur al zaude %s desblokeatu nahi duzula?</string>
|
||||
<string name="block_domain_confirm_message">Ziur al zaude %s blokeatu nahi duzula?</string>
|
||||
<string name="blocked_domains">Blokeatutako domeinuak</string>
|
||||
<string name="block_domain">Blokeatu domeinua</string>
|
||||
<string name="toast_block_domain">Domeinu hau blokeatuta dago</string>
|
||||
<string name="toast_unblock_domain">Domeinua ez dago jada blokeatuta!</string>
|
||||
<string name="retrieve_remote_status">Urruneko mezua jasotzen</string>
|
||||
<string name="comment">Iruzkina</string>
|
||||
<string-array name="filter_expire">
|
||||
<item>Inoiz ez</item>
|
||||
<item>30 minutu</item>
|
||||
|
|
|
@ -123,7 +123,7 @@
|
|||
<item>Ућуткај овај налог?</item>
|
||||
<item>Блокирај овај налог?</item>
|
||||
<item>Пријави овaj тут?</item>
|
||||
<item>Block this domain?</item>
|
||||
<item>Блокирај овај домен?</item>
|
||||
</string-array>
|
||||
<string-array name="more_action_owner_confirm">
|
||||
<item>Уклони овај тут?</item>
|
||||
|
@ -567,17 +567,17 @@
|
|||
<string name="select_sound">Изаберите тон</string>
|
||||
<string name="set_enable_time_slot">Омогући термин</string>
|
||||
<string name="how_to_videos">Видео упутства</string>
|
||||
<string name="retrieve_remote_conversation">Fetching remote thread!</string>
|
||||
<string name="no_blocked_domain">No blocked domains!</string>
|
||||
<string name="unblock_domain_confirm">Unblock domain</string>
|
||||
<string name="unblock_domain_confirm_message">Are you sure to unblock %s?</string>
|
||||
<string name="block_domain_confirm_message">Are you sure to block %s?</string>
|
||||
<string name="blocked_domains">Blocked domains</string>
|
||||
<string name="block_domain">Block domain</string>
|
||||
<string name="toast_block_domain">The domain is blocked</string>
|
||||
<string name="toast_unblock_domain">The domain is no longer blocked!</string>
|
||||
<string name="retrieve_remote_status">Fetching remote status</string>
|
||||
<string name="comment">Comment</string>
|
||||
<string name="retrieve_remote_conversation">Дохватам удаљену преписку!</string>
|
||||
<string name="no_blocked_domain">Нема блокираних домена!</string>
|
||||
<string name="unblock_domain_confirm">Одблокирај домен</string>
|
||||
<string name="unblock_domain_confirm_message">Да ли сте сигурни да желите да одблокирате %s?</string>
|
||||
<string name="block_domain_confirm_message">Да ли сте сигурни да желите да блокирате %s?</string>
|
||||
<string name="blocked_domains">Блокирани домени</string>
|
||||
<string name="block_domain">Блокирај домен</string>
|
||||
<string name="toast_block_domain">Домен блокиран</string>
|
||||
<string name="toast_unblock_domain">Домен није више блокиран!</string>
|
||||
<string name="retrieve_remote_status">Дохватам удаљени статус</string>
|
||||
<string name="comment">Коментар</string>
|
||||
<string-array name="filter_expire">
|
||||
<item>Никадa</item>
|
||||
<item>30 минута</item>
|
||||
|
|
Loading…
Reference in New Issue