Commit Graph

729 Commits

Author SHA1 Message Date
Conny Duck e261125e93 Merge branch 'master' of https://github.com/Vavassor/Tusky 2019-03-08 21:13:17 +01:00
Konrad Pozniak c266638bd1
New Crowdin translations (#1106)
* New translations strings.xml (Italian)

* New translations strings.xml (Czech)

* New translations strings.xml (Esperanto)

* New translations strings.xml (Esperanto)

* New translations strings.xml (Esperanto)

* New translations strings.xml (Esperanto)

* New translations strings.xml (Esperanto)

* New translations strings.xml (Esperanto)

* New translations strings.xml (Esperanto)

* New translations strings.xml (Esperanto)

* New translations strings.xml (Esperanto)

* New translations strings.xml (Czech)

* New translations strings.xml (Czech)

* New translations strings.xml (Czech)

* New translations strings.xml (Czech)

* New translations strings.xml (Czech)

* New translations strings.xml (Czech)

* New translations strings.xml (Czech)

* New translations strings.xml (Czech)

* New translations strings.xml (Czech)

* New translations strings.xml (Czech)

* New translations strings.xml (Czech)

* New translations strings.xml (Dutch)

* New translations strings.xml (Italian)

* New translations strings.xml (Tamil)

* New translations strings.xml (Russian)

* New translations strings.xml (Portuguese, Brazilian)

* New translations strings.xml (Polish)

* New translations strings.xml (Persian)

* New translations strings.xml (Occitan)

* New translations strings.xml (Hungarian)

* New translations strings.xml (German)

* New translations strings.xml (French)

* New translations strings.xml (Chinese Traditional, Singapore)

* New translations strings.xml (Chinese Traditional, Macau)

* New translations strings.xml (Chinese Traditional, Hong Kong)

* New translations strings.xml (Chinese Traditional)

* New translations strings.xml (Arabic)

* New translations strings.xml (Japanese)

* New translations strings.xml (Turkish)

* New translations strings.xml (Spanish)

* New translations strings.xml (Esperanto)

* New translations strings.xml (Dutch)

* New translations strings.xml (Dutch)

* New translations strings.xml (Portuguese, Brazilian)

* New translations strings.xml (Dutch)

* New translations strings.xml (Esperanto)

* New translations strings.xml (Esperanto)

* New translations strings.xml (Esperanto)

* New translations strings.xml (Esperanto)

* New translations strings.xml (Esperanto)

* New translations strings.xml (Esperanto)

* New translations strings.xml (Italian)

* New translations strings.xml (Japanese)

* New translations strings.xml (Japanese)

* New translations strings.xml (Czech)

* New translations strings.xml (Czech)

* New translations strings.xml (Czech)

* New translations strings.xml (Czech)
2019-03-08 21:12:07 +01:00
Conny Duck 028db440ee cleanup code 2019-03-08 21:10:48 +01:00
Mélanie Chauvel (ariasuni) bac131c6d5 Add support for language switching (#1108)
* Add support for language switching

* Clean and improve code based on feedback

* Remove useless logging
2019-03-08 20:33:42 +01:00
Konrad Pozniak 0506bfa7d6
remove todos from status layouts (#1112)
* remove todos from status layouts

* remove todo from account autocomplete layout
2019-03-08 20:27:30 +01:00
Konrad Pozniak 830b3802a5
refactor EditProfileActivity layout (#1110)
* refactor EditProfileActivity layout

* refactor EditProfileActivity layout
2019-03-08 20:27:16 +01:00
Bernd 507ffb1b41 Add new Theme "Use System Design" + fixes to night mode (#1069)
* Add theme system

A theme which follows system design.
See: https://www.xda-developers.com/samsung-galaxy-s9-update-night-mode-schedule/

* update

to be in line with https://github.com/tuskyapp/Tusky/pull/1060/files

* Update ThemeUtils.java

* update

* Cleanup

* Update Deps

* Cleanup

* Update PreferencesActivity.kt

* Workaround to make MODE_NIGHT_FOLLOW_SYSTEM work

* Update ThemeUtils.java

* Use ThemeUtils.THEME_SYSTEM

* Update SplashActivity.kt

* Update strings.xml

* Update Deps

* Update build.gradle

* Update build.gradle

* fix tests
2019-03-07 21:33:29 +01:00
Konrad Pozniak 5ef5f91c6d
New Crowdin translations (#1101)
* New translations strings.xml (German)

* New translations strings.xml (German)

* New translations strings.xml (French)

* New translations strings.xml (French)

* New translations strings.xml (Hungarian)

* New translations strings.xml (French)

* New translations strings.xml (Italian)
2019-03-05 19:32:19 +01:00
Konrad Pozniak 237f209174
make black theme navigation bar color lighter so it works on One Plus (#1103)
* try to fix black theme navigation bar color on One Plus

* make navbar color lighter
2019-03-04 22:34:27 +01:00
autumnontape 10fcee4798 Add autocompletion for custom emoji (#1089)
* Remove unnecessary //noinspection ConstantConditions

* Add autocompletion for custom emoji

* Update MentionTagTokenizer tests for emoji autocomplete support

* Move 1) emoji list retrieval notifying and 2) setting of emojiList field into setEmojiList() method of ComposeActivity

* Convert RelativeLayout in item_autocomplete_emoji.xml to LinearLayout

* Rename MentionTag* to Compose*

* Improve emoji autocomplete matching

* Make hashtag autocomplete results bold

* Use Context.getString()'s built-in formatting

* Add a divider between emoji autocomplete results that *start with* the token and those that *contain* it
2019-03-04 19:28:08 +01:00
Ivan Kupalov 479d210e64 Timeline a11y (#1059)
* Improve timeline accessibility

* Improve a11y description and actions in timeline

* Refactor timeline accessibility handling, add more actions

* Update app/src/main/java/com/keylesspalace/tusky/adapter/StatusViewHolder.java

Co-Authored-By: charlag <charlag@tutanota.com>

* Add a11y actions for links, hashtags and mentions, enable for detailed.

* A11y delegate: Add open reblogger action, cleanup

* a11y delegate: add reblogs/boosts, improve interrupts

* a11y delegate: add reblogs/boosts, improve interrupts

* a11y delegate: add to notifications fragment
2019-03-04 19:24:27 +01:00
Konrad Pozniak 0a6709296d
crowdin sync (#1097)
* New translations strings.xml (Russian)

* New translations strings.xml (Portuguese, Brazilian)

* New translations strings.xml (Polish)

* New translations strings.xml (Persian)

* New translations strings.xml (Occitan)

* New translations strings.xml (Korean)

* New translations strings.xml (Italian)

* New translations strings.xml (Chinese Traditional, Singapore)

* New translations strings.xml (Chinese Traditional, Macau)

* New translations strings.xml (Chinese Traditional, Hong Kong)

* New translations strings.xml (Chinese Traditional)

* New translations strings.xml (Arabic)

* New translations strings.xml (Tamil)
2019-03-04 17:41:27 +01:00
Konrad Pozniak 64748bf36f change "show media previews" wording to "download media previews"
closes #1077
2019-03-04 10:09:21 +01:00
Konrad Pozniak 6430ed02d7
remove empty FAB styling (#1095) 2019-03-03 20:53:10 +01:00
Konrad Pozniak a7bc6a443d
New Crowdin translations (Japanese) (#1092)
* New translations strings.xml (Japanese)

* New translations strings.xml (Japanese)

* New translations strings.xml (Japanese)
2019-03-03 20:46:07 +01:00
Konrad Pozniak cfb744b08a
New Crowdin translations (Spanish) (#1090)
* New translations strings.xml (Spanish)

* New translations strings.xml (Spanish)

* New translations strings.xml (Spanish)

* New translations strings.xml (German)

* New translations strings.xml (German)
2019-03-01 20:54:14 +01:00
koyu 3748d75d34 change German placeholder text for compose field (#1074)
* Made compose field on par with web UI

* Escaping character
2019-02-27 19:11:28 +01:00
Frieder Bluemle d45c024143 Fix line endings in spellcheck.xml 2019-02-26 18:34:29 +01:00
INAGAKI Hiroshi 3d021d4e80 l10n: update Japanese translation (#1079)
Synchronized values-ja/strings.xml with values/strings.xml and added
translations.

Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
2019-02-26 18:32:46 +01:00
Konrad Pozniak 5ee78e68ba
remove unnecessary divider styling (#1057) 2019-02-26 18:28:20 +01:00
Konrad Pozniak 7f99f936d1
New translations strings.xml (Dutch) (#1063)
* New translations strings.xml (Dutch)

* New translations strings.xml (Dutch)

* New translations strings.xml (Dutch)

* New translations strings.xml (Dutch)

* New translations strings.xml (Dutch)

* New translations strings.xml (Dutch)

* New translations strings.xml (Dutch)

* New translations strings.xml (Dutch)

* New translations strings.xml (Dutch)
2019-02-19 23:01:20 +01:00
Konrad Pozniak 0bb9c0717f
New Crowdin translations Hungarian and Turkish (#1058)
* New translations strings.xml (Hungarian)

* New translations strings.xml (Hungarian)

* New translations strings.xml (Hungarian)

* New translations strings.xml (Turkish)
2019-02-18 15:40:00 +01:00
Konrad Pozniak 2ec17bbb1b
New translations strings.xml (French) (#1054) 2019-02-17 18:35:10 +01:00
tsdgeos 30436872ab ca: Fix typo: multimètida -> multimèdia (#1050)
Fixes #1048
2019-02-17 14:20:06 +01:00
Ondřej Hruška fcc67c6918 Fix large image attachments not showing (#1043)
* fix for too large image attachments not fitting into GL texture

* Don't use context!!
2019-02-16 14:31:41 +01:00
Evgeny Petrov 1805caaef7 Fixed typo in SwitchPreference (#1046) 2019-02-15 22:48:27 +01:00
Evgeny Petrov 35255f10c4 Russian language updated: (#1044)
* Russian language updated:

• Added strings for tabs customization.
• Added strings for Likes/Boosts counters.
• Added strings for external open/share.
• Some other fixes and additions.

* Added missing "maximum tabs reached" string.

* Small change to "hide compose button" string
2019-02-15 22:24:44 +01:00
Evgeny Petrov 9af3606daa Change CheckboxPreference to SwitchPreference, so that long lines show properly. (#1045) 2019-02-15 22:18:39 +01:00
Conny Duck f4ac9b3da6 make max tabs reached message translateable 2019-02-15 21:35:14 +01:00
Conny Duck 9089a2831c update german translation 2019-02-15 17:45:07 +01:00
aka-rin e8f1739add Update Chinese translations (#1039)
* Update zh-CN translations for Tusky 5.0.

Can't wait any more!

* Fix a period in zh-CN translations.

* Update zh-SG translations for Tusky 5.0

* Update zh-TW translations for Tusky 5.0

* Update zh-HK translations for Tusky 5.0

* Update zh-MO translations for Tusky 5.0
2019-02-15 17:29:07 +01:00
Konrad Pozniak e371fa0e24
Tab customization & direct messages tab (#1012)
* custom tabs

* custom tabs interface

* implement custom tab functionality

* add database migration

* fix bugs, improve ThemeUtils nullability handling

* implement conversationsfragment

* setup ConversationViewHolder

* implement favs

* add button functionality

* revert 10.json

* revert item_status_notification.xml

* implement more menu, replying, fix stuff, clean up

* fix tests

* fix bug with expanding statuses

* min and max number of tabs

* settings support, fix bugs

* database migration

* fix scrolling to top after refresh

* fix                                 bugs

* fix warning in item_conversation
2019-02-12 19:22:37 +01:00
Conny Duck 683b06a35d upgrade deps, fix some lint warnings 2019-02-11 16:59:01 +01:00
Levi Bard d5173c2268 Add support for selecting account when sharing from outside apps (#1011)
* Add direct-share support (API 23+)

* Add account selection dialog for non-direct sharing
2019-02-06 10:23:02 +01:00
marcin mikołajczak e98c7ac435 i18n: Update Polish translation🇵🇱 (#1029)
Signed-off-by: Marcin Mikołajczak <me@m4sk.in>
2019-02-05 20:13:09 +01:00
Ivan Kupalov 87364edd98 Fix empty state for account media, fix tablets (#1018) 2019-01-31 18:31:15 +01:00
Ivan Kupalov c0c73f5c06 Error artwork (#1000)
* Add new Elephant Friend images. Use them in ListsActivity.

* Add error images to AccountListFragment

* Add error images to Timeline & Notifications fragment. Needs rework.

* Introduce BackgroundMessageView. Use it in AccountList.

* Use correct button style for BackgroundMessageView

Co-Authored-By: charlag <charlag@tutanota.com>

* Use BackgroundMessageView

* Add BackgroundMessageView docs

* Re-color and document elephants

* Apply feedback, disable refresh when error is shown

* Fix string typo
2019-01-28 19:02:31 +01:00
Sylke Vicious 6e610b1d9d Updated italian translation (#1010)
* Updated italian translation

* Updated italian translation

* Fix for CircleCI failing test

* Updated italian translation
2019-01-28 11:05:42 +01:00
Ivan Kupalov a3ee13d767 Add hashtag autocompletion, closes #769 (#1001)
* Add hashtag autocompletion, closes #769

* Apply review feedback
2019-01-28 11:04:05 +01:00
kyori19 96162ab544 Add pinned status tab (#994)
* Add pinned status tab

* Make TabLayout scrollable.
2019-01-21 08:37:25 +01:00
Levi Bard 6252204dd5 Add character counter to profile bio field. #881 (#991) 2019-01-17 22:15:06 +01:00
Levi Bard 91fba293f2 Implement "Open status as (another account)" #958 (#988) 2019-01-16 20:50:09 +01:00
Ivan Kupalov 20f257c35b Fix layout issue with narrow timelines (#982) 2019-01-11 07:36:14 +01:00
Sylke Vicious de6246a212 Updated italian translation (#979)
* Updated italian translation

* Updated italian translation

* Fix for CircleCI failing test
2019-01-10 20:42:14 +01:00
Ivan Kupalov 0300a11d1e Fix layout issue with long CWs (#978) 2019-01-10 20:41:39 +01:00
Ivan Kupalov 38c7c8c71a Rework status layouts with ConstraintLayout (#967)
* Migrate item_status_detailed layout, minimum

* Migrate item_status_detailed layout, buttons

* Migrate item_status layout, minimum + buttons

* Migrate status layouts, fix RTL, cleanup

* Fix item_status layout

* Fix item_status name layout, fix CW button

* Simplify item_status, item_status_detailed layouts with chains

* Apply statuses layout feedback
2019-01-06 10:39:42 +01:00
Konrad Pozniak 40346ff304 fix multiline account field alignment 2018-12-29 18:37:12 +01:00
Konrad Pozniak 5e6a4ae93d fix radiobutton size in compose options 2018-12-29 00:02:29 +01:00
jchmrt 30df1cf403 Set image previews correctly according to their focal points (#899)
* Add serialization of the meta-data and focus objects

These objects are added in some attachments. This commit adds data
classes which are able to serialize these (partially) in preparation
for the ability to honour the focal point information in image
previews.

* Implement correctly honouring the focal point meta-data in previews

This commit adds code which ensures that the image previews of media
attachments to toots are correctly cropped to always show the focal
point of the image (if it is specified). It should not in any way
influence how previews of media without a focal point are shown.

To achieve the correct crop on the image a few components were
needed:

First of all we needed a way to influence how the image is cropped
into the ImageView. It turns out that the preferred way to do this is
by setting the ScaleType to MATRIX and adjusting the matrix of the
image as needed. This matrix allows us to scale and transform the
image in the way we need to make sure that the focal point is visible
within the view. For this purpose we have the FocalPointEnforcer which
can calculate and set the appropriate matrix on an ImageView as soon
as the image is loaded.

However a second problem is that we need to make sure that this matrix
is updated whenever the size of the ImageView changes. The size might
change for example because the orientation of the device changed from
portrait to landscape or vice versas, or for a number of other reasons
such as the screen being split vertically or something like that.

To be able to hook onto this event we need to create a new extended
version of the ImageView class, which we call
MediaPreviewImageView. This class behaves exactly the same as a normal
ImageView, however if the focalPointEnforcer of this view is set, then
it will call this enforcer to update the image matrix any time the
size is changed.

So this commit changes all media previews in the item_status.xml and
item_status_detailled.xml layout files to the new
MediaPreviewImageView class. Additionally in the code for loading the
images into the previews a new case is added which tests if there is a
focus attribute in the meta-data. If so it makes sure to create and
set the FocalPointEnforcer.

* Fix typos in documentation comment

"to" -> "too"

* Use static imports to remove clutter in FocalPointEnforcerTest

Instead of duplication Assert. in front of every assertEquals, simply
statically import it.

* Move the MetaData and Focus classes into the Attachment class

Since they are very strongly linked to the attachment class and are
themselves very small.

* Refactor the focal point handling code

- All the code modifying the actual members of the
  MediaPreviewImageView is now in this class itself. This class still
  uses the FocalPointUtil to calculate the new Matrix, but it now
  handles setting this new Matrix itself.

- The FocalPointEnforcer has been renamed to the FocalPointUtil to
  reflect that it only calculates the correct matrix, but doesn't set
  anything on the MediaPreviewImageView.

- The Matrix used to control the cropping of the
  MediaPreviewImageViews is now only allocated a single time per view
  instead of each time the view is resized. This is done by caching
  the Matrix and passing it to the FocalPointUtil to update on each
  resize.

* Only reallocate focalMatrix if it is not yet initialized

This helps prevent unnecessary allocations in the case where
setFocalPoint is called multiple times.

* Change checking of availability of objects to use != null

As pointed out, the 'is' keyword is meant for checking types, not for
checking non-nullness.

* Make updateFocalPointMatrix() return nothing

This makes it clearer that it actually mutates the matrix it is
given.

* Fix bug with transitions crashing the PhotoView

Due to the android transitions for some reason copying the scaletype
from the MediaPreviewImageView to the PhotoView during the transition,
the PhotoView would crash on pictures with a focal point, since
PhotoView doesn't support ScaleType.MATRIX.

This is solved by the workaround of overriding both the getScaleType
and setScaleType methods to ensure that we use the MATRIX type in the
preview and the center_crop type in the PhotoView.

Additionally this commit also makes sure to remove the focal point
when the MediaPreviewImageView is recycled.

* Fix bug in overriden getScaleType

Instead of simply returning the scaleType we need to return the
super.getScaleType() method, to avoid crashing.

* Merge changes from master

Mainly the migration to androidx.
2018-12-28 16:32:07 +01:00
Pellaeon Lin 675e90e508 Update zh-rTW translation (#930)
* Update zh-rTW translation

* Add missing translation

* Copy zh-rTW strings to HK and MO for now, per @connyduck 's request
https://github.com/tuskyapp/Tusky/pull/930#issuecomment-450240996

Note that this should not be the final solution, HK and MO should be
able to understand the TW variant, but they're still different.
2018-12-28 15:39:02 +01:00