68 questions
7
votes
0
answers
171
views
WKInterfaceController title alignment change on watchOS 10
I use setTitle() to display a custom text on the top left corner (aligned to the clock) of a controller. But after upgrading to watchOS 10, the title is displayed on the right, under the clock, ...
5
votes
1
answer
366
views
watchOS 10 Beta - WKInterfaceController title alignment
In our existing watchOS application developed in Objective-C (not SwiftUI), we used to set the title property (WKInterfaceController class) of each screen of the application (in Interface Builder or ...
1
vote
1
answer
128
views
WatchOS set title action
When only a single interface is shown, is it possible to set an action when the top title is tapped?
image
0
votes
1
answer
121
views
[WKInterfaceController pushControllerWithName:context:]: called from queue other than main. This is not supported and may fail in the future(iOS)
Error - [WKInterfaceController pushControllerWithName:context:]: called from queue other than main. This is not supported and may fail in the future.
In my iOS with apple watch, this error is coming ...
0
votes
1
answer
178
views
WKInterfaceController, how to programmatically set "Spacing" & "Insets"
I looked at Apples' docs for their WKInterfaceController:
Insets: The amount of space (in points) to insert between the edges of the interface controller and its content. Selecting Custom lets you ...
0
votes
1
answer
47
views
Move from one interface controller to another on
I am trying to have a countdown timer in a interface controller and when the time is 0 I would like it to perform a segue to the next interface controller.
Is there any way to do this?
if ...
0
votes
2
answers
177
views
Black screen page on apple watch apps with more that one page
Hi I have created a Watch app which has two pages but when I run it on apple watch and do switch between pages after few seconds one page(sometimes page1 and sometimes page2)goes black and It doesn’t ...
3
votes
0
answers
354
views
Breakpoint at UITableViewAlertForLayoutOutsideViewHierarchy when an alert should be shown on WKInterfaceController
My watch app uses a WKInterfaceController to display a WKInterfaceTable. In case of errors, it displays an alert using presentAlert called in the presented WKInterfaceController.
I have set a symbolic ...
0
votes
1
answer
272
views
How to fix missing interface controller inside Page Controller in Apple Watch?
What I found is ?
Try to scroll horizontally between the interface controllers inside a root page controller.
Randomly after a while (30-1 min).
You will find that one of the interface controllers ...
1
vote
0
answers
106
views
How to get Apple Watch display radius?
Is there some way to get the display radius? I tried to use contentSafeAreaInsets but they are 0 inside willActivate() and awake(withContext:) which is very frustrating.
0
votes
1
answer
707
views
How to display an alert in page based interface on WatchOS?
My watch app has a page based interface where I don’t really know what InterfaceController is currently on the screen (it could be 1 of 4), however I need to pop an alert no matter what screen the app ...
0
votes
1
answer
119
views
WATCH OS: How to seek WKInterfaceInlineMovie
Successfully played a video using 'WKInterfaceInlineMovie'. However, I need an option to start the video from the middle. Is this possible? Also, there is no delegate method to know when the video ...
3
votes
0
answers
147
views
How to inject viewModel class into WKInterfaceController?
I'm trying to inject my viewModel class to WKInterfaceController, in my InterfaceController I have set property but when I try to use it in func awake(withContext context: Any?), it's nil.
So the way ...
2
votes
0
answers
354
views
WKInterfaceController's becomeCurrentPage not working as expected
I'm loading up 4 WKInterfaceControllers into a page based horizontal interface in watchKit. When a delegate callback fires alerting the app that the screen has been water locked, I want the watch to ...
0
votes
1
answer
328
views
How to dismiss WKInterfaceController from another controller?
I am creating my first WatchOS app as a companion to an iOS app.
The Watch App needs to be able to display a bingo ball whose number is sent from the phone. Since I can't overlay images with WatchOS,...
1
vote
0
answers
188
views
WatchKit interfaceController not found
When running my App I get an error that an interface controller was not found, which crashes the app in runtime.
AppNameWatchExtension[809:615971] [default] -[SPRemoteInterface ...
1
vote
1
answer
1k
views
How do I dismiss a WKInterfaceController that was presented with contextForSegue?
I have a WKInterfaceController with a WKInterfaceTable that lists some events a user has recorded in my app.
A user can tap a row of the table to see more details about that event. To accomplish this,...
0
votes
1
answer
96
views
Setting the initial view controller in a page based navigation to something other than the first view
In watchOS, I'm implementing a Page-based navigation. The page based navigation contains three interface controllers; however, the first interface controller is the one that shows up first. In my ...
0
votes
1
answer
107
views
How to segue to the middle InterfaceController in Page Based Navigation on Apple Watch?
I am trying to build a similar flow to the Apple Watch Workout App where after you begin a workout you are presented with an InterfaceController showing the duration and you scan swipe left to see an ...
6
votes
1
answer
1k
views
WatchOS warning: rejected resignFirstResponder when being removed from hierarchy
I'm getting this error in Xcode.
2018-02-26 07:13:22.326888-0500 Watch Extension[1298:2691330] [View]
First responder warning: '<SPInterfacePicker: 0x14dc1740; frame = (76
0; 58 44); ...
5
votes
1
answer
521
views
Strange WatchKit WKInterfaceController and WKExtensionDelegate lifecycle calls
I have added logs on both WKExtensionDelegate and WKInterfaceController.
Here is what i get when playing around with starting and exiting the app in
Watch OS Simulator. (Simulator is running watchOS ...
0
votes
1
answer
330
views
Programmatically setting WKPickerItem won't go above a certain value?
Can't figure this out, via the code below I let the user set a value on a WKPickerItem, store it in UserDefaults, then load it up the next time the InterfaceController is loaded and attempt to set the ...
1
vote
0
answers
194
views
Scroll only WKInterfaceTable - WatchKit
I have this situation:
one WKInterfaceController within an WKInterfaceTable and a Group within one label.
I want to do this:
insert the group and below it the table but only table has to scroll and ...
0
votes
1
answer
174
views
Get visibile controller iWatch
I have this situation:
I have an iWatch app that has a root WKInterfaceController and when it fires a particular event I present another WKInterfaceController in this way:
WKInterfaceController * ...
1
vote
1
answer
77
views
How come Xcode Stops letting me hook up IBOutlets after two Interface Controllers?
I was setting the IBOutlets for the first few objects of a Watch App.
However, after doing a few IBOutlets it stops once I get to work on the third InterfaceController, closes InterfaceController....
2
votes
0
answers
377
views
WatchOS App: What is lifecycle of WKInterfaceController?
Anyone explain me correct way the WKInterfaceController lifecycle?
I would like to know how to use when creating an interface controller, WatchKit instantiates the class and calls its -init, -...
3
votes
2
answers
860
views
How can I share variables between multiple interface controllers in a paged-based interface on watchOS
I have multiple interface controllers that are both open at the same time in a paged-based format. I need to share information between these interface controllers.
For my use case, I cannot force the ...
0
votes
1
answer
290
views
context showing nil when trying to send data across Interface Controllers in WatchKit
I have two Interface Controllers with FirstInterfaceController being the one where I have a context object I want to send to SecondInterfaceController. I am wondering why context is showing up as nil ...
1
vote
1
answer
125
views
how to show second screen of the array when presentController(withNames:contexts:) is executed
presentController(withNames:["ScreenOne", "ScreenTwo", "ScreenThree"], contexts:nil)
when the above line is executed, the ScreenOne screen shows up as below:
first page in the array is highlighted
...
0
votes
1
answer
132
views
Passing data between two Interface Controllers
I want to pass a string between two Interface Controllers. On InterfaceController1 I want to create a variable like:
var level: String = ("easy")
And then be able to access that variable on ...
2
votes
1
answer
124
views
Passing Data between Interface Controllers on Xcode 8.0 Swift 3.0
I want to pass a string between two Interface Controllers. On InterfaceController1 I want to create a variable like:
var level:String = ("easy")
and then be able to access that variable on ...
4
votes
2
answers
1k
views
Why can't I send data between interface controllers for Apple Watch?
Basically, what I'm trying to do is pass an integer from one interface controller. The slider in the controller "SecondPage" will get an integer value from the slider and should send it to the ...
0
votes
1
answer
48
views
WatchOS 3 sharing information and actions between interfaces
I have a table on my main watch interface. Upon user selection, a 2nd interface will show and display more details about the user picked item.
I'm thinking about adding a button to this 2nd ...
1
vote
1
answer
705
views
How to pass data back to an interface controller in Watchkit
I know that this question has been asked a lot but it seems that nobody has given a proper answer.
I have an interface controller that has a table. Now when the user selects a a row I push the ...
1
vote
1
answer
169
views
Watch OS Swift Table load data in order
Watch OS 3/Xcode 8 allows for stand alone watch apps. Can someone provide the best Swift array/method for loading data to a table in storbyboard in order from Interface Controller, updating after each ...
0
votes
1
answer
428
views
How to open a specific view controller from a custom notification action in WatchOS 3
I'm developing a WatchOS3 application in which the user receives local notifications with custom actions. The user has 2 custom actions that he can call on the notification, option 1 and option 2. ...
0
votes
1
answer
322
views
watchOS app resets to root view controller after display sleep
I'm implementing a simple hierarchical interface for a watchOS app, using pushController(withName: String, context: Any?) to add views onto the stack. When trying to test on a watchOS 3 device, my app ...
0
votes
1
answer
67
views
How to set Apple Watch title for VoiceOver AccessibilityLabel
Is there any way to change the AccessibilityLabel of a WKInterfaceController title?
Or to turn off just the title VoiceOver?
I have shortened the title to X|Y to show the user what they are viewing ...
0
votes
0
answers
123
views
WatchKit : applicationWillResignActive called after x seconds and dictation stop
My application have to start automatically dictation (with presentTextInputControllerWithSuggestions with an empty array of suggestions). For this, I schedule a dictation with a delay after X seconds ...
0
votes
1
answer
38
views
How to display Apple Watch unable to connect screens?
I am developing an Apple Watch app and trying to handle the error cases of not being able to connect to the iPhone:
And needing to unlock the iPhone to access it:
I have seen several apps that have ...
7
votes
1
answer
380
views
Set rootInterfaceController in Apple Watch's "ExtensionDelegate"
I am making a Apple Watch app and I'd like to set different root view controllers, depending on an initial condition.
I cannot set the WatchKit rootInterfaceController directly though, because it is ...
1
vote
1
answer
78
views
Update InterfaceController with different data
Hi I am new to WatchKit development. I want to know that can I update a single interface controller with multiple data for button clicks
2
votes
2
answers
146
views
WatchKit InterfaceController conditionally play haptic in sendMessage:replyHandler:
I want to make the interface controller check to make sure it is still in the foreground when I get a reply from the phone. If it is, perform a haptic to let the user know it finished working.
...
1
vote
3
answers
2k
views
Prevent dismissing modal WKInterfaceController
Is there a way to prevent the user from dismissing a modal controller?
I think it is pretty common to want to "block" the main Watch App interface while asking the user to open the iPhone counterpart ...
1
vote
1
answer
329
views
WKInterfaceController top right button
On WKInterfaceController, is there a way to add a button (such as 'Done') at the top right corner of the watch screen instead of the time?
1
vote
0
answers
56
views
Watch app crashing with variable name "properties"
I've been debugging my watch app for a few hours now because every time I try to segue to a new interface controller, my app crashes after the return statement in contextForSegueWithIdentifier. I was ...
2
votes
1
answer
99
views
How to know when user has closed modally presented controller by tapping on title?
Is there a way to know in code when user has closed a modal by tapping the title? Apple's documentation states:
The title of the modal interface is set to the string Cancel unless the presented ...
2
votes
0
answers
105
views
WatchKit: modal controller with it's own hierarchical navigation
Watchkit offers 3 types of navigation: Page-based, modal and hierarchical interfaces.
Imagine that kind of hierarchy:
Main controller V1 -> Modal controller V2 -> Push to controller V3
The main ...
1
vote
1
answer
339
views
Customise title in the WK Status Bar
I'm trying to customise title in the WK Status Bar of my first Controller.
The correct way should be this:
public func setTitle(title: String?) // title of controller. displayed when controller ...
0
votes
1
answer
392
views
Call a public method of a WKInterfaceController from ExtensionDelegate class- WatchKit
I am calling the
`[[WCSession defaultSession] updateApplicationContext:message error:error]`
method which is triggered in my
`-(void)session:(WCSession *)session didReceiveApplicationContext:(...