Trying to do screen capture with private framework IOSurface no longer seems to work in iOS 9 - screenshot

I'm working on an existing (non app-store) app for a client that uses the IOSurface private framework to do screen captures while in the background. There are a few threads here on SO that outline the technique, as well as several open source example projects.
Again, this is an internal application used by the client. It isn't intended for app-store release, so the fact that it uses private frameworks is acceptable.
Here is an example project on Github that uses a very similar technique:
https://github.com/k06a/UIView-FastScreenshot
I just tried to run the client's app on the latest iOS 9 beta, and it crashes with the error that it is unable to load the library CoreSurface.
I've seen documentation that CoreSurface is the previous name of the framework that became IOSurface, but it also seems that in iOS 8 there is indeed a private framework called CoreSurface as well as a private framework called IOSurface.
Has anybody else been able to use IOSurface to do screen captures from the background in iOS 9?
I'm adding a bounty for anybody who can give me a way to make this work for iOS 9 (again, private frameworks are fine, but it can't be on a Jailbroken device)

Related

App crashes on iOS (Phonegap) if multiple images are captured from camera

I am developing Phonegap Application and my application has scenarios where camera is used very frequently.
In my application I have used custom camera plugin (https://www.npmjs.com/package/cordova-camera-custom) to take picture and use it in my application.
Now when I capture images from this camera 30 times by opening camera and capturing again and again the app goes to crash.
The app just crashes so I am not able to identify the root cause of the crash.
I am not an iOS Programmer though I have tried to check the plugin code but I was not able to find the cause.
You can even check the plugin code on your end if needed.
I have also posted this issue to DevExtreme, the framework which I am using to develop hybrid applications at following link:
https://www.devexpress.com/support/center/Question/Details/T480068
and they found that issue indeed is related to memory shortage. The error message was with bug_type: 298 and fault cause: vm_pageshortage.
Please help me on this, I am struggling on it since long before.
Any Help is greatly appreciated.

Different UI for Android/iOS in interpreted JS cross-platform tools

Some cross-platform tools (like Xamarin native and RubyMotion) allow the development of two separate views for Android and iOS, while keeping the business logic shared for both of them. Others (like Apache Cordova or Xamarin.Forms) share both UI and business layer, with the option to use platform-specific overrides when necessary.
What is the state of the interpreted JavaScript frameworks (NativeScript, React Native or Appcelerator)? Are they all focused on creating single UI with platform overrides, or do they allow creating two separate views for each platform? For example, is it possible to create a view using Fragments in Android, but a different view on iOS (since Fragments do not exist there)?
Cordova uses WebView, that mean GUI level will be the same for both Android and iOS but different per Device version. In case of Android each client has own Chronium version and it can break UI behaviour. So developers use Crosswalk to set fixed Chronium version. (extra 20M to your application).
BTW Ionic that uses Cordova architecture uses native behaviour per platform. For example for Android Tabs located at the top, on iOS - at the bottom
On other hand Xamarin (C#), React-Native(JS) and NativeScript(JS) call native APIs. They don't use WebView but generate Native code.
For example if you create button - it will look different: on Android - material theme, on iOS - iPhone theme
Anyways, the bottom line is: everything depends on resources and time. If you want to build application fast, with the same view - I would go on Ionic2+ Angular2 + Cordova.
If you you have more time - go on React-Native or NativeScript (Still has poor documentation) or Xamarin (C#).
React-native's slogan is Learn once, write everywhere. So, you can choose what suits your needs, you can:
Share UI between platforms.
Share Only business logic.
So, the answer for react-native is yes. You can create separate UIs or you can share it.
Since you are writing components, one way of separating this logic is to write component.android.js and component.ios.js and the platform loads the appropriate one for you. Note that you can also do that programmatically.
You can see that in action in the official f8 app made by facebook using react-native

How to know about app launched and details jailbreak iOS 7

I am making a tweak for iOS 7, in which I want to know about app launch event, and the details of app being launched (name and identifier). So far the only useful framework I have found is SpringBoardServices.framework. The header files which may be/are useful to track app launch event include:
SBAppLaunchUtilities.h
SBLaunchAppListener.h
If I am on right track, can anyone provide me information about their methods usage? There is no relevant information or guide present on iphonedevwiki.
Moreover, How can I get information about app launched? I have studied Andy ibanez's tutorial. It hooks SBApplicationIcon class, which I guess has been removed from iOS 7 frameworks because I can't find it in dumped frameworks. So what is alternate header? Is it SBSCardItem.h and SBSCardItemsController ?
Looking forward for help. Thanks.
You need to look into SpringBoard.app instead of SpringBoardServices.framework. SpringBoard app comes "alone" because like it's extension implies, it's an app, and not a framework that can be found in the entire Private Frameworks.
You can get a lot of info from the SBApplicationIcon class in SpringBoard, such as the app display name and things like that. Check the headers for more info.

Blur classes in UIKit missing

Anybody tried blur effects in iOS 7 presented at the WWDC 2013 - session 226: Implementing Engaging UI on iOS?
I tried to use the code snippets mentioned at time 15:00:
UIGraphicsBeginImageContextWithOptions(image.size, NULL, 0);
[view drawViewHierarchyInRect:rect];
.
.
.
etc...BUT the code won't run, because it calls methods and classes that are not even in the API.
Plus I downloaded the sample project - Running with a Snap. That project doesn't even compile because the classes imported are simply not in the there. Example project...seriously...
Anybody knows if there is ANY way how to do the blurs in iOS 7 without using 3rd party frameworks?
They haven't implemented the api for it yet. A neat temporary solution has been found in the mean time that involves stealing the background layer of UIToolbar.
You can find the solution here bundled up in a nice class

Including iOS 6 properties in an object for an iOS 4.3 backwards-compatible app?

I'm adding some iOS 6 features to an existing app -- specifically, the built-in facebook integration. However, I need my app to retain backwards compatibility with iOS 4.3.
In most code, I understand how to handle this using respondsToSelector; I also understand to weakly link the Social and Accounts frameworks so they're only loaded if available.
What I don't know, though, is this: In order to enable the Facebook integration, I need to add a property to my "ShareViewController" -- which handles all the sharing for my app -- to hold the composition sheet, i.e.:
SLComposeViewController *mySLComposerSheet;
However, SLComposeViewController is a class that exists only in iOS6. So essentially, I need that property only to exist if the user is running iOS 6.
How does one handle this sort of situation?
It will just work. There's some metadata in the property/ivar that references the class name, but it doesn't actually link against the class or cause an error at runtime.
Of course, always test!
I suggest you use NSClassFromString and [UIDevice isSystemVersionHigherOrEqualTo:#"6.0"].