Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(235)

Side by Side Diff: chrome/renderer/resources/plugin_poster.html

Issue 977653002: Plugin Power Saver: Accept SPACE or ENTER to unthrottle plugins. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <!doctype html> 1 <!doctype html>
2 <html> 2 <html>
3 <head> 3 <head>
4 <meta charset="utf-8"> 4 <meta charset="utf-8">
5 <meta name="viewport" content="width=device-width, user-scalable=no"> 5 <meta name="viewport" content="width=device-width, user-scalable=no">
6 <script> 6 <script>
7 function notifyDidFinishLoading() { 7 function notifyDidFinishLoading() {
8 if (plugin.didFinishLoading) 8 if (plugin.didFinishLoading)
9 plugin.didFinishLoading(); 9 plugin.didFinishLoading();
10 } 10 }
11
12 document.onkeypress = function(e) {
Dan Beam 2015/03/03 19:51:51 nit: maybe do this onkeydown instead
tommycli 2015/03/03 20:02:00 Done.
13 if (e.keyCode == 13 || e.keyCode == 32) {
Dan Beam 2015/03/03 19:51:51 nit: e.keyIdentifier == 'Enter' || e.keyIdentifier
tommycli 2015/03/03 20:02:00 Done.
14 plugin.load();
Dan Beam 2015/03/03 19:51:51 e.preventDefault();
tommycli 2015/03/03 20:02:00 Done.
15 }
Dan Beam 2015/03/03 19:51:51 nit: no curlies
tommycli 2015/03/03 20:02:00 Added back due to adding e.preventDefault().
16 };
11 </script> 17 </script>
12 <link rel="stylesheet" href="plugin_placeholders.css"></link> 18 <link rel="stylesheet" href="plugin_placeholders.css"></link>
13 <style> 19 <style>
14 #outer { 20 #outer {
15 border: none; 21 border: none;
16 cursor: pointer; 22 cursor: pointer;
17 background-position: center; 23 background-position: center;
18 background-repeat: no-repeat; 24 background-repeat: no-repeat;
19 background-size: contain; 25 background-size: contain;
20 } 26 }
(...skipping 23 matching lines...) Expand all
44 <div i18n-values="title:name;.style.background-image:background" id="outer" 50 <div i18n-values="title:name;.style.background-image:background" id="outer"
45 onclick="plugin.load()"> 51 onclick="plugin.load()">
46 <div id="shielding"> 52 <div id="shielding">
47 <div id="inner"> 53 <div id="inner">
48 <div><img id="plugin_icon" src="plugin_power_saver_play.png" /></div> 54 <div><img id="plugin_icon" src="plugin_power_saver_play.png" /></div>
49 </div> 55 </div>
50 </div> 56 </div>
51 </div> 57 </div>
52 </body> 58 </body>
53 </html> 59 </html>
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698