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

Side by Side Diff: third_party/WebKit/Source/devtools/front_end/console/ConsoleView.js

Issue 2466123002: DevTools: reformat front-end code to match chromium style. (Closed)
Patch Set: Created 4 years, 1 month 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved. 2 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved.
3 * Copyright (C) 2009 Joseph Pecoraro 3 * Copyright (C) 2009 Joseph Pecoraro
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 8 *
9 * 1. Redistributions of source code must retain the above copyright 9 * 1. Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 312 matching lines...) Expand 10 before | Expand all | Expand 10 after
323 }); 323 });
324 }, 324 },
325 325
326 _executionContextChanged: function() 326 _executionContextChanged: function()
327 { 327 {
328 this._prompt.clearAutocomplete(); 328 this._prompt.clearAutocomplete();
329 if (!this._showAllMessagesCheckbox.checked()) 329 if (!this._showAllMessagesCheckbox.checked())
330 this._updateMessageList(); 330 this._updateMessageList();
331 }, 331 },
332 332
333 /**
334 * @override
335 */
333 willHide: function() 336 willHide: function()
334 { 337 {
335 this._hidePromptSuggestBox(); 338 this._hidePromptSuggestBox();
336 }, 339 },
337 340
341 /**
342 * @override
343 */
338 wasShown: function() 344 wasShown: function()
339 { 345 {
340 this._viewport.refresh(); 346 this._viewport.refresh();
341 }, 347 },
342 348
349 /**
350 * @override
351 */
343 focus: function() 352 focus: function()
344 { 353 {
345 if (this._prompt.hasFocus()) 354 if (this._prompt.hasFocus())
346 return; 355 return;
347 // Set caret position before setting focus in order to avoid scrolling 356 // Set caret position before setting focus in order to avoid scrolling
348 // by focus(). 357 // by focus().
349 this._prompt.moveCaretToEndOfPrompt(); 358 this._prompt.moveCaretToEndOfPrompt();
350 this._prompt.focus(); 359 this._prompt.focus();
351 }, 360 },
352 361
362 /**
363 * @override
364 */
353 restoreScrollPositions: function() 365 restoreScrollPositions: function()
354 { 366 {
355 if (this._viewport.stickToBottom()) 367 if (this._viewport.stickToBottom())
356 this._immediatelyScrollToBottom(); 368 this._immediatelyScrollToBottom();
357 else 369 else
358 WebInspector.Widget.prototype.restoreScrollPositions.call(this); 370 WebInspector.VBox.prototype.restoreScrollPositions.call(this);
359 }, 371 },
360 372
373 /**
374 * @override
375 */
361 onResize: function() 376 onResize: function()
362 { 377 {
363 this._scheduleViewportRefresh(); 378 this._scheduleViewportRefresh();
364 this._hidePromptSuggestBox(); 379 this._hidePromptSuggestBox();
365 if (this._viewport.stickToBottom()) 380 if (this._viewport.stickToBottom())
366 this._immediatelyScrollToBottom(); 381 this._immediatelyScrollToBottom();
367 for (var i = 0; i < this._visibleViewMessages.length; ++i) 382 for (var i = 0; i < this._visibleViewMessages.length; ++i)
368 this._visibleViewMessages[i].onResize(); 383 this._visibleViewMessages[i].onResize();
369 }, 384 },
370 385
(...skipping 999 matching lines...) Expand 10 before | Expand all | Expand 10 after
1370 return true; 1385 return true;
1371 } 1386 }
1372 return false; 1387 return false;
1373 } 1388 }
1374 }; 1389 };
1375 1390
1376 /** 1391 /**
1377 * @typedef {{messageIndex: number, matchIndex: number}} 1392 * @typedef {{messageIndex: number, matchIndex: number}}
1378 */ 1393 */
1379 WebInspector.ConsoleView.RegexMatchRange; 1394 WebInspector.ConsoleView.RegexMatchRange;
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698