diff options
Diffstat (limited to 'Example Apps/Example Swift/ButtonManager.swift')
-rw-r--r-- | Example Apps/Example Swift/ButtonManager.swift | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/Example Apps/Example Swift/ButtonManager.swift b/Example Apps/Example Swift/ButtonManager.swift index 2a7b7ccf7..e0953accc 100644 --- a/Example Apps/Example Swift/ButtonManager.swift +++ b/Example Apps/Example Swift/ButtonManager.swift @@ -70,8 +70,10 @@ private extension ButtonManager { let textSoftButtonState = SDLSoftButtonState(stateName: AlertSoftButtonTextState, text: AlertSoftButtonText, image: nil) return SDLSoftButtonObject(name: AlertSoftButton, states: [imageSoftButtonState, textSoftButtonState], initialStateName: imageSoftButtonState.name) { (buttonPress, buttonEvent) in guard buttonPress != nil else { return } - let alert = AlertManager.alertWithMessageAndCloseButton("You pressed the button!") - manager.send(alert) + manager.fileManager.upload(artwork: SDLArtwork(image: UIImage(named: CarBWIconImageName)!, persistent: false, as: .PNG), completionHandler: { (success, artworkName, bytesAvailable, err) in + let alert = AlertManager.alertWithMessageAndCloseButton("You pressed the button!", iconName: artworkName) + manager.send(alert) + }) } } |