Hi,
Can i build a template for the privacy of.complications like I am doing for the timeline entry or does it just show the placeholder image?
This is what im doing for the watch compllcation
switch complication.family {
case .circularSmall:
let circularSmallTemplate = CLKComplicationTemplateCircularSmallRingImage()
let image = UIImage(named: "complicationImage")
circularSmallTemplate.imageProvider = CLKImageProvider(onePieceImage: image!)
circularSmallTemplate.ringStyle = .closed
circularSmallTemplate.fillFraction = 0.0
let entry = CLKComplicationTimelineEntry(date: Date(), complicationTemplate: circularSmallTemplate)
handler(entry)
...and for the placeholder template very similar
// MARK: - Placeholder Templates
func getLocalizableSampleTemplate(for complication: CLKComplication, withHandler handler: @escaping (CLKComplicationTemplate?) -> Void) {
// This method will be called once per supported complication, and the results will be cached
switch complication.family {
case .circularSmall:
let circularSmallTemplate = CLKComplicationTemplateCircularSmallRingImage()
let image = UIImage(named: "complicationImage")
circularSmallTemplate.imageProvider = CLKImageProvider(onePieceImage: image!)
circularSmallTemplate.ringStyle = .closed
circularSmallTemplate.fillFraction = 0.66
handler(circularSmallTemplate)
...but for the privacy I have se it to
func getPrivacyBehavior(for complication: CLKComplication, withHandler handler: @escaping (CLKComplicationPrivacyBehavior) -> Void) {
handler(.hideOnLockScreen)
}But it just shows the complication image i put into the assest folder. I would like it to look more like the actual complication, not just the placeholder image. For example the Activity app on the corner bezzel tamplate has a complication with rinngs that is not filled, and the word ACTIVITY curverd around. Mine just has an image and "-- --".
Thank you in advance.