فهرست منبع

collaps add media view controller when download is complete, if the user hasn't already done so

Felix Paul Kühne 12 سال پیش
والد
کامیت
61687d2f4f
2فایلهای تغییر یافته به همراه5 افزوده شده و 0 حذف شده
  1. 1 0
      AspenProject/VLCAddMediaViewController.h
  2. 4 0
      AspenProject/VLCHTTPFileDownloader.m

+ 1 - 0
AspenProject/VLCAddMediaViewController.h

@@ -28,6 +28,7 @@
 @property (strong, nonatomic) IBOutlet UITextField *openURLField;
 @property (strong, nonatomic) IBOutlet UIButton *openURLButton;
 
+- (IBAction)dismiss:(id)sender;
 - (IBAction)openAboutPanel:(id)sender;
 - (IBAction)openNetworkStream:(id)sender;
 - (IBAction)downloadFromHTTPServer:(id)sender;

+ 4 - 0
AspenProject/VLCHTTPFileDownloader.m

@@ -85,12 +85,16 @@
 
     VLCAppDelegate * appDelegate = [UIApplication sharedApplication].delegate;
     [appDelegate updateMediaList];
+
+    [_mediaViewController dismiss:nil];
 }
 
 -(void)connection:(NSURLConnection *)connection didFailWithError:(NSError *)error {
     APLog(@"http file download failed (%i)", error.code);
     _downloadInProgress = NO;
     _progressIndicator.hidden = YES;
+
+    [_mediaViewController dismiss:nil];
 }
 
 @end