Permalink
Browse files

MDL-26260 Fix quiz right-click prevention loophole.

  • Loading branch information...
1 parent 269c884 commit 8f8db0fc5ff01345d2560bc689154e7776b78ad0 Jason Ilicic committed with timhunt Feb 4, 2011
Showing with 5 additions and 5 deletions.
  1. +5 −5 mod/quiz/module.js
View
@@ -186,11 +186,11 @@ M.mod_quiz.secure_window = {
if (window.location.href.substring(0, 4) == 'file') {
window.location = 'about:blank';
}
- Y.delegate('contextmenu', M.mod_quiz.secure_window.prevent, document.body, '*');
- Y.delegate('mousedown', M.mod_quiz.secure_window.prevent_mouse, document.body, '*');
- Y.delegate('mouseup', M.mod_quiz.secure_window.prevent_mouse, document.body, '*');
- Y.delegate('dragstart', M.mod_quiz.secure_window.prevent, document.body, '*');
- Y.delegate('selectstart', M.mod_quiz.secure_window.prevent, document.body, '*');
+ Y.delegate('contextmenu', M.mod_quiz.secure_window.prevent, document, '*');
+ Y.delegate('mousedown', M.mod_quiz.secure_window.prevent_mouse, document, '*');
+ Y.delegate('mouseup', M.mod_quiz.secure_window.prevent_mouse, document, '*');
+ Y.delegate('dragstart', M.mod_quiz.secure_window.prevent, document, '*');
+ Y.delegate('selectstart', M.mod_quiz.secure_window.prevent, document, '*');
M.mod_quiz.secure_window.clear_status;
Y.on('beforeprint', function() {
Y.one(document.body).setStyle('display', 'none');

0 comments on commit 8f8db0f

Please sign in to comment.