Skip to content

Swift 5 and Swift Package Manager#698

Open
joshbillions wants to merge 11 commits into
C4Labs:masterfrom
joshbillions:master
Open

Swift 5 and Swift Package Manager#698
joshbillions wants to merge 11 commits into
C4Labs:masterfrom
joshbillions:master

Conversation

@joshbillions
Copy link
Copy Markdown

Support for Swift 5 and Swift Package Manager

Copy link
Copy Markdown
Member

@alejandro-isaza alejandro-isaza left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

Comment thread C4/Core/Color.swift Outdated
/// Initializes a UIColor object from a Color object.
/// - parameter color: The C4 color object.
public convenience init?(_ color: Color) {
convenience init?(_ color: Color) {
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please use spaces for indentation.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oops. Moved 'em back to spaces.

Comment thread C4/UI/AudioPlayer.swift Outdated
public init?(_ name: String) {
do {
try AVAudioSession.sharedInstance().setCategory(AVAudioSessionCategoryPlayback)
try AVAudioSession.sharedInstance().setCategory(.playback)
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All these indentation changes need to be reverted.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oops. Moved 'em back to spaces.

@alejandro-isaza
Copy link
Copy Markdown
Member

I still see a lot to tabs and other spacing changes...

@joshbillions
Copy link
Copy Markdown
Author

Ok. I think I've got everything now.

Comment thread C4/UI/AudioPlayer.swift Outdated
public init?(_ name: String) {
do {
try AVAudioSession.sharedInstance().setCategory(AVAudioSessionCategoryPlayback)
try AVAudioSession.sharedInstance().setCategory(AVAudioSession.Category(rawValue: convertFromAVAudioSessionCategory(AVAudioSession.Category.playback)))
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This can all be just .playback

Comment thread C4/UI/AudioPlayer.swift Outdated
// Helper function inserted by Swift 4.2 migrator.
private func convertFromAVAudioSessionCategory(_ input: AVAudioSession.Category) -> String {
return input.rawValue
}
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is not necessary.

@yoching
Copy link
Copy Markdown

yoching commented Jul 21, 2022

Hello. Any updates with this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants