    var gallery = null;

    function unloading() {
    	if (gallery) {
	    gallery.close();
	}
    }
