Changeset 2141

Show
Ignore:
Timestamp:
10/05/08 11:07:23 (3 months ago)
Author:
jaymacdonald
Message:

User is not restricted in installing old applications; but when they do start one, they are noted about the compatibility problem and are offered the choice to start it or not.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • branches/1.0/desktop/dojotoolkit/desktop/apps/_App.js

    r2139 r2141  
    2525                this.compatible = info.compatible; 
    2626                if(!desktop.version.isCompatible(info.compatible)) { 
    27                         api.ui.alertDialog({title: this.name, message: "This program is not compatible with this version of Lucid Desktop.<br>Please check the Lucid Desktop site or contact the application distributor for a compatible edition.<br><br>App: "+this.compatible+"<br>Desktop: "+desktop.version.toString()}); 
    28                         this.status = "killed"; 
    29                         var pid = this.instance; 
    30                         //allow the garbage collector to free up memory 
    31                         setTimeout(function(){ 
    32                                 desktop.app.instances[pid]=null; 
    33                         }, desktop.config.window.animSpeed + 1000); 
    34                         return false; 
     27                        api.ui.yesnoDialog({title: "Compatibility Note: "+this.name, message: "This program may not be compatible with this version of Lucid Desktop.<br>Please check the Lucid Desktop site or contact the application distributor for a compatible edition.<br><br>App: "+this.compatible+"<br>Desktop: "+desktop.version.toString()+"<br><br><br>Launching this application may cause undesired effects.<br>Are you sure you wish to launch the application?",callback: dojo.hitch(this, function(value) { 
     28                        if(value) { 
     29                                try { 
     30                                        this.init(info.args||{}); 
     31                                } 
     32                                catch(e) { 
     33                                        console.error(e); 
     34                                } 
     35                                this.status = "active"; 
     36                                if(typeof info.callback == "function") info.callback(this); 
     37                        } 
     38                        else { 
     39                                this.status = "killed"; 
     40                                var pid = this.instance; 
     41                                //allow the garbage collector to free up memory 
     42                                setTimeout(function(){ 
     43                                        desktop.app.instances[pid]=null; 
     44                                }, desktop.config.window.animSpeed + 1000); 
     45                                return false; 
     46                        } 
     47                        }) 
     48                        }); 
     49                        return; 
    3550                } 
    3651                try {