Maybe not ideal but fairly simple so worth considering: Add Up/Down buttons to your section headers. Down on the first, Up on the last and Up and Down on all the others. The respond to the button presses by programmatically re-ordering the table. Up moves the section up one and Down moves the section down one. Martin
Answer by Martin Lockett for Reordering UITableView sections on the iPhone by dragging (like reordering rows)
Comment by Martin Lockett on What happened after NKIssue download terminated due to network unavailability?
Answer by Martin Lockett for What happened after NKIssue download terminated due to network unavailability?
I have two theories if you want to investigate further and have no better ideas:
I am surprised NSURLConnection calls didFailWithError. I would have expected the downloading asset to stay in downloadingAssets and be automatically retried later. My theory on this is: The didFailWithError method is optional and Newsstand Kit behaves differently depending on whether you implement this method or not. NSURLConnection may check that the delegate responds to the method to make this decision. If you implement the method and there is a network error, the error is reported using the didFailWithError method. After that method has finished executing, the downloading asset will be removed from the library. If you don't implement the method the download will not fail and any errors will be handled by the Newsstand Kit: the downloading asset will remain in the queue and will be retried indefinitely (as far as your software is concerned the download will never fail).
If a download fails (or completes) you are informed by the didFailWithError (or the connectionDidFinishDownloading) delegate callback method. The downloading asset will probably not be removed from downloadingAssets until after that method has finished. If you present an alert during the method, the asset will not be there when the user presses the Download button again.
Comment by Martin Lockett on NKAssetDownload destinationURL does not exist as file or directory
Answer by Martin Lockett for Apple Newsstand Download Complete Notification
If you start downloading while the app is running and then terminate the app you won't get any asset download delegate methods called (there is a launch option UIApplicationLaunchOptionsNewsstandDownloadsKey which I expected in this case but I've never seen this happen). The best solution is when the user starts the app, resume downloading each of the assets in [[NKLibrary sharedLibrary] downloadingAssets] and you should get a connectionDidFinishDownloading for each that has already downloaded. Be sure to do this in the didFinishLaunchingWithOptions method on the main thread or the assets will be deleted.
Also see Detecting background app launch in Xcode to debug a Newsstand app and Newsstand resume download after the App closed by user Fully
Comment by Martin Lockett on IB plug in for CALayer subclass
Comment by Martin Lockett on Detecting background app launch in Xcode to debug a Newsstand app
Comment by Martin Lockett on Detecting background app launch in Xcode to debug a Newsstand app
Detecting background app launch in Xcode to debug a Newsstand app
I'm trying to breakpoint didFinishLaunchingWithOptions in my app delegate to capture the app being launched (in the background) when a newsstand issue download completes after the app was terminated. I believe it could happen for example if a user manually requests a download and then terminates the app.
On the info tab of the run scheme in the Xcode scheme editor there is an option to wait for the app to launch. The comment below it says that it is to be used when you want to launch your app manually. Although that isn't what I want, I have tried it anyway and not surprisingly it doesn't seem to do what I want. Does anyone else have a way of doing this?
Answer by Martin Lockett for Different Property List format on IOS
Use a text editor, change the first <dict> to <array>, change the last </dict> to </array>, delete all lines beginning <key>Item





