Here's the Notification Observer for the Pasteboard change event, I need it to handle the copied selected text
[[NSNotificationCenter defaultCenter] addObserver:self
selector:@selector(receiveClipBoardNotification:)
name:@"UIPasteboardChangedNotification"
object:nil];
And here's the implementation for the selector method receiveClipBoardNotification:
- (void) receiveClipBoardNotification:(NSNotification *) notification {
// NSMutableArray *typesAddedKey = [[notification userInfo] objectForKey:@"UIPasteboardChangedTypesAddedKey"];
// pasteBoardItemType = [typesAddedKey objectAtIndex:0];
NSLog(@"%@", [notification userInfo]);
}
The problem is that [notification userInfo] returns nil on iOS 6, although it works perfectly on iOS 5.