Redesign report activity (#1295)

* Report activity core

* Implement navigation

* Implement navigation

* Update strings

* Revert manifest formatting

* Implement Done page

* Add landscape layout

* Implement Note fragment

* Create component

* Implement simple status adapter

* Format code

* Add date/time to report statuses

* Refactor status view holder

* Refactor code

* Refactor ViewPager

* Replace MaterialButton with Button

* Remove unneeded string

* Update Text and Check views style

* Remove old ReportActivity and rename Report2Activity to ReportActivity

* Hide "report to remote instance" checkbox for local accounts

* Add account, hashtag and links click handler

* Add media preview

* Add sensitive content support

* Add status expand/collapse support

* Update adapter to user adapterPosition instead of stored status

* Updated checked change handling

* Add polls support to report screen

* Add copyright

* Set buttonTint at CheckBox

* Exclude reblogs from statuses for reports

* Change final page check mark size

* Update report note screen

* Fix typos

* Remove unused params from api endpoint

* Replace .visibility with show()/hide()

* Replace Date().time with System.currentTime...

* Add line spacing

* Fix close button tint issue

* Updated status adapter
This commit is contained in:
pandasoft0 2019-06-09 17:55:34 +03:00 committed by Konrad Pozniak
commit c335651b6b
39 changed files with 2726 additions and 416 deletions

View file

@ -44,9 +44,9 @@ import com.keylesspalace.tusky.BottomSheetActivity;
import com.keylesspalace.tusky.ComposeActivity;
import com.keylesspalace.tusky.MainActivity;
import com.keylesspalace.tusky.R;
import com.keylesspalace.tusky.ReportActivity;
import com.keylesspalace.tusky.ViewMediaActivity;
import com.keylesspalace.tusky.ViewTagActivity;
import com.keylesspalace.tusky.components.report.ReportActivity;
import com.keylesspalace.tusky.db.AccountEntity;
import com.keylesspalace.tusky.db.AccountManager;
import com.keylesspalace.tusky.di.Injectable;
@ -54,7 +54,6 @@ import com.keylesspalace.tusky.entity.Attachment;
import com.keylesspalace.tusky.entity.Status;
import com.keylesspalace.tusky.network.MastodonApi;
import com.keylesspalace.tusky.network.TimelineCases;
import com.keylesspalace.tusky.util.HtmlUtils;
import com.keylesspalace.tusky.viewdata.AttachmentViewData;
import java.util.LinkedHashSet;
@ -327,12 +326,7 @@ public abstract class SFragment extends BaseFragment implements Injectable {
protected void openReportPage(String accountId, String accountUsername, String statusId,
Spanned statusContent) {
Intent intent = new Intent(getContext(), ReportActivity.class);
intent.putExtra("account_id", accountId);
intent.putExtra("account_username", accountUsername);
intent.putExtra("status_id", statusId);
intent.putExtra("status_content", HtmlUtils.toHtml(statusContent));
startActivity(intent);
startActivity(ReportActivity.getIntent(requireContext(),accountId,accountUsername,statusId,statusContent));
}
protected void showConfirmDeleteDialog(final String id, final int position) {