mirror of
https://github.com/zhigang1992/facebook-ios-sdk.git
synced 2026-04-30 18:32:53 +08:00
Summary: This is to prevent the following error that was seen in D33750740 (8044535803) ``` objc attribute used without importing module 'Foundation' ``` Found the files with: ``` git ls-files '*.swift' | xargs ack -l 'objc' | xargs ack -L 'import (Foundation|XCTest)' ``` Note: In D33783526 (4610b07bda) a custom SwiftLint rule was added to detect this but it only works if there aren't any other imports. Reviewed By: samodom Differential Revision: D33803396 fbshipit-source-id: 575d7798a77aac30384f8f44c1d45f97d60fe8f7
37 lines
1.0 KiB
Swift
37 lines
1.0 KiB
Swift
/*
|
|
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
* All rights reserved.
|
|
*
|
|
* This source code is licensed under the license found in the
|
|
* LICENSE file in the root directory of this source tree.
|
|
*/
|
|
|
|
import Foundation
|
|
import UIKit
|
|
|
|
@objcMembers
|
|
@objc(FBSDKGamingImageUploaderConfiguration)
|
|
public class GamingImageUploaderConfiguration: NSObject {
|
|
public private(set) var image: UIImage
|
|
public private(set) var caption: String?
|
|
public private(set) var shouldLaunchMediaDialog: Bool
|
|
|
|
/**
|
|
A model for Gaming image upload content to be shared.
|
|
|
|
@param image the image that will be shared.
|
|
@param caption and optional caption that will appear along side the image on Facebook.
|
|
@param shouldLaunchMediaDialog whether or not to open the media dialog on Facebook when the upload completes.
|
|
*/
|
|
|
|
public init(
|
|
image: UIImage,
|
|
caption: String?,
|
|
shouldLaunchMediaDialog: Bool
|
|
) {
|
|
self.image = image
|
|
self.caption = caption
|
|
self.shouldLaunchMediaDialog = shouldLaunchMediaDialog
|
|
}
|
|
}
|