|
@@ -75,6 +75,7 @@ |
75 |
75 |
|
|
76 |
76 |
|
|
77 |
77 |
|
self.poi = [self.routeForDetail.routePois objectAtIndex:[self.poiIndex intValue]]; |
|
78 |
+ |
[self.poi setStatus:@"999"]; |
78 |
79 |
|
|
79 |
80 |
|
DATAMANAGER.secondsCount = [DATAMANAGER.user.timeForRoute objectForKey:self.routeForDetail.routeId]; |
80 |
81 |
|
|
|
@@ -186,7 +187,7 @@ |
186 |
187 |
|
- (IBAction)doOpenPoiList{ |
187 |
188 |
|
|
188 |
189 |
|
PoiListVC * poiLisVC = [[PoiListVC alloc]init]; |
189 |
|
- |
poiLisVC.poi= self.poi; |
|
190 |
+ |
poiLisVC.poi = self.poi; |
190 |
191 |
|
poiLisVC.routeForDetail = self.routeForDetail; |
191 |
192 |
|
|
192 |
193 |
|
self.navigationItem.backBarButtonItem = [[UIBarButtonItem alloc] initWithTitle:@"" style:UIBarButtonItemStylePlain target:nil action:nil]; |
|
@@ -264,51 +265,44 @@ |
264 |
265 |
|
[self.navigationController popToRootViewControllerAnimated:TRUE]; |
265 |
266 |
|
} |
266 |
267 |
|
|
267 |
|
- |
#pragma mark - MemoryWarning |
268 |
|
- |
|
269 |
|
- |
- (void)didReceiveMemoryWarning { |
270 |
|
- |
[super didReceiveMemoryWarning]; |
271 |
|
- |
} |
272 |
|
- |
|
273 |
268 |
|
#pragma UIAlertview Delegate |
274 |
269 |
|
|
275 |
|
- |
- (void)customIOS7dialogButtonTouchUpInside: (CustomIOSAlertView *)alertView clickedButtonAtIndex: (NSInteger)buttonIndex |
276 |
|
- |
{ |
277 |
|
- |
if (alertView.tag==1 && buttonIndex == 0) { |
278 |
|
- |
|
279 |
|
- |
FinalQuizVC *finalQuizVC = [[FinalQuizVC alloc] init]; |
280 |
|
- |
finalQuizVC.routeForDetail = self.routeForDetail; |
281 |
|
- |
|
282 |
|
- |
self.navigationItem.backBarButtonItem = [[UIBarButtonItem alloc] initWithTitle:@"" style:UIBarButtonItemStylePlain target:nil action:nil]; |
283 |
|
- |
|
284 |
|
- |
[self.navigationController pushViewController:finalQuizVC animated:YES]; |
285 |
|
- |
} else if (alertView.tag==1 && buttonIndex == 1) { |
286 |
|
- |
|
287 |
|
- |
RouteQuestionsVC *routeQuestionsVC = [[RouteQuestionsVC alloc] init]; |
288 |
|
- |
routeQuestionsVC.allRoutes = self.allRoutes; |
289 |
|
- |
routeQuestionsVC.routeForDetail = self.routeForDetail; |
290 |
|
- |
|
291 |
|
- |
self.navigationItem.backBarButtonItem = [[UIBarButtonItem alloc] initWithTitle:@"" style:UIBarButtonItemStylePlain target:nil action:nil]; |
292 |
|
- |
|
293 |
|
- |
[self.navigationController pushViewController:routeQuestionsVC animated:YES]; |
294 |
|
- |
|
295 |
|
- |
}else if (alertView.tag ==02 || alertView.tag == 03){ |
|
270 |
+ |
- (void)customIOS7dialogButtonTouchUpInside: (CustomIOSAlertView *)alertView clickedButtonAtIndex: (NSInteger)buttonIndex { |
|
271 |
+ |
if (alertView.tag == 1 && buttonIndex == 0) { |
296 |
272 |
|
|
297 |
|
- |
[alertView close]; |
298 |
|
- |
} |
|
273 |
+ |
FinalQuizVC *finalQuizVC = [[FinalQuizVC alloc] init]; |
|
274 |
+ |
finalQuizVC.routeForDetail = self.routeForDetail; |
|
275 |
+ |
|
|
276 |
+ |
self.navigationItem.backBarButtonItem = [[UIBarButtonItem alloc] initWithTitle:@"" style:UIBarButtonItemStylePlain target:nil action:nil]; |
|
277 |
+ |
|
|
278 |
+ |
[self.navigationController pushViewController:finalQuizVC animated:YES]; |
|
279 |
+ |
} |
|
280 |
+ |
else if (alertView.tag == 1 && buttonIndex == 1) { |
|
281 |
+ |
|
|
282 |
+ |
RouteQuestionsVC *routeQuestionsVC = [[RouteQuestionsVC alloc] init]; |
|
283 |
+ |
routeQuestionsVC.allRoutes = self.allRoutes; |
|
284 |
+ |
routeQuestionsVC.routeForDetail = self.routeForDetail; |
|
285 |
+ |
|
|
286 |
+ |
self.navigationItem.backBarButtonItem = [[UIBarButtonItem alloc] initWithTitle:@"" style:UIBarButtonItemStylePlain target:nil action:nil]; |
|
287 |
+ |
|
|
288 |
+ |
[self.navigationController pushViewController:routeQuestionsVC animated:YES]; |
|
289 |
+ |
|
|
290 |
+ |
} |
|
291 |
+ |
else if (alertView.tag == 02 || alertView.tag == 03) { |
|
292 |
+ |
[alertView close]; |
|
293 |
+ |
} |
299 |
294 |
|
|
300 |
295 |
|
if (alertView.tag == 15 && buttonIndex == 0) { |
301 |
|
- |
////inserire chiamata al metodo stepOverClue |
302 |
296 |
|
[self stepOverClue]; |
303 |
297 |
|
[alertView close]; |
304 |
|
- |
|
305 |
|
- |
|
306 |
|
- |
}else if (alertView.tag == 15 && buttonIndex == 1){ |
|
298 |
+ |
|
|
299 |
+ |
} else if (alertView.tag == 15 && buttonIndex == 1){ |
307 |
300 |
|
[alertView close]; |
308 |
301 |
|
} |
309 |
302 |
|
} |
310 |
303 |
|
|
311 |
|
- |
- (void)stepOverClue{ |
|
304 |
+ |
- (void)stepOverClue { |
|
305 |
+ |
|
312 |
306 |
|
PoiVC *poiVC = [[PoiVC alloc] init]; |
313 |
307 |
|
poiVC.allRoutes = self.allRoutes; |
314 |
308 |
|
poiVC.routeForDetail = self.routeForDetail; |
|
@@ -341,21 +335,16 @@ |
341 |
335 |
|
conVC.routeForDetail = self.routeForDetail; |
342 |
336 |
|
conVC.allRoutes = self.allRoutes; |
343 |
337 |
|
[self.navigationController pushViewController:conVC animated:NO]; |
344 |
|
- |
|
345 |
338 |
|
} |
346 |
|
- |
|
347 |
339 |
|
} |
348 |
340 |
|
|
349 |
|
- |
|
350 |
|
- |
|
351 |
|
- |
-(void)timeRun{ |
|
341 |
+ |
- (void)timeRun{ |
352 |
342 |
|
|
353 |
343 |
|
[DATAMANAGER timeInc]; |
354 |
344 |
|
self.poiDuration.text = [NSString stringWithFormat:@"Durata %@", [DATAMANAGER getTime]]; |
355 |
345 |
|
} |
356 |
346 |
|
|
357 |
|
- |
-(void)timerStop{ |
358 |
|
- |
|
|
347 |
+ |
- (void)timerStop{ |
359 |
348 |
|
|
360 |
349 |
|
if(countTimer){ |
361 |
350 |
|
|
|
@@ -364,4 +353,10 @@ |
364 |
353 |
|
} |
365 |
354 |
|
} |
366 |
355 |
|
|
|
356 |
+ |
#pragma mark - MemoryWarning |
|
357 |
+ |
|
|
358 |
+ |
- (void)didReceiveMemoryWarning { |
|
359 |
+ |
[super didReceiveMemoryWarning]; |
|
360 |
+ |
} |
|
361 |
+ |
|
367 |
362 |
|
@end |