-
Notifications
You must be signed in to change notification settings - Fork 213
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
MXMediaManager/MXMediaLoader: Do not allow non-mxc content URLs. #593
Conversation
- The Matrix Media Content repository contants are moved to MXEnumConstants.h - MXSession: Add a MediaManager instance to handle directly the media stored on the Matrix Content repository. - MediaManager: an instance is initialized with homeserver URL to be able to handle itself the Matrix Content URI (mxc://...). - API break: "- (NSString *)urlOfIdenticon:(NSString *)identiconString" is moved from MXRestClient to MXMediaManager.
…URI (in the form of "mxc://...").
- Replace all the set of notifications with only one notification based on state change
…ned url is nil whatever the value returned by the server
which should not be used anymore.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM but could we remove all deprecated methods, please?
That will help to maintain it later.
@"info": [@{ | ||
@"thumbnail_url": fakeMediaManagerThumbnailURL, | ||
@"thumbnail_url": fakeMediaURI, | ||
@"thumbnail_info": @{ | ||
@"mimetype": @"image/jpeg", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not for this PR but that would be nice MIME type constants
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
agree
/** | ||
Statistics on the operation in progress. | ||
- kMXMediaLoaderProgressValueKey: progress value in [0, 1] range (NSNumber object) [In case of upload, the properties |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note for future: kMXMediaLoaderProgressValueKey
, kMXMediaLoaderProgressValueKey
and kMXMediaLoaderTotalBytesCountKey
values could all fit a NSProgress
object.
kMXMediaLoaderCurrentDataRateKey
could even be stored as userInfo of this NSProgress
object.
And increase MediaCacheSdkVersion
Improvements: * Replace the deprecated MXMediaManager and MXMediaLoader interfaces use (see matrix-org/matrix-ios-sdk/pull/593). * Replace the deprecated MXKAttachment and MXKImageView interfaces use (see matrix-org/matrix-ios-kit/pull/487). * Server Quota Notices: Implement the blue banner (1937). * Lazy loading: Enable it by default (if the homeserver supports it). * i18n: Add Spanish (sp). * Settings: Make advanced info copyable (2023). * Settings: Made cryptography info copyable, thanks to @daverPL (PR 1999). Bug fix: * Notifications: old notifications can reappear (1985). * Fix missing read receipts when lazy-loading room members. * Weird text color when selecting a message (2046). * Fix input toolbar reset in RoomViewController on MXSession state change (2006 and 2008). * User defaults: the preset application language (if any) is ignored. * Recents: Avoid to open a room twice (it crashed on room creation on quick HSes). * Riot-bot: Do not try to create a room with it if the user homeserver is not federated. * Empty app if initial /sync fails (1975). * Fix possible race conditions in direct rooms management.
* Rebase onto vector-im/riot-ios: Improvements: * Replace the deprecated MXMediaManager and MXMediaLoader interfaces use (see matrix-org/matrix-ios-sdk/pull/593). * Replace the deprecated MXKAttachment and MXKImageView interfaces use (see matrix-org/matrix-ios-kit/pull/487). * Server Quota Notices: Implement the blue banner (1937). * Lazy loading: Enable it by default (if the homeserver supports it). * i18n: Add Spanish (sp). * Settings: Make advanced info copyable (2023). * Settings: Made cryptography info copyable, thanks to @daverPL (PR 1999). Bug fix: * Notifications: old notifications can reappear (1985). * Fix missing read receipts when lazy-loading room members. * Weird text color when selecting a message (2046). * Fix input toolbar reset in RoomViewController on MXSession state change (2006 and 2008). * User defaults: the preset application language (if any) is ignored. * Recents: Avoid to open a room twice (it crashed on room creation on quick HSes). * Riot-bot: Do not try to create a room with it if the user homeserver is not federated. * Empty app if initial /sync fails (1975). * Fix possible race conditions in direct rooms management. - Remove deprecated MXKImageView interface use
Improvements:
Bug Fix:
Deprecated API:
API break: