Commit 10dfe909294d9350c345eb9b8bc51347d62ad73e
1 parent
8a21167f
removed flush canvas and added to remove all elements of canavsDIv on view change
Showing
1 changed file
with
6 additions
and
2 deletions
400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js
@@ -6868,8 +6868,12 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo | @@ -6868,8 +6868,12 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo | ||
6868 | $scope.layerNumber = 0; | 6868 | $scope.layerNumber = 0; |
6869 | 6869 | ||
6870 | //remove existing body view | 6870 | //remove existing body view |
6871 | - $scope.flushCanvas(); | ||
6872 | - | 6871 | + // $scope.flushCanvas(); |
6872 | + var canDiv = document.getElementById('canvasDiv'); | ||
6873 | + var canDivChildCount = canDiv.childElementCount; | ||
6874 | + if (canDivChildCount > 0) { | ||
6875 | + canDiv.innerHTML = ''; | ||
6876 | + } | ||
6873 | 6877 | ||
6874 | var selectedViewId = $scope.bodyViews[event.currentTarget.title]; | 6878 | var selectedViewId = $scope.bodyViews[event.currentTarget.title]; |
6875 | $rootScope.viewOrientationId = selectedViewId; | 6879 | $rootScope.viewOrientationId = selectedViewId; |