Commit Graph

86 Commits

Author SHA1 Message Date
Alibek Omarov 1228256bfc Merge remote-tracking branch 'weblate2/develop' into develop 2021-02-08 10:00:39 +03:00
Alibek Omarov cca59c7192 ComposeTokenizer: add tests 2021-01-31 05:58:38 +03:00
Alibek Omarov 2cf07fc496 ComposeTokenizer: add tests 2021-01-31 05:41:12 +03:00
Konrad Pozniak e952b6c627 Drafts v2 (#2032)
* cleanup warnings, reorganize some code

* move ComposeAutoCompleteAdapter to compose package

* composeOptions doesn't need to be a class member

* add DraftsActivity and DraftsViewModel

* drafts

* remove unnecessary Unit in ComposeViewModel

* add schema/25.json

* fix db migration

* drafts

* cleanup code

* fix compose activity rotation bug

* fix media descriptions getting lost when restoring a draft

* improve deleting drafts

* fix ComposeActivityTest

* improve draft layout for almost empty drafts

* reformat code

* show toast when opening reply to deleted toot

* improve item_draft layout
2021-01-30 05:17:56 +03:00
Alibek Omarov 9c11fea95d Fix tests 2020-12-06 02:33:38 +03:00
Konrad Pozniak 58d839ef0d upgrade dependencies (#1990)
* upgrade dependencies

* fix tests
2020-11-29 19:22:51 +03:00
Levi Bard 684289d3e3 Add tests for compose activity initial state changes (#1972) 2020-11-29 18:47:41 +03:00
Alibek Omarov c6b945b3ab FilterTest: fix test 2020-10-19 03:15:04 +03:00
Alibek Omarov 05ddc762c7 TimelineRepositoryTest: fix test 2020-10-19 01:28:08 +03:00
Levi Bard 8ee0420678 Set onClick listener for poll result view. (#1946)
Fixes #1861
2020-10-05 13:44:02 +03:00
Konrad Pozniak ac54677b53 simplify timeline cleanup (#1932)
* simplify timeline cleanup

* fix test
2020-10-05 13:23:51 +03:00
Konrad Pozniak ac00c62e5e convert EmojiPreference and EmojiCompatFont to Kotlin (#1922)
* convert EmojiPreference and EmojiCompatFont to Kotlin

* move preference related to to dedicated preference package

* update proguard-rules.pro

* reformat & add comment

* maintain disposable information in EmojiPreference instead of EmojiCompatFont
2020-10-05 13:22:15 +03:00
Alibek Omarov 0f6d0eaff0 test: fix tests 2020-10-04 03:24:26 +03:00
Alibek Omarov 159f0f0615 chats: add media, stickers, emojis (wip) 2020-09-22 20:31:31 +03:00
Alibek Omarov 7fb0bd4c85 ComposeActivityTest: fix test 2020-06-25 19:04:25 +03:00
Alibek Omarov 4741ab524c entity: Instance: fix optional pleroma field type 2020-06-25 18:57:47 +03:00
Alibek Omarov 930e05be27 NodeInfo: replace Int by Long in upload limits, add test cases 2020-05-23 14:57:14 +03:00
kyori19 06a0bf7744 Fix tag highlighting in editor (#1773)
* Fix tag highlighting in editor

* Add test case for tag highlighting
2020-05-22 20:48:35 +03:00
a1batross 473ac895b9 Fix test and lint 2020-05-03 12:42:57 +02:00
Konrad Pozniak 2ed14d0b90 replace HtmlUtils with HtmlCompat (#1741)
* replace HtmlUtils with HtmlCompat

* fix tests
2020-05-03 04:12:08 +03:00
Alibek Omarov c7e7da9433 Cherry-picked 2cf1e366. 2020-05-03 04:05:38 +03:00
Levi Bard 507d9fe19d Add notifications for follow requests (#1729)
* Add notifications for follow requests
Issue #1719

* Revert item_follow_request layout, create new layout for follow request notifications

* Migrate follow request interaction from notification to observable pattern

* Filter follow request notifications by default

* Add missing cases for system notification generation

* Format code
2020-05-03 03:01:16 +03:00
Alibek Omarov 3295348a79 Merge upstream 2020-02-28 10:30:09 +03:00
Alibek Omarov 9144484994 Add more URL cases for Pleroma, Misskey and Friendica (#1702) 2020-02-25 19:59:40 +01:00
Konrad Pozniak 0279987821 simplify DI & test setup, convert TuskyApplication to Kotlin (#1675)
* simplify DI & test setup, convert TuskyApplication to Kotlin

* try to fix tests on bitrise

* remove conscrypt-openjdk-uber test dependency again
2020-02-25 19:49:15 +01:00
Alibek Omarov ceba88af5c Add MORE cases for Pleroma, Misskey and Friendica 2020-02-19 05:14:40 +03:00
Alibek Omarov 216f0d3e2b MainActivity: increase velocity threshold for viewPager 2020-01-20 13:48:32 +03:00
Alibek Omarov f16799bf8f TimelineRepositoryTest: fix 2020-01-16 18:26:31 +03:00
Alibek Omarov 5b8b54c536 ComposeActivityTest: fix test(for now empty nodeinfo) 2020-01-16 17:17:21 +03:00
Alibek Omarov 71d8393098 Merge with upstream 2020-01-14 17:07:21 +03:00
Levi Bard 91bf35f627 Compose activity: When selection is nonempty and a "special character" button is pressed, decorate all selected word starts (#1523)
* ComposeActivity: When selection is nonempty and a "special character" button is pressed, decorate all selected word starts
Closes #1417

* ComposeActivity: Tests for word break prepend logic
2020-01-13 15:21:17 +01:00
Alibek Omarov 3e5e4329de Merge with upstream 2020-01-09 02:06:12 +03:00
Levi Bard 844cf317ab Filters: Make behavior of "whole word" filters consistent with the web UI when filters are non-alphanumeric (#1623)
* Fix tests build

* Make behavior of non-alphanumeric whole-word filters consistent with the web UI.
Fixes #1543

* Fix typo in filter tests
2020-01-06 16:16:54 +01:00
Alibek Omarov 0e5e0bea39 Merge upstream develop 2020-01-03 22:55:09 +03:00
Konrad Pozniak 03c66d62df add test for VersionUtils (#1602)
* add test for VersionUtils

* add nullability annotation to VersionUtils
2019-12-21 18:56:30 +01:00
Ivan Kupalov 9c59d000f9 ComposeActivity refactor (#1541)
* Convert ComposeActivity to Kotlin

* More ComposeActivity cleanups

* Move ComposeActivity to it's own package

* Remove ComposeActivity.IntentBuilder

* Re-do part of the media downsizing/uploading

* Add sending of status to ViewModel, draft media descriptions

* Allow uploading video, update description after uploading

* Enable camera, enable upload cancelling

* Cleanup of ComposeActivity

* Extract CaptionDialog, extract ComposeActivity methods

* Fix handling of redrafted media

* Add initial state and media uploading out of Activity

* Change ComposeOptions.mentionedUsernames to be Set rather than List

We probably don't want repeated usernames when we are writing a post
and Set provides such guarantee for free plus it tells it to the
callers. The only disadvantage is lack of order but it shouldn't be a
problem.

* Add combineOptionalLiveData. Add docs.

It it useful for nullable LiveData's. I think we cannot differentiate
between value not being set and value being null so I just added the
variant without null check.

* Add poll support to Compose.

* cleanup code

* move more classes into compose package

* cleanup code

* fix button behavior

* add error handling for media upload

* add caching for instance data again

* merge develop

* fix scheduled toots

* delete unused string

* cleanup ComposeActivity

* fix restoring media from drafts

* make media upload code a little bit clearer

* cleanup autocomplete search code

* avoid duplicate object creation in SavedTootActivity

* perf: avoid unnecessary work when initializing ComposeActivity

* add license header to new files

* use small toot button on bigger displays

* fix ComposeActivityTest

* fix bad merge

* use Singles.zip instead of Single.zip
2019-12-19 19:09:40 +01:00
Alibek Omarov 4de11cb073 Revert 36b8664f 2019-12-17 03:28:28 +03:00
Konrad Pozniak 8a65f91d2c Bookmarks (#1560)
* add bookmarks to timelines

* add Bookmarks to main menu

* cleanup

* handle BookmarkEvent

* fix tests

* fix bookmark handling in NotificationsFragment

* add bookmark accessibility actions
2019-11-19 10:15:32 +01:00
Konrad Pozniak d5d9af4fde Upgrade api level to Android 10, implement new sharing api (#1537)
* upgrade api level to Android 10, resolve compile errors

* use androidx.preference.PreferenceManager instead of deprecated platform class

* add hyphenation to important TextViews

*  setBottomSheetCallback -> addBottomSheetCallback

* implement new sharing api

* improve TuskyTileService so it shows account picker when multiple accounts are present

* delete unused AccountChooserService

* fix test

* improve ShareShortcutHelper

* remove debug log statement

* improve image loading fallback behavior in ShareShortcutHelper

* improve behavior on foldable devices
2019-10-22 21:18:20 +02:00
Levi Bard 66c084cad2 When opening a post via "Open As", if post lookup from the target instance fails, display an error instead of opening the post in the browser. (#1531)
Addresses #1526
2019-10-11 17:51:47 +02:00
Konrad Pozniak 14ce0c4952 upgrade appcompat, fix nightmode (#1455)
* upgrade appcompat, fix language switching & nightmode

* cleanup ThemeUtils

* upgrade dependencies

* change active boost icon (#1513)

* upgrade jetifier and android gradle plugin

* fix FilterTest
2019-10-03 19:58:21 +02:00
Konrad Pozniak 89eb1e2987 remove callList from BaseActivity (#1503)
* remove callList from BaseActivity

* remove callList from BaseActivity
2019-09-28 16:29:40 +02:00
Konrad Pozniak 18702da998 filter polls (#1496) 2019-09-24 20:33:29 +02:00
Konrad Pozniak 03cd374792 Remove search v1 (#1484)
* remove search v1, convert MastodonApi to Kotlin

* format MastodonApi nicely

* use default params in ConversationRepository

* improve code for LoginActivity
2019-09-22 08:18:44 +02:00
Konrad Pozniak 50b9cdf117 Create polls (#1452)
* add AddPollDialog

* add support for pleroma poll options

* add PollPreviewView

* add Poll support to drafts

* add license header, cleanup

* rename drawable files to correct size

* fix tests

* fix bug with Poll having wrong duration after delete&redraft

* add input validation

* grey out poll button when its disabled

* code cleanup & small improvements
2019-08-22 20:30:08 +02:00
Levi Bard 0454601ed6 Add support for instance property `max_bio_chars` (#1414)
* Migrate getInstance from Call to Single

* Add support for instance max_bio_chars.
Addresses #1329
2019-08-04 20:25:07 +02:00
Konrad Pozniak 43cf0e0ec8 fix shouldTrimStatus and add tests (#1404) 2019-07-25 12:15:54 +02:00
Marie Axelsson 36b8664fb4 Merge pull request #1303 from mlc/rick_roll_domains
Rick roll instead of logging in on selected domains. This is not censorship, but rather a choice by this house who will facilitate our services to.
2019-06-17 12:37:15 +02:00
Konrad Pozniak 421cfe9f3a cleanup entity classes and ViewThreadFragment (#1302)
* cleanup entity classes and ViewThreadFragment

* fix tests
2019-06-02 21:23:18 +02:00
mike castleman 3c2696ac67 add tests 2019-06-01 15:30:17 -04:00