MDL-28235 form: Removed close icon of help icon popups
authorFrederic Massart <fred@moodle.com>
Tue, 2 Oct 2012 06:34:15 +0000 (14:34 +0800)
committerFrederic Massart <fred@moodle.com>
Wed, 31 Oct 2012 05:00:08 +0000 (13:00 +0800)
lib/javascript-static.js

index 158e5ff..2b6cefd 100644 (file)
@@ -1395,11 +1395,9 @@ M.util.help_icon = {
                     init : function() {
 
                         var strclose = Y.Escape.html(M.str.form.close);
-                        var closebtn = Y.Node.create('<a id="closehelpbox" href="#"><img src="'+M.util.image_url('t/delete', 'moodle')+'" alt="'+strclose+'" /></a>');
                         var footerbtn = Y.Node.create('<button class="closebtn">'+strclose+'</button>');
                         // Create an overlay from markup
                         this.overlay = new Y.Overlay({
-                            headerContent: closebtn,
                             footerContent: footerbtn,
                             bodyContent: '',
                             id: 'helppopupbox',
@@ -1409,7 +1407,6 @@ M.util.help_icon = {
                         });
                         this.overlay.render(Y.one(document.body));
 
-                        closebtn.on('click', this.overlay.hide, this.overlay);
                         footerbtn.on('click', this.overlay.hide, this.overlay);
 
                         var boundingBox = this.overlay.get("boundingBox");
@@ -1426,9 +1423,6 @@ M.util.help_icon = {
                                 this.overlay.hide();
                             }
                         }, this);
-
-                        Y.on("key", this.close, closebtn , "down:13", this);
-                        closebtn.on('click', this.close, this);
                     },
 
                     close : function(e) {