Chris Craik | b2cbf15 | 2015-07-28 16:26:29 -0700 | [diff] [blame^] | 1 | <!DOCTYPE html> |
| 2 | <!-- |
| 3 | Copyright (c) 2013 The Chromium Authors. All rights reserved. |
| 4 | Use of this source code is governed by a BSD-style license that can be |
| 5 | found in the LICENSE file. |
| 6 | --> |
| 7 | |
| 8 | <link rel="import" href="/extras/chrome/cc/layer_tree_host_impl.html"> |
| 9 | <link rel="import" href="/extras/importer/trace_event_importer.html"> |
| 10 | <link rel="import" href="/extras/chrome/cc/raster_task.html"> |
| 11 | <link rel="import" href="/model/model.html"> |
| 12 | <link rel="import" href="/ui/extras/chrome/cc/layer_tree_host_impl_view.html"> |
| 13 | |
| 14 | <script src="/extras/chrome/cc/layer_tree_host_impl_test_data.js"></script> |
| 15 | |
| 16 | <script> |
| 17 | 'use strict'; |
| 18 | |
| 19 | tr.b.unittest.testSuite(function() { |
| 20 | test('instantiate', function() { |
| 21 | var m = new tr.Model(g_catLTHIEvents); |
| 22 | var p = tr.b.dictionaryValues(m.processes)[0]; |
| 23 | |
| 24 | var instance = p.objects.getAllInstancesNamed('cc::LayerTreeHostImpl')[0]; |
| 25 | var snapshot = instance.snapshots[0]; |
| 26 | |
| 27 | var view = new tr.ui.e.chrome.cc.LayerTreeHostImplSnapshotView(); |
| 28 | view.style.width = '900px'; |
| 29 | view.style.height = '400px'; |
| 30 | view.objectSnapshot = snapshot; |
| 31 | |
| 32 | this.addHTMLOutput(view); |
| 33 | }); |
| 34 | }); |
| 35 | </script> |