Ignore:
Timestamp:
Mar 10, 2012, 1:36:26 PM (10 years ago)
Author:
livings124
Message:

less crashing with ARC

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/macosx/BlocklistDownloaderViewController.m

    r13248 r13249  
    3838@implementation BlocklistDownloaderViewController
    3939
    40 #warning make gcd singleton
     40#warning make gcd singleton?
     41BlocklistDownloaderViewController * fDLViewController = nil;
    4142+ (void) downloadWithPrefsController: (PrefsController *) prefsController
    4243{
    43     BlocklistDownloaderViewController * downloader = [[BlocklistDownloaderViewController alloc] initWithPrefsController: prefsController];
    44     [downloader startDownload];
     44    if (!fDLViewController)
     45    {
     46        fDLViewController = [[BlocklistDownloaderViewController alloc] initWithPrefsController: prefsController];
     47        [fDLViewController startDownload];
     48    }
    4549}
    4650
     
    103107    [fStatusWindow orderOut: self];
    104108   
     109    fDLViewController = nil;
    105110}
    106111
     
    149154{
    150155    [[alert window] orderOut: self];
     156   
     157    fDLViewController = nil;
    151158}
    152159
Note: See TracChangeset for help on using the changeset viewer.