Commit Graph

42 Commits

Author SHA1 Message Date
Shadowfacts c7746d3084
Add unknown notification fallback
Closes #90
2020-03-02 19:44:10 -05:00
Shadowfacts 53707593a6
Show custom emojis in display names (where possible) 2020-03-01 19:40:32 -05:00
Shadowfacts 244659c262
Fix intermittent crash
If a status in a conversation view controller creates a work item to
update the timestamp in 1 minute, but the view controller is deinit'd
before that time elapses, the mastodonController instance will be nil,
resulting in a crash.

The DispatchWorkItems's are cancelled by the respective cell deinit
methods. But if the work item has already begun, cancelling it has no
effect, potentially leading to a crash in the conditions described above
are true. Using a weak reference to self fixes this.

Additionally, don't unnecessarily recreate the work items every time.
They don't capture any local variables, only self, so nothing changes.
2020-03-01 18:33:44 -05:00
Shadowfacts 5a6c12c5a7 Fix missing context menu actions on follow notifications for only one person 2020-01-25 10:30:04 -05:00
Shadowfacts d6ae51c02f Improve ImageCache loading
Keep track of the number of requests and only cancel the underlying
URLSessionTask if there are no concrete requsts remaining.

Closes #81
2020-01-25 10:30:04 -05:00
Shadowfacts 8eb6f6f573
Fix retain cycle in timestamp updating code
The timestamp update work item shouldn't retain a reference to the cell.
It can be unowned because when the cell is deinit'd, the work item will
be cancelled.
2020-01-19 23:10:52 -05:00
Shadowfacts 32e89f2c16
Fix retain cycles with TuskerNavigationDelegate
TuskerNavigationDelegate is now class-bound and only weak references to
it are stored.
2020-01-19 23:02:07 -05:00
Shadowfacts 6421d4dc12
Merge branch 'master' into multiple-accounts 2020-01-18 18:56:36 -05:00
Shadowfacts b5a41badcc
Replace content labels with text views
UITextView uses TextKit internally, unlike UILabel, so no additional
code is needed to keep the TextKit and view representations of the text
in sync since they are one and the same. This means that detecting which
character was tapped in a content text view is much more accurate, which
means link handling is substantially imrpoved.

Fixes #20
2020-01-18 16:05:00 -05:00
Shadowfacts 0255483f97
Make MastodonCache specific to each API controller
See #16
2020-01-05 19:54:28 -05:00
Shadowfacts e3be424f5a
Fix instance public timelines not loading 2020-01-05 19:45:12 -05:00
Shadowfacts 2bdcb9b7f8
Replace global shared MastodonController instance with (mostly)
dependency injection

The places still using the .shared property are cases where there is no
view controller from which to (easily) get the appropriate instance,
such as user activity and X-Callback-URL handling. These uses will need
to be revisited once there are multiple MastodonControllers.

See #16
2020-01-05 15:25:07 -05:00
Shadowfacts a18bcac8b8
Pachyderm: Change Client request methods to be static, like all other
models

Tusker: Add run method to MastodonController and no-longer expose API
client object
2020-01-05 14:00:39 -05:00
Shadowfacts ad09e36907
Show follow requsts in notifications w/ accept/reject buttons
Closes #64
2020-01-04 23:13:23 -05:00
Shadowfacts 05d79d5d03
Use same nav delegate more options for context menu share sheet 2019-12-14 13:36:05 -05:00
Shadowfacts eb6cfba9aa
Fix tablel view cells being re-selected on aborted nav swipe back 2019-12-14 11:59:31 -05:00
Shadowfacts b47b08fa95
Store status collapse state in containing view controller
Also, copy the state between screens, so e.g. expanding a status in the
timeline and then opening that conversation already has that status
expanded.

This intentionally doesn't store the sensitive attachment visibility
state, since showing text when not necessary is less dangerous than for
images. (Possibly a preference for this in the future?)

Closes #55
2019-11-28 18:36:58 -05:00
Shadowfacts da6ff67a51
Add notification dismissal context menu actions
Closes #49

This is a workaround for UIKit's built-in suggested context menu actions
not working as expected, and should be replaced with the system thing if
it becomes possible.
2019-11-17 18:49:48 -05:00
Shadowfacts 4cfe5e0fa5
Change action notification line limit to 3 2019-11-17 15:16:58 -05:00
Shadowfacts 2edb65d302
Show favorite, reblog, and full timestamp in conversation main status 2019-09-07 17:10:58 -04:00
Shadowfacts 49380692f3
Add context menu for follow notifications 2019-09-06 17:59:57 -04:00
Shadowfacts 8723921cec
Add context menu for status action notifications 2019-09-06 17:56:45 -04:00
Shadowfacts d9abf3ec09
Show list of accounts based on grouped notifications 2019-09-05 23:16:45 -04:00
Shadowfacts 76bc6a665c
Show list of accounts for grouped follow notifications 2019-09-05 22:30:58 -04:00
Shadowfacts a8ae559c9d
Add timestamp to follow notifications 2019-09-05 19:53:08 -04:00
Shadowfacts a363308147
Follow notification grouping
Closes #28
2019-09-05 19:35:19 -04:00
Shadowfacts 1618313742
Fav/reblog notification grouping
#28
2019-09-05 17:45:45 -04:00
Shadowfacts 84cfa923ca
Use Notification for updating view appearance on preferences change 2019-08-02 18:05:47 -06:00
Shadowfacts a89fb56a60
Add support for iOS 13 previewing and actions 2019-06-04 17:04:37 -04:00
Shadowfacts b3b9d566b7
iOS 13 Dark Mode Support 2019-06-04 13:31:05 -04:00
Shadowfacts 55ed2f5d26
Get rid of AppRouter 2019-01-19 14:31:31 -05:00
Shadowfacts f684591888
Use Gifu for GIF playback 2018-11-09 15:48:08 -05:00
Shadowfacts 7e8f22c471
Refactor view controller creation/navigation into AppRouter 2018-10-20 22:07:04 -04:00
Shadowfacts 0b6459a806
Add 3d touch peek/pop navigation 2018-10-11 21:52:41 -04:00
Shadowfacts 982e42ca2f
Refactor AvatarCache to ImageCache
Use Cache library (https://github.com/hyperoslo/Cache) for caching
2018-10-03 08:45:03 -04:00
Shadowfacts 3d39087980
Replace ActiveLabel-based implementation with TTTAttributedLabel 2018-10-01 19:50:03 -04:00
Shadowfacts a4eb862e3a
Use light text for usernames and timestamps 2018-09-30 21:15:18 -04:00
Shadowfacts 81a67ee76b
Minor UI tweaks 2018-09-30 19:05:06 -04:00
Shadowfacts a10b990073
Cache accounts 2018-09-18 12:59:07 -04:00
Shadowfacts a6d23d12eb
Add shared status cache 2018-09-17 21:57:46 -04:00
Shadowfacts 1119a861d8
Replace MastodonKit with Pachyderm 2018-09-11 10:52:21 -04:00
Shadowfacts bd1f8fa20a
Reorganize sources 2018-09-03 17:10:26 -04:00