<!DOCTYPE HTML>
<html>
<!--
Copyright (c) 2010 The Chromium Authors. All rights reserved.
Use of this source code is governed by a BSD-style license that can be
found in the LICENSE file.
-->
<head i18n-values="dir:textdirection;">
<link rel="stylesheet" href="webui.css">
<style>
* {
  box-sizing: border-box;
}

html, body, #main-tabs {
  height: 100%;
}

body {
  cursor: default;
  font-family: sans-serif;
  padding: 0;
  margin: 0;
}

#debug-div {
  display: -webkit-box;
  position: fixed;
  top: 0px;
  left: 50%;
  border: 1px solid red;
}

</style>
<link rel="stylesheet" href="gpu_internals/info_view.css">
<link rel="stylesheet" href="gpu_internals/overlay.css">
<link rel="stylesheet" href="gpu_internals/profiling_view.css">
<link rel="stylesheet" href="gpu_internals/tab_control.css">
<link rel="stylesheet" href="gpu_internals/timeline_view.css">
<link rel="stylesheet" href="gpu_internals/timeline.css">
<link rel="stylesheet" href="gpu_internals/tracing_controller.css">
<script src="chrome://resources/js/cr.js"></script>
<script src="chrome://resources/js/cr/event_target.js"></script>
<script src="chrome://resources/js/cr/ui.js"></script>
<script src="chrome://resources/js/util.js"></script>
<script src="gpu_internals/tab_control.js"></script>
<script src="gpu_internals/overlay.js"></script>
<script src="gpu_internals/browser_bridge.js"></script>
<script src="gpu_internals/tracing_controller.js"></script>
<script src="gpu_internals/info_view.js"></script>
<script src="gpu_internals/timeline_model.js"></script>
<script src="gpu_internals/sorted_array_utils.js"></script>
<script src="gpu_internals/timeline.js"></script>
<script src="gpu_internals/timeline_track.js"></script>
<script src="gpu_internals/fast_rect_renderer.js"></script>
<script src="gpu_internals/profiling_view.js"></script>
<script src="gpu_internals/timeline_view.js"></script>

<script>
var browserBridge;
var tracingController;
var timelineView; // made global for debugging purposes only
var profilingView; // made global for debugging purposes only

/**
 * Main entry point. called once the page has loaded.
 */
function onLoad() {
  browserBridge = new gpu.BrowserBridge();
  tracingController = new gpu.TracingController();

  // Create the views.
  cr.ui.decorate('#info-view', gpu.InfoView);

  profilingView = $('profiling-view');
  cr.ui.decorate(profilingView, gpu.ProfilingView);

  // Create the main tab control
  var tabs = $('main-tabs');
  cr.ui.decorate(tabs, gpu.TabControl);

  // Sync the main-tabs selectedTabs in-sync with the location.
  tabs.addEventListener('selectedTabChange', function() {
    if (tabs.selectedTab.id) {
      history.pushState('', '', '#' + tabs.selectedTab.id);
    }
  });
  window.onhashchange = function() {
    var cur = window.location.hash;
    if (cur == '#' || cur == '') {
      if (tabs.tabs.length)
        tabs.selectedTab = tabs.tabs[0];
    } else {
      var tab = $(window.location.hash.substr(1));
      if (tab)
        tabs.selectedTab = tab;
    }
  };
  window.onhashchange();
}

document.addEventListener('DOMContentLoaded', onLoad);

</script>
</head>
<body>
  <div id="debug-div">
  </div>
  <!-- Tabs -->
  <div id="main-tabs">
    <include src="gpu_internals/info_view.html">
    <div id="profiling-view" label="Profiling"></div>
  </div>
</body>
</html>
