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

Side by Side Diff: Source/devtools/front_end/host/InspectorFrontendHost.js

Issue 670303002: DevTools: fix Ctrl-Plus/Ctrl-Minus shortcuts for zooming in hosted mode (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: fix compilation Created 6 years, 2 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 | Annotate | Revision Log
« 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 /* 1 /*
2 * Copyright (C) 2009 Google Inc. All rights reserved. 2 * Copyright (C) 2009 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 278 matching lines...) Expand 10 before | Expand all | Expand 10 after
289 289
290 /** 290 /**
291 * @return {boolean} 291 * @return {boolean}
292 */ 292 */
293 isHostedMode: function() { } 293 isHostedMode: function() { }
294 } 294 }
295 295
296 /** 296 /**
297 * @constructor 297 * @constructor
298 * @implements {InspectorFrontendHostAPI} 298 * @implements {InspectorFrontendHostAPI}
299 * @suppressGlobalPropertiesCheck
299 */ 300 */
300 WebInspector.InspectorFrontendHostStub = function() 301 WebInspector.InspectorFrontendHostStub = function()
301 { 302 {
303 /**
304 * @param {!Event} event
305 */
306 function stopEventPropagation(event)
307 {
308 // Let browser handle Ctrl+/Ctrl- shortcuts in hosted mode.
309 if (event.ctrlKey && (event.keyCode === 187 || event.keyCode === 189))
310 event.stopPropagation();
311 }
312 document.addEventListener("keydown", stopEventPropagation, true);
302 } 313 }
303 314
304 WebInspector.InspectorFrontendHostStub.prototype = { 315 WebInspector.InspectorFrontendHostStub.prototype = {
305 /** 316 /**
306 * @return {string} 317 * @return {string}
307 */ 318 */
308 getSelectionBackgroundColor: function() 319 getSelectionBackgroundColor: function()
309 { 320 {
310 return "#6e86ff"; 321 return "#6e86ff";
311 }, 322 },
(...skipping 378 matching lines...) Expand 10 before | Expand all | Expand 10 after
690 * @param {number} id 701 * @param {number} id
691 * @param {?string} error 702 * @param {?string} error
692 */ 703 */
693 embedderMessageAck: function(id, error) 704 embedderMessageAck: function(id, error)
694 { 705 {
695 InspectorFrontendHost["embedderMessageAck"](id, error); 706 InspectorFrontendHost["embedderMessageAck"](id, error);
696 } 707 }
697 } 708 }
698 709
699 var InspectorFrontendAPI = new InspectorFrontendAPIImpl(); 710 var InspectorFrontendAPI = new InspectorFrontendAPIImpl();
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