SSMP 0.3.1

SSMP 0.3.1

Maintained by Kinpil.



SSMP 0.3.1

  • By
  • Ethan Lipnik

SSMP

Second Screen Mode Protocol for iOS

This is a Pre-release

Swift PodVersion Carthage Compatible Platform: iOS

Example project

iCode beta is coming soon! For more info click here

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.

Installation

Cocoapods

Add this to your Podfile

pod 'SSMP'

Carthage

Add this to your Cartfile

github "Devecstatic/SSMP"

Framework

Download the most recent from the releases.

Usage

Setup

In your AppDelegate, set the view controller the second display should have:

SSMPApp.default.viewController = MyAppMainViewController()

If you want to set whats on the device's display (You will lose the mouse pointer):

SSMPApp.default.deviceViewController = MyOtherViewController()

Replace all gesture recognizers with SSMP{type}GestureRecognizer. For example, UITapGestureRecognizer changes to SSMPTapGestureRecognizer

Options

For SSMPApp:

verboseLogging: Bool
allowedClickTypes: [clickType]
clickType = .tap, .hardpress
primaryBackgroundColor: UIColor

To Start

SSMPApp.default.start()