Migration

Roland Moers edited this page Sep 17, 2017 · 12 revisions
Clone this wiki locally

This page will describe how to migrate from your current version of RMActionController to the latest version of RMActionController.

Version 1.3.1

This update disabled the blur effects for the background by default. If you want this blur effect to be enabled you need to set disableBlurEffectsForBackground to false.

Version 1.3.0

No migration required

Version 1.2.1

No migration required

Version 1.2.0

No migration required

Version 1.1.0

The definition of RMAction changed a little bit. Previously it looked like follows:

@interface RMAction<T : RMActionController<UIView *> *> : NSObject

To make RMActionController compatible with Swift 3 it changed to this definition:

@interface RMAction<T : UIView *> : NSObject

As you can see, RMActionController has been dropped from the generic type. Now let's assume you have a subclass of RMActionController called MapActionController defined as follows:

@interface RMMapActionController : RMActionController<MKMapView *>
@end

Then your code to initialize a RMAction instance for your MapActionController should look like one of the following two examples:

RMAction *selectAction = [RMAction<RMActionController<MKMapView *> *> actionWithTitle:@"Select" style:RMActionStyleDone andHandler:^(RMActionController<MKMapView *> *controller) {
    NSLog(@"Action controller selected location: %f, %f", controller.contentView.centerCoordinate.latitude, controller.contentView.centerCoordinate.longitude);
}];

or

RMAction *selectAction = [RMAction<MapActionController *> actionWithTitle:@"Select" style:RMActionStyleDone andHandler:^(MapActionController *controller) {
    NSLog(@"Action controller selected location: %f, %f", controller.contentView.centerCoordinate.latitude, controller.contentView.centerCoordinate.longitude);
}];

As RMActionController version 1.1 dropped RMActionController from the generic of RMAction, you need to drop that reference, too. So your new code should look like follows:

RMAction *selectAction = [RMAction<MKMapView *> actionWithTitle:@"Select" style:RMActionStyleDone andHandler:^(RMActionController<MKMapView *> *controller) {
    NSLog(@"Action controller selected location: %f, %f", controller.contentView.centerCoordinate.latitude, controller.contentView.centerCoordinate.longitude);
}];

Version 1.0.5

No migration required

Version 1.0.4

No migration required

Version 1.0.3

No migration required

Version 1.0.2

No migration required

Version 1.0.1

No migration required