diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/LinkController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/LinkController.js index 0e7877a..005d5a9 100644 --- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/LinkController.js +++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/LinkController.js @@ -29,22 +29,40 @@ function ($scope, $rootScope, log, $location, pages, $routeParams) { for (var i = 0; i < $scope.links.length; i++) { if ($scope.links[i].modname == $routeParams.modname) { $rootScope.currentActiveModuleTitle = $scope.links[i].title; - if ($rootScope.currentActiveModuleTitle == "IP 10" || $rootScope.currentActiveModuleTitle == "A.D.A.M OnDemand") + if ($rootScope.currentActiveModuleTitle == "IP 10" ) { // document.getElementById('externalLink').style.height = "1024px"; - if ($uaAOD.match(/(iPod|iPhone|iPad|android)/i)) { - document.getElementById('externalLink').style.height = 2048 + "px"; - } - else { - document.getElementById('externalLink').style.height = $(window).outerHeight() - 128 + "px"; - } + document.getElementById('externalLink').style.height = $(window).outerHeight() - 41 + "px"; } $scope.objdata = $scope.links[i].objurl; - $scope.myObj = $scope.links[i].objstyle; - } + $scope.myObj = $scope.links[i].objstyle; + if ($('#externalLink').css('display') === 'none') + { + document.getElementById('externalLink').style.display = "block"; + document.getElementById('externalLinkiframe').style.display = "none"; + + } + + if ($rootScope.currentActiveModuleTitle == "A.D.A.M OnDemand") { + if ($uaAOD.match(/(iPod|iPhone|iPad)/i)) + { + document.getElementById('externalLink').style.display = "none"; + document.getElementById('externalLinkiframe').style.display = "block"; + document.getElementById('externalLinkiframe').style.height = $(window).outerHeight() - 128 + "px"; + document.getElementById("externalLinkiframe").src = $scope.objdata; + + } + + else { + document.getElementById('externalLink').style.height = $(window).outerHeight() - 128 + "px"; + + } + + } + } } }); diff --git a/400-SOURCECODE/AIAHTML5.Web/app/views/Link/Link-view.html b/400-SOURCECODE/AIAHTML5.Web/app/views/Link/Link-view.html index 0329f61..6f49a84 100644 --- a/400-SOURCECODE/AIAHTML5.Web/app/views/Link/Link-view.html +++ b/400-SOURCECODE/AIAHTML5.Web/app/views/Link/Link-view.html @@ -4,6 +4,9 @@