project_files/HedgewarsMobile/Classes/InGameMenuViewController.m
changeset 6076 e1b4771f6472
parent 6019 8843ea756cfc
child 6078 8c0cc07731e5
equal deleted inserted replaced
6075:0173cd44c3bc 6076:e1b4771f6472
    88         [self.view performSelector:@selector(removeFromSuperview) withObject:nil afterDelay:0.35];
    88         [self.view performSelector:@selector(removeFromSuperview) withObject:nil afterDelay:0.35];
    89     }
    89     }
    90 
    90 
    91     SDL_iPhoneKeyboardHide((SDL_Window *)HW_getSDLWindow());
    91     SDL_iPhoneKeyboardHide((SDL_Window *)HW_getSDLWindow());
    92 
    92 
       
    93     /*
    93     if (shouldTakeScreenshot) {
    94     if (shouldTakeScreenshot) {
    94         UIAlertView *alert = [[UIAlertView alloc] initWithTitle:@"Please wait"
    95         UIAlertView *alert = [[UIAlertView alloc] initWithTitle:@"Please wait"
    95                                                         message:nil
    96                                                         message:nil
    96                                                        delegate:nil
    97                                                        delegate:nil
    97                                               cancelButtonTitle:nil
    98                                               cancelButtonTitle:nil
   105         [indicator release];
   106         [indicator release];
   106 
   107 
   107         // all these hacks because of the PAUSE caption on top of everything...
   108         // all these hacks because of the PAUSE caption on top of everything...
   108         [self performSelector:@selector(saveCurrentScreenToPhotoAlbum:) withObject:alert afterDelay:0.3];
   109         [self performSelector:@selector(saveCurrentScreenToPhotoAlbum:) withObject:alert afterDelay:0.3];
   109     }
   110     }
       
   111     */
   110     shouldTakeScreenshot = NO;
   112     shouldTakeScreenshot = NO;
   111 }
   113 }
   112 
   114 
   113 #pragma mark -
   115 #pragma mark -
   114 #pragma mark tableView methods
   116 #pragma mark tableView methods
   190         HW_terminate(NO);
   192         HW_terminate(NO);
   191     }
   193     }
   192 }
   194 }
   193 
   195 
   194 //TODO: check this is still needed since we switched to SDL_GL_CreateContext()
   196 //TODO: check this is still needed since we switched to SDL_GL_CreateContext()
       
   197 /*
   195 #pragma mark -
   198 #pragma mark -
   196 #pragma mark save screenshot
   199 #pragma mark save screenshot
   197 //by http://www.bit-101.com/blog/?p=1861
   200 //by http://www.bit-101.com/blog/?p=1861
   198 // callback for CGDataProviderCreateWithData
   201 // callback for CGDataProviderCreateWithData
   199 void releaseData(void *info, const void *data, size_t dataSize) {
   202 void releaseData(void *info, const void *data, size_t dataSize) {
   245     CGImageRelease(imageRef);
   248     CGImageRelease(imageRef);
   246 
   249 
   247     // add callback for cleaning memory and removing alert
   250     // add callback for cleaning memory and removing alert
   248     UIImageWriteToSavedPhotosAlbum(image, self, @selector(image:didFinishSavingWithError:contextInfo:), (void *)alert);
   251     UIImageWriteToSavedPhotosAlbum(image, self, @selector(image:didFinishSavingWithError:contextInfo:), (void *)alert);
   249 }
   252 }
   250 
   253 */
   251 
   254 
   252 @end
   255 @end