953e4a09522471cd2f452dacb2090d9ccf48f893
[ccsdk/features.git] /
1 (function( app ) {
2
3         var ux = app.ns("ux");
4
5         var extend = ux.Observable.extend;
6         var instance = function() {
7                 if( ! ("me" in this) ) {
8                         this.me = new this();
9                 }
10                 return this.me;
11         };
12
13         ux.Singleton = ux.Observable.extend({});
14
15         ux.Singleton.extend = function() {
16                 var Self = extend.apply( this, arguments );
17                 Self.instance = instance;
18                 return Self;
19         };
20
21 })( this.app );