Skip to content
Snippets Groups Projects
Commit 164be46b authored by Maxime Graulich's avatar Maxime Graulich
Browse files

iOS: GUI refresh in main thread

parent 9136621b
Branches
Tags
No related merge requests found
...@@ -182,6 +182,11 @@ ...@@ -182,6 +182,11 @@
dispatch_group_notify(group, queue, ^{ dispatch_group_notify(group, queue, ^{
[UIApplication sharedApplication].applicationIconBadgeNumber = -1; [UIApplication sharedApplication].applicationIconBadgeNumber = -1;
[self performSelectorOnMainThread:@selector(stopGUI) withObject:nil waitUntilDone:YES];
});
}
-(void)stopGUI
{
[_runStopButton setAction:@selector(compute)]; [_runStopButton setAction:@selector(compute)];
[_runStopButton setTitle:@"Run"]; [_runStopButton setTitle:@"Run"];
[_progressLabel setHidden:YES]; [_progressLabel setHidden:YES];
...@@ -191,7 +196,6 @@ ...@@ -191,7 +196,6 @@
_errorAlert = [[UIErrorAlertView alloc] initWithTitle:@"Gmsh/GetDP error" message:[_errors lastObject] delegate:self cancelButtonTitle:@"Hide" otherButtonTitles:@"Show more", nil]; _errorAlert = [[UIErrorAlertView alloc] initWithTitle:@"Gmsh/GetDP error" message:[_errors lastObject] delegate:self cancelButtonTitle:@"Hide" otherButtonTitles:@"Show more", nil];
[_errorAlert show]; [_errorAlert show];
} }
});
} }
- (void)stop - (void)stop
{ {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment