| OLD | NEW |
| 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) 2008, 2009 Anthony Ricaud <rik@webkit.org> | 3 * Copyright (C) 2008, 2009 Anthony Ricaud <rik@webkit.org> |
| 4 * Copyright (C) 2011 Google Inc. All rights reserved. | 4 * Copyright (C) 2011 Google Inc. All rights reserved. |
| 5 * | 5 * |
| 6 * Redistribution and use in source and binary forms, with or without | 6 * Redistribution and use in source and binary forms, with or without |
| 7 * modification, are permitted provided that the following conditions | 7 * modification, are permitted provided that the following conditions |
| 8 * are met: | 8 * are met: |
| 9 * | 9 * |
| 10 * 1. Redistributions of source code must retain the above copyright | 10 * 1. Redistributions of source code must retain the above copyright |
| (...skipping 712 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 723 eventsRetrievalProgress: function(progress) | 723 eventsRetrievalProgress: function(progress) |
| 724 { | 724 { |
| 725 }, | 725 }, |
| 726 | 726 |
| 727 startRecording: function() | 727 startRecording: function() |
| 728 { | 728 { |
| 729 if (this._target) | 729 if (this._target) |
| 730 return; | 730 return; |
| 731 | 731 |
| 732 this._target = WebInspector.targetManager.mainTarget(); | 732 this._target = WebInspector.targetManager.mainTarget(); |
| 733 this._tracingModel = new WebInspector.TracingModel(new WebInspector.Temp
FileBackingStorage("tracing")); | 733 if (this._tracingModel) |
| 734 this._tracingModel.reset(); |
| 735 else |
| 736 this._tracingModel = new WebInspector.TracingModel(new WebInspector.
TempFileBackingStorage("tracing")); |
| 734 this._target.tracingManager.start(this, "-*,disabled-by-default-devtools
.screenshot", ""); | 737 this._target.tracingManager.start(this, "-*,disabled-by-default-devtools
.screenshot", ""); |
| 735 this._filmStripView.reset(); | 738 this._filmStripView.reset(); |
| 736 this._filmStripView.setStatusText(WebInspector.UIString("Recording frame
s...")); | 739 this._filmStripView.setStatusText(WebInspector.UIString("Recording frame
s...")); |
| 737 }, | 740 }, |
| 738 | 741 |
| 739 /** | 742 /** |
| 740 * @return {boolean} | 743 * @return {boolean} |
| 741 */ | 744 */ |
| 742 isRecording: function() | 745 isRecording: function() |
| 743 { | 746 { |
| (...skipping 28 matching lines...) Expand all Loading... |
| 772 * @param {!WebInspector.Context} context | 775 * @param {!WebInspector.Context} context |
| 773 * @param {string} actionId | 776 * @param {string} actionId |
| 774 */ | 777 */ |
| 775 handleAction: function(context, actionId) | 778 handleAction: function(context, actionId) |
| 776 { | 779 { |
| 777 var panel = WebInspector.context.flavor(WebInspector.NetworkPanel); | 780 var panel = WebInspector.context.flavor(WebInspector.NetworkPanel); |
| 778 console.assert(panel && panel instanceof WebInspector.NetworkPanel); | 781 console.assert(panel && panel instanceof WebInspector.NetworkPanel); |
| 779 panel._toggleRecording(); | 782 panel._toggleRecording(); |
| 780 } | 783 } |
| 781 } | 784 } |
| OLD | NEW |