GitHub - Devecstatic/SSMP: Second Screen Mode Protocol allows for any iOS device...
source link: https://github.com/Devecstatic/SSMP
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
README.md
SSMP
Second Screen Mode Protocol for iOS
This is a Pre-release
What is SSMP?
SSM or Second Screen Mode Protocol is an open source framework for iOS writen in Swift that makes it easy for apps to take advantage of a second display (through a cable or AirPlay).
What does it do?
When your device is connected to a display, the device becomes a mouse and keyboard. The display has the main view. It adds a mouse pointer which does all the normal touch inputs.
Usage
Setup
In your AppDelegate, set the view controller the second display should have:
SSMPApp.default.secondaryViewController = MyAppMainViewController()
For extension type, custom. This is the main display on the device:
SSMPApp.default.primaryViewController = MyOtherViewController()
Options
For SSMPApp:
verboseLogging: Bool
allowedClickTypes: [clickType] clickType = .tap, .hardpress
extensionType: screenType screenType = .default, .custom
To Start
SSMPApp.default.start()
Recommend
About Joyk
Aggregate valuable and interesting links.
Joyk means Joy of geeK