简体   繁体   中英

how do I create a horizontal scrolling Photo collection in Cocoa OSX?

If you look into the Compose View of the current Version of the Facebook iOS app, you will see that it has a horizontal scrolling View that shows attached Photos. In it you can not only scroll but also change the order of the photos via drag and drop. Can someone explain to me how I can create something similar in Cocoa OSX? Just the basics, which View could be the starting point for something like this? 在此处输入图片说明

Previously, I would've started with an NSTableView rotated 90 degrees. Nowadays, NSCollectionView should be your starting point. You can get horizontal scrolling, NSCollectionViewCells in which to draw your photos, and editing behavior for re-ordering.

您可能要使用NSCollectionView。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM