Categories
tvOS

Custom tvOS player

I have been working on a custom player control for tvOS recently for one of our project. In this little article I would like to share what are the important interactions to replicate if you are implementing a custom player and not using the default AVPlayerView Controller Interactions with Gesture Recognizers 4 types of gesture […]

Categories
iOS Swift tvOS Xcode

WWCD 2021

WWDC 2021 is over. We got lot of new announcements for development. Here are some of my favourites sessions of the week. In App Purchase Meet StoreKit 2 Support customer and handle refunds Swift What’s new in Swift? What’s new in Foundation? Async Await Elevate your DocC documentation in Xcode Swift AttributedString Embrace Expected Failure […]

Categories
tvOS

Search screen on tvOS

Today we discover something interesting when working on the Search page on tvOS. Everyone knows the following search page. We have the keyboard on top, and a space for search results UISearchController In case you are running your apple tv with a different remote control than the SIRI remote (for example, a standard tv remote, […]

Categories
Programming

Carbon

In some previous posts I was using a tool to generate nice images with source code. I just want to recommend Carbon which is very convenient, easy to use and very customisable for that purpose. Go check it out. Thank you for reading until here…  👊 Have a good week end…  🍺

Categories
iOS Swift

Rounded Corners

Radius for all corners I have used the possibility to make rounded corners on iOS. It’s quite straight forward using the CALayer of a view. Doing the following will round all 4 corners of the view. Adding radius for some corners Is it possible to add a rounded corner to only 2 of the corners? […]

Categories
Programming Swift

Do-while-false?

Have you already use Do-While-False in some project ? This is of course not much applicable in Swift as we have guard let, but in C++, Java or ObjectiveC, this could be very useful in some cases. Let me past an example I found in old project. The purpose of the function here doesn’t really […]

Categories
Swift

Using OptionSet

Let’s take an example. You are working as a team, with 4 members (Alex, John, Michael, Henry). The team is working on 4 iOS projects (Calculator, Tetris, Streaming App, Social Network) Now we want to mark which team member is working on which project. A simple way would be to use enum for this. One […]

Categories
iOS Xcode

Swift Package Manager.4

This is going to be the last post of the Swift Package Manager Series. After we create a package, then make it automated, and include it in our project, we would like to make a second package. And we would like the package A to depend on packageB. What we want Package A Package B, […]

Categories
Swift Xcode

Swift Package Manager.3

Now that we know how to create a package hosted in a git repo and use in a client project, we would like to try to set up some automated build + running our unit tests. This would prevent any wrong commits, and we could be notified automatically by the system. For the example, I […]

Categories
Swift Xcode

Swift Package Manager.2

In the first post, we saw how to create a package, here we’ll see how to use our newly created package without our project. Add code to your package First, open your xcode project, and create some code. Get rid of the automatically generated code : FluentCoding_MediaControl.swift Create a new swift file: MediaControlManager.swift ⚠️ Please […]