Skip to content
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

[UX] Truncate long file names in the middle (instead of tail) #516

Closed
hosy opened this issue Oct 4, 2019 · 0 comments
Closed

[UX] Truncate long file names in the middle (instead of tail) #516

hosy opened this issue Oct 4, 2019 · 0 comments

Comments

@hosy
Copy link
Collaborator

hosy commented Oct 4, 2019

Steps to reproduce

  1. Enter a long file name (or more than one, but with a different suffix or enumeration)
  2. As an user you cannot see the end of the file name

Expected behaviour

As an user I want to see the end of the file name, to differ between files with the same prefix

TruncatingMiddle

Actual behaviour

I cannot the see difference between file names

TruncatingTail

Client

ownCloud app version:
1.1.0

@hosy hosy added the Estimation - 1 (XS) 1 point label Oct 4, 2019
@hosy hosy closed this as completed Oct 7, 2019
hosy pushed a commit that referenced this issue Oct 10, 2019
* #516 truncate middle of file name instead of tail (#517)

* new app version and build version

* Added a fix for background media playback

- Added audio session activation / deactivation code
- Also fixed potential issue for background video playback (PiP) as suggested by Apple in https://developer.apple.com/documentation/avfoundation/media_assets_playback_and_editing/creating_a_basic_video_player_ios_and_tvos/playing_audio_from_a_video_asset_in_the_background

* Fixed naming of uploaded edited photos

* Fixed mission icons for ‘moreFolder’ location (#523)

* [feature/darkmode] iOS 13 dark mode support (#489)

* Naming improvements based on latest SDK:
- uploads use new OCCoreOptionAutomaticConflictResolutionNameStyle option to automatically resolve naming conflicts during upload
- Duplicate action uses the new OCCore name suggestion API to
	- determine naming conflicts and resolve them automatically
	- match the name style of the file to duplicate, f.ex.
		- duplicating "File copy.jpg" will create "File copy 2.jpg"
		- duplicating "File (1).jpg" will create "File (2).jpg"
		- duplicating "File Kopie 2.jpg" will create "File Kopie 3.jpg"
- folder creation uses the new OCCore name suggestion API to
	- detect naming conflicts beforehand
	- pre-fill the new folder name name with an unused name directly

* #393 added an activity indicator which will be shown, if offline copies will be deleted to give the user a UI feedback

* - Change SDK branch to master

* #76 user can import files using the iOS share sheet. all file types are accepted.

* - using new SDK with fixes for requesting core
- minor code fixes

* - Log device, version and locale information at the beginning of every log file using new SDK protocol
- Show SDK commit hash in Settings

* fixed crash, changed bookmark name to shortname

* changed UIAlertViewController for account selection to CardViewController style for testing

* fixed icon badge creation for fastlane lane In-House Enterprise IPA generation

* install librsvg for fastlane via sh

* moved import file code to own class

* added option to automatically resolve name conflicts, if file name already exists

* Changed app version to 1.1.0

* enabled beta build and warning

*  Keep the gallery alive after doing some action over an item (#447)

* Rename updates the currently visible file in the gallery

* Keeping gallery alive fix

- Don’t pop to the root view controller on destructive action by default
- Only pop to the root if all items have been deleted
- Select next item upon deletion of the current ones
- Update UIPageViewController data source if number of items changes due e.g. to duplication or deletion

* Small fixes

* Fixed review findings

* Media player implemented using AVKit (#429)

* Media player implemented using AVKit

* Added possibility to stream audio / video

* Improved error handling

* Fixed review finding

* Added background audio, airplay and PiP mode

* Propagating safe area to the main view of AVPlayerViewController

* Another fix for safe area considering layout of AVPlayerViewController

* Updated to latest develop version of SDK

* Display error message in case file couldn’t be preview e.g. due to file corruption (#427)

* Fixed UI test for creating folder, need to return a fixed name, because suggestion is not working in tests

* added a description header and changed typo

* - fixed showing the directory picker controller, after the card view was dismissed
- use the current development SDK

* Version Bump to 126

* - create local copy of import file, if needed
- fixed create folder action
- delete local copy, if needed
- code review changes

* - improved duplicate item deletion behaviour
	- add additional safeguard so duplicate files are only deleted if they were actually duplicated (previously non-duplicate files could be removed if duplication or folder creation failed)
	- remove temporary container folder, too
- add 2 second delay before returning the core to give the core an opportunity to schedule the upload on a NSURLSession

* Version Bump to 127

* changed back signing identity

* Version Bump to 128

* added required CFBundleTypeName key

* Version Bump to 129

* updated changelog

* use formSheet presentation style for the iPad when showing the document picker

* Fix for images not being displayed in the gallery

* Version Bump to 130

* Version Bump to 131

* [fix/sharing-search] Fixed min length for searching sharing users (#455)

* #454 used correct comparator for sharingSearchMinLength and set a new default value, if capability does not exists

* added a constant for defaultSharingSearchMinLength value

* - Update ios-sdk to address finding (1) in ios-app #446

* Preventing updating UI in DisplayViewController while item is being changed

- Not calling present(item:) while meta data of OCItem is being updated
- Elliminated an assumption in MediaDisplayViewController that render renderSpecificView() can be called only once.
- Making sure that AVPlayer is not re-created upon changes in OCItem but that rather AVPlayerItem is replaced.

* Fixed a small warning

* Tried to improve gallery logic concerning items modification

- Watch out if the modification does still includes the item with local ID of the currently visible item.
- Take care of failed move but watching out for reappearing items

* Added a setting allowing to decide user if media files shall be streamed

* - Add debug output to Display*ViewController
- Fix SwiftLint warnings

* Fixed handling of deleted / moved item in the gallery

* Another small fix for handling of failed item move

* Version Bump to 132

* Added LSSupportsOpeningDocumentsInPlace key to Info.plist

* Fixed Info.plist and added LSHandlerRank property

* Fix for #455 issue: no search request triggered

* show always the account selection sheet and added a note, that only one file can be imported at once

* use securtiy scoped file operation for importing a file

* Fix for the PR #447 (keep gallery alive) (#465)

* Keeping track of individual OCItems in DisplayViewController instances

But loading the list of items in the gallery only once and not reacting to any changes (moving, deleting)

* Removed query stop call in DisplayHostViewController

Since this query is not created there but just passed from the parent view.

* Removing more button if the currently viewed file got moved or deleted

* Fixed updating UI after renaming current item

* Fixed a warning

* Fixed issues in the gallery

* - Minor fixes

* [feature/bundle-import] Add support for certain bundle formats to the share sheet (#471)

* - Add support for import of bundle-based document formats through transparent zipping
	- moved previous FileProvider functionality into ownCloudApp.framework
	- new method OCCore.importItemNamed() ensures correct handling of bundle-based document formats
	- fixes finding (4) in #445
- Changed LSSupportsOpeningDocumentsInPlace to NO address two issues:
	- the app is now listed as "Copy to ownCloud" (previously "Open in ownCloud", which was technically not correct)
	- previously, documents using "Open to ownCloud" would no longer open in f.ex. Pages, but in the ownCloud app when selected in the Files app

* - Refactored ImportFilesController around using NSFileCoordinator, fixing finding (1) in #471

* changed path for moved Info.plist for target ownCloudAppFramework

* Version Bump to 133

* [feature/sort direction] Allow sorting asc/desc for all sort methods (#474)

* #470 added change sort direction asc/desc for all sort methods

* - removed comments
- changed translation keys

* fixes sort comparator for sort method "shared"

* use correct images for sort direction asc and desc

* updated choosing sort method from a tableView/Popover instead of a UIAlertViewController

* set maximum width for popover and set arrow direction

* Added show sort direction in UISegmentControl

* - make sure arrows of popovers appear in same color as the popover contents
- fix issue where direction was toggled during setup of SortBar (setting of initial value from user defaults), so logging in, logging out and logging in would change the sort direction
- reset sort direction to ascendant when switching sort methods
- SortMethodTableViewController
	- remove extraneous instance lets
	- enforce row height used for table view height calculation
	- change table view height calculation to account for the last divider (which could look a bit off if present)

* tap on segment control was fired twice, because there was a missing check, if selected segment changed

* fixed changing width on selecting an other segment

* fixed jumping width of sortSegmentControl items by setting the same width for all items by calculating the longest width before

* [fix/index-bar] Make Index Bar available in general file list (#469)

* #413 show index bar in general file list
- Index bar is only visible, if sorting is "Sort by name"
- Index bar is only visible, if more than one different letters are available
- Index bar is only visible, if more items are available as visible

* - adopt to new sort methods
- reverse index list, if sort direction is descendant

* Version Bump to 134

* Version Bump to 135

* Version Bump to 136

*  Change behaviour of default expiration date (#476)

* Enabling expiration date switch if default expiration date is configured

Checking files_sharing.public.expire_date.expire_date.days server capability. If it is set then it is used as default date and the switch is enabled even if the expiration date is not enforced.

* Fixed QA issue (1)

* Fixed QA finding (2): limiting the date range if expiration date is enforced

* Permission increasing UX in reshares (#467)

* Not showing permissions which can’t be elevated

Affecting items shared with the current users which are being reshared

* Fixed an issue with wrong permissions displayed when creating public link

- Checking if permissions can be elevated for the public link
- Only viable options are displayed

* Fixed a trailing whitespace warning

* Fixed another compiler warning

* Inhereting permissions from the share when creating public link

* Fixed QA finding (4)

* Fixed QA finding (1)

* Fixed QA finding (2)

* Version Bump to 137

* [feature/itempolicy] Item Policy / Available Offline support (#456)

* Available Offline Support
- new MakeAvailableOfflineAction and MakeUnavailableOfflineAction actions
- new Available Offline Library section
	- easy access to all files available offline via Available Offline
	- new ItemPolicyTableViewController and ItemPolicyCell prepared for reuse for presenting other item policies
- Design: added SVG/TVG/PNG icons and cloud symbols for make available offline / make unavailable offline

ClientItemCell changes
- new ClientItemResolvingCell can resolve item from LocalID or path, new superclass of ShareClientItemCell and ItemPolicyCell
- string to use as content for title and detail are now provided via titleLabelString(for:) and detailLabelString(for:), updated via updateLabels(with:), making customization easier
- support for new available offline badge

ProgressSummarizer changes
- changed ProgressSummary from a struct to a class, addressing issue #451 ("Waiting for server response..." message sometimes not disappearing)

* - Adopt OCClaim to ensure files aren't deleted while they are being used in
	- DisplayViewController
	- DownloadItemsHUDViewController
	- FileListTableViewController
	- File Provider
- Add new Storage Settings to allow control over how long unused local copies are kept around
- DisplayViewController now uses OCClaims to ensure files aren't deleted while they are being viewed
- ClientItemCell uses new SDK APIs to
	- show "available offline" badges for folders
	- to indicate if an item has been made available offline directly (solid icon) or indirectly (dimmed icon)
	- keep the cloud status icon updated following changes
- Change "+" icon to "•••" icon in file list, rename plusButton to folderAction everywhere
- Action.provideAlertAction() now applies padding to images if necessary so their text aligns at the same horizontal offset
- Fix typo in BookmarkInfoViewController and change wording from "Delete Offline Copies" to "Delete Local Copies" for consistency
- Update swiftlint.yml to silence ownCloudScreenshotsTests warnings

* - Update ios-sdk

* - Make changes requested in code review, adding missing localizable strings and removing extraneous code

* - Update SDK

* - Add downloadTriggerIdentifier and availableOfflinePolicyCoverage as properties that trigger the update of an item's visual representation (addressing finding 6 in #456)
- Update make available offline action to use new convertExistingLocalDownloads option (addressing finding 2 in #456)
- Update SDK (addressing finding 5 in #456)

* Items in moved Available Offline folders should no longer be cleared locally and re-downloaded, following under the hood improvements in the ios-sdk

* - Add initial support for cookies via SDK update

* - Temporarily disable some UI tests broken due to lack of database running

* - Fix issue (11) in #456 by updating the lastUsed date of already downloaded items when they are viewed

* - Added slider type to StaticTableViewRow
- changed storage settings to allow picking a timeframe via slider rather than a list of time frames

* - Change text from "Remove" to "Make unavailable offline" in Quick Access > Available Offline list (addressing issue (9))

* - Update BookmarkInfoViewController to provide users with the choice to also remove local copies of items marked as Available Offline, issuing a warning and giving the users a way to cancel, addressing issue (12) in #456.

* - Update ios-sdk
- Take advantage of the new key-value store and OCCoreSkipAvailableOfflineKey to make sure available offline files are not immediately downloaded again after clearing the vault from local copies of available offline files.
- Logging into an account removes any previously set OCCoreSkipAvailableOfflineKey from the key value store
- Move Bookmark locking to an OCBookmarkManager category (next stop: use the new key-value store and bake support for locking bookmarks directly into the SDK)

* - Add missing localization

* Update SDK with latest fixes

* - Fix SettingsTests bugs

* - Apply additional fixes to UI tests and disable the remaining failing ones

* - Wait for connection initialization to complete before requesting sharing info
- Use latest SDK with cookie filtering

* - Turn off Request/Response log tags only filter in project file

* - Disable cookie support

* - Address (13) via SDK update

* link against newest development SDK

* Fixes for UI testing:
- use new SDK version that returns errors if the SQLite DB has not been opened
- MockOCCore.state now returns .running to avoid queueing of PROPFINDs

* - Fix unit tests

* - UI testing: make MockOCCore.state no longer return .running due to side effects
- fixed conflicting constraints in two places

* - force-delete bookmarks in UI tests if timeout has passed, log error but don't assert in that case
- handle case where a swipe on table cells in DeleteBookmarkTests triggers deletion outright

* - Further hardening of SettingsTests against timing differences local vs. CI

* - make SettingsTest.testCheckMoreItems() more robust

* iOS 13 dark mode support:
- detects dark / light mode changes and applies a different ThemeStyle as needed
- added ThemeStyle.darkStyleIdentifier so ThemeStyles can indicate their dark counter part (or their lack thereof, in case of the dark theme)
- add setting "Follow system light / dark appearance" to Settings > Theme

* Version Bump to 138

* [feature/reorder buttons] Reorder Navigation Bar Actions (#478)

* Available Offline Support
- new MakeAvailableOfflineAction and MakeUnavailableOfflineAction actions
- new Available Offline Library section
	- easy access to all files available offline via Available Offline
	- new ItemPolicyTableViewController and ItemPolicyCell prepared for reuse for presenting other item policies
- Design: added SVG/TVG/PNG icons and cloud symbols for make available offline / make unavailable offline

ClientItemCell changes
- new ClientItemResolvingCell can resolve item from LocalID or path, new superclass of ShareClientItemCell and ItemPolicyCell
- string to use as content for title and detail are now provided via titleLabelString(for:) and detailLabelString(for:), updated via updateLabels(with:), making customization easier
- support for new available offline badge

ProgressSummarizer changes
- changed ProgressSummary from a struct to a class, addressing issue #451 ("Waiting for server response..." message sometimes not disappearing)

* - Adopt OCClaim to ensure files aren't deleted while they are being used in
	- DisplayViewController
	- DownloadItemsHUDViewController
	- FileListTableViewController
	- File Provider
- Add new Storage Settings to allow control over how long unused local copies are kept around
- DisplayViewController now uses OCClaims to ensure files aren't deleted while they are being viewed
- ClientItemCell uses new SDK APIs to
	- show "available offline" badges for folders
	- to indicate if an item has been made available offline directly (solid icon) or indirectly (dimmed icon)
	- keep the cloud status icon updated following changes
- Change "+" icon to "•••" icon in file list, rename plusButton to folderAction everywhere
- Action.provideAlertAction() now applies padding to images if necessary so their text aligns at the same horizontal offset
- Fix typo in BookmarkInfoViewController and change wording from "Delete Offline Copies" to "Delete Local Copies" for consistency
- Update swiftlint.yml to silence ownCloudScreenshotsTests warnings

* - Update ios-sdk

* - Make changes requested in code review, adding missing localizable strings and removing extraneous code

* #477 reorganize navigation bar with create and more button and moved select button to sort menu

* added safeAreaLayoutGuide.rightAnchor

* - Update SDK

* changed "Select" image

* - Add downloadTriggerIdentifier and availableOfflinePolicyCoverage as properties that trigger the update of an item's visual representation (addressing finding 6 in #456)
- Update make available offline action to use new convertExistingLocalDownloads option (addressing finding 2 in #456)
- Update SDK (addressing finding 5 in #456)

* Items in moved Available Offline folders should no longer be cleared locally and re-downloaded, following under the hood improvements in the ios-sdk

* - Temporarily disable some UI tests broken due to lack of database running

* - Fix issue (11) in #456 by updating the lastUsed date of already downloaded items when they are viewed

* - Added slider type to StaticTableViewRow
- changed storage settings to allow picking a timeframe via slider rather than a list of time frames

* - Change text from "Remove" to "Make unavailable offline" in Quick Access > Available Offline list (addressing issue (9))

* - Update BookmarkInfoViewController to provide users with the choice to also remove local copies of items marked as Available Offline, issuing a warning and giving the users a way to cancel, addressing issue (12) in #456.

* addresses:
- missing multiselection UI in toolbar
- missing select all / deselect all button in navigation bar

* set if selectButton should be shown

* disable temporary some tests due to bitrise failures

* Version Bump to 139

* Feature/task scheduling (#484)

* #386 Added relevant classes

* First draft of the scheduled task manager

* Just changed some comments

* Implemented background fetch

* Implemented background update fetch

* Clean up of the code

* Fixed merge problems from previous commit

And eliminated some warnings

* Small changes in background fetch operation

* Some refactoring done

* Added some user defaults for media upload

* Available Offline Support
- new MakeAvailableOfflineAction and MakeUnavailableOfflineAction actions
- new Available Offline Library section
	- easy access to all files available offline via Available Offline
	- new ItemPolicyTableViewController and ItemPolicyCell prepared for reuse for presenting other item policies
- Design: added SVG/TVG/PNG icons and cloud symbols for make available offline / make unavailable offline

ClientItemCell changes
- new ClientItemResolvingCell can resolve item from LocalID or path, new superclass of ShareClientItemCell and ItemPolicyCell
- string to use as content for title and detail are now provided via titleLabelString(for:) and detailLabelString(for:), updated via updateLabels(with:), making customization easier
- support for new available offline badge

ProgressSummarizer changes
- changed ProgressSummary from a struct to a class, addressing issue #451 ("Waiting for server response..." message sometimes not disappearing)

* UI for bookmark / upload path selection

* Added dummy implementation of media upload task

* - Adopt OCClaim to ensure files aren't deleted while they are being used in
	- DisplayViewController
	- DownloadItemsHUDViewController
	- FileListTableViewController
	- File Provider
- Add new Storage Settings to allow control over how long unused local copies are kept around
- DisplayViewController now uses OCClaims to ensure files aren't deleted while they are being viewed
- ClientItemCell uses new SDK APIs to
	- show "available offline" badges for folders
	- to indicate if an item has been made available offline directly (solid icon) or indirectly (dimmed icon)
	- keep the cloud status icon updated following changes
- Change "+" icon to "•••" icon in file list, rename plusButton to folderAction everywhere
- Action.provideAlertAction() now applies padding to images if necessary so their text aligns at the same horizontal offset
- Fix typo in BookmarkInfoViewController and change wording from "Delete Offline Copies" to "Delete Local Copies" for consistency
- Update swiftlint.yml to silence ownCloudScreenshotsTests warnings

* - Update ios-sdk

* - Make changes requested in code review, adding missing localizable strings and removing extraneous code

* - Update SDK

* Refactored current implementation of media upload

* Added method to fetch photos from photo library

* - Add downloadTriggerIdentifier and availableOfflinePolicyCoverage as properties that trigger the update of an item's visual representation (addressing finding 6 in #456)
- Update make available offline action to use new convertExistingLocalDownloads option (addressing finding 2 in #456)
- Update SDK (addressing finding 5 in #456)

* Items in moved Available Offline folders should no longer be cleared locally and re-downloaded, following under the hood improvements in the ios-sdk

* - Add initial support for cookies via SDK update

* First draft of instant photo upload implementation

* Calling task completion handler after upload was finished

* - Temporarily disable some UI tests broken due to lack of database running

* - Fix issue (11) in #456 by updating the lastUsed date of already downloaded items when they are viewed

* - Added slider type to StaticTableViewRow
- changed storage settings to allow picking a timeframe via slider rather than a list of time frames

* - Change text from "Remove" to "Make unavailable offline" in Quick Access > Available Offline list (addressing issue (9))

* - Update BookmarkInfoViewController to provide users with the choice to also remove local copies of items marked as Available Offline, issuing a warning and giving the users a way to cancel, addressing issue (12) in #456.

* Fixed QA finding (1)

* Using PHAsset.creationDate to check which media files shall be instantly uploaded

* Fixed naming of class / group

* Moved Tasks folder

* Fixed some review findings

* - Fix issue where a busy bookmark alert is followed by duplicating the bookmark

* Fixed some review findings

* Improved background update fetching

* Fixed some issues in media upload

* Fixed a type in settings key

* Improvements in the instant media upload task

* Added missing returnCore in the selection of the instant upload path

* Fixed QA finding (3)

* Fixes for the correct core returning / requesting

* Small cosmetic code changes

* Fixed video and serialized photo / video uploads

* Moved upload() method to UploadBaseAction class

* Some refactoring in InstantMediaUploadTaskExtension

* Improvements for bookmark / path selection for instant upload

* Remove instant upload configuration if bookmark is not available

* minor refactoring

* Added possibility to cancel account selection

* Small fix: reset the path if new account is selected

* Using item tracking instead of OCQuery

- Disabling instant photo upload if target directory is removed
- Item tracking is potentially faster since it can use cached item information and is not always issuing PROPFIND

* Made some ivars private

* Detect in settings that instant upload path is gone

In this case instant upload is disabled

* - Update ios-sdk
- Take advantage of the new key-value store and OCCoreSkipAvailableOfflineKey to make sure available offline files are not immediately downloaded again after clearing the vault from local copies of available offline files.
- Logging into an account removes any previously set OCCoreSkipAvailableOfflineKey from the key value store
- Move Bookmark locking to an OCBookmarkManager category (next stop: use the new key-value store and bake support for locking bookmarks directly into the SDK)

* - Add missing localization

* Update SDK with latest fixes

* - Fix SettingsTests bugs

* - Apply additional fixes to UI tests and disable the remaining failing ones

* - Wait for connection initialization to complete before requesting sharing info
- Use latest SDK with cookie filtering

* - Turn off Request/Response log tags only filter in project file

* - Disable cookie support

* - Address (13) via SDK update

* link against newest development SDK

* Showing warning that instant upload was disabled

* Fixes for UI testing:
- use new SDK version that returns errors if the SQLite DB has not been opened
- MockOCCore.state now returns .running to avoid queueing of PROPFINDs

* - Fix unit tests

* Added alert shown when in settings when instant upload is disabled

* Added fetchUpdates() within which target folder tracking is started

* - UI testing: make MockOCCore.state no longer return .running due to side effects
- fixed conflicting constraints in two places

* - force-delete bookmarks in UI tests if timeout has passed, log error but don't assert in that case
- handle case where a swipe on table cells in DeleteBookmarkTests triggers deletion outright

* - Further hardening of SettingsTests against timing differences local vs. CI

* - make SettingsTest.testCheckMoreItems() more robust

* Update to the latest changes in the SDK

Those changes reduce memory consumption used for hash calculation

* Change required to accomodate latest SDK changes

* Less parallel photo uploads

* - update SDK to address stuck sync action issues
- no longer auto-open the last selected bookmark when launched by iOS in the background. Instead, the last selected bookmark is now auto-openend only when the app comes to the foreground.
- update FileProviderInterfaceManager to better support the case where the app ships without File Provider.

* Fixed compilation warning

* - Add ATS exemption for File Provider

* - Update SDK

* - Update SDK + add colored debugging option to scheme

* Addressed code review comments

* Removed unneeded weak self

* Removed another unwanted weak self

* - Fix OCEvent-dropping issue via SDK update with fix
- Make UploadMediaAction use OCBackgroundTask to protect while exporting

* - Added missing OCBackgroundTask.start call in UploadMediaAction
- Update SDK

* Fixed missing copyright information and some warnings

* Version Bump to 140

* Media upload pending flag added

- Displaying a warning alert on the next launch, in case media upload couldn’t be completed due e.g. app being terminated in a backround or even due to an app crash.
- Fixed an issue with DispatchGroup.notify() called prematurely in MediaUploadQueue.uploadAssets()

* - Clarify comment

* - sortbar was sometimes hidden
- fixing layout issue

* fixed location identifier for actions

* Added more logs in PHAsset+Upload extension

* - extend ThemeCollection and Theme support throughout the app, fixing the remaining issues with iOS 13 light/dark mode
- ownCloudApp: add annotated properties using ObjC associated values

* - Fix infinite loop / crash on trait changes
- Improve status bar style changes on dark / light mode changes

* - Make Issues view controller themeable / add dark/light mode support

* Version Bump to 141

* Version Bump to 142

* Version Bump to 143

* - new ThemedAlertController automatically adapts to the current style, can be used as drop-in replacement for UIAlertController (which it subclasses)
- make MoreViewHeader fully Themeable (fixing issues when switching between dark/light mode when visible), including TVG icons
- remove hard-coded background color for header in SharingTableViewController
- make NamingViewController use a blur effect and keyboard that match the current dark/light mode
- make ClientItemCell fully Themeable, including TVG icons
- add option to StaticTableViewRow to allow picking different icon tint colors that adapt with dark/light mode changes
- make use of that option in LibraryTableViewController
- fix magnification glass color in GroupSharingTableViewController and make it fully Themeable
- fix SortBar popover content inset issue (iOS 13 only)
- fix UISearchBar theme application / magnification glass color in NSObject+ThemeApplication
- add support for UIVisualEffectView to NSObject+ThemeApplication
- ThemeCollection improvements and fixes
	- add new properties keyboardAppearance and backgroundBlurEffectStyle
	- provide tableRowHighlightColors.backgroundColor to fix issue when overriding system-wide dark mode
- adopt Themeable for CardPresentationController, fixing wrong background color when dragging up a card that was already open before a theme change

* - Address review issues

* solved merge conflict error

* fixed colors in UISegmentedControl for iOS 13

* set tintColor to UIRefreshControl

* Only show theme selection, if follow system appearance is not enabled

* fixed iOS 13 content inset issue for popover

* set the tint color in ThemedAlertController

* set the UITableViewCell interface style for a better, multi-selection circle and disclosure indicator color

* UIActivityIndicator is no longer working proper in iOS 13. Removed this UI element from UISearchBar and showing a message view instead

* fixed default value of system UI appearance

* - Fix finding (7) in #502

* - Fix finding (3) in #502 by translating OCErrorDomain errors to NSCocoaErrorDomain before return (on iOS 13 only)

* Show available Themes for current system appearance mode, if enabled

* code refactoring

* solved some UI updating animations

* changed theme selection again and show system appearance in theme selection list

* - set the tint color for cells so that checkmark will match the same tint color
- changed icon for available offline action

* System was not shown as selected value

* - Update SDK to new version to include OIDC improvements and OCCore fixes

* disable beta build and beta warning

* added changelog for version 1.1.1

* - added activity indicator instead of search message
- fixed searchbar text color
jesmrec pushed a commit that referenced this issue Dec 10, 2019
…548)

* #516 truncate middle of file name instead of tail (#517)

* new app version and build version

* Started implementing more secure photo upload

* Added a fix for background media playback

- Added audio session activation / deactivation code
- Also fixed potential issue for background video playback (PiP) as suggested by Apple in https://developer.apple.com/documentation/avfoundation/media_assets_playback_and_editing/creating_a_basic_video_player_ios_and_tvos/playing_audio_from_a_video_asset_in_the_background

* Fixed naming of uploaded edited photos

* Changes to the mechanism of storing pending PHAsset IDs

* Pending media upload task added

- When uploading photo / video assets, their local identifiers along with target path are stored in the KV-store of the bookmark
- When the app is killed, at next launch, task is spawned which checks if there are any pending assets not yet imported by the core
- Pending assets are uploaded

* Updated with latest sdk version

* Uploading multiple assets within OCCore.schedul(inCoreQueue:) block

* Fixed some issues with uploading pending assets

* Reworked media uploads

- Performing most of the operations synchronously and trying to not spawn to many worker threads
- Executing file imports withing OCCore.schedule() call to post-pone execution of sync operations and to reduce their amount

* Small fixes

* Refactored PendingMediaUploadTaskExtension class

* Removed unccessary scheduling of tasks in the next run loop iteration

- Removed OnMainThread{..} wrapping from scheduleTasks()
- Made sure scheduleTasks() is called after properties affecting current context are set

* Modal UI presented when media files are imported

* Fixed some review findings

* Addressed review findings

* Ignoring fastlane sub-folder

* Fixed some compiler warnings

* Fixed the issue with overwriting asset downloads

Now able to store multiple paths along with single asset in the key value store

* Added OCActivitiy publishing to MediaUploadQueue

* Refactored media upload related OCActivity into separate class

* First working implementation of refactored MediaUploadQueue

- Simplified the architecture
- Separate KV based storadge of upload jobs into MediaUploadStorage class which takes care of handling MediaUploadJob objects
- Improved inter-process concurrency handling

* Removing stored upload jobs upon activity cancellation

* MediaUploadQueue:
- switch to "needsScheduling" mechanism to ensure that assets that get added to the queue are processed as timely as possible. Previously, if assets were added while the queue is being processed, no new run that would include the newly added assets would be triggered.
- fix broken processing locking: creating an OCProcessSession via "OCProcessSession()" creates a session that is never valid, so the queue would get scheduled multiple times, which could lead to many duplicate uploads. Instead OCProcessManager.shared.processSession is now used, which returns a valid session of the current process.
- make control over MediaUploadStorage.processing atomic to avoid race conditions
- use copies of MediaUploadStorage.queue and MediaUploadStorage.jobs as starting point for scheduling, to avoid running into issues if MediaUploadStorage is cached by OCKeyValueStorage and a change to these is made during enumeration
- added additional error logging in case of upload errors
- make addUpload() trigger the newly introduced setNeedsScheduling() so that calls to scheduleUploads() become unnecessary when adding assets to the queue.

MediaUploadStorage:
- convert property-like methods into actual properties

Localizable.strings:
- fix two errors that led to the file becoming unparseable

ios-sdk:
- SDK update to avoid unneeded deserializations

* - Remove duplicate file

* Fixed problem with updating key-value store for every single media asset

- When key value store is updated separately for every media item, there is huge number of background tasks, worker threads etc. being spawned.
- Now adding assets to be uploaded within single [OCKeyValueStore updateObjectForKey:…] block
hosy added a commit that referenced this issue Jan 27, 2020
* Autoplay Media / Show album artwork in the media player view (#566)

* [fix/fp-offline-browsing] Allow offline browsing of folders in the File Provider (#547)

* - Fix Swift and SwiftLint warnings
- Remove unused UploadsSettingsSection (was replaced by MediaUploadSettings)

* - address libzip Xcode project upgrade warning
- add research note to FileProviderExtension
- update SDK

* - Allow offline browsing of folders in the File Provider

* Revert "[fix/fp-offline-browsing] Allow offline browsing of folders in the File Provider (#547)" (#553)

This reverts commit 9a0bc93.

* Autoplay media files implemented as described in issue #59

* Added album artwork as overlay in the player

* Fixed playing next media item in BG and lock screen

- Now multiple items can be played contignuously in the background
- Now playing info in the lock screen contains artwork, title, artist info and displays correct playback timeline
- Audio can be paused / resumed from the lock screen
- Added skip controls allowing to jump 10s backwards and forwards from the play-head position in the lock screen

* Small fixes

* [fix/open-in-on-ipad] Share sheet not visible on iPad (#570)

* [fix/fp-offline-browsing] Allow offline browsing of folders in the File Provider (#547)

* - Fix Swift and SwiftLint warnings
- Remove unused UploadsSettingsSection (was replaced by MediaUploadSettings)

* - address libzip Xcode project upgrade warning
- add research note to FileProviderExtension
- update SDK

* - Allow offline browsing of folders in the File Provider

* Revert "[fix/fp-offline-browsing] Allow offline browsing of folders in the File Provider (#547)" (#553)

This reverts commit 9a0bc93.

* Fix for issue #568: Share sheet was now visible on iPad, if tableview was scrolled down, after first visible page rect

* Changed app version to 1.2.0

* [fix/improve_photo_upload_responsiveness] More reliable photo upload (#548)

* #516 truncate middle of file name instead of tail (#517)

* new app version and build version

* Started implementing more secure photo upload

* Added a fix for background media playback

- Added audio session activation / deactivation code
- Also fixed potential issue for background video playback (PiP) as suggested by Apple in https://developer.apple.com/documentation/avfoundation/media_assets_playback_and_editing/creating_a_basic_video_player_ios_and_tvos/playing_audio_from_a_video_asset_in_the_background

* Fixed naming of uploaded edited photos

* Changes to the mechanism of storing pending PHAsset IDs

* Pending media upload task added

- When uploading photo / video assets, their local identifiers along with target path are stored in the KV-store of the bookmark
- When the app is killed, at next launch, task is spawned which checks if there are any pending assets not yet imported by the core
- Pending assets are uploaded

* Updated with latest sdk version

* Uploading multiple assets within OCCore.schedul(inCoreQueue:) block

* Fixed some issues with uploading pending assets

* Reworked media uploads

- Performing most of the operations synchronously and trying to not spawn to many worker threads
- Executing file imports withing OCCore.schedule() call to post-pone execution of sync operations and to reduce their amount

* Small fixes

* Refactored PendingMediaUploadTaskExtension class

* Removed unccessary scheduling of tasks in the next run loop iteration

- Removed OnMainThread{..} wrapping from scheduleTasks()
- Made sure scheduleTasks() is called after properties affecting current context are set

* Modal UI presented when media files are imported

* Fixed some review findings

* Addressed review findings

* Ignoring fastlane sub-folder

* Fixed some compiler warnings

* Fixed the issue with overwriting asset downloads

Now able to store multiple paths along with single asset in the key value store

* Added OCActivitiy publishing to MediaUploadQueue

* Refactored media upload related OCActivity into separate class

* First working implementation of refactored MediaUploadQueue

- Simplified the architecture
- Separate KV based storadge of upload jobs into MediaUploadStorage class which takes care of handling MediaUploadJob objects
- Improved inter-process concurrency handling

* Removing stored upload jobs upon activity cancellation

* MediaUploadQueue:
- switch to "needsScheduling" mechanism to ensure that assets that get added to the queue are processed as timely as possible. Previously, if assets were added while the queue is being processed, no new run that would include the newly added assets would be triggered.
- fix broken processing locking: creating an OCProcessSession via "OCProcessSession()" creates a session that is never valid, so the queue would get scheduled multiple times, which could lead to many duplicate uploads. Instead OCProcessManager.shared.processSession is now used, which returns a valid session of the current process.
- make control over MediaUploadStorage.processing atomic to avoid race conditions
- use copies of MediaUploadStorage.queue and MediaUploadStorage.jobs as starting point for scheduling, to avoid running into issues if MediaUploadStorage is cached by OCKeyValueStorage and a change to these is made during enumeration
- added additional error logging in case of upload errors
- make addUpload() trigger the newly introduced setNeedsScheduling() so that calls to scheduleUploads() become unnecessary when adding assets to the queue.

MediaUploadStorage:
- convert property-like methods into actual properties

Localizable.strings:
- fix two errors that led to the file becoming unparseable

ios-sdk:
- SDK update to avoid unneeded deserializations

* - Remove duplicate file

* Fixed problem with updating key-value store for every single media asset

- When key value store is updated separately for every media item, there is huge number of background tasks, worker threads etc. being spawned.
- Now adding assets to be uploaded within single [OCKeyValueStore updateObjectForKey:…] block

* [fix/fp-word] Fix Word FileProvider issue (#574)

* - Overhaul -importDocumentAtURL: to use file coordination and return placeholders only after they've been added to the database (via updated SDK)
- Fix app toolbar icons glitch when re-opening the client browser for an account after launch

* - Switch from develop to master branch for ios-sdk

* - Update SDK to fix finding (1)

* Fixed (4) and (5)

- Disabled skip X seconds commands for now
- Added play next / previous track commands
- Removing system-wide now playing info if corresponding media playback view controller gets released

* #550 fixed QA finding (1) for regression test 1.2.0, Import panel was not displayed on iOS 13

* Fixed a now playing issue with jumping time

* Fixed issue with images not being uploaded when MP4 conversion option was active

* new build number

* Temporarily removed conversion of videos to MP4

* disable beta warning

* Translation Sync (#525)

* [tx] updated from transifex

* Removed the es lang because was wrong and it is not necessary to map it (es -> es) (#310)

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* use newest SDK version

* changed file encoding for localization files

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* - using correct SDK
- solved encoding problems for localization files

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* change version number 1.0 -> 1.0.1

* Fixed QA finding (1). "Share item" menu item was not visible, if item was not shared

* Fix finding (3)

* Fixed an issue with go-to button not being shown in PDF viewer (#403)

* Fixed an issue with go-to button not being shown in PDF viewer

* Added accessibility labels to bar button items in the PDF viewer

* Version Bump to 121

* - Action class:
	- extend ActionWillRunHandler with a completionHandler and adding a new .perform() method to wrap .willRun() and .run(), allowing for actions to trigger view controller dismissals, wait for them to finish and then present their own view controllers
- Card upgrades, improvement and fixes
	- fix MoreViewController "shaking" on initial presentation
	- create new CardPresentationSizing protocol to allow view controllers to provide sizing information to CardPresentationController
	- allow disabling the handle and the ability to dismiss by tapping in the background
	- create CardViewController as base class for future view controllers that should be presented as cards
 - Add new DownloadItemsHUDViewController class (a CardViewController subclass) to modally download files, provide a summary, allow cancellation and simplified retrieval of the corresponding OCFile objects
- Clean up OpenInAction and rewrite most of it to use DownloadItemsHUDViewController
- KVOWaiter allows waiting for an object's value to change, check if the change meets the criteria and then run a block once. Ended up not being used and is therefore not included in the builds. But since it may be useful in the future, left the source code regardless.
- Add ProgressSummary.update(progressView:) convenience method

* [tx] updated from transifex

* - Switch to release/1.0.1 branch for ios-sdk

* - Add "Preparing" message to DownloadItemsHUDViewController while scheduling downloads
- Update ios-sdk, fixing findings (5) + (6)

* - Fix premature release of UIDocumentInteractionController in OpenInAction

* using correct release SDK

* [tx] updated from transifex

* - Add support for Progress.isCancelled to ProgressSummarizer

* Version Bump to 122

* - Addressing (5) via SDK update rescheduling/retrying dropped requests

* - Addressing (5) via SDK update rescheduling/retrying dropped requests

* - Make File Provider use new SDK option to return immediately from a thumbnail request when offline

* [tx] updated from transifex

* Version Bump to 123

* - Add new APP_SHORT_VERSION variable to build settings
- Make Info.plist for app, File Provider and File Provider UI use it

* - Fix remaining (5) issue for cases where the upload succeeded but the server response was cut off, prompting a retry and resulting in a "item already exists" error

* - Update ios-sdk

* [tx] updated from transifex

* [tx] updated from transifex

* changed wrong file encoding from UTF-16LE to UTF-8

* QA finding (14) removed ownCloud name from localizable stings

* removed ownCloud string in localizable strings

* fixed merge conclicts

* using newest release SDK

* changed file encoding from UTF-16LE to UTF-8

* changed file encoding from UTF-16LE to UTF-8

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* Naming improvements based on latest SDK:
- uploads use new OCCoreOptionAutomaticConflictResolutionNameStyle option to automatically resolve naming conflicts during upload
- Duplicate action uses the new OCCore name suggestion API to
	- determine naming conflicts and resolve them automatically
	- match the name style of the file to duplicate, f.ex.
		- duplicating "File copy.jpg" will create "File copy 2.jpg"
		- duplicating "File (1).jpg" will create "File (2).jpg"
		- duplicating "File Kopie 2.jpg" will create "File Kopie 3.jpg"
- folder creation uses the new OCCore name suggestion API to
	- detect naming conflicts beforehand
	- pre-fill the new folder name name with an unused name directly

* #393 added an activity indicator which will be shown, if offline copies will be deleted to give the user a UI feedback

* - Change SDK branch to master

* #76 user can import files using the iOS share sheet. all file types are accepted.

* - using new SDK with fixes for requesting core
- minor code fixes

* - Log device, version and locale information at the beginning of every log file using new SDK protocol
- Show SDK commit hash in Settings

* fixed crash, changed bookmark name to shortname

* changed UIAlertViewController for account selection to CardViewController style for testing

* fixed icon badge creation for fastlane lane In-House Enterprise IPA generation

* install librsvg for fastlane via sh

* moved import file code to own class

* added option to automatically resolve name conflicts, if file name already exists

* Changed app version to 1.1.0

* enabled beta build and warning

*  Keep the gallery alive after doing some action over an item (#447)

* Rename updates the currently visible file in the gallery

* Keeping gallery alive fix

- Don’t pop to the root view controller on destructive action by default
- Only pop to the root if all items have been deleted
- Select next item upon deletion of the current ones
- Update UIPageViewController data source if number of items changes due e.g. to duplication or deletion

* Small fixes

* Fixed review findings

* Media player implemented using AVKit (#429)

* Media player implemented using AVKit

* Added possibility to stream audio / video

* Improved error handling

* Fixed review finding

* Added background audio, airplay and PiP mode

* Propagating safe area to the main view of AVPlayerViewController

* Another fix for safe area considering layout of AVPlayerViewController

* Updated to latest develop version of SDK

* Display error message in case file couldn’t be preview e.g. due to file corruption (#427)

* [tx] updated from transifex

* Fixed UI test for creating folder, need to return a fixed name, because suggestion is not working in tests

* added a description header and changed typo

* - fixed showing the directory picker controller, after the card view was dismissed
- use the current development SDK

* Version Bump to 126

* - create local copy of import file, if needed
- fixed create folder action
- delete local copy, if needed
- code review changes

* - improved duplicate item deletion behaviour
	- add additional safeguard so duplicate files are only deleted if they were actually duplicated (previously non-duplicate files could be removed if duplication or folder creation failed)
	- remove temporary container folder, too
- add 2 second delay before returning the core to give the core an opportunity to schedule the upload on a NSURLSession

* Version Bump to 127

* changed back signing identity

* Version Bump to 128

* added required CFBundleTypeName key

* Version Bump to 129

* updated changelog

* use formSheet presentation style for the iPad when showing the document picker

* Fix for images not being displayed in the gallery

* Version Bump to 130

* [tx] updated from transifex

* Version Bump to 131

* [fix/sharing-search] Fixed min length for searching sharing users (#455)

* #454 used correct comparator for sharingSearchMinLength and set a new default value, if capability does not exists

* added a constant for defaultSharingSearchMinLength value

* [tx] updated from transifex

* - Update ios-sdk to address finding (1) in ios-app #446

* Preventing updating UI in DisplayViewController while item is being changed

- Not calling present(item:) while meta data of OCItem is being updated
- Elliminated an assumption in MediaDisplayViewController that render renderSpecificView() can be called only once.
- Making sure that AVPlayer is not re-created upon changes in OCItem but that rather AVPlayerItem is replaced.

* Fixed a small warning

* Tried to improve gallery logic concerning items modification

- Watch out if the modification does still includes the item with local ID of the currently visible item.
- Take care of failed move but watching out for reappearing items

* Added a setting allowing to decide user if media files shall be streamed

* - Add debug output to Display*ViewController
- Fix SwiftLint warnings

* Fixed handling of deleted / moved item in the gallery

* Another small fix for handling of failed item move

* Version Bump to 132

* Added LSSupportsOpeningDocumentsInPlace key to Info.plist

* Fixed Info.plist and added LSHandlerRank property

* Fix for #455 issue: no search request triggered

* show always the account selection sheet and added a note, that only one file can be imported at once

* use securtiy scoped file operation for importing a file

* Fix for the PR #447 (keep gallery alive) (#465)

* Keeping track of individual OCItems in DisplayViewController instances

But loading the list of items in the gallery only once and not reacting to any changes (moving, deleting)

* Removed query stop call in DisplayHostViewController

Since this query is not created there but just passed from the parent view.

* Removing more button if the currently viewed file got moved or deleted

* Fixed updating UI after renaming current item

* Fixed a warning

* Fixed issues in the gallery

* - Minor fixes

* [feature/bundle-import] Add support for certain bundle formats to the share sheet (#471)

* - Add support for import of bundle-based document formats through transparent zipping
	- moved previous FileProvider functionality into ownCloudApp.framework
	- new method OCCore.importItemNamed() ensures correct handling of bundle-based document formats
	- fixes finding (4) in #445
- Changed LSSupportsOpeningDocumentsInPlace to NO address two issues:
	- the app is now listed as "Copy to ownCloud" (previously "Open in ownCloud", which was technically not correct)
	- previously, documents using "Open to ownCloud" would no longer open in f.ex. Pages, but in the ownCloud app when selected in the Files app

* - Refactored ImportFilesController around using NSFileCoordinator, fixing finding (1) in #471

* changed path for moved Info.plist for target ownCloudAppFramework

* Version Bump to 133

* [feature/sort direction] Allow sorting asc/desc for all sort methods (#474)

* #470 added change sort direction asc/desc for all sort methods

* - removed comments
- changed translation keys

* fixes sort comparator for sort method "shared"

* use correct images for sort direction asc and desc

* updated choosing sort method from a tableView/Popover instead of a UIAlertViewController

* set maximum width for popover and set arrow direction

* Added show sort direction in UISegmentControl

* - make sure arrows of popovers appear in same color as the popover contents
- fix issue where direction was toggled during setup of SortBar (setting of initial value from user defaults), so logging in, logging out and logging in would change the sort direction
- reset sort direction to ascendant when switching sort methods
- SortMethodTableViewController
	- remove extraneous instance lets
	- enforce row height used for table view height calculation
	- change table view height calculation to account for the last divider (which could look a bit off if present)

* tap on segment control was fired twice, because there was a missing check, if selected segment changed

* fixed changing width on selecting an other segment

* fixed jumping width of sortSegmentControl items by setting the same width for all items by calculating the longest width before

* [fix/index-bar] Make Index Bar available in general file list (#469)

* #413 show index bar in general file list
- Index bar is only visible, if sorting is "Sort by name"
- Index bar is only visible, if more than one different letters are available
- Index bar is only visible, if more items are available as visible

* - adopt to new sort methods
- reverse index list, if sort direction is descendant

* Version Bump to 134

* Version Bump to 135

* Version Bump to 136

*  Change behaviour of default expiration date (#476)

* Enabling expiration date switch if default expiration date is configured

Checking files_sharing.public.expire_date.expire_date.days server capability. If it is set then it is used as default date and the switch is enabled even if the expiration date is not enforced.

* Fixed QA issue (1)

* Fixed QA finding (2): limiting the date range if expiration date is enforced

* Permission increasing UX in reshares (#467)

* Not showing permissions which can’t be elevated

Affecting items shared with the current users which are being reshared

* Fixed an issue with wrong permissions displayed when creating public link

- Checking if permissions can be elevated for the public link
- Only viable options are displayed

* Fixed a trailing whitespace warning

* Fixed another compiler warning

* Inhereting permissions from the share when creating public link

* Fixed QA finding (4)

* Fixed QA finding (1)

* Fixed QA finding (2)

* Version Bump to 137

* [feature/itempolicy] Item Policy / Available Offline support (#456)

* Available Offline Support
- new MakeAvailableOfflineAction and MakeUnavailableOfflineAction actions
- new Available Offline Library section
	- easy access to all files available offline via Available Offline
	- new ItemPolicyTableViewController and ItemPolicyCell prepared for reuse for presenting other item policies
- Design: added SVG/TVG/PNG icons and cloud symbols for make available offline / make unavailable offline

ClientItemCell changes
- new ClientItemResolvingCell can resolve item from LocalID or path, new superclass of ShareClientItemCell and ItemPolicyCell
- string to use as content for title and detail are now provided via titleLabelString(for:) and detailLabelString(for:), updated via updateLabels(with:), making customization easier
- support for new available offline badge

ProgressSummarizer changes
- changed ProgressSummary from a struct to a class, addressing issue #451 ("Waiting for server response..." message sometimes not disappearing)

* - Adopt OCClaim to ensure files aren't deleted while they are being used in
	- DisplayViewController
	- DownloadItemsHUDViewController
	- FileListTableViewController
	- File Provider
- Add new Storage Settings to allow control over how long unused local copies are kept around
- DisplayViewController now uses OCClaims to ensure files aren't deleted while they are being viewed
- ClientItemCell uses new SDK APIs to
	- show "available offline" badges for folders
	- to indicate if an item has been made available offline directly (solid icon) or indirectly (dimmed icon)
	- keep the cloud status icon updated following changes
- Change "+" icon to "•••" icon in file list, rename plusButton to folderAction everywhere
- Action.provideAlertAction() now applies padding to images if necessary so their text aligns at the same horizontal offset
- Fix typo in BookmarkInfoViewController and change wording from "Delete Offline Copies" to "Delete Local Copies" for consistency
- Update swiftlint.yml to silence ownCloudScreenshotsTests warnings

* - Update ios-sdk

* - Make changes requested in code review, adding missing localizable strings and removing extraneous code

* - Update SDK

* - Add downloadTriggerIdentifier and availableOfflinePolicyCoverage as properties that trigger the update of an item's visual representation (addressing finding 6 in #456)
- Update make available offline action to use new convertExistingLocalDownloads option (addressing finding 2 in #456)
- Update SDK (addressing finding 5 in #456)

* Items in moved Available Offline folders should no longer be cleared locally and re-downloaded, following under the hood improvements in the ios-sdk

* - Add initial support for cookies via SDK update

* - Temporarily disable some UI tests broken due to lack of database running

* - Fix issue (11) in #456 by updating the lastUsed date of already downloaded items when they are viewed

* - Added slider type to StaticTableViewRow
- changed storage settings to allow picking a timeframe via slider rather than a list of time frames

* - Change text from "Remove" to "Make unavailable offline" in Quick Access > Available Offline list (addressing issue (9))

* - Update BookmarkInfoViewController to provide users with the choice to also remove local copies of items marked as Available Offline, issuing a warning and giving the users a way to cancel, addressing issue (12) in #456.

* - Update ios-sdk
- Take advantage of the new key-value store and OCCoreSkipAvailableOfflineKey to make sure available offline files are not immediately downloaded again after clearing the vault from local copies of available offline files.
- Logging into an account removes any previously set OCCoreSkipAvailableOfflineKey from the key value store
- Move Bookmark locking to an OCBookmarkManager category (next stop: use the new key-value store and bake support for locking bookmarks directly into the SDK)

* - Add missing localization

* Update SDK with latest fixes

* - Fix SettingsTests bugs

* - Apply additional fixes to UI tests and disable the remaining failing ones

* - Wait for connection initialization to complete before requesting sharing info
- Use latest SDK with cookie filtering

* - Turn off Request/Response log tags only filter in project file

* - Disable cookie support

* - Address (13) via SDK update

* link against newest development SDK

* Fixes for UI testing:
- use new SDK version that returns errors if the SQLite DB has not been opened
- MockOCCore.state now returns .running to avoid queueing of PROPFINDs

* - Fix unit tests

* - UI testing: make MockOCCore.state no longer return .running due to side effects
- fixed conflicting constraints in two places

* - force-delete bookmarks in UI tests if timeout has passed, log error but don't assert in that case
- handle case where a swipe on table cells in DeleteBookmarkTests triggers deletion outright

* - Further hardening of SettingsTests against timing differences local vs. CI

* - make SettingsTest.testCheckMoreItems() more robust

* Version Bump to 138

* [feature/reorder buttons] Reorder Navigation Bar Actions (#478)

* Available Offline Support
- new MakeAvailableOfflineAction and MakeUnavailableOfflineAction actions
- new Available Offline Library section
	- easy access to all files available offline via Available Offline
	- new ItemPolicyTableViewController and ItemPolicyCell prepared for reuse for presenting other item policies
- Design: added SVG/TVG/PNG icons and cloud symbols for make available offline / make unavailable offline

ClientItemCell changes
- new ClientItemResolvingCell can resolve item from LocalID or path, new superclass of ShareClientItemCell and ItemPolicyCell
- string to use as content for title and detail are now provided via titleLabelString(for:) and detailLabelString(for:), updated via updateLabels(with:), making customization easier
- support for new available offline badge

ProgressSummarizer changes
- changed ProgressSummary from a struct to a class, addressing issue #451 ("Waiting for server response..." message sometimes not disappearing)

* - Adopt OCClaim to ensure files aren't deleted while they are being used in
	- DisplayViewController
	- DownloadItemsHUDViewController
	- FileListTableViewController
	- File Provider
- Add new Storage Settings to allow control over how long unused local copies are kept around
- DisplayViewController now uses OCClaims to ensure files aren't deleted while they are being viewed
- ClientItemCell uses new SDK APIs to
	- show "available offline" badges for folders
	- to indicate if an item has been made available offline directly (solid icon) or indirectly (dimmed icon)
	- keep the cloud status icon updated following changes
- Change "+" icon to "•••" icon in file list, rename plusButton to folderAction everywhere
- Action.provideAlertAction() now applies padding to images if necessary so their text aligns at the same horizontal offset
- Fix typo in BookmarkInfoViewController and change wording from "Delete Offline Copies" to "Delete Local Copies" for consistency
- Update swiftlint.yml to silence ownCloudScreenshotsTests warnings

* - Update ios-sdk

* - Make changes requested in code review, adding missing localizable strings and removing extraneous code

* #477 reorganize navigation bar with create and more button and moved select button to sort menu

* added safeAreaLayoutGuide.rightAnchor

* - Update SDK

* changed "Select" image

* - Add downloadTriggerIdentifier and availableOfflinePolicyCoverage as properties that trigger the update of an item's visual representation (addressing finding 6 in #456)
- Update make available offline action to use new convertExistingLocalDownloads option (addressing finding 2 in #456)
- Update SDK (addressing finding 5 in #456)

* Items in moved Available Offline folders should no longer be cleared locally and re-downloaded, following under the hood improvements in the ios-sdk

* - Temporarily disable some UI tests broken due to lack of database running

* - Fix issue (11) in #456 by updating the lastUsed date of already downloaded items when they are viewed

* - Added slider type to StaticTableViewRow
- changed storage settings to allow picking a timeframe via slider rather than a list of time frames

* - Change text from "Remove" to "Make unavailable offline" in Quick Access > Available Offline list (addressing issue (9))

* - Update BookmarkInfoViewController to provide users with the choice to also remove local copies of items marked as Available Offline, issuing a warning and giving the users a way to cancel, addressing issue (12) in #456.

* addresses:
- missing multiselection UI in toolbar
- missing select all / deselect all button in navigation bar

* set if selectButton should be shown

* disable temporary some tests due to bitrise failures

* using correct SDK

* Version Bump to 139

* Feature/task scheduling (#484)

* #386 Added relevant classes

* First draft of the scheduled task manager

* Just changed some comments

* Implemented background fetch

* Implemented background update fetch

* Clean up of the code

* Fixed merge problems from previous commit

And eliminated some warnings

* Small changes in background fetch operation

* Some refactoring done

* Added some user defaults for media upload

* Available Offline Support
- new MakeAvailableOfflineAction and MakeUnavailableOfflineAction actions
- new Available Offline Library section
	- easy access to all files available offline via Available Offline
	- new ItemPolicyTableViewController and ItemPolicyCell prepared for reuse for presenting other item policies
- Design: added SVG/TVG/PNG icons and cloud symbols for make available offline / make unavailable offline

ClientItemCell changes
- new ClientItemResolvingCell can resolve item from LocalID or path, new superclass of ShareClientItemCell and ItemPolicyCell
- string to use as content for title and detail are now provided via titleLabelString(for:) and detailLabelString(for:), updated via updateLabels(with:), making customization easier
- support for new available offline badge

ProgressSummarizer changes
- changed ProgressSummary from a struct to a class, addressing issue #451 ("Waiting for server response..." message sometimes not disappearing)

* UI for bookmark / upload path selection

* Added dummy implementation of media upload task

* - Adopt OCClaim to ensure files aren't deleted while they are being used in
	- DisplayViewController
	- DownloadItemsHUDViewController
	- FileListTableViewController
	- File Provider
- Add new Storage Settings to allow control over how long unused local copies are kept around
- DisplayViewController now uses OCClaims to ensure files aren't deleted while they are being viewed
- ClientItemCell uses new SDK APIs to
	- show "available offline" badges for folders
	- to indicate if an item has been made available offline directly (solid icon) or indirectly (dimmed icon)
	- keep the cloud status icon updated following changes
- Change "+" icon to "•••" icon in file list, rename plusButton to folderAction everywhere
- Action.provideAlertAction() now applies padding to images if necessary so their text aligns at the same horizontal offset
- Fix typo in BookmarkInfoViewController and change wording from "Delete Offline Copies" to "Delete Local Copies" for consistency
- Update swiftlint.yml to silence ownCloudScreenshotsTests warnings

* - Update ios-sdk

* - Make changes requested in code review, adding missing localizable strings and removing extraneous code

* - Update SDK

* Refactored current implementation of media upload

* Added method to fetch photos from photo library

* - Add downloadTriggerIdentifier and availableOfflinePolicyCoverage as properties that trigger the update of an item's visual representation (addressing finding 6 in #456)
- Update make available offline action to use new convertExistingLocalDownloads option (addressing finding 2 in #456)
- Update SDK (addressing finding 5 in #456)

* Items in moved Available Offline folders should no longer be cleared locally and re-downloaded, following under the hood improvements in the ios-sdk

* - Add initial support for cookies via SDK update

* First draft of instant photo upload implementation

* Calling task completion handler after upload was finished

* - Temporarily disable some UI tests broken due to lack of database running

* - Fix issue (11) in #456 by updating the lastUsed date of already downloaded items when they are viewed

* - Added slider type to StaticTableViewRow
- changed storage settings to allow picking a timeframe via slider rather than a list of time frames

* - Change text from "Remove" to "Make unavailable offline" in Quick Access > Available Offline list (addressing issue (9))

* - Update BookmarkInfoViewController to provide users with the choice to also remove local copies of items marked as Available Offline, issuing a warning and giving the users a way to cancel, addressing issue (12) in #456.

* Fixed QA finding (1)

* Using PHAsset.creationDate to check which media files shall be instantly uploaded

* Fixed naming of class / group

* Moved Tasks folder

* Fixed some review findings

* - Fix issue where a busy bookmark alert is followed by duplicating the bookmark

* Fixed some review findings

* Improved background update fetching

* Fixed some issues in media upload

* Fixed a type in settings key

* Improvements in the instant media upload task

* Added missing returnCore in the selection of the instant upload path

* Fixed QA finding (3)

* Fixes for the correct core returning / requesting

* Small cosmetic code changes

* Fixed video and serialized photo / video uploads

* Moved upload() method to UploadBaseAction class

* Some refactoring in InstantMediaUploadTaskExtension

* Improvements for bookmark / path selection for instant upload

* Remove instant upload configuration if bookmark is not available

* minor refactoring

* Added possibility to cancel account selection

* Small fix: reset the path if new account is selected

* Using item tracking instead of OCQuery

- Disabling instant photo upload if target directory is removed
- Item tracking is potentially faster since it can use cached item information and is not always issuing PROPFIND

* Made some ivars private

* Detect in settings that instant upload path is gone

In this case instant upload is disabled

* - Update ios-sdk
- Take advantage of the new key-value store and OCCoreSkipAvailableOfflineKey to make sure available offline files are not immediately downloaded again after clearing the vault from local copies of available offline files.
- Logging into an account removes any previously set OCCoreSkipAvailableOfflineKey from the key value store
- Move Bookmark locking to an OCBookmarkManager category (next stop: use the new key-value store and bake support for locking bookmarks directly into the SDK)

* - Add missing localization

* Update SDK with latest fixes

* - Fix SettingsTests bugs

* - Apply additional fixes to UI tests and disable the remaining failing ones

* - Wait for connection initialization to complete before requesting sharing info
- Use latest SDK with cookie filtering

* - Turn off Request/Response log tags only filter in project file

* - Disable cookie support

* - Address (13) via SDK update

* link against newest development SDK

* Showing warning that instant upload was disabled

* Fixes for UI testing:
- use new SDK version that returns errors if the SQLite DB has not been opened
- MockOCCore.state now returns .running to avoid queueing of PROPFINDs

* - Fix unit tests

* Added alert shown when in settings when instant upload is disabled

* Added fetchUpdates() within which target folder tracking is started

* - UI testing: make MockOCCore.state no longer return .running due to side effects
- fixed conflicting constraints in two places

* - force-delete bookmarks in UI tests if timeout has passed, log error but don't assert in that case
- handle case where a swipe on table cells in DeleteBookmarkTests triggers deletion outright

* - Further hardening of SettingsTests against timing differences local vs. CI

* - make SettingsTest.testCheckMoreItems() more robust

* Update to the latest changes in the SDK

Those changes reduce memory consumption used for hash calculation

* Change required to accomodate latest SDK changes

* Less parallel photo uploads

* - update SDK to address stuck sync action issues
- no longer auto-open the last selected bookmark when launched by iOS in the background. Instead, the last selected bookmark is now auto-openend only when the app comes to the foreground.
- update FileProviderInterfaceManager to better support the case where the app ships without File Provider.

* Fixed compilation warning

* - Add ATS exemption for File Provider

* - Update SDK

* - Update SDK + add colored debugging option to scheme

* Addressed code review comments

* Removed unneeded weak self

* Removed another unwanted weak self

* - Fix OCEvent-dropping issue via SDK update with fix
- Make UploadMediaAction use OCBackgroundTask to protect while exporting

* - Added missing OCBackgroundTask.start call in UploadMediaAction
- Update SDK

* Fixed missing copyright information and some warnings

* Version Bump to 140

* Media upload pending flag added

- Displaying a warning alert on the next launch, in case media upload couldn’t be completed due e.g. app being terminated in a backround or even due to an app crash.
- Fixed an issue with DispatchGroup.notify() called prematurely in MediaUploadQueue.uploadAssets()

* - sortbar was sometimes hidden
- fixing layout issue

* fixed location identifier for actions

* Added more logs in PHAsset+Upload extension

* removed unused string files for fastlane screenshot creation

* Fixes (1) and (2)

* disable beta warning

* Fixes issue (3) with downloads being cancelled by preview

* - Update SDK to address finding (4) in #461

* - Update SDK to solve remaining of finding (4)

* fixed strange text encoding (Transifex error)=

* - Update ios-sdk to include latest changes
- Fix SwiftLint warning in DisplayHostViewController.swift

* [tx] updated from transifex

* updated changelog for version 1.1.0

* - change presentation of "Make unavailable offline" action to filled icon + "Available offline" + checkmark
- optimize PNG images to save space
- fix lack of OAuth2 renewed token propagation (#501: token renewal from Files App) via ios-sdk update

* added missing localization string

* - Update ios-sdk to satisfy new requirements for using ASAuthorization in iOS 13

* - Fix finding (11) in #461 via SDK update

* Fixed issue (6)

* - Add debug output to verify theory on stuck uploads issue

* - Update SDK to add improved logging and allowing to enable use of OCCores after they were returned and stopped ("zombie core detection")

* - Update SDK
- Fix retain cycle in MediaUploadSettingsSection that could also lead to a zombie core

* using the newest development SDK:
- solving showing certificate error in document browser (file provider)
- solved importFile on main thread issue

* Version Bump to 141

* - new localization values from Transifex
- changed wrong/too long localization strings
- added missing localizations

* added new localization language Basque

* added localization files for fastlane screenshot generator

* updated to newest SDK after localization changes

* - added new var to get beta warning state
- disabled beta warning, beta build
- using the newest development SDK

* set new build number

* using master SDK version 1.1.0

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* new build number

* fixed encoding hell UTF-8 / UTF-16

* - added arabic language files to project
- fixed wrong encoding

* - fixed wrong padding for label
- localized "Feedback" button

* removed Feedback button from server list view

* Renamed instant upload to auto upload

* Version Bump to 146

* added changelog for version 1.2.0

* Updated oC SDK to latest master

* Fixed compilation issue

* Fix infinite loop when duplicating a Folder in Files app (#577)

- QueryFileListTableViewController: request only needed/used data (#577)
- FileProviderExtension: return correct error for file collissions (previously commented out due to duplicate bug) on iOS 13.3 and later
- FileProviderEnumerator: include the root item only for the root folder. If it's not included, no folder can be created in the root directory. If a non-root folder is included in a query result for its content, the Files Duplicate action will loop infinitely.

* added missing delete bookmark confirmation

* fixed german translation string

* using ThemeWindow in SceneDelegate

* fixed getting current system appearance

* fixed broken badge generation for bitrise builds, reverting to an old pange version

* - adapt to ios-sdk changes with regards to OCActivityIdentifier
- make ClientActivityViewController prevent display sleep while shown and there are activities

* - Turn UIApplication.shared.currentWindow into a property and adapt code accordingly

* using correct SDK

* Remove previous merge debris

* - Remove previous merge debris, part 2

* update sdk reference

Co-authored-by: Michael Neuwert <[email protected]>
Co-authored-by: Matthias Hühne <[email protected]>
Co-authored-by: Jesús Recio Rincón <[email protected]>
hosy added a commit that referenced this issue Feb 12, 2020
* [tx] updated from transifex

* use newest SDK version

* changed file encoding for localization files

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* - using correct SDK
- solved encoding problems for localization files

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* change version number 1.0 -> 1.0.1

* Fixed QA finding (1). "Share item" menu item was not visible, if item was not shared

* Fix finding (3)

* Fixed an issue with go-to button not being shown in PDF viewer (#403)

* Fixed an issue with go-to button not being shown in PDF viewer

* Added accessibility labels to bar button items in the PDF viewer

* Version Bump to 121

* - Action class:
	- extend ActionWillRunHandler with a completionHandler and adding a new .perform() method to wrap .willRun() and .run(), allowing for actions to trigger view controller dismissals, wait for them to finish and then present their own view controllers
- Card upgrades, improvement and fixes
	- fix MoreViewController "shaking" on initial presentation
	- create new CardPresentationSizing protocol to allow view controllers to provide sizing information to CardPresentationController
	- allow disabling the handle and the ability to dismiss by tapping in the background
	- create CardViewController as base class for future view controllers that should be presented as cards
 - Add new DownloadItemsHUDViewController class (a CardViewController subclass) to modally download files, provide a summary, allow cancellation and simplified retrieval of the corresponding OCFile objects
- Clean up OpenInAction and rewrite most of it to use DownloadItemsHUDViewController
- KVOWaiter allows waiting for an object's value to change, check if the change meets the criteria and then run a block once. Ended up not being used and is therefore not included in the builds. But since it may be useful in the future, left the source code regardless.
- Add ProgressSummary.update(progressView:) convenience method

* [tx] updated from transifex

* - Switch to release/1.0.1 branch for ios-sdk

* - Add "Preparing" message to DownloadItemsHUDViewController while scheduling downloads
- Update ios-sdk, fixing findings (5) + (6)

* - Fix premature release of UIDocumentInteractionController in OpenInAction

* using correct release SDK

* [tx] updated from transifex

* - Add support for Progress.isCancelled to ProgressSummarizer

* Version Bump to 122

* - Addressing (5) via SDK update rescheduling/retrying dropped requests

* - Addressing (5) via SDK update rescheduling/retrying dropped requests

* - Make File Provider use new SDK option to return immediately from a thumbnail request when offline

* [tx] updated from transifex

* Version Bump to 123

* - Add new APP_SHORT_VERSION variable to build settings
- Make Info.plist for app, File Provider and File Provider UI use it

* - Fix remaining (5) issue for cases where the upload succeeded but the server response was cut off, prompting a retry and resulting in a "item already exists" error

* - Update ios-sdk

* [tx] updated from transifex

* [tx] updated from transifex

* changed wrong file encoding from UTF-16LE to UTF-8

* QA finding (14) removed ownCloud name from localizable stings

* removed ownCloud string in localizable strings

* fixed merge conclicts

* using newest release SDK

* changed file encoding from UTF-16LE to UTF-8

* changed file encoding from UTF-16LE to UTF-8

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* Naming improvements based on latest SDK:
- uploads use new OCCoreOptionAutomaticConflictResolutionNameStyle option to automatically resolve naming conflicts during upload
- Duplicate action uses the new OCCore name suggestion API to
	- determine naming conflicts and resolve them automatically
	- match the name style of the file to duplicate, f.ex.
		- duplicating "File copy.jpg" will create "File copy 2.jpg"
		- duplicating "File (1).jpg" will create "File (2).jpg"
		- duplicating "File Kopie 2.jpg" will create "File Kopie 3.jpg"
- folder creation uses the new OCCore name suggestion API to
	- detect naming conflicts beforehand
	- pre-fill the new folder name name with an unused name directly

* #393 added an activity indicator which will be shown, if offline copies will be deleted to give the user a UI feedback

* - Change SDK branch to master

* #76 user can import files using the iOS share sheet. all file types are accepted.

* - using new SDK with fixes for requesting core
- minor code fixes

* - Log device, version and locale information at the beginning of every log file using new SDK protocol
- Show SDK commit hash in Settings

* fixed crash, changed bookmark name to shortname

* changed UIAlertViewController for account selection to CardViewController style for testing

* fixed icon badge creation for fastlane lane In-House Enterprise IPA generation

* install librsvg for fastlane via sh

* moved import file code to own class

* added option to automatically resolve name conflicts, if file name already exists

* Changed app version to 1.1.0

* enabled beta build and warning

*  Keep the gallery alive after doing some action over an item (#447)

* Rename updates the currently visible file in the gallery

* Keeping gallery alive fix

- Don’t pop to the root view controller on destructive action by default
- Only pop to the root if all items have been deleted
- Select next item upon deletion of the current ones
- Update UIPageViewController data source if number of items changes due e.g. to duplication or deletion

* Small fixes

* Fixed review findings

* Media player implemented using AVKit (#429)

* Media player implemented using AVKit

* Added possibility to stream audio / video

* Improved error handling

* Fixed review finding

* Added background audio, airplay and PiP mode

* Propagating safe area to the main view of AVPlayerViewController

* Another fix for safe area considering layout of AVPlayerViewController

* Updated to latest develop version of SDK

* Display error message in case file couldn’t be preview e.g. due to file corruption (#427)

* [tx] updated from transifex

* Fixed UI test for creating folder, need to return a fixed name, because suggestion is not working in tests

* added a description header and changed typo

* - fixed showing the directory picker controller, after the card view was dismissed
- use the current development SDK

* Version Bump to 126

* - create local copy of import file, if needed
- fixed create folder action
- delete local copy, if needed
- code review changes

* - improved duplicate item deletion behaviour
	- add additional safeguard so duplicate files are only deleted if they were actually duplicated (previously non-duplicate files could be removed if duplication or folder creation failed)
	- remove temporary container folder, too
- add 2 second delay before returning the core to give the core an opportunity to schedule the upload on a NSURLSession

* Version Bump to 127

* changed back signing identity

* Version Bump to 128

* added required CFBundleTypeName key

* Version Bump to 129

* updated changelog

* use formSheet presentation style for the iPad when showing the document picker

* Fix for images not being displayed in the gallery

* Version Bump to 130

* [tx] updated from transifex

* Version Bump to 131

* [fix/sharing-search] Fixed min length for searching sharing users (#455)

* #454 used correct comparator for sharingSearchMinLength and set a new default value, if capability does not exists

* added a constant for defaultSharingSearchMinLength value

* [tx] updated from transifex

* - Update ios-sdk to address finding (1) in ios-app #446

* Preventing updating UI in DisplayViewController while item is being changed

- Not calling present(item:) while meta data of OCItem is being updated
- Elliminated an assumption in MediaDisplayViewController that render renderSpecificView() can be called only once.
- Making sure that AVPlayer is not re-created upon changes in OCItem but that rather AVPlayerItem is replaced.

* Fixed a small warning

* Tried to improve gallery logic concerning items modification

- Watch out if the modification does still includes the item with local ID of the currently visible item.
- Take care of failed move but watching out for reappearing items

* Added a setting allowing to decide user if media files shall be streamed

* - Add debug output to Display*ViewController
- Fix SwiftLint warnings

* Fixed handling of deleted / moved item in the gallery

* Another small fix for handling of failed item move

* Version Bump to 132

* Added LSSupportsOpeningDocumentsInPlace key to Info.plist

* Fixed Info.plist and added LSHandlerRank property

* Fix for #455 issue: no search request triggered

* show always the account selection sheet and added a note, that only one file can be imported at once

* use securtiy scoped file operation for importing a file

* Fix for the PR #447 (keep gallery alive) (#465)

* Keeping track of individual OCItems in DisplayViewController instances

But loading the list of items in the gallery only once and not reacting to any changes (moving, deleting)

* Removed query stop call in DisplayHostViewController

Since this query is not created there but just passed from the parent view.

* Removing more button if the currently viewed file got moved or deleted

* Fixed updating UI after renaming current item

* Fixed a warning

* Fixed issues in the gallery

* - Minor fixes

* [feature/bundle-import] Add support for certain bundle formats to the share sheet (#471)

* - Add support for import of bundle-based document formats through transparent zipping
	- moved previous FileProvider functionality into ownCloudApp.framework
	- new method OCCore.importItemNamed() ensures correct handling of bundle-based document formats
	- fixes finding (4) in #445
- Changed LSSupportsOpeningDocumentsInPlace to NO address two issues:
	- the app is now listed as "Copy to ownCloud" (previously "Open in ownCloud", which was technically not correct)
	- previously, documents using "Open to ownCloud" would no longer open in f.ex. Pages, but in the ownCloud app when selected in the Files app

* - Refactored ImportFilesController around using NSFileCoordinator, fixing finding (1) in #471

* changed path for moved Info.plist for target ownCloudAppFramework

* Version Bump to 133

* [feature/sort direction] Allow sorting asc/desc for all sort methods (#474)

* #470 added change sort direction asc/desc for all sort methods

* - removed comments
- changed translation keys

* fixes sort comparator for sort method "shared"

* use correct images for sort direction asc and desc

* updated choosing sort method from a tableView/Popover instead of a UIAlertViewController

* set maximum width for popover and set arrow direction

* Added show sort direction in UISegmentControl

* - make sure arrows of popovers appear in same color as the popover contents
- fix issue where direction was toggled during setup of SortBar (setting of initial value from user defaults), so logging in, logging out and logging in would change the sort direction
- reset sort direction to ascendant when switching sort methods
- SortMethodTableViewController
	- remove extraneous instance lets
	- enforce row height used for table view height calculation
	- change table view height calculation to account for the last divider (which could look a bit off if present)

* tap on segment control was fired twice, because there was a missing check, if selected segment changed

* fixed changing width on selecting an other segment

* fixed jumping width of sortSegmentControl items by setting the same width for all items by calculating the longest width before

* [fix/index-bar] Make Index Bar available in general file list (#469)

* #413 show index bar in general file list
- Index bar is only visible, if sorting is "Sort by name"
- Index bar is only visible, if more than one different letters are available
- Index bar is only visible, if more items are available as visible

* - adopt to new sort methods
- reverse index list, if sort direction is descendant

* Version Bump to 134

* Version Bump to 135

* Version Bump to 136

*  Change behaviour of default expiration date (#476)

* Enabling expiration date switch if default expiration date is configured

Checking files_sharing.public.expire_date.expire_date.days server capability. If it is set then it is used as default date and the switch is enabled even if the expiration date is not enforced.

* Fixed QA issue (1)

* Fixed QA finding (2): limiting the date range if expiration date is enforced

* Permission increasing UX in reshares (#467)

* Not showing permissions which can’t be elevated

Affecting items shared with the current users which are being reshared

* Fixed an issue with wrong permissions displayed when creating public link

- Checking if permissions can be elevated for the public link
- Only viable options are displayed

* Fixed a trailing whitespace warning

* Fixed another compiler warning

* Inhereting permissions from the share when creating public link

* Fixed QA finding (4)

* Fixed QA finding (1)

* Fixed QA finding (2)

* Version Bump to 137

* [feature/itempolicy] Item Policy / Available Offline support (#456)

* Available Offline Support
- new MakeAvailableOfflineAction and MakeUnavailableOfflineAction actions
- new Available Offline Library section
	- easy access to all files available offline via Available Offline
	- new ItemPolicyTableViewController and ItemPolicyCell prepared for reuse for presenting other item policies
- Design: added SVG/TVG/PNG icons and cloud symbols for make available offline / make unavailable offline

ClientItemCell changes
- new ClientItemResolvingCell can resolve item from LocalID or path, new superclass of ShareClientItemCell and ItemPolicyCell
- string to use as content for title and detail are now provided via titleLabelString(for:) and detailLabelString(for:), updated via updateLabels(with:), making customization easier
- support for new available offline badge

ProgressSummarizer changes
- changed ProgressSummary from a struct to a class, addressing issue #451 ("Waiting for server response..." message sometimes not disappearing)

* - Adopt OCClaim to ensure files aren't deleted while they are being used in
	- DisplayViewController
	- DownloadItemsHUDViewController
	- FileListTableViewController
	- File Provider
- Add new Storage Settings to allow control over how long unused local copies are kept around
- DisplayViewController now uses OCClaims to ensure files aren't deleted while they are being viewed
- ClientItemCell uses new SDK APIs to
	- show "available offline" badges for folders
	- to indicate if an item has been made available offline directly (solid icon) or indirectly (dimmed icon)
	- keep the cloud status icon updated following changes
- Change "+" icon to "•••" icon in file list, rename plusButton to folderAction everywhere
- Action.provideAlertAction() now applies padding to images if necessary so their text aligns at the same horizontal offset
- Fix typo in BookmarkInfoViewController and change wording from "Delete Offline Copies" to "Delete Local Copies" for consistency
- Update swiftlint.yml to silence ownCloudScreenshotsTests warnings

* - Update ios-sdk

* - Make changes requested in code review, adding missing localizable strings and removing extraneous code

* - Update SDK

* - Add downloadTriggerIdentifier and availableOfflinePolicyCoverage as properties that trigger the update of an item's visual representation (addressing finding 6 in #456)
- Update make available offline action to use new convertExistingLocalDownloads option (addressing finding 2 in #456)
- Update SDK (addressing finding 5 in #456)

* Items in moved Available Offline folders should no longer be cleared locally and re-downloaded, following under the hood improvements in the ios-sdk

* - Add initial support for cookies via SDK update

* - Temporarily disable some UI tests broken due to lack of database running

* - Fix issue (11) in #456 by updating the lastUsed date of already downloaded items when they are viewed

* - Added slider type to StaticTableViewRow
- changed storage settings to allow picking a timeframe via slider rather than a list of time frames

* - Change text from "Remove" to "Make unavailable offline" in Quick Access > Available Offline list (addressing issue (9))

* - Update BookmarkInfoViewController to provide users with the choice to also remove local copies of items marked as Available Offline, issuing a warning and giving the users a way to cancel, addressing issue (12) in #456.

* - Update ios-sdk
- Take advantage of the new key-value store and OCCoreSkipAvailableOfflineKey to make sure available offline files are not immediately downloaded again after clearing the vault from local copies of available offline files.
- Logging into an account removes any previously set OCCoreSkipAvailableOfflineKey from the key value store
- Move Bookmark locking to an OCBookmarkManager category (next stop: use the new key-value store and bake support for locking bookmarks directly into the SDK)

* - Add missing localization

* Update SDK with latest fixes

* - Fix SettingsTests bugs

* - Apply additional fixes to UI tests and disable the remaining failing ones

* - Wait for connection initialization to complete before requesting sharing info
- Use latest SDK with cookie filtering

* - Turn off Request/Response log tags only filter in project file

* - Disable cookie support

* - Address (13) via SDK update

* link against newest development SDK

* Fixes for UI testing:
- use new SDK version that returns errors if the SQLite DB has not been opened
- MockOCCore.state now returns .running to avoid queueing of PROPFINDs

* - Fix unit tests

* - UI testing: make MockOCCore.state no longer return .running due to side effects
- fixed conflicting constraints in two places

* - force-delete bookmarks in UI tests if timeout has passed, log error but don't assert in that case
- handle case where a swipe on table cells in DeleteBookmarkTests triggers deletion outright

* - Further hardening of SettingsTests against timing differences local vs. CI

* - make SettingsTest.testCheckMoreItems() more robust

* Version Bump to 138

* [feature/reorder buttons] Reorder Navigation Bar Actions (#478)

* Available Offline Support
- new MakeAvailableOfflineAction and MakeUnavailableOfflineAction actions
- new Available Offline Library section
	- easy access to all files available offline via Available Offline
	- new ItemPolicyTableViewController and ItemPolicyCell prepared for reuse for presenting other item policies
- Design: added SVG/TVG/PNG icons and cloud symbols for make available offline / make unavailable offline

ClientItemCell changes
- new ClientItemResolvingCell can resolve item from LocalID or path, new superclass of ShareClientItemCell and ItemPolicyCell
- string to use as content for title and detail are now provided via titleLabelString(for:) and detailLabelString(for:), updated via updateLabels(with:), making customization easier
- support for new available offline badge

ProgressSummarizer changes
- changed ProgressSummary from a struct to a class, addressing issue #451 ("Waiting for server response..." message sometimes not disappearing)

* - Adopt OCClaim to ensure files aren't deleted while they are being used in
	- DisplayViewController
	- DownloadItemsHUDViewController
	- FileListTableViewController
	- File Provider
- Add new Storage Settings to allow control over how long unused local copies are kept around
- DisplayViewController now uses OCClaims to ensure files aren't deleted while they are being viewed
- ClientItemCell uses new SDK APIs to
	- show "available offline" badges for folders
	- to indicate if an item has been made available offline directly (solid icon) or indirectly (dimmed icon)
	- keep the cloud status icon updated following changes
- Change "+" icon to "•••" icon in file list, rename plusButton to folderAction everywhere
- Action.provideAlertAction() now applies padding to images if necessary so their text aligns at the same horizontal offset
- Fix typo in BookmarkInfoViewController and change wording from "Delete Offline Copies" to "Delete Local Copies" for consistency
- Update swiftlint.yml to silence ownCloudScreenshotsTests warnings

* - Update ios-sdk

* - Make changes requested in code review, adding missing localizable strings and removing extraneous code

* #477 reorganize navigation bar with create and more button and moved select button to sort menu

* added safeAreaLayoutGuide.rightAnchor

* - Update SDK

* changed "Select" image

* - Add downloadTriggerIdentifier and availableOfflinePolicyCoverage as properties that trigger the update of an item's visual representation (addressing finding 6 in #456)
- Update make available offline action to use new convertExistingLocalDownloads option (addressing finding 2 in #456)
- Update SDK (addressing finding 5 in #456)

* Items in moved Available Offline folders should no longer be cleared locally and re-downloaded, following under the hood improvements in the ios-sdk

* - Temporarily disable some UI tests broken due to lack of database running

* - Fix issue (11) in #456 by updating the lastUsed date of already downloaded items when they are viewed

* - Added slider type to StaticTableViewRow
- changed storage settings to allow picking a timeframe via slider rather than a list of time frames

* - Change text from "Remove" to "Make unavailable offline" in Quick Access > Available Offline list (addressing issue (9))

* - Update BookmarkInfoViewController to provide users with the choice to also remove local copies of items marked as Available Offline, issuing a warning and giving the users a way to cancel, addressing issue (12) in #456.

* addresses:
- missing multiselection UI in toolbar
- missing select all / deselect all button in navigation bar

* set if selectButton should be shown

* disable temporary some tests due to bitrise failures

* using correct SDK

* Version Bump to 139

* Feature/task scheduling (#484)

* #386 Added relevant classes

* First draft of the scheduled task manager

* Just changed some comments

* Implemented background fetch

* Implemented background update fetch

* Clean up of the code

* Fixed merge problems from previous commit

And eliminated some warnings

* Small changes in background fetch operation

* Some refactoring done

* Added some user defaults for media upload

* Available Offline Support
- new MakeAvailableOfflineAction and MakeUnavailableOfflineAction actions
- new Available Offline Library section
	- easy access to all files available offline via Available Offline
	- new ItemPolicyTableViewController and ItemPolicyCell prepared for reuse for presenting other item policies
- Design: added SVG/TVG/PNG icons and cloud symbols for make available offline / make unavailable offline

ClientItemCell changes
- new ClientItemResolvingCell can resolve item from LocalID or path, new superclass of ShareClientItemCell and ItemPolicyCell
- string to use as content for title and detail are now provided via titleLabelString(for:) and detailLabelString(for:), updated via updateLabels(with:), making customization easier
- support for new available offline badge

ProgressSummarizer changes
- changed ProgressSummary from a struct to a class, addressing issue #451 ("Waiting for server response..." message sometimes not disappearing)

* UI for bookmark / upload path selection

* Added dummy implementation of media upload task

* - Adopt OCClaim to ensure files aren't deleted while they are being used in
	- DisplayViewController
	- DownloadItemsHUDViewController
	- FileListTableViewController
	- File Provider
- Add new Storage Settings to allow control over how long unused local copies are kept around
- DisplayViewController now uses OCClaims to ensure files aren't deleted while they are being viewed
- ClientItemCell uses new SDK APIs to
	- show "available offline" badges for folders
	- to indicate if an item has been made available offline directly (solid icon) or indirectly (dimmed icon)
	- keep the cloud status icon updated following changes
- Change "+" icon to "•••" icon in file list, rename plusButton to folderAction everywhere
- Action.provideAlertAction() now applies padding to images if necessary so their text aligns at the same horizontal offset
- Fix typo in BookmarkInfoViewController and change wording from "Delete Offline Copies" to "Delete Local Copies" for consistency
- Update swiftlint.yml to silence ownCloudScreenshotsTests warnings

* - Update ios-sdk

* - Make changes requested in code review, adding missing localizable strings and removing extraneous code

* - Update SDK

* Refactored current implementation of media upload

* Added method to fetch photos from photo library

* - Add downloadTriggerIdentifier and availableOfflinePolicyCoverage as properties that trigger the update of an item's visual representation (addressing finding 6 in #456)
- Update make available offline action to use new convertExistingLocalDownloads option (addressing finding 2 in #456)
- Update SDK (addressing finding 5 in #456)

* Items in moved Available Offline folders should no longer be cleared locally and re-downloaded, following under the hood improvements in the ios-sdk

* - Add initial support for cookies via SDK update

* First draft of instant photo upload implementation

* Calling task completion handler after upload was finished

* - Temporarily disable some UI tests broken due to lack of database running

* - Fix issue (11) in #456 by updating the lastUsed date of already downloaded items when they are viewed

* - Added slider type to StaticTableViewRow
- changed storage settings to allow picking a timeframe via slider rather than a list of time frames

* - Change text from "Remove" to "Make unavailable offline" in Quick Access > Available Offline list (addressing issue (9))

* - Update BookmarkInfoViewController to provide users with the choice to also remove local copies of items marked as Available Offline, issuing a warning and giving the users a way to cancel, addressing issue (12) in #456.

* Fixed QA finding (1)

* Using PHAsset.creationDate to check which media files shall be instantly uploaded

* Fixed naming of class / group

* Moved Tasks folder

* Fixed some review findings

* - Fix issue where a busy bookmark alert is followed by duplicating the bookmark

* Fixed some review findings

* Improved background update fetching

* Fixed some issues in media upload

* Fixed a type in settings key

* Improvements in the instant media upload task

* Added missing returnCore in the selection of the instant upload path

* Fixed QA finding (3)

* Fixes for the correct core returning / requesting

* Small cosmetic code changes

* Fixed video and serialized photo / video uploads

* Moved upload() method to UploadBaseAction class

* Some refactoring in InstantMediaUploadTaskExtension

* Improvements for bookmark / path selection for instant upload

* Remove instant upload configuration if bookmark is not available

* minor refactoring

* Added possibility to cancel account selection

* Small fix: reset the path if new account is selected

* Using item tracking instead of OCQuery

- Disabling instant photo upload if target directory is removed
- Item tracking is potentially faster since it can use cached item information and is not always issuing PROPFIND

* Made some ivars private

* Detect in settings that instant upload path is gone

In this case instant upload is disabled

* - Update ios-sdk
- Take advantage of the new key-value store and OCCoreSkipAvailableOfflineKey to make sure available offline files are not immediately downloaded again after clearing the vault from local copies of available offline files.
- Logging into an account removes any previously set OCCoreSkipAvailableOfflineKey from the key value store
- Move Bookmark locking to an OCBookmarkManager category (next stop: use the new key-value store and bake support for locking bookmarks directly into the SDK)

* - Add missing localization

* Update SDK with latest fixes

* - Fix SettingsTests bugs

* - Apply additional fixes to UI tests and disable the remaining failing ones

* - Wait for connection initialization to complete before requesting sharing info
- Use latest SDK with cookie filtering

* - Turn off Request/Response log tags only filter in project file

* - Disable cookie support

* - Address (13) via SDK update

* link against newest development SDK

* Showing warning that instant upload was disabled

* Fixes for UI testing:
- use new SDK version that returns errors if the SQLite DB has not been opened
- MockOCCore.state now returns .running to avoid queueing of PROPFINDs

* - Fix unit tests

* Added alert shown when in settings when instant upload is disabled

* Added fetchUpdates() within which target folder tracking is started

* - UI testing: make MockOCCore.state no longer return .running due to side effects
- fixed conflicting constraints in two places

* - force-delete bookmarks in UI tests if timeout has passed, log error but don't assert in that case
- handle case where a swipe on table cells in DeleteBookmarkTests triggers deletion outright

* - Further hardening of SettingsTests against timing differences local vs. CI

* - make SettingsTest.testCheckMoreItems() more robust

* Update to the latest changes in the SDK

Those changes reduce memory consumption used for hash calculation

* Change required to accomodate latest SDK changes

* Less parallel photo uploads

* - update SDK to address stuck sync action issues
- no longer auto-open the last selected bookmark when launched by iOS in the background. Instead, the last selected bookmark is now auto-openend only when the app comes to the foreground.
- update FileProviderInterfaceManager to better support the case where the app ships without File Provider.

* Fixed compilation warning

* - Add ATS exemption for File Provider

* - Update SDK

* - Update SDK + add colored debugging option to scheme

* Addressed code review comments

* Removed unneeded weak self

* Removed another unwanted weak self

* - Fix OCEvent-dropping issue via SDK update with fix
- Make UploadMediaAction use OCBackgroundTask to protect while exporting

* - Added missing OCBackgroundTask.start call in UploadMediaAction
- Update SDK

* Fixed missing copyright information and some warnings

* Version Bump to 140

* Media upload pending flag added

- Displaying a warning alert on the next launch, in case media upload couldn’t be completed due e.g. app being terminated in a backround or even due to an app crash.
- Fixed an issue with DispatchGroup.notify() called prematurely in MediaUploadQueue.uploadAssets()

* - sortbar was sometimes hidden
- fixing layout issue

* fixed location identifier for actions

* Added more logs in PHAsset+Upload extension

* removed unused string files for fastlane screenshot creation

* Fixes (1) and (2)

* disable beta warning

* Fixes issue (3) with downloads being cancelled by preview

* - Update SDK to address finding (4) in #461

* - Update SDK to solve remaining of finding (4)

* fixed strange text encoding (Transifex error)=

* - Update ios-sdk to include latest changes
- Fix SwiftLint warning in DisplayHostViewController.swift

* [tx] updated from transifex

* updated changelog for version 1.1.0

* - change presentation of "Make unavailable offline" action to filled icon + "Available offline" + checkmark
- optimize PNG images to save space
- fix lack of OAuth2 renewed token propagation (#501: token renewal from Files App) via ios-sdk update

* added missing localization string

* - Update ios-sdk to satisfy new requirements for using ASAuthorization in iOS 13

* - Fix finding (11) in #461 via SDK update

* Fixed issue (6)

* - Add debug output to verify theory on stuck uploads issue

* - Update SDK to add improved logging and allowing to enable use of OCCores after they were returned and stopped ("zombie core detection")

* - Update SDK
- Fix retain cycle in MediaUploadSettingsSection that could also lead to a zombie core

* using the newest development SDK:
- solving showing certificate error in document browser (file provider)
- solved importFile on main thread issue

* Version Bump to 141

* - new localization values from Transifex
- changed wrong/too long localization strings
- added missing localizations

* added new localization language Basque

* added localization files for fastlane screenshot generator

* updated to newest SDK after localization changes

* - added new var to get beta warning state
- disabled beta warning, beta build
- using the newest development SDK

* set new build number

* using master SDK version 1.1.0

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* Autoplay Media / Show album artwork in the media player view (#566)

* [fix/fp-offline-browsing] Allow offline browsing of folders in the File Provider (#547)

* - Fix Swift and SwiftLint warnings
- Remove unused UploadsSettingsSection (was replaced by MediaUploadSettings)

* - address libzip Xcode project upgrade warning
- add research note to FileProviderExtension
- update SDK

* - Allow offline browsing of folders in the File Provider

* Revert "[fix/fp-offline-browsing] Allow offline browsing of folders in the File Provider (#547)" (#553)

This reverts commit 9a0bc93215b786e715b0a89cc9aa793fd121407b.

* Autoplay media files implemented as described in issue #59

* Added album artwork as overlay in the player

* Fixed playing next media item in BG and lock screen

- Now multiple items can be played contignuously in the background
- Now playing info in the lock screen contains artwork, title, artist info and displays correct playback timeline
- Audio can be paused / resumed from the lock screen
- Added skip controls allowing to jump 10s backwards and forwards from the play-head position in the lock screen

* Small fixes

* [fix/open-in-on-ipad] Share sheet not visible on iPad (#570)

* [fix/fp-offline-browsing] Allow offline browsing of folders in the File Provider (#547)

* - Fix Swift and SwiftLint warnings
- Remove unused UploadsSettingsSection (was replaced by MediaUploadSettings)

* - address libzip Xcode project upgrade warning
- add research note to FileProviderExtension
- update SDK

* - Allow offline browsing of folders in the File Provider

* Revert "[fix/fp-offline-browsing] Allow offline browsing of folders in the File Provider (#547)" (#553)

This reverts commit 9a0bc93215b786e715b0a89cc9aa793fd121407b.

* Fix for issue #568: Share sheet was now visible on iPad, if tableview was scrolled down, after first visible page rect

* Changed app version to 1.2.0

* [tx] updated from transifex

* [fix/improve_photo_upload_responsiveness] More reliable photo upload (#548)

* #516 truncate middle of file name instead of tail (#517)

* new app version and build version

* Started implementing more secure photo upload

* Added a fix for background media playback

- Added audio session activation / deactivation code
- Also fixed potential issue for background video playback (PiP) as suggested by Apple in https://developer.apple.com/documentation/avfoundation/media_assets_playback_and_editing/creating_a_basic_video_player_ios_and_tvos/playing_audio_from_a_video_asset_in_the_background

* Fixed naming of uploaded edited photos

* Changes to the mechanism of storing pending PHAsset IDs

* Pending media upload task added

- When uploading photo / video assets, their local identifiers along with target path are stored in the KV-store of the bookmark
- When the app is killed, at next launch, task is spawned which checks if there are any pending assets not yet imported by the core
- Pending assets are uploaded

* Updated with latest sdk version

* Uploading multiple assets within OCCore.schedul(inCoreQueue:) block

* Fixed some issues with uploading pending assets

* Reworked media uploads

- Performing most of the operations synchronously and trying to not spawn to many worker threads
- Executing file imports withing OCCore.schedule() call to post-pone execution of sync operations and to reduce their amount

* Small fixes

* Refactored PendingMediaUploadTaskExtension class

* Removed unccessary scheduling of tasks in the next run loop iteration

- Removed OnMainThread{..} wrapping from scheduleTasks()
- Made sure scheduleTasks() is called after properties affecting current context are set

* Modal UI presented when media files are imported

* Fixed some review findings

* Addressed review findings

* Ignoring fastlane sub-folder

* Fixed some compiler warnings

* Fixed the issue with overwriting asset downloads

Now able to store multiple paths along with single asset in the key value store

* Added OCActivitiy publishing to MediaUploadQueue

* Refactored media upload related OCActivity into separate class

* First working implementation of refactored MediaUploadQueue

- Simplified the architecture
- Separate KV based storadge of upload jobs into MediaUploadStorage class which takes care of handling MediaUploadJob objects
- Improved inter-process concurrency handling

* Removing stored upload jobs upon activity cancellation

* MediaUploadQueue:
- switch to "needsScheduling" mechanism to ensure that assets that get added to the queue are processed as timely as possible. Previously, if assets were added while the queue is being processed, no new run that would include the newly added assets would be triggered.
- fix broken processing locking: creating an OCProcessSession via "OCProcessSession()" creates a session that is never valid, so the queue would get scheduled multiple times, which could lead to many duplicate uploads. Instead OCProcessManager.shared.processSession is now used, which returns a valid session of the current process.
- make control over MediaUploadStorage.processing atomic to avoid race conditions
- use copies of MediaUploadStorage.queue and MediaUploadStorage.jobs as starting point for scheduling, to avoid running into issues if MediaUploadStorage is cached by OCKeyValueStorage and a change to these is made during enumeration
- added additional error logging in case of upload errors
- make addUpload() trigger the newly introduced setNeedsScheduling() so that calls to scheduleUploads() become unnecessary when adding assets to the queue.

MediaUploadStorage:
- convert property-like methods into actual properties

Localizable.strings:
- fix two errors that led to the file becoming unparseable

ios-sdk:
- SDK update to avoid unneeded deserializations

* - Remove duplicate file

* Fixed problem with updating key-value store for every single media asset

- When key value store is updated separately for every media item, there is huge number of background tasks, worker threads etc. being spawned.
- Now adding assets to be uploaded within single [OCKeyValueStore updateObjectForKey:…] block

* [fix/fp-word] Fix Word FileProvider issue (#574)

* - Overhaul -importDocumentAtURL: to use file coordination and return placeholders only after they've been added to the database (via updated SDK)
- Fix app toolbar icons glitch when re-opening the client browser for an account after launch

* - Switch from develop to master branch for ios-sdk

* - Update SDK to fix finding (1)

* Fixed (4) and (5)

- Disabled skip X seconds commands for now
- Added play next / previous track commands
- Removing system-wide now playing info if corresponding media playback view controller gets released

* #550 fixed QA finding (1) for regression test 1.2.0, Import panel was not displayed on iOS 13

* Fixed a now playing issue with jumping time

* Fixed issue with images not being uploaded when MP4 conversion option was active

* new build number

* Temporarily removed conversion of videos to MP4

* disable beta warning

* fixed encoding hell UTF-8 / UTF-16

* - added arabic language files to project
- fixed wrong encoding

* - fixed wrong padding for label
- localized "Feedback" button

* Translation Sync (#525)

* [tx] updated from transifex

* Removed the es lang because was wrong and it is not necessary to map it (es -> es) (#310)

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* use newest SDK version

* changed file encoding for localization files

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* - using correct SDK
- solved encoding problems for localization files

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* change version number 1.0 -> 1.0.1

* Fixed QA finding (1). "Share item" menu item was not visible, if item was not shared

* Fix finding (3)

* Fixed an issue with go-to button not being shown in PDF viewer (#403)

* Fixed an issue with go-to button not being shown in PDF viewer

* Added accessibility labels to bar button items in the PDF viewer

* Version Bump to 121

* - Action class:
	- extend ActionWillRunHandler with a completionHandler and adding a new .perform() method to wrap .willRun() and .run(), allowing for actions to trigger view controller dismissals, wait for them to finish and then present their own view controllers
- Card upgrades, improvement and fixes
	- fix MoreViewController "shaking" on initial presentation
	- create new CardPresentationSizing protocol to allow view controllers to provide sizing information to CardPresentationController
	- allow disabling the handle and the ability to dismiss by tapping in the background
	- create CardViewController as base class for future view controllers that should be presented as cards
 - Add new DownloadItemsHUDViewController class (a CardViewController subclass) to modally download files, provide a summary, allow cancellation and simplified retrieval of the corresponding OCFile objects
- Clean up OpenInAction and rewrite most of it to use DownloadItemsHUDViewController
- KVOWaiter allows waiting for an object's value to change, check if the change meets the criteria and then run a block once. Ended up not being used and is therefore not included in the builds. But since it may be useful in the future, left the source code regardless.
- Add ProgressSummary.update(progressView:) convenience method

* [tx] updated from transifex

* - Switch to release/1.0.1 branch for ios-sdk

* - Add "Preparing" message to DownloadItemsHUDViewController while scheduling downloads
- Update ios-sdk, fixing findings (5) + (6)

* - Fix premature release of UIDocumentInteractionController in OpenInAction

* using correct release SDK

* [tx] updated from transifex

* - Add support for Progress.isCancelled to ProgressSummarizer

* Version Bump to 122

* - Addressing (5) via SDK update rescheduling/retrying dropped requests

* - Addressing (5) via SDK update rescheduling/retrying dropped requests

* - Make File Provider use new SDK option to return immediately from a thumbnail request when offline

* [tx] updated from transifex

* Version Bump to 123

* - Add new APP_SHORT_VERSION variable to build settings
- Make Info.plist for app, File Provider and File Provider UI use it

* - Fix remaining (5) issue for cases where the upload succeeded but the server response was cut off, prompting a retry and resulting in a "item already exists" error

* - Update ios-sdk

* [tx] updated from transifex

* [tx] updated from transifex

* changed wrong file encoding from UTF-16LE to UTF-8

* QA finding (14) removed ownCloud name from localizable stings

* removed ownCloud string in localizable strings

* fixed merge conclicts

* using newest release SDK

* changed file encoding from UTF-16LE to UTF-8

* changed file encoding from UTF-16LE to UTF-8

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* Naming improvements based on latest SDK:
- uploads use new OCCoreOptionAutomaticConflictResolutionNameStyle option to automatically resolve naming conflicts during upload
- Duplicate action uses the new OCCore name suggestion API to
	- determine naming conflicts and resolve them automatically
	- match the name style of the file to duplicate, f.ex.
		- duplicating "File copy.jpg" will create "File copy 2.jpg"
		- duplicating "File (1).jpg" will create "File (2).jpg"
		- duplicating "File Kopie 2.jpg" will create "File Kopie 3.jpg"
- folder creation uses the new OCCore name suggestion API to
	- detect naming conflicts beforehand
	- pre-fill the new folder name name with an unused name directly

* #393 added an activity indicator which will be shown, if offline copies will be deleted to give the user a UI feedback

* - Change SDK branch to master

* #76 user can import files using the iOS share sheet. all file types are accepted.

* - using new SDK with fixes for requesting core
- minor code fixes

* - Log device, version and locale information at the beginning of every log file using new SDK protocol
- Show SDK commit hash in Settings

* fixed crash, changed bookmark name to shortname

* changed UIAlertViewController for account selection to CardViewController style for testing

* fixed icon badge creation for fastlane lane In-House Enterprise IPA generation

* install librsvg for fastlane via sh

* moved import file code to own class

* added option to automatically resolve name conflicts, if file name already exists

* Changed app version to 1.1.0

* enabled beta build and warning

*  Keep the gallery alive after doing some action over an item (#447)

* Rename updates the currently visible file in the gallery

* Keeping gallery alive fix

- Don’t pop to the root view controller on destructive action by default
- Only pop to the root if all items have been deleted
- Select next item upon deletion of the current ones
- Update UIPageViewController data source if number of items changes due e.g. to duplication or deletion

* Small fixes

* Fixed review findings

* Media player implemented using AVKit (#429)

* Media player implemented using AVKit

* Added possibility to stream audio / video

* Improved error handling

* Fixed review finding

* Added background audio, airplay and PiP mode

* Propagating safe area to the main view of AVPlayerViewController

* Another fix for safe area considering layout of AVPlayerViewController

* Updated to latest develop version of SDK

* Display error message in case file couldn’t be preview e.g. due to file corruption (#427)

* [tx] updated from transifex

* Fixed UI test for creating folder, need to return a fixed name, because suggestion is not working in tests

* added a description header and changed typo

* - fixed showing the directory picker controller, after the card view was dismissed
- use the current development SDK

* Version Bump to 126

* - create local copy of import file, if needed
- fixed create folder action
- delete local copy, if needed
- code review changes

* - improved duplicate item deletion behaviour
	- add additional safeguard so duplicate files are only deleted if they were actually duplicated (previously non-duplicate files could be removed if duplication or folder creation failed)
	- remove temporary container folder, too
- add 2 second delay before returning the core to give the core an opportunity to schedule the upload on a NSURLSession

* Version Bump to 127

* changed back signing identity

* Version Bump to 128

* added required CFBundleTypeName key

* Version Bump to 129

* updated changelog

* use formSheet presentation style for the iPad when showing the document picker

* Fix for images not being displayed in the gallery

* Version Bump to 130

* [tx] updated from transifex

* Version Bump to 131

* [fix/sharing-search] Fixed min length for searching sharing users (#455)

* #454 used correct comparator for sharingSearchMinLength and set a new default value, if capability does not exists

* added a constant for defaultSharingSearchMinLength value

* [tx] updated from transifex

* - Update ios-sdk to address finding (1) in ios-app #446

* Preventing updating UI in DisplayViewController while item is being changed

- Not calling present(item:) while meta data of OCItem is being updated
- Elliminated an assumption in MediaDisplayViewController that render renderSpecificView() can be called only once.
- Making sure that AVPlayer is not re-created upon changes in OCItem but that rather AVPlayerItem is replaced.

* Fixed a small warning

* Tried to improve gallery logic concerning items modification

- Watch out if the modification does still includes the item with local ID of the currently visible item.
- Take care of failed move but watching out for reappearing items

* Added a setting allowing to decide user if media files shall be streamed

* - Add debug output to Display*ViewController
- Fix SwiftLint warnings

* Fixed handling of deleted / moved item in the gallery

* Another small fix for handling of failed item move

* Version Bump to 132

* Added LSSupportsOpeningDocumentsInPlace key to Info.plist

* Fixed Info.plist and added LSHandlerRank property

* Fix for #455 issue: no search request triggered

* show always the account selection sheet and added a note, that only one file can be imported at once

* use securtiy scoped file operation for importing a file

* Fix for the PR #447 (keep gallery alive) (#465)

* Keeping track of individual OCItems in DisplayViewController instances

But loading the list of items in the gallery only once and not reacting to any changes (moving, deleting)

* Removed query stop call in DisplayHostViewController

Since this query is not created there but just passed from the parent view.

* Removing more button if the currently viewed file got moved or deleted

* Fixed updating UI after renaming current item

* Fixed a warning

* Fixed issues in the gallery

* - Minor fixes

* [feature/bundle-import] Add support for certain bundle formats to the share sheet (#471)

* - Add support for import of bundle-based document formats through transparent zipping
	- moved previous FileProvider functionality into ownCloudApp.framework
	- new method OCCore.importItemNamed() ensures correct handling of bundle-based document formats
	- fixes finding (4) in #445
- Changed LSSupportsOpeningDocumentsInPlace to NO address two issues:
	- the app is now listed as "Copy to ownCloud" (previously "Open in ownCloud", which was technically not correct)
	- previously, documents using "Open to ownCloud" would no longer open in f.ex. Pages, but in the ownCloud app when selected in the Files app

* - Refactored ImportFilesController around using NSFileCoordinator, fixing finding (1) in #471

* changed path for moved Info.plist for target ownCloudAppFramework

* Version Bump to 133

* [feature/sort direction] Allow sorting asc/desc for all sort methods (#474)

* #470 added change sort direction asc/desc for all sort methods

* - removed comments
- changed translation keys

* fixes sort comparator for sort method "shared"

* use correct images for sort direction asc and desc

* updated choosing sort method from a tableView/Popover instead of a UIAlertViewController

* set maximum width for popover and set arrow direction

* Added show sort direction in UISegmentControl

* - make sure arrows of popovers appear in same color as the popover contents
- fix issue where direction was toggled during setup of SortBar (setting of initial value from user defaults), so logging in, logging out and logging in would change the sort direction
- reset sort direction to ascendant when switching sort methods
- SortMethodTableViewController
	- remove extraneous instance lets
	- enforce row height used for table view height calculation
	- change table view height calculation to account for the last divider (which could look a bit off if present)

* tap on segment control was fired twice, because there was a missing check, if selected segment changed

* fixed changing width on selecting an other segment

* fixed jumping width of sortSegmentControl items by setting the same width for all items by calculating the longest width before

* [fix/index-bar] Make Index Bar available in general file list (#469)

* #413 show index bar in general file list
- Index bar is only visible, if sorting is "Sort by name"
- Index bar is only visible, if more than one different letters are available
- Index bar is only visible, if more items are available as visible

* - adopt to new sort methods
- reverse index list, if sort direction is descendant

* Version Bump to 134

* Version Bump to 135

* Version Bump to 136

*  Change behaviour of default expiration date (#476)

* Enabling expiration date switch if default expiration date is configured

Checking files_sharing.public.expire_date.expire_date.days server capability. If it is set then it is used as default date and the switch is enabled even if the expiration date is not enforced.

* Fixed QA issue (1)

* Fixed QA finding (2): limiting the date range if expiration date is enforced

* Permission increasing UX in reshares (#467)

* Not showing permissions which can’t be elevated

Affecting items shared with the current users which are being reshared

* Fixed an issue with wrong permissions displayed when creating public link

- Checking if permissions can be elevated for the public link
- Only viable options are displayed

* Fixed a trailing whitespace warning

* Fixed another compiler warning

* Inhereting permissions from the share when creating public link

* Fixed QA finding (4)

* Fixed QA finding (1)

* Fixed QA finding (2)

* Version Bump to 137

* [feature/itempolicy] Item Policy / Available Offline support (#456)

* Available Offline Support
- new MakeAvailableOfflineAction and MakeUnavailableOfflineAction actions
- new Available Offline Library section
	- easy access to all files available offline via Available Offline
	- new ItemPolicyTableViewController and ItemPolicyCell prepared for reuse for presenting other item policies
- Design: added SVG/TVG/PNG icons and cloud symbols for make available offline / make unavailable offline

ClientItemCell changes
- new ClientItemResolvingCell can resolve item from LocalID or path, new superclass of ShareClientItemCell and ItemPolicyCell
- string to use as content for title and detail are now provided via titleLabelString(for:) and detailLabelString(for:), updated via updateLabels(with:), making customization easier
- support for new available offline badge

ProgressSummarizer changes
- changed ProgressSummary from a struct to a class, addressing issue #451 ("Waiting for server response..." message sometimes not disappearing)

* - Adopt OCClaim to ensure files aren't deleted while they are being used in
	- DisplayViewController
	- DownloadItemsHUDViewController
	- FileListTableViewController
	- File Provider
- Add new Storage Settings to allow control over how long unused local copies are kept around
- DisplayViewController now uses OCClaims to ensure files aren't deleted while they are being viewed
- ClientItemCell uses new SDK APIs to
	- show "available offline" badges for folders
	- to indicate if an item has been made available offline directly (solid icon) or indirectly (dimmed icon)
	- keep the cloud status icon updated following changes
- Change "+" icon to "•••" icon in file list, rename plusButton to folderAction everywhere
- Action.provideAlertAction() now applies padding to images if necessary so their text aligns at the same horizontal offset
- Fix typo in BookmarkInfoViewController and change wording from "Delete Offline Copies" to "Delete Local Copies" for consistency
- Update swiftlint.yml to silence ownCloudScreenshotsTests warnings

* - Update ios-sdk

* - Make changes requested in code review, adding missing localizable strings and removing extraneous code

* - Update SDK

* - Add downloadTriggerIdentifier and availableOfflinePolicyCoverage as properties that trigger the update of an item's visual representation (addressing finding 6 in #456)
- Update make available offline action to use new convertExistingLocalDownloads option (addressing finding 2 in #456)
- Update SDK (addressing finding 5 in #456)

* Items in moved Available Offline folders should no longer be cleared locally and re-downloaded, following under the hood improvements in the ios-sdk

* - Add initial support for cookies via SDK update

* - Temporarily disable some UI tests broken due to lack of database running

* - Fix issue (11) in #456 by updating the lastUsed date of already downloaded items when they are viewed

* - Added slider type to StaticTableViewRow
- changed storage settings to allow picking a timeframe via slider rather than a list of time frames

* - Change text from "Remove" to "Make unavailable offline" in Quick Access > Available Offline list (addressing issue (9))

* - Update BookmarkInfoViewController to provide users with the choice to also remove local copies of items marked as Available Offline, issuing a warning and giving the users a way to cancel, addressing issue (12) in #456.

* - Update ios-sdk
- Take advantage of the new key-value store and OCCoreSkipAvailableOfflineKey to make sure available offline files are not immediately downloaded again after clearing the vault from local copies of available offline files.
- Logging into an account removes any previously set OCCoreSkipAvailableOfflineKey from the key value store
- Move Bookmark locking to an OCBookmarkManager category (next stop: use the new key-value store and bake support for locking bookmarks directly into the SDK)

* - Add missing localization

* Update SDK with latest fixes

* - Fix SettingsTests bugs

* - Apply additional fixes to UI tests and disable the remaining failing ones

* - Wait for connection initialization to complete before requesting sharing info
- Use latest SDK with cookie filtering

* - Turn off Request/Response log tags only filter in project file

* - Disable cookie support

* - Address (13) via SDK update

* link against newest development SDK

* Fixes for UI testing:
- use new SDK version that returns errors if the SQLite DB has not been opened
- MockOCCore.state now returns .running to avoid queueing of PROPFINDs

* - Fix unit tests

* - UI testing: make MockOCCore.state no longer return .running due to side effects
- fixed conflicting constraints in two places

* - force-delete bookmarks in UI tests if timeout has passed, log error but don't assert in that case
- handle case where a swipe on table cells in DeleteBookmarkTests triggers deletion outright

* - Further hardening of SettingsTests against timing differences local vs. CI

* - make SettingsTest.testCheckMoreItems() more robust

* Version Bump to 138

* [feature/reorder buttons] Reorder Navigation Bar Actions (#478)

* Available Offline Support
- new MakeAvailableOfflineAction and MakeUnavailableOfflineAction actions
- new Available Offline Library section
	- easy access to all files available offline via Available Offline
	- new ItemPolicyTableViewController and ItemPolicyCell prepared for reuse for presenting other item policies
- Design: added SVG/TVG/PNG icons and cloud symbols for make available offline / make unavailable offline

ClientItemCell changes
- new ClientItemResolvingCell can resolve item from LocalID or path, new superclass of ShareClientItemCell and ItemPolicyCell
- string to use as content for title and detail are now provided via titleLabelString(for:) and detailLabelString(for:), updated via updateLabels(with:), making customization easier
- support for new available offline badge

ProgressSummarizer changes
- changed ProgressSummary from a struct to a class, addressing issue #451 ("Waiting for server response..." message sometimes not disappearing)

* - Adopt OCClaim to ensure files aren't deleted while they are being used in
	- DisplayViewController
	- DownloadItemsHUDViewController
	- FileListTableViewController
	- File Provider
- Add new Storage Settings to allow control over how long unused local copies are kept around
- DisplayViewController now uses OCClaims to ensure files aren't deleted while they are being viewed
- ClientItemCell uses new SDK APIs to
	- show "available offline" badges for folders
	- to indicate if an item has been made available offline directly (solid icon) or indirectly (dimmed icon)
	- keep the cloud status icon updated following changes
- Change "+" icon to "•••" icon in file list, rename plusButton to folderAction everywhere
- Action.provideAlertAction() now applies padding to images if necessary so their text aligns at the same horizontal offset
- Fix typo in BookmarkInfoViewController and change wording from "Delete Offline Copies" to "Delete Local Copies" for consistency
- Update swiftlint.yml to silence ownCloudScreenshotsTests warnings

* - Update ios-sdk

* - Make changes requested in code review, adding missing localizable strings and removing extraneous code

* #477 reorganize navigation bar with create and more button and moved select button to sort menu

* added safeAreaLayoutGuide.rightAnchor

* - Update SDK

* changed "Select" image

* - Add downloadTriggerIdentifier and availableOfflinePolicyCoverage as properties that trigger the update of an item's visual representation (addressing finding 6 in #456)
- Update make available offline action to use new convertExistingLocalDownloads option (addressing finding 2 in #456)
- Update SDK (addressing finding 5 in #456)

* Items in moved Available Offline folders should no longer be cleared locally and re-downloaded, following under the hood improvements in the ios-sdk

* - Temporarily disable some UI tests broken due to lack of database running

* - Fix issue (11) in #456 by updating the lastUsed date of already downloaded items when they are viewed

* - Added slider type to StaticTableViewRow
- changed storage settings to allow picking a timeframe via slider rather than a list of time frames

* - Change text from "Remove" to "Make unavailable offline" in Quick Access > Available Offline list (addressing issue (9))

* - Update BookmarkInfoViewController to provide users with the choice to also remove local copies of items marked as Available Offline, issuing a warning and giving the users a way to cancel, addressing issue (12) in #456.

* addresses:
- missing multiselection UI in toolbar
- missing select all / deselect all button in navigation bar

* set if selectButton should be shown

* disable temporary some tests due to bitrise failures

* using correct SDK

* Version Bump to 139

* Feature/task scheduling (#484)

* #386 Added relevant classes

* First draft …
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant