changes
This commit is contained in:
parent
85f37ddfe0
commit
bc9c28aa3f
@ -321,12 +321,6 @@ NSString * const KeyActionTypeOpen = @"openPage";
|
|||||||
[delegateObject.actionDelegate willShowPopupWithAlertObject:alertObject alertJson:actionInformation];
|
[delegateObject.actionDelegate willShowPopupWithAlertObject:alertObject alertJson:actionInformation];
|
||||||
}
|
}
|
||||||
|
|
||||||
NSDictionary *alertDictionary = [actionInformation dict:@"alert"];
|
|
||||||
NSNumber *style = [alertDictionary optionalNumberForKey:@"style"];
|
|
||||||
if ([style isEqual:@0]) {
|
|
||||||
alertObject.alertStyle = UIAlertControllerStyleActionSheet;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (alertObject) {
|
if (alertObject) {
|
||||||
[[MVMCoreAlertHandler sharedAlertHandler] showAlertWithAlertObject:alertObject];
|
[[MVMCoreAlertHandler sharedAlertHandler] showAlertWithAlertObject:alertObject];
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@ -30,10 +30,15 @@ public extension MVMCoreAlertObject {
|
|||||||
}
|
}
|
||||||
actionsForAlert.append(alertAction)
|
actionsForAlert.append(alertAction)
|
||||||
}
|
}
|
||||||
|
|
||||||
return MVMCoreAlertObject(popupAlertWithTitle: alertJson.optionalStringForKey(KeyTitle),
|
let alertObject = MVMCoreAlertObject(popupAlertWithTitle: alertJson.optionalStringForKey(KeyTitle),
|
||||||
message: alertJson.optionalStringForKey(KeyMessage),
|
message: alertJson.optionalStringForKey(KeyMessage),
|
||||||
actions: actionsForAlert,
|
actions: actionsForAlert,
|
||||||
isGreedy: false)
|
isGreedy: false)
|
||||||
|
|
||||||
|
let alertStyle = alertJson.int32ForKey("style")
|
||||||
|
alertObject?.alertStyle = alertStyle == 0 ? .actionSheet : .alert
|
||||||
|
|
||||||
|
return alertObject
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user