Skip to content

Commit

Permalink
chrome 48 fix to dagre-d3
Browse files Browse the repository at this point in the history
dagrejs/dagre-d3#202

Change-Id: Ic9450e8eef55af2778e2cea571f6e174841d5f43
  • Loading branch information
Alon Heller committed Mar 13, 2016
1 parent b15019b commit d94471a
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
</thead>
<tbody>
<tr ng-repeat="alarm in alarmList.ialarms track by $index">
<td title="{$ alarm.normalized_severity $}"><i class="fa" ng-class="{'orange fa-exclamation-triangle': alarm.normalized_severity == 'SEVER', 'orange fa-exclamation-triangle': alarm.normalized_severity == 'WARNING', 'red fa-exclamation-circle': alarm.normalized_severity == 'CRITICAL', 'green fa-check': alarm.normalized_severity == 'DISABLED', 'gray fa-circle-o-notch': alarm.normalized_severity == 'UNKNOWN'}"></i></td>
<td title="{$ alarm.normalized_severity $}"><i class="fa" ng-class="{'orange fa-exclamation-triangle': alarm.normalized_severity == 'SEVER' || alarm.normalized_severity == 'SEVERE', 'orange fa-exclamation-triangle': alarm.normalized_severity == 'WARNING', 'red fa-exclamation-circle': alarm.normalized_severity == 'CRITICAL', 'green fa-check': alarm.normalized_severity == 'DISABLED', 'gray fa-circle-o-notch': alarm.normalized_severity == 'UNKNOWN'}"></i></td>
<td><i class="fa fa-clock-o"></i> {$alarm.update_timestamp | date:"h:mm a"$} </td>
<td>{$alarm.name$}</td>
<td>{$alarm.resource_type$}</td>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ <h1>{$ 'Alarms' | translate $}</h1>
<li class="list-group-item" ng-click="alarmsCtrl.onAlarmClick(alarm)">
<h4 class="list-group-item-heading">{$alarm.name$}</h4>
<p class="list-group-item-text">
<span title="{$ alarm.normalized_severity $}"><i class="fa" ng-class="{'orange fa-exclamation-triangle': alarm.normalized_severity == 'SEVER', 'orange fa-exclamation-triangle': alarm.normalized_severity == 'WARNING', 'red fa-exclamation-circle': alarm.normalized_severity == 'CRITICAL', 'green fa-check': alarm.normalized_severity == 'DISABLED', 'gray fa-circle-o-notch': alarm.normalized_severity == 'UNKNOWN'}"></i></span>
<span title="{$ alarm.normalized_severity $}"><i class="fa" ng-class="{'orange fa-exclamation-triangle': alarm.normalized_severity == 'SEVER' || alarm.normalized_severity == 'SEVERE', 'orange fa-exclamation-triangle': alarm.normalized_severity == 'WARNING', 'red fa-exclamation-circle': alarm.normalized_severity == 'CRITICAL', 'green fa-check': alarm.normalized_severity == 'DISABLED', 'gray fa-circle-o-notch': alarm.normalized_severity == 'UNKNOWN'}"></i></span>
{$alarm.severity$} |
{$alarm.update_timestamp | date:"h:mma"$}
</p>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,7 @@ function hzRootCauseAnalysisGraph($filter) {
break;
case 'ACTIVE_WARNING':
case 'ACTIVE_SEVER':
case 'ACTIVE_SEVERE':
html += '<img src="' + STATIC_URL + 'dashboard/project/assets/bell_orange_on.svg" style="width: 80px; height: 80px; padding-top: 10px;float: left;">';
break;
case 'ACTIVE_DISABLED':
Expand All @@ -137,6 +138,7 @@ function hzRootCauseAnalysisGraph($filter) {
html += '<img src="' + STATIC_URL + 'dashboard/project/assets/bell_red_off.svg" style="width: 80px; height: 80px; padding-top: 10px;float: left;">';
break;
case 'INACTIVE_WARNING':
case 'INACTIVE_SEVER':
case 'INACTIVE_SEVER':
html += '<img src="' + STATIC_URL + 'dashboard/project/assets/bell_orange_off.svg" style="width: 80px; height: 80px; padding-top: 10px;float: left;">';
break;
Expand Down Expand Up @@ -217,7 +219,6 @@ function hzRootCauseAnalysisGraph($filter) {
}

scope.$watch("data", function (newValue, oldValue) {
console.log('data watch');
if (scope.data) {
createGraph();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -226,7 +226,9 @@ function createLine(edge, points) {

function getCoords(elem) {
var bbox = elem.getBBox(),
matrix = elem.getTransformToElement(elem.ownerSVGElement)
matrix = elem.ownerSVGElement.getScreenCTM()
.inverse()
.multiply(elem.getScreenCTM())
.translate(bbox.width / 2, bbox.height / 2);
return { x: matrix.e, y: matrix.f };
}
Expand Down

0 comments on commit d94471a

Please sign in to comment.