Skip to content

Commit

Permalink
[Fix] (dirty) prevent users from upload dialogs (via js)
Browse files Browse the repository at this point in the history
  • Loading branch information
jegger authored and allestuetsmerweh committed May 8, 2017
1 parent 04651af commit 3f70e05
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions cefbrowser/cefbrowser.py
Original file line number Diff line number Diff line change
Expand Up @@ -1200,6 +1200,14 @@ def OnLoadStart(self, browser, frame): # noqa: N802
console.log("Print dialog blocked");
};
window.addEventListener('load', function () {
document.querySelectorAll('input[type=file]').forEach(function (elem) {
elem.onclick = function () {
return false;
}
});
});
// Keyboard management
Expand Down

0 comments on commit 3f70e05

Please sign in to comment.