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

Side by Side Diff: runtime/bin/vmservice/client/lib/src/elements/script_inset.html

Issue 381383010: Add breakpoints and single-stepping to Observatory. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: fix bugs, gen js Created 6 years, 4 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
OLDNEW
1 <link rel="import" href="../../../../packages/polymer/polymer.html"> 1 <link rel="import" href="../../../../packages/polymer/polymer.html">
2 <link rel="import" href="observatory_element.html"> 2 <link rel="import" href="observatory_element.html">
3 3
4 <polymer-element name="script-inset" extends="observatory-element"> 4 <polymer-element name="script-inset" extends="observatory-element">
5 <template> 5 <template>
6 <style> 6 <style>
7 .sourceInset { 7 .sourceInset {
8 padding-left: 15%; 8 padding-left: 15%;
9 padding-right: 15%; 9 padding-right: 15%;
10 } 10 }
(...skipping 28 matching lines...) Expand all
39 background-color: #e66; 39 background-color: #e66;
40 } 40 }
41 .hitsExecuted { 41 .hitsExecuted {
42 background-color: #6d6; 42 background-color: #6d6;
43 } 43 }
44 </style> 44 </style>
45 <div class="sourceInset"> 45 <div class="sourceInset">
46 <content></content> 46 <content></content>
47 <div class="sourceBox" style="height:{{height}}"> 47 <div class="sourceBox" style="height:{{height}}">
48 <div class="sourceTable"> 48 <div class="sourceTable">
49 <template repeat="{{ line in lines }}"> 49 <template if="{{ linesReady }}">
50 <div class="sourceRow" id="{{ makeLineId(line.line) }}"> 50 <template repeat="{{ line in lines }}">
51 <template if="{{ line.hits == null }}"> 51 <div class="sourceRow" id="{{ makeLineId(line.line) }}">
52 <div class="hitsNone">{{ line.line }}</div> 52 <breakpoint-toggle line="{{ line }}"></breakpoint-toggle>
53 </template> 53
54 <template if="{{ line.hits == 0 }}"> 54 <div class="sourceItem">&nbsp;</div>
55 <div class="hitsNotExecuted">{{ line.line }}</div> 55
56 </template> 56 <template if="{{ line.hits == null ||
57 <template if="{{ line.hits > 0 }}"> 57 line.hits < 0 }}">
58 <div class="hitsExecuted">{{ line.line }}</div> 58 <div class="hitsNone">{{ line.line }}</div>
59 </template> 59 </template>
60 <div class="sourceItem">&nbsp;</div> 60 <template if="{{ line.hits == 0 }}">
61 <template if="{{ line.line == currentLine }}"> 61 <div class="hitsNotExecuted">{{ line.line }}</div>
62 <div id="currentLine" class="sourceItemCurrent">{{line.text}}</d iv> 62 </template>
63 </template> 63 <template if="{{ line.hits > 0 }}">
64 <template if="{{ line.line != currentLine }}"> 64 <div class="hitsExecuted">{{ line.line }}</div>
65 <div class="sourceItem">{{line.text}}</div> 65 </template>
66 </template> 66
67 <div class="sourceItem">&nbsp;</div>
68
69 <template if="{{ line.line == currentLine }}">
70 <div class="sourceItemCurrent">{{line.text}}</div>
71 </template>
72 <template if="{{ line.line != currentLine }}">
73 <div class="sourceItem">{{line.text}}</div>
74 </template>
75 </div>
76 </template>
77 </template>
78
79 <template if="{{ !linesReady }}">
80 <div class="sourceRow">
81 <div class="sourceItem">loading...</div>
67 </div> 82 </div>
68 </template> 83 </template>
69 </div> 84 </div>
70 </div> 85 </div>
71 </div> 86 </div>
72 </template> 87 </template>
73 </polymer-element> 88 </polymer-element>
74 89
90 <polymer-element name="breakpoint-toggle" extends="observatory-element">
91 <template>
92 <style>
93 .emptyBreakpoint, .possibleBreakpoint, .busyBreakpoint, .unresolvedBreakpo int, .resolvedBreakpoint {
94 display: table-cell;
95 vertical-align: top;
96 font: 400 14px consolas, courier, monospace;
97 min-width: 1em;
98 text-align: center;
99 cursor: pointer;
100 }
101 .possibleBreakpoint {
102 color: #e0e0e0;
103 }
104 .possibleBreakpoint:hover {
105 color: white;
106 background-color: #777;
107 }
108 .busyBreakpoint {
109 color: white;
110 background-color: black;
111 cursor: wait;
112 }
113 .unresolvedBreakpoint {
114 color: white;
115 background-color: #cac;
116 }
117 .resolvedBreakpoint {
118 color: white;
119 background-color: #e66;
120 }
121 </style>
122
123 <template if="{{ line.possibleBpt && busy}}">
124 <div class="busyBreakpoint">B</div>
125 </template>
126
127 <template if="{{ line.bpt == null && !line.possibleBpt }}">
128 <div class="emptyBreakpoint">&nbsp;</div>
129 </template>
130
131 <template if="{{ line.bpt == null && line.possibleBpt && !busy}}">
132 <div class="possibleBreakpoint">
133 <a on-click="{{ toggleBreakpoint }}">B</a>
134 </div>
135 </template>
136
137 <template if="{{ line.bpt != null && !line.bpt['resolved'] && !busy}}">
138 <div class="unresolvedBreakpoint">
139 <a on-click="{{ toggleBreakpoint }}">B</a>
140 </div>
141 </template>
142
143 <template if="{{ line.bpt != null && line.bpt['resolved'] && !busy}}">
144 <div class="resolvedBreakpoint">
145 <a on-click="{{ toggleBreakpoint }}">B</a>
146 </div>
147 </template>
148
149 </template>
150 </polymer-element>
151
75 <script type="application/dart" src="script_inset.dart"></script> 152 <script type="application/dart" src="script_inset.dart"></script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698