Source: widgets/SpwEmptyWidget.js

Retour à la documentation
/**
 * @class spw.widgets.SpwEmptyWidget
 */
define(["dojo/_base/declare","spw/api/SpwBaseWidget"],
		function(declare, SpwBaseWidget){
	
	return declare("spw.widgets.SpwEmptyWidget", [SpwBaseWidget], /** @lends spw.widgets.SpwEmptyWidget.prototype */{

		url: '',

        /**
         * @constructs
         * @param config
         */
		constructor: function (config) {
		},
		
		postMixInProperties: function (config) {
			this.inherited(arguments);
		},
		
		buildRendering: function (config) {
			this.inherited(arguments);
		},
		
		postCreate: function() {
			this.inherited(arguments);
		},
		
		startup: function() {
			this.inherited(arguments);
		},
		
		onActivate: function(){
			this.inherited(arguments);

			if (this.url) {
				if (window.top) {
					window.top.location.href = this.url;
				}
				else {
					location.href = this.url;
				}
			}
		},
		
		onDeactivate: function(){
			this.inherited(arguments);
		},
		
		destroy: function() {
			this.inherited(arguments);
		}
	});
});