Orientation o = Orientation.fromInterfaceOrientation(orientationCode.intValue());
// TODO freynaud rethink that.
if (screenshot) {
TakeScreenshotService service = getNativeDriver().getScreenshotService();
if (service instanceof InstrumentsAppleScreenshotService) {
File source = ((InstrumentsAppleScreenshotService) service).getScreenshotFile();
JSONWireImage image = new InstrumentsGeneratedImage(source, o);
try {