IQMediaPickerController icon indicating copy to clipboard operation
IQMediaPickerController copied to clipboard

Photo Library

Open Kayoto1 opened this issue 11 years ago • 1 comments

At photo library the default view show me the older images at the top and not the new one on the bottom, How can i set the scroll to be at the bottom view so i can see my new photos as default?

Thank you

Kayoto1 avatar Nov 25 '15 22:11 Kayoto1

Maybe too late, but can be helpful for someone else: The easiest way - find IQAssetsPickerController lines in collectionViewCellFor...(188 probably)

    [self.assetsGroup enumerateAssetsAtIndexes:[NSIndexSet indexSetWithIndex:indexPath.row] options:NSEnumerationConcurrent usingBlock:^(ALAsset *result, NSUInteger index, BOOL *stop)
     {

As y see here we taking indexPath.row. To redirect just start taking items from end:

NSInteger index = self.assetsGroup.numberOfAssets - 1 - indexPath.row;
  [self.assetsGroup enumerateAssetsAtIndexes:[NSIndexSet indexSetWithIndex: index] options:NSEnumerationConcurrent usingBlock:^(ALAsset *result, NSUInteger index, BOOL *stop)
   {

Y can find edited file here: https://github.com/LemonRuss/IQMediaPickerController/blob/master/MediaPickerController/IQMediaPickerController/IQAssetsPickerController/IQAlbumAssetsViewController.m

LemonRuss avatar May 02 '16 11:05 LemonRuss