diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/3dAController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/3dAController.js index 26ba7f8..a48c0b3 100644 --- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/3dAController.js +++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/3dAController.js @@ -12,8 +12,8 @@ function ($scope, $rootScope, pages, log, $http, DataService, $filter, $location 'parentSlugName': '', 'currentSlug': '', 'imageId': '', - 'top': 0, - 'left': 0, + 'y': 0, + 'x': 0, 'width': 0, 'height': 0, 'minimised': false, @@ -226,7 +226,8 @@ function ($scope, $rootScope, pages, log, $http, DataService, $filter, $location "id": $event.currentTarget.id, "mType": 'THREE_D_ANATOMY', "windowTitle": $event.currentTarget.textContent, - "size": { height: 600, width: 900 } + "size": { height: 600, width: 900 }, + "position": { x: 300, y: 110 } }; window.parent.AIAModuleOpenResourceInfo(ThreeDopenData); @@ -405,10 +406,15 @@ function ($scope, $rootScope, pages, log, $http, DataService, $filter, $location $scope.jsPanelHeight = $scope.ThreeDOpenInOtherModules.size.height; if ($scope.ThreeDOpenInOtherModules.size.height > 560) $scope.jsPanelHeight = 560; - $scope.jsPanelLeft = 320; - $scope.jsPanelTop = $rootScope.cBModulejsPanelTop(); + + $scope.jsPanelLeft = $scope.ThreeDOpenInOtherModules.position.x; + if ($scope.ThreeDOpenInOtherModules.position.x < 20) + $scope.jsPanelLeft = 20; + $scope.jsPanelTop = $scope.ThreeDOpenInOtherModules.position.y; + if($location.url()!= "/curriculum-builder-detail") { $scope.jsPanelLeft = 1; + $scope.jsPanelTop = $rootScope.cBModulejsPanelTop(); } } @@ -428,8 +434,8 @@ function ($scope, $rootScope, pages, log, $http, DataService, $filter, $location theme: 'success', currentController: '3dAController', parentSlug: $scope.Get3DwindowStoreData(windowviewid, 'parentSlugName'), - content: '
' + - '' + + content: '
' + + '' + '
', title: tittle, position: { @@ -441,6 +447,18 @@ function ($scope, $rootScope, pages, log, $http, DataService, $filter, $location width: $scope.jsPanelWidth, height: $scope.jsPanelHeight }, + onminimized:function (panel) { + $scope.Set3DwindowStoreData(windowviewid, 'minimised',true); + $scope.Set3DwindowStoreData(windowviewid, 'maximised',false); + }, + onmaximized:function (panel) { + $scope.Set3DwindowStoreData(windowviewid, 'maximised',true); + $scope.Set3DwindowStoreData(windowviewid, 'minimised',false); + }, + onnormalized:function (panel) { + $scope.Set3DwindowStoreData(windowviewid, 'minimised',false); + $scope.Set3DwindowStoreData(windowviewid, 'maximised',false); + } }); @@ -455,8 +473,8 @@ function ($scope, $rootScope, pages, log, $http, DataService, $filter, $location else { $scope.jsPanel3D.normalize(); } - $scope.Set3DwindowStoreData(windowviewid, 'top', $scope.jsPanelTop); - $scope.Set3DwindowStoreData(windowviewid, 'left', $scope.jsPanelLeft); + $scope.Set3DwindowStoreData(windowviewid, 'y', $scope.jsPanelTop); + $scope.Set3DwindowStoreData(windowviewid, 'x', $scope.jsPanelLeft); $scope.Set3DwindowStoreData(windowviewid, 'width', $scope.jsPanelWidth); $scope.Set3DwindowStoreData(windowviewid, 'height', $scope.jsPanelHeight); @@ -563,7 +581,7 @@ function ($scope, $rootScope, pages, log, $http, DataService, $filter, $location $('#' + panelid).remove(); } - $rootScope.resetjsPanelTop(panelid); + // $rootScope.resetjsPanelTop(panelid); } } } @@ -588,8 +606,8 @@ function ($scope, $rootScope, pages, log, $http, DataService, $filter, $location var len = (event.currentTarget.id).split("_").length; var windowviewid = (event.currentTarget.id).split("_")[len - 1]; //var offSets = $(this).offset(); var postions = (this).position(); (this).offsetTop (this).offsetLeft - $scope.Set3DwindowStoreData(windowviewid, 'top', ui.position.top); - $scope.Set3DwindowStoreData(windowviewid, 'left', ui.position.left); + $scope.Set3DwindowStoreData(windowviewid, 'y', ui.position.top); + $scope.Set3DwindowStoreData(windowviewid, 'x', ui.position.left); } }); diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/AIController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/AIController.js index 52cac7c..a4f70cd 100644 --- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/AIController.js +++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/AIController.js @@ -72,8 +72,8 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout 'currentSlug': '', 'imageId': '', 'imageName': '', - 'top': 0, - 'left': 0, + 'y': 0, + 'x': 0, 'width': 0, 'height': 0, 'minimised': false, @@ -206,7 +206,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout $('#' + panelid).remove(); } - $rootScope.resetjsPanelTop(panelid); + // $rootScope.resetjsPanelTop(panelid); } } } @@ -226,8 +226,8 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout stop: function (event, ui) { var len = (event.currentTarget.id).split("_").length; var windowviewid = (event.currentTarget.id).split("_")[len - 1]; - $scope.SetAIwindowStoreData(windowviewid, 'top', ui.position.top); - $scope.SetAIwindowStoreData(windowviewid, 'left', ui.position.left); + $scope.SetAIwindowStoreData(windowviewid, 'y', ui.position.top); + $scope.SetAIwindowStoreData(windowviewid, 'x', ui.position.left); } }); @@ -988,7 +988,8 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout "id": $event.currentTarget.id, "mType": 'ADAM_IMAGES', "windowTitle": $rootScope.ViewTitle, - "size": { height: 600, width: 900 } + "size": { height: 600, width: 900 }, + "position": { x: 300, y: 110 } }; window.parent.AIAModuleOpenResourceInfo(AIDopenData); @@ -1172,10 +1173,15 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout $scope.jsPanelHeight = $scope.aiOpenInOtherModules.size.height; if ($scope.aiOpenInOtherModules.size.height > 540) $scope.jsPanelHeight = 540; - $scope.jsPanelLeft = 320; - $scope.jsPanelTop = $rootScope.cBModulejsPanelTop(); + + $scope.jsPanelLeft = $scope.aiOpenInOtherModules.position.x; + if ($scope.aiOpenInOtherModules.position.x < 20) + $scope.jsPanelLeft = 20; + $scope.jsPanelTop = $scope.aiOpenInOtherModules.position.y; + if($location.url()!= "/curriculum-builder-detail") { $scope.jsPanelLeft = 1; + $scope.jsPanelTop = $rootScope.cBModulejsPanelTop(); } } else { @@ -1192,9 +1198,9 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout theme: 'success', currentController: 'AIController', parentSlug: $scope.GetAIwindowStoreData(windowviewid, 'parentSlugName'), - content: '
' + + content: '
' + '
' + - '' + + '' + '
', @@ -1208,6 +1214,18 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout width: $scope.jsPanelWidth, height: $scope.jsPanelHeight }, + onminimized:function (panel) { + $scope.SetAIwindowStoreData(windowviewid, 'minimised',true); + $scope.SetAIwindowStoreData(windowviewid, 'maximised',false); + }, + onmaximized:function (panel) { + $scope.SetAIwindowStoreData(windowviewid, 'maximised',true); + $scope.SetAIwindowStoreData(windowviewid, 'minimised',false); + }, + onnormalized:function (panel) { + $scope.SetAIwindowStoreData(windowviewid, 'minimised',false); + $scope.SetAIwindowStoreData(windowviewid, 'maximised',false); + } }); @@ -1223,8 +1241,8 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout else { $scope.jsPanelAI.normalize(); } - $scope.SetAIwindowStoreData(windowviewid, 'top', $scope.jsPanelTop); - $scope.SetAIwindowStoreData(windowviewid, 'left', $scope.jsPanelLeft); + $scope.SetAIwindowStoreData(windowviewid, 'y', $scope.jsPanelTop); + $scope.SetAIwindowStoreData(windowviewid, 'x', $scope.jsPanelLeft); $scope.SetAIwindowStoreData(windowviewid, 'width', $scope.jsPanelWidth); $scope.SetAIwindowStoreData(windowviewid, 'height', $scope.jsPanelHeight); $scope.EnableUI(); @@ -1233,8 +1251,13 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout var canvas = document.getElementById("canvasAI_" + windowviewid); var canvasPaint = document.getElementById("canvasPaintAI_" + windowviewid); - canvas.height = $("#" + $scope.jsPanelID + " .jsPanel-content").height(); - canvasPaint.height = $("#" + $scope.jsPanelID + " .jsPanel-content").height(); + var canvasDIvHeight = $("#" + $scope.jsPanelID + " .jsPanel-content").height(); + + $('#canvasDivAI_' + windowviewid).css('height', canvasDIvHeight); + $("#" + $scope.jsPanelID + " .img-thumbnail").css("height", canvasDIvHeight); + + canvas.height = canvasDIvHeight; + canvasPaint.height = canvasDIvHeight; if ($rootScope.isCallFromOtherModule) { var annotationData= $scope.aiOpenInOtherModules.annotationData; // load annotation @@ -1258,7 +1281,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout "slug": $scope.GetAIwindowStoreData(windowviewid, 'currentSlug') }); - $("#" + $scope.jsPanelID + " .img-thumbnail").css("min-height", $("#" + $scope.jsPanelID + " .jsPanel-content").height()); + $('.jsPanel-content .jsPanel-theme-success').css('overflow-y', 'auto !important') // console.log($rootScope.OpenAdamImages); @@ -1266,9 +1289,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout $('#AIView').css("width", $(window).outerWidth() - 15); - var canvasDIvHeight = $("#" + $scope.jsPanelID + " .jsPanel-content").height(); - - $('#canvasDivCI_' + windowviewid).css('height', canvasDIvHeight); + } $scope.PanelActivity(); } diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/CAController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/CAController.js index c90a18f..c09ef96 100644 --- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/CAController.js +++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/CAController.js @@ -42,8 +42,8 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout 'clickedCASummary': '', 'hostedFolderId': '', 'isTextVisible': true, - 'top': 0, - 'left': 0, + 'y': 0, + 'x': 0, 'width': 0, 'height': 0, 'minimised': false, @@ -681,7 +681,8 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout "mType": 'CLINICAL_ANIMATIONS', "textVisible": true, "windowTitle": $rootScope.ViewTitle, - "size": { height: 600, width: 900 } + "size": { height: 600, width: 900 }, + "position": { x: 300, y: 110 } }; window.parent.AIAModuleOpenResourceInfo(CADopenData); @@ -908,10 +909,15 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout $scope.jsPanelHeight = $scope.caOpenInOtherModules.size.height; if ($scope.caOpenInOtherModules.size.height > 510) $scope.jsPanelHeight = 510; - $scope.jsPanelLeft = 320; - $scope.jsPanelTop = $rootScope.cBModulejsPanelTop(); + + $scope.jsPanelLeft = $scope.caOpenInOtherModules.position.x; + if ($scope.caOpenInOtherModules.position.x < 20) + $scope.jsPanelLeft = 20; + $scope.jsPanelTop = $scope.caOpenInOtherModules.position.y; + if($location.url()!= "/curriculum-builder-detail") { $scope.jsPanelLeft = 1; + $scope.jsPanelTop = $rootScope.cBModulejsPanelTop(); } } @@ -936,7 +942,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout currentController: 'CAController', parentSlug: $scope.GetCAwindowStoreData(windowviewid, 'parentSlugName'), content: '' + - '
', + ' Here we are

' + clickedCASummary + '

', title: tittle, position: { @@ -963,6 +969,18 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout width: $scope.jsPanelWidth, height: $scope.jsPanelHeight }, + onminimized:function (panel) { + $scope.SetCAwindowStoreData(windowviewid, 'minimised',true); + $scope.SetCAwindowStoreData(windowviewid, 'maximised',false); + }, + onmaximized:function (panel) { + $scope.SetCAwindowStoreData(windowviewid, 'maximised',true); + $scope.SetCAwindowStoreData(windowviewid, 'minimised',false); + }, + onnormalized:function (panel) { + $scope.SetCAwindowStoreData(windowviewid, 'minimised',false); + $scope.SetCAwindowStoreData(windowviewid, 'maximised',false); + } }); @@ -978,8 +996,8 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout else { $scope.jsPanelCA.normalize(); } - $scope.SetCAwindowStoreData(windowviewid, 'top', $scope.jsPanelTop); - $scope.SetCAwindowStoreData(windowviewid, 'left', $scope.jsPanelLeft); + $scope.SetCAwindowStoreData(windowviewid, 'y', $scope.jsPanelTop); + $scope.SetCAwindowStoreData(windowviewid, 'x', $scope.jsPanelLeft); $scope.SetCAwindowStoreData(windowviewid, 'width', $scope.jsPanelWidth); $scope.SetCAwindowStoreData(windowviewid, 'height', $scope.jsPanelHeight); @@ -992,13 +1010,14 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout }); - var jspContentHeight = $('.jsPanel-content').height(); - var videoHeight = $('#divplayerinlineVideo_'+ windowviewid +' div').height(); - if (videoHeight <= 0) - videoHeight = 360; + var canvasDIvHeight = $("#" + $scope.jsPanelID + " .jsPanel-content").height(); + $('#playerinlineVideo_'+ windowviewid ).css("height",canvasDIvHeight-120 ); + + var videoHeight = $('#playerinlineVideo_'+ windowviewid ).height(); + var textH = $('.video-subtitle').height(); textH = textH + 40; - var blackBorderHeight = jspContentHeight - (videoHeight + textH); + var blackBorderHeight = canvasDIvHeight - (videoHeight + textH); if ($('.jsPanel-content').length > 0) { $('.video-subtitle').css('margin-bottom', blackBorderHeight); @@ -1137,7 +1156,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout $('#' + panelid).remove(); } - $rootScope.resetjsPanelTop(panelid); + // $rootScope.resetjsPanelTop(panelid); } } } @@ -1163,8 +1182,8 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout var len = (event.currentTarget.id).split("_").length; var windowviewid = (event.currentTarget.id).split("_")[len - 1]; //var offSets = $(this).offset(); var postions = (this).position(); (this).offsetTop (this).offsetLeft - $scope.SetCAwindowStoreData(windowviewid, 'top', ui.position.top); - $scope.SetCAwindowStoreData(windowviewid, 'left', ui.position.left); + $scope.SetCAwindowStoreData(windowviewid, 'y', ui.position.top); + $scope.SetCAwindowStoreData(windowviewid, 'x', ui.position.left); } }); diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/CIController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/CIController.js index 685c878..088deb8 100644 --- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/CIController.js +++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/CIController.js @@ -51,8 +51,8 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout 'imageId': '', 'imageName': '', 'isTextVisible': true, - 'top': 0, - 'left': 0, + 'y': 0, + 'x': 0, 'width': 0, 'height': 0, 'minimised': false, @@ -688,7 +688,8 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout "mType": 'CLINICAL_ILLUSTRATIONS', "textVisible": true, "windowTitle": $rootScope.ViewTitle, - "size": { height: 500, width: 900 } + "size": { height: 500, width: 900 }, + "position": { x: 300, y: 110 } }; window.parent.AIAModuleOpenResourceInfo(CIDopenData); @@ -877,10 +878,15 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout $scope.jsPanelHeight = $scope.ciOpenInOtherModules.size.height; if ($scope.ciOpenInOtherModules.size.height > 540) $scope.jsPanelHeight = 540; - $scope.jsPanelLeft = 320; - $scope.jsPanelTop = $rootScope.cBModulejsPanelTop(); + + $scope.jsPanelLeft = $scope.ciOpenInOtherModules.position.x; + if ($scope.ciOpenInOtherModules.position.x < 20) + $scope.jsPanelLeft = 20; + $scope.jsPanelTop = $scope.ciOpenInOtherModules.position.y; + if($location.url()!= "/curriculum-builder-detail") { $scope.jsPanelLeft = 1; + $scope.jsPanelTop = $rootScope.cBModulejsPanelTop(); } } @@ -897,9 +903,9 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout theme: 'success', currentController: 'CIController', parentSlug: $scope.GetCIwindowStoreData(windowviewid, 'parentSlugName'), - content: '
' + + content: '
' + '
' + - '
' + + '
' + '

' + selectedImageCISummary + '

' + '
' + '
', @@ -913,6 +919,18 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout width: $scope.jsPanelWidth, height: $scope.jsPanelHeight }, + onminimized:function (panel) { + $scope.SetCIwindowStoreData(windowviewid, 'minimised',true); + $scope.SetCIwindowStoreData(windowviewid, 'maximised',false); + }, + onmaximized:function (panel) { + $scope.SetCIwindowStoreData(windowviewid, 'maximised',true); + $scope.SetCIwindowStoreData(windowviewid, 'minimised',false); + }, + onnormalized:function (panel) { + $scope.SetCIwindowStoreData(windowviewid, 'minimised',false); + $scope.SetCIwindowStoreData(windowviewid, 'maximised',false); + } }); @@ -927,8 +945,8 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout else { $scope.jsPanelCI.normalize(); } - $scope.SetCIwindowStoreData(windowviewid, 'top', $scope.jsPanelTop); - $scope.SetCIwindowStoreData(windowviewid, 'left', $scope.jsPanelLeft); + $scope.SetCIwindowStoreData(windowviewid, 'y', $scope.jsPanelTop); + $scope.SetCIwindowStoreData(windowviewid, 'x', $scope.jsPanelLeft); $scope.SetCIwindowStoreData(windowviewid, 'width', $scope.jsPanelWidth); $scope.SetCIwindowStoreData(windowviewid, 'height', $scope.jsPanelHeight); @@ -943,7 +961,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout $("#" + $scope.jsPanelID + " .img-thumbnail").css("height", $("#" + $scope.jsPanelID + " .jsPanel-content").height()); - + if (!$rootScope.isCallFromOtherModule) { $('#CIView').css("height", $(window).outerHeight() - 65); @@ -966,7 +984,12 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout $scope.EnableUI(); $rootScope.isLoading = false; $('#spinner').css('visibility', 'hidden'); - + var imgheight= $("#" + $scope.jsPanelID + " .img-thumbnail img").height(); + var canvas = document.getElementById("canvasCI_" + windowviewid); + var canvasPaint = document.getElementById("canvasPaintCI_" + windowviewid); + canvas.height = imgheight; + canvasPaint.height = imgheight; + $scope.JsPanelclick(windowviewid); var isTextVisible = $scope.GetCIwindowStoreData(windowviewid, 'isTextVisible'); @@ -1105,7 +1128,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout $('#' + panelid).remove(); } - $rootScope.resetjsPanelTop(panelid); + // $rootScope.resetjsPanelTop(panelid); } } } @@ -1129,8 +1152,8 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout var len = (event.currentTarget.id).split("_").length; var windowviewid = (event.currentTarget.id).split("_")[len - 1]; //var offSets = $(this).offset(); var postions = (this).position(); (this).offsetTop (this).offsetLeft - $scope.SetCIwindowStoreData(windowviewid, 'top', ui.position.top); - $scope.SetCIwindowStoreData(windowviewid, 'left', ui.position.left); + $scope.SetCIwindowStoreData(windowviewid, 'y', ui.position.top); + $scope.SetCIwindowStoreData(windowviewid, 'x', ui.position.left); } }); diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/CurrBuildController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/CurrBuildController.js index 64b1fd9..71b63c3 100644 --- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/CurrBuildController.js +++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/CurrBuildController.js @@ -30,13 +30,27 @@ function ($scope, $rootScope, pages, log, Modules, $http, $compile, $location, $ angular.element(document).ready(function (e) { + $("#treecontent").css('height',screen.height-250); + $("#cbdivarea").css('height',screen.height-155); + + $('#sidebar-wrapper').unbind('click'); $("#sidebar-wrapper").on('click', function (event) { //4. on click disable menu option $rootScope.resetMenuOptionOnClick("CBTinyMCEPanel"); }); - + $(".toggle-icon").on('click', function (event) { + + if ($('.CBLeft-Sidebar').hasClass('active')) { + $(".CB-JS-Panel").css('margin-left','0px'); + } + else{ + $(".CB-JS-Panel").css('margin-left','285px'); + } + + }); + // close all selected open panel in CB $(document).on("click", " .jsPanel-hdr .jsPanel-hdr-r .jsPanel-btn-close .jsglyph-remove", function () { @@ -551,8 +565,12 @@ function ($scope, $rootScope, pages, log, Modules, $http, $compile, $location, $ }); $timeout(function () { - $rootScope.resetMenuOptionOnClick("CBTinyMCEPanel"); - }, 200); + $rootScope.resetMenuOptionOnClick("CBTinyMCEPanel"); + $("#CBTinyMCEPanel").resize(function(){ + $("#CBTextArea_ifr").css("display", "block"); + }); + + }, 200); } @@ -627,6 +645,9 @@ function ($scope, $rootScope, pages, log, Modules, $http, $compile, $location, $ $("#viwerSelect").hide(); if ($('#cbparentcustomDiv').html() != "") { $('#cbparentcustomDiv').empty(); + } + if ($('#jsPanel-min-container').html() != "") { + $('#jsPanel-min-container').empty(); } if ($scope.nodeTypeIsBranch == "false") { @@ -2529,7 +2550,7 @@ function ($scope, $rootScope, pages, log, Modules, $http, $compile, $location, $ //var selectedText = $("#viwerSelect option:selected").text(); var selected_Id = $("#viwerSelect option:selected").val(); if (selected_Id != "0") { - $('body,html').animate({ scrollTop: $('#' + selected_Id).position().top }, 500); + $('#cbdivarea').animate({ scrollTop: $('#' + selected_Id).position().top }, 500); } } @@ -2572,8 +2593,8 @@ function ($scope, $rootScope, pages, log, Modules, $http, $compile, $location, $ containsCapturedContent: true, contextMenu: { lockResize: false, hideToolBar: false, hideTitleBar: false }, position: { - top: $rootScope.LEWindowData[i].top, - left: $rootScope.LEWindowData[i].left, + y: $rootScope.LEWindowData[i].y, + x: $rootScope.LEWindowData[i].x, }, size: { height: $rootScope.LEWindowData[i].height, @@ -2605,8 +2626,8 @@ function ($scope, $rootScope, pages, log, Modules, $http, $compile, $location, $ annotationData: $rootScope.AIWindowData[i].annotationData, contextMenu: { lockResize: false, hideTitleBar: false }, position: { - top: $rootScope.AIWindowData[i].top, - left: $rootScope.AIWindowData[i].left, + y: $rootScope.AIWindowData[i].y, + x: $rootScope.AIWindowData[i].x, }, size: { height: $rootScope.AIWindowData[i].height, @@ -2638,8 +2659,8 @@ function ($scope, $rootScope, pages, log, Modules, $http, $compile, $location, $ annotationData: $rootScope.CIWindowData[i].annotationData,//$rootScope.CIWindowData[i] N contextMenu: { lockResize: false, hideTitleBar: false }, // N position: { - top: $rootScope.CIWindowData[i].top, - left: $rootScope.CIWindowData[i].left, + y: $rootScope.CIWindowData[i].y, + x: $rootScope.CIWindowData[i].x, }, size: { height: $rootScope.CIWindowData[i].height, @@ -2673,8 +2694,8 @@ function ($scope, $rootScope, pages, log, Modules, $http, $compile, $location, $ //annotationData: "",//$rootScope.CAWindowData[i] N contextMenu: { lockResize: false, hideToolBar: false, hideTitleBar: false },//N position: { - top: $rootScope.CAWindowData[i].top, - left: $rootScope.CAWindowData[i].left, + y: $rootScope.CAWindowData[i].y, + x: $rootScope.CAWindowData[i].x, }, size: { height: $rootScope.CAWindowData[i].height, @@ -2707,8 +2728,8 @@ function ($scope, $rootScope, pages, log, Modules, $http, $compile, $location, $ //annotationData: "",//$rootScope.TheeDWindowData[i] N contextMenu: { lockResize: true, hideTitleBar: true, hideToolBar: false, hideLeftBar: false, hideTopToolBar: false }, position: { - top: $rootScope.TheeDWindowData[i].top, - left: $rootScope.TheeDWindowData[i].left, + y: $rootScope.TheeDWindowData[i].y, + x: $rootScope.TheeDWindowData[i].x, }, size: { height: $rootScope.TheeDWindowData[i].height, @@ -2743,8 +2764,8 @@ function ($scope, $rootScope, pages, log, Modules, $http, $compile, $location, $ annotationData: $rootScope.PICWindowData[i].annotationData, contextMenu: { lockResize: true, hideTitleBar: true }, position: { - top: $rootScope.PICWindowData[i].top, - left: $rootScope.PICWindowData[i].left, + y: $rootScope.PICWindowData[i].y, + x: $rootScope.PICWindowData[i].x, }, size: { height: $rootScope.PICWindowData[i].height, @@ -2771,7 +2792,7 @@ function ($scope, $rootScope, pages, log, Modules, $http, $compile, $location, $ $scope.saveMyAnimationWindowActivity = function (isNotSaved,slideId) { if ($rootScope.VideoWindowData != undefined && $rootScope.VideoWindowData.length > 0) { for (var i = 0; i < $rootScope.VideoWindowData.length; i++) { - var isSourceExist = $rootScope.VideoWindowData[i].isSourceExist; + var isSourceExist = $rootScope.VideoWindowData[i].yisSourceExist; if(isSourceExist==true) { var imageId = $rootScope.VideoWindowData[i].imageId; @@ -2795,8 +2816,8 @@ function ($scope, $rootScope, pages, log, Modules, $http, $compile, $location, $ containsCapturedContent: true, contextMenu: { lockResize: false, hideToolBar: false, hideTitleBar: false }, position: { - top: $rootScope.VideoWindowData[i].top, - left: $rootScope.VideoWindowData[i].left, + y: $rootScope.VideoWindowData[i].y, + x: $rootScope.VideoWindowData[i].x, }, size: { height: $rootScope.VideoWindowData[i].height, @@ -2852,8 +2873,8 @@ function ($scope, $rootScope, pages, log, Modules, $http, $compile, $location, $ imageId: $rootScope.AAWindowData[i].imageId, //position: { x: 840, y: 263 }, position: { - top: $rootScope.AAWindowData[i].top, - left: $rootScope.AAWindowData[i].left, + y: $rootScope.AAWindowData[i].y, + x: $rootScope.AAWindowData[i].x, }, mType: $rootScope.AAWindowData[i].moduleName, containsCapturedContent: true, @@ -2907,8 +2928,8 @@ function ($scope, $rootScope, pages, log, Modules, $http, $compile, $location, $ imageId: $rootScope.DaWindowData[i].imageId, position: { - top: $rootScope.DaWindowData[i].top, - left: $rootScope.DaWindowData[i].left, + y: $rootScope.DaWindowData[i].y, + x: $rootScope.DaWindowData[i].x, }, mType: $rootScope.DaWindowData[i].moduleName, containsCapturedContent: true, diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js index 443fbed..d2f940e 100644 --- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js +++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js @@ -128,8 +128,8 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l 'updatedGrayDataList':[], 'updatedGrayMRDataList':[], 'SearchTimeStampValue': 0, - 'top': 0, - 'left': 0, + 'y': 0, + 'x': 0, 'width': 0, 'height': 0, 'minimised': false, @@ -512,6 +512,7 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l "windowTitle": $event.currentTarget.textContent, "zoom": 75, "size":{height:600,width:900}, + "position": { x: 300, y: 110 }, "mType": 'DISSECTIBLE_ANATOMY', "isModestyOn":userModestysettings, "skinId": userEthnicity, @@ -918,34 +919,37 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l if ($rootScope.isCallFromOtherModule) { if($rootScope.cernerIntegrationActive) { - $rootScope.jsPanelWidth = $(window).outerWidth() - 20; - $rootScope.jsPanelHeight = $(window).outerHeight() - 110; - $rootScope.jsPanelLeft = 1; - $rootScope.jsPanelTop = 70; + $scope.jsPanelWidth = $(window).outerWidth() - 20; + $scope.jsPanelHeight = $(window).outerHeight() - 110; + $scope.jsPanelLeft = 1; + $scope.jsPanelTop = 70; $rootScope.cernerIntegrationActive=false; } else { // open JS panel for curriculum with define cornonate in CB jason - $rootScope.jsPanelWidth = $scope.daOpenInOtherModules.size.width;//1000; - $rootScope.jsPanelHeight = $scope.daOpenInOtherModules.size.height; + $scope.jsPanelWidth = $scope.daOpenInOtherModules.size.width;//1000; + $scope.jsPanelHeight = $scope.daOpenInOtherModules.size.height; if($scope.daOpenInOtherModules.size.height<450) - $rootScope.jsPanelHeight = 450; + $scope.jsPanelHeight = 450; - $rootScope.jsPanelLeft = 320; - - $rootScope.jsPanelTop = $rootScope.cBModulejsPanelTop(); + $scope.jsPanelLeft = $scope.daOpenInOtherModules.position.x; + if ($scope.daOpenInOtherModules.position.x < 20) + $scope.jsPanelLeft = 20; + $scope.jsPanelTop = $scope.daOpenInOtherModules.position.y; + if($location.url()!= "/curriculum-builder-detail") { - $rootScope.jsPanelLeft = 1; + $scope.jsPanelLeft = 1; + $scope.jsPanelTop = $rootScope.cBModulejsPanelTop(); } } } else { - $rootScope.jsPanelWidth = $(window).outerWidth() - 20; - $rootScope.jsPanelHeight = $(window).outerHeight() - 110; - $rootScope.jsPanelLeft = 1; - $rootScope.jsPanelTop = 70; + $scope.jsPanelWidth = $(window).outerWidth() - 20; + $scope.jsPanelHeight = $(window).outerHeight() - 110; + $scope.jsPanelLeft = 1; + $scope.jsPanelTop = 70; } $scope.jsPanelDA = $.jsPanel({ @@ -960,14 +964,26 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l title: currentViewTitle, position: { - top: $rootScope.jsPanelTop, - left: $rootScope.jsPanelLeft, + top: $scope.jsPanelTop, + left: $scope.jsPanelLeft, }, size: { - width: $rootScope.jsPanelWidth, - height: $rootScope.jsPanelHeight + width: $scope.jsPanelWidth, + height: $scope.jsPanelHeight }, + onminimized:function (panel) { + $scope.SetwindowStoreData(windowviewid, 'minimised',true); + $scope.SetwindowStoreData(windowviewid, 'maximised',false); + }, + onmaximized:function (panel) { + $scope.SetwindowStoreData(windowviewid, 'maximised',true); + $scope.SetwindowStoreData(windowviewid, 'minimised',false); + }, + onnormalized:function (panel) { + $scope.SetwindowStoreData(windowviewid, 'minimised',false); + $scope.SetwindowStoreData(windowviewid, 'maximised',false); + } }); @@ -996,8 +1012,8 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l else { $scope.jsPanelDA.normalize(); } - $scope.SetwindowStoreData(windowviewid, 'top', $scope.jsPanelTop); - $scope.SetwindowStoreData(windowviewid, 'left', $scope.jsPanelLeft); + $scope.SetwindowStoreData(windowviewid, 'y', $scope.jsPanelTop); + $scope.SetwindowStoreData(windowviewid, 'x', $scope.jsPanelLeft); $scope.SetwindowStoreData(windowviewid, 'width', $scope.jsPanelWidth); $scope.SetwindowStoreData(windowviewid, 'height', $scope.jsPanelHeight); @@ -11525,8 +11541,8 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l var len = (event.currentTarget.id).split("_").length; var windowviewid = (event.currentTarget.id).split("_")[len - 1]; //var offSets = $(this).offset(); var postions = (this).position(); (this).offsetTop (this).offsetLeft - $scope.SetwindowStoreData(windowviewid, 'top', ui.position.top); - $scope.SetwindowStoreData(windowviewid, 'left', ui.position.left); + $scope.SetwindowStoreData(windowviewid, 'y', ui.position.top); + $scope.SetwindowStoreData(windowviewid, 'x', ui.position.left); } }); @@ -11586,7 +11602,7 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l $('#' + panelid).remove(); } - $rootScope.resetjsPanelTop(panelid); + // $rootScope.resetjsPanelTop(panelid); } } } diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js index 5cb9464..158fa9d 100644 --- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js +++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js @@ -146,7 +146,8 @@ function ($rootScope, $scope, Modules, $log, $location, $compile, $timeout, Data "mType": 'MY_PICTURES', "imageSource":reader.result, "windowTitle": file.name.split(".")[0], - "size": { height: 500, width: 800 } + "size": { height: 500, width: 800 }, + "position": { x: 300, y: 110 } }; AIAModuleOpenResourceInfo(PicOpenData); @@ -216,7 +217,8 @@ function ($rootScope, $scope, Modules, $log, $location, $compile, $timeout, Data "id":animationId,//user for identify resource until save or export cb "videoSource":reader.result, "windowTitle": file.name.split(".")[0], - "size": { height: 500, width: 800 } + "size": { height: 500, width: 800 }, + "position": { x: 300, y: 110 } }; AIAModuleOpenResourceInfo(AniOpenData); } @@ -313,7 +315,7 @@ function ($rootScope, $scope, Modules, $log, $location, $compile, $timeout, Data currentController: 'HomeController', parentSlug: parentslag, content: '
' + - '', + '', title: "", position: { top: 1, @@ -324,7 +326,7 @@ function ($rootScope, $scope, Modules, $log, $location, $compile, $timeout, Data size: { width: screen.width-10, - height: 610 + height: screen.height-150 }, }); @@ -333,6 +335,9 @@ function ($rootScope, $scope, Modules, $log, $location, $compile, $timeout, Data $scope.OpenResourcePanel = function (iframe) { + var canvasDIvHeight = $("#dvOpenResourcePanel .jsPanel-content").height(); + $('#OpenModuleInCB').css('height', canvasDIvHeight); + //var iframe = document.getElementById('OpenModuleInCB'); var innerDoc = (iframe.contentDocument) ? iframe.contentDocument : iframe.contentWindow.document; var head = $(innerDoc).contents().find("head"); @@ -688,6 +693,7 @@ function ($rootScope, $scope, Modules, $log, $location, $compile, $timeout, Data $scope.currentUserDetails = $rootScope.getLocalStorageValue('loggedInUserDetails'); if ($scope.currentUserDetails != undefined) { $rootScope.isVisibleLogin = false; + $location.url('/'); ConfigurationService.getCofigValue() .then( function (configresult) { @@ -1781,23 +1787,8 @@ function ($rootScope, $scope, Modules, $log, $location, $compile, $timeout, Data if (userInfo.LoginId != undefined || userInfo.LoginId != "" || userInfo.LoginId != null) { userInfo["username"] = userInfo.LoginId; - userInfo["password"] = userInfo.Password; - - + userInfo["password"] = userInfo.Password; $rootScope.AuthenticateUser(userInfo,true); - - if ($rootScope.refreshcheck == null) { - - if ($location.path() == "/lab-exercises-detail") { - - $location.url('/'); - } - else { - - $location.url('/'); - } - $rootScope.isVisibleLogin = false; - } } @@ -2393,7 +2384,7 @@ function ($rootScope, $scope, Modules, $log, $location, $compile, $timeout, Data var pTop = ctx.offsetTop + ctx.offsetHeight + 10; if (paneltopPosition < pTop) { - paneltopPosition = pTop; + paneltopPosition = pTop+20; } } } @@ -7527,6 +7518,9 @@ function ($rootScope, $scope, Modules, $log, $location, $compile, $timeout, Data $('#dvOpenResourcePanel').remove(); sessionStorage.removeItem('isModuleOpenByOpenResource'); $("#jsPanel-min-container").removeAttr("style"); + if (document.location.pathname == "/curriculum-builder-detail") { + $("#jsPanel-min-container").css( 'left', '300px' ); + } }); $rootScope.restrictBodySystemList = function () { @@ -7872,8 +7866,12 @@ function AIAModuleOpenResourceInfo(windowData) { sessionStorage.removeItem('isModuleOpenByOpenResource'); window.parent.closeIFrame(); $("#jsPanel-min-container").removeAttr("style"); + var scope = angular.element(document.querySelector('[ng-controller="HomeController"]')).scope(); scope.$apply(function () { + if (document.location.pathname == "/curriculum-builder-detail") { + $("#jsPanel-min-container").css( 'left', '300px' ); + } scope.AIAModuleOpenResourceInfo(windowData); }); diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/LabExercController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/LabExercController.js index 7550aec..8397868 100644 --- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/LabExercController.js +++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/LabExercController.js @@ -35,8 +35,8 @@ function ($scope, $rootScope, pages, log, $http, $timeout, DataService, $filter, 'userloginid': 0, 'correctResonseKeyValue': [], 'correctResponseForSavingDatabase':'', - 'top': 0, - 'left': 0, + 'y': 0, + 'x': 0, 'width': 0, 'height': 0, 'minimised': false, @@ -215,7 +215,8 @@ function ($scope, $rootScope, pages, log, $http, $timeout, DataService, $filter, "id": excercise.Slug, "mType": 'LAB_EXERCISE', "windowTitle": excercise.Topic, - "size": { height: 500, width: 900 } + "size": { height: 500, width: 900 }, + "position": { x: 300, y: 110 } }; window.parent.AIAModuleOpenResourceInfo(LEopenData); @@ -345,24 +346,27 @@ function ($scope, $rootScope, pages, log, $http, $timeout, DataService, $filter, if ($rootScope.isCallFromOtherModule) { // open JS panel for curriculum with define cornonate in CB jason - $rootScope.jsPanelWidth = $scope.leOpenInOtherModules.size.width;//1000; - $rootScope.jsPanelHeight = $scope.leOpenInOtherModules.size.height; + $scope.jsPanelWidth = $scope.leOpenInOtherModules.size.width;//1000; + $scope.jsPanelHeight = $scope.leOpenInOtherModules.size.height; if ($scope.leOpenInOtherModules.size.height < 450) - $rootScope.jsPanelHeight = 450; + $scope.jsPanelHeight = 450; - $rootScope.jsPanelLeft = 320; - - $rootScope.jsPanelTop = $rootScope.cBModulejsPanelTop(); + $scope.jsPanelLeft = $scope.leOpenInOtherModules.position.x; + if ($scope.leOpenInOtherModules.position.x < 20) + $scope.jsPanelLeft = 20; + $scope.jsPanelTop = $scope.leOpenInOtherModules.position.y; + if($location.url()!= "/curriculum-builder-detail") { - $rootScope.jsPanelLeft = 1; + $scope.jsPanelLeft = 1; + $scope.jsPanelTop = $rootScope.cBModulejsPanelTop(); } } else { - $rootScope.jsPanelWidth = $(window).outerWidth() - 10; - $rootScope.jsPanelHeight = $(window).outerHeight() - 110; - $rootScope.jsPanelLeft = 1; - $rootScope.jsPanelTop = 70; + $scope.jsPanelWidth = $(window).outerWidth() - 10; + $scope.jsPanelHeight = $(window).outerHeight() - 110; + $scope.jsPanelLeft = 1; + $scope.jsPanelTop = 70; } $scope.jsPanelLab = $.jsPanel({ @@ -377,14 +381,26 @@ function ($scope, $rootScope, pages, log, $http, $timeout, DataService, $filter, title: currentViewTitle, position: { - top: $rootScope.jsPanelTop, - left: $rootScope.jsPanelLeft, + top: $scope.jsPanelTop, + left: $scope.jsPanelLeft, }, size: { - width: $rootScope.jsPanelWidth, - height: $rootScope.jsPanelHeight + width: $scope.jsPanelWidth, + height: $scope.jsPanelHeight }, + onminimized:function (panel) { + $scope.SetLEwindowStoreData(windowviewid, 'minimised',true); + $scope.SetLEwindowStoreData(windowviewid, 'maximised',false); + }, + onmaximized:function (panel) { + $scope.SetLEwindowStoreData(windowviewid, 'maximised',true); + $scope.SetLEwindowStoreData(windowviewid, 'minimised',false); + }, + onnormalized:function (panel) { + $scope.SetLEwindowStoreData(windowviewid, 'minimised',false); + $scope.SetLEwindowStoreData(windowviewid, 'maximised',false); + } }); @@ -404,8 +420,8 @@ function ($scope, $rootScope, pages, log, $http, $timeout, DataService, $filter, else { $scope.jsPanelLab.normalize(); } - $scope.SetLEwindowStoreData(windowviewid, 'top', $scope.jsPanelTop); - $scope.SetLEwindowStoreData(windowviewid, 'left', $scope.jsPanelLeft); + $scope.SetLEwindowStoreData(windowviewid, 'y', $scope.jsPanelTop); + $scope.SetLEwindowStoreData(windowviewid, 'x', $scope.jsPanelLeft); $scope.SetLEwindowStoreData(windowviewid, 'width', $scope.jsPanelWidth); $scope.SetLEwindowStoreData(windowviewid, 'height', $scope.jsPanelHeight); @@ -580,8 +596,8 @@ function ($scope, $rootScope, pages, log, $http, $timeout, DataService, $filter, stop: function (event, ui) { var len = (event.currentTarget.id).split("_").length; var windowviewid = (event.currentTarget.id).split("_")[len - 1]; - $scope.SetLEwindowStoreData(windowviewid, 'top', ui.position.top); - $scope.SetLEwindowStoreData(windowviewid, 'left', ui.position.left); + $scope.SetLEwindowStoreData(windowviewid, 'y', ui.position.top); + $scope.SetLEwindowStoreData(windowviewid, 'x', ui.position.left); } }); @@ -637,7 +653,7 @@ function ($scope, $rootScope, pages, log, $http, $timeout, DataService, $filter, $('#' + panelid).remove(); } - $rootScope.resetjsPanelTop(); + // $rootScope.resetjsPanelTop(); } } } diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/MyAnimationController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/MyAnimationController.js index e640c2c..332ad2d 100644 --- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/MyAnimationController.js +++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/MyAnimationController.js @@ -12,8 +12,8 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout 'parentSlugName': '', 'currentSlug': '', 'imageId': '', - 'top': 0, - 'left': 0, + 'y': 0, + 'x': 0, 'width': 0, 'height': 0, 'minimised': false, @@ -127,7 +127,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout $('#' + panelid).remove(); } - $rootScope.resetjsPanelTop(panelid); + // $rootScope.resetjsPanelTop(panelid); } } } @@ -148,8 +148,8 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout var len = (event.currentTarget.id).split("_").length; var windowviewid = (event.currentTarget.id).split("_")[len - 1]; //var offSets = $(this).offset(); var postions = (this).position(); (this).offsetTop (this).offsetLeft - $scope.SetVideowindowStoreData(windowviewid, 'top', ui.position.top); - $scope.SetVideowindowStoreData(windowviewid, 'left', ui.position.left); + $scope.SetVideowindowStoreData(windowviewid, 'y', ui.position.top); + $scope.SetVideowindowStoreData(windowviewid, 'x', ui.position.left); } }); // close panel @@ -279,10 +279,15 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout $scope.jsPanelHeight = $scope.VidOpenInOtherModules.size.height; if ($scope.VidOpenInOtherModules.size.height > 360) $scope.jsPanelHeight = 360; - $scope.jsPanelLeft = 320; - $scope.jsPanelTop = $rootScope.cBModulejsPanelTop(); + + $scope.jsPanelLeft = $scope.VidOpenInOtherModules.position.x; + if ($scope.VidOpenInOtherModules.position.x < 20) + $scope.jsPanelLeft = 20; + $scope.jsPanelTop = $scope.VidOpenInOtherModules.position.y; + if($location.url()!= "/curriculum-builder-detail") { $scope.jsPanelLeft = 1; + $scope.jsPanelTop = $rootScope.cBModulejsPanelTop(); } } @@ -329,6 +334,18 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout width: $scope.jsPanelWidth, height: $scope.jsPanelHeight }, + onminimized:function (panel) { + $scope.SetVideowindowStoreData(windowviewid, 'minimised',true); + $scope.SetVideowindowStoreData(windowviewid, 'maximised',false); + }, + onmaximized:function (panel) { + $scope.SetVideowindowStoreData(windowviewid, 'maximised',true); + $scope.SetVideowindowStoreData(windowviewid, 'minimised',false); + }, + onnormalized:function (panel) { + $scope.SetVideowindowStoreData(windowviewid, 'minimised',false); + $scope.SetVideowindowStoreData(windowviewid, 'maximised',false); + } }); @@ -344,8 +361,8 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout else { $scope.jsPanelVideo.normalize(); } - $scope.SetVideowindowStoreData(windowviewid, 'top', $scope.jsPanelTop); - $scope.SetVideowindowStoreData(windowviewid, 'left', $scope.jsPanelLeft); + $scope.SetVideowindowStoreData(windowviewid, 'y', $scope.jsPanelTop); + $scope.SetVideowindowStoreData(windowviewid, 'x', $scope.jsPanelLeft); $scope.SetVideowindowStoreData(windowviewid, 'width', $scope.jsPanelWidth); $scope.SetVideowindowStoreData(windowviewid, 'height', $scope.jsPanelHeight); diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/MyPictureController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/MyPictureController.js index 04aabb5..dc35923 100644 --- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/MyPictureController.js +++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/MyPictureController.js @@ -13,8 +13,8 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout 'parentSlugName': '', 'currentSlug': '', 'imageId': '', - 'top': 0, - 'left': 0, + 'y': 0, + 'x': 0, 'width': 0, 'height': 0, 'minimised': false, @@ -142,7 +142,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout $('#' + panelid).remove(); } - $rootScope.resetjsPanelTop(panelid); + // $rootScope.resetjsPanelTop(panelid); } } } @@ -163,8 +163,8 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout var len = (event.currentTarget.id).split("_").length; var windowviewid = (event.currentTarget.id).split("_")[len - 1]; //var offSets = $(this).offset(); var postions = (this).position(); (this).offsetTop (this).offsetLeft - $scope.SetPICwindowStoreData(windowviewid, 'top', ui.position.top); - $scope.SetPICwindowStoreData(windowviewid, 'left', ui.position.left); + $scope.SetPICwindowStoreData(windowviewid, 'y', ui.position.top); + $scope.SetPICwindowStoreData(windowviewid, 'x', ui.position.left); } }); // close panel @@ -279,11 +279,16 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout $scope.jsPanelHeight = $scope.picOpenInOtherModules.size.height; if ($scope.picOpenInOtherModules.size.height > 540) $scope.jsPanelHeight = 540; - $scope.jsPanelLeft = 320; - $scope.jsPanelTop = $rootScope.cBModulejsPanelTop(); - if($location.url()!= "/curriculum-builder-detail") { - $scope.jsPanelLeft = 1; - } + + $scope.jsPanelLeft = $scope.picOpenInOtherModules.position.x; + if ($scope.picOpenInOtherModules.position.x < 20) + $scope.jsPanelLeft = 20; + $scope.jsPanelTop = $scope.picOpenInOtherModules.position.y; + + if($location.url()!= "/curriculum-builder-detail") { + $scope.jsPanelLeft = 1; + $scope.jsPanelTop = $rootScope.cBModulejsPanelTop(); + } $scope.jsPanelPIC = $.jsPanel({ id: $scope.jsPanelID, @@ -307,24 +312,37 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout width: $scope.jsPanelWidth, height: $scope.jsPanelHeight }, + onminimized:function (panel) { + $scope.SetPICwindowStoreData(windowviewid, 'minimised',true); + $scope.SetPICwindowStoreData(windowviewid, 'maximised',false); + }, + onmaximized:function (panel) { + $scope.SetPICwindowStoreData(windowviewid, 'maximised',true); + $scope.SetPICwindowStoreData(windowviewid, 'minimised',false); + }, + onnormalized:function (panel) { + $scope.SetPICwindowStoreData(windowviewid, 'minimised',false); + $scope.SetPICwindowStoreData(windowviewid, 'maximised',false); + } }); + var isMaximize = $scope.GetPICwindowStoreData(windowviewid, 'maximised'); + var isMinimize = $scope.GetPICwindowStoreData(windowviewid, 'minimised'); + if (isMaximize) { + $scope.jsPanelPIC.maximize(); + } + else if (isMinimize) { + $scope.jsPanelPIC.minimize(); + } + else { + $scope.jsPanelPIC.normalize(); + } $('#canvasDivPIC_' + windowviewid + ' img').load(function () { - var isMaximize = $scope.GetPICwindowStoreData(windowviewid, 'maximised'); - var isMinimize = $scope.GetPICwindowStoreData(windowviewid, 'minimised'); - if (isMaximize) { - $scope.jsPanelPIC.maximize(); - } - else if (isMinimize) { - $scope.jsPanelPIC.minimize(); - } - else { - $scope.jsPanelPIC.normalize(); - } - $scope.SetPICwindowStoreData(windowviewid, 'top', $scope.jsPanelTop); - $scope.SetPICwindowStoreData(windowviewid, 'left', $scope.jsPanelLeft); + + $scope.SetPICwindowStoreData(windowviewid, 'y', $scope.jsPanelTop); + $scope.SetPICwindowStoreData(windowviewid, 'x', $scope.jsPanelLeft); $scope.SetPICwindowStoreData(windowviewid, 'width', $scope.jsPanelWidth); $scope.SetPICwindowStoreData(windowviewid, 'height', $scope.jsPanelHeight); diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/TileViewListController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/TileViewListController.js index c4b7b9d..69438aa 100644 --- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/TileViewListController.js +++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/TileViewListController.js @@ -83,8 +83,8 @@ function ($scope, $window, $rootScope, $compile, $http, $log, $location, $timeou 'CBselectedpinCordinate': [], 'verticalScroll': 0, 'horizontalScroll':0, - 'top': 0, - 'left': 0, + 'y': 0, + 'x': 0, 'width': 0, 'height': 0, 'minimised': false, @@ -350,7 +350,8 @@ function ($scope, $window, $rootScope, $compile, $http, $log, $location, $timeou "showAllPins":true, "windowTitle": moduleItemDataToBeSaved, "scaleIndex":100, - "size": { height: 600, width: 900 } + "size": { height: 600, width: 900 }, + "position": { x: 300, y: 110 } }; window.parent.AIAModuleOpenResourceInfo(AAopenData); @@ -600,10 +601,15 @@ function ($scope, $window, $rootScope, $compile, $http, $log, $location, $timeou $scope.jsPanelHeight = $scope.aaOpenInOtherModules.size.height; if($scope.aaOpenInOtherModules.size.height<420) $scope.jsPanelHeight = 420; - $scope.jsPanelLeft = 320; - $scope.jsPanelTop = $rootScope.cBModulejsPanelTop(); + + $scope.jsPanelLeft = $scope.aaOpenInOtherModules.position.x; + if ($scope.aaOpenInOtherModules.position.x < 20) + $scope.jsPanelLeft = 20; + $scope.jsPanelTop = $scope.aaOpenInOtherModules.position.y; + if($location.url()!= "/curriculum-builder-detail") { $scope.jsPanelLeft = 1; + $scope.jsPanelTop = $rootScope.cBModulejsPanelTop(); } } @@ -636,6 +642,18 @@ function ($scope, $window, $rootScope, $compile, $http, $log, $location, $timeou width: $scope.jsPanelWidth, height: $scope.jsPanelHeight }, + onminimized:function (panel) { + $scope.SetAAwindowStoreData(windowviewid, 'minimised',true); + $scope.SetAAwindowStoreData(windowviewid, 'maximised',false); + }, + onmaximized:function (panel) { + $scope.SetAAwindowStoreData(windowviewid, 'maximised',true); + $scope.SetAAwindowStoreData(windowviewid, 'minimised',false); + }, + onnormalized:function (panel) { + $scope.SetAAwindowStoreData(windowviewid, 'minimised',false); + $scope.SetAAwindowStoreData(windowviewid, 'maximised',false); + } }); @@ -664,8 +682,8 @@ function ($scope, $window, $rootScope, $compile, $http, $log, $location, $timeou else { $scope.jsPanelAA.normalize(); } - $scope.SetAAwindowStoreData(windowviewid, 'top', $scope.jsPanelTop); - $scope.SetAAwindowStoreData(windowviewid, 'left', $scope.jsPanelLeft); + $scope.SetAAwindowStoreData(windowviewid, 'y', $scope.jsPanelTop); + $scope.SetAAwindowStoreData(windowviewid, 'x', $scope.jsPanelLeft); $scope.SetAAwindowStoreData(windowviewid, 'width', $scope.jsPanelWidth); $scope.SetAAwindowStoreData(windowviewid, 'height', $scope.jsPanelHeight); @@ -3248,8 +3266,8 @@ function ($scope, $window, $rootScope, $compile, $http, $log, $location, $timeou var len = (event.currentTarget.id).split("_").length; var windowviewid = (event.currentTarget.id).split("_")[len - 1]; //var offSets = $(this).offset(); var postions = (this).position(); (this).offsetTop (this).offsetLeft - $scope.SetAAwindowStoreData(windowviewid, 'top', ui.position.top); - $scope.SetAAwindowStoreData(windowviewid, 'left', ui.position.left); + $scope.SetAAwindowStoreData(windowviewid, 'y', ui.position.top); + $scope.SetAAwindowStoreData(windowviewid, 'x', ui.position.left); } }); @@ -3309,7 +3327,7 @@ function ($scope, $window, $rootScope, $compile, $http, $log, $location, $timeou $('#' + panelid).remove(); } - $rootScope.resetjsPanelTop(panelid); + // $rootScope.resetjsPanelTop(panelid); } } } diff --git a/400-SOURCECODE/AIAHTML5.Web/app/views/CBuild/CBuild-view.html b/400-SOURCECODE/AIAHTML5.Web/app/views/CBuild/CBuild-view.html index 88ba65c..6c5271d 100644 --- a/400-SOURCECODE/AIAHTML5.Web/app/views/CBuild/CBuild-view.html +++ b/400-SOURCECODE/AIAHTML5.Web/app/views/CBuild/CBuild-view.html @@ -2,7 +2,7 @@
-
+
    diff --git a/400-SOURCECODE/AIAHTML5.Web/app/views/CBuild/curriculum-builder-TinyMCEjspanel.html b/400-SOURCECODE/AIAHTML5.Web/app/views/CBuild/curriculum-builder-TinyMCEjspanel.html index 13c1b25..bb1cdf4 100644 --- a/400-SOURCECODE/AIAHTML5.Web/app/views/CBuild/curriculum-builder-TinyMCEjspanel.html +++ b/400-SOURCECODE/AIAHTML5.Web/app/views/CBuild/curriculum-builder-TinyMCEjspanel.html @@ -26,7 +26,7 @@
    -
    + -
    -
    @@ -48,7 +48,7 @@
    -
    +
    @@ -99,7 +99,7 @@ function editorHideShow() { $("#cbEditorRightSideBar").toggle(); - $("#cbEditorLeftSideBar").toggle(); + // $("#cbEditorLeftSideBar").toggle(); } function cbRenameModelShow() { diff --git a/400-SOURCECODE/AIAHTML5.Web/app/views/CBuild/curriculum-builder-detail.html b/400-SOURCECODE/AIAHTML5.Web/app/views/CBuild/curriculum-builder-detail.html index b1ca447..e9e9162 100644 --- a/400-SOURCECODE/AIAHTML5.Web/app/views/CBuild/curriculum-builder-detail.html +++ b/400-SOURCECODE/AIAHTML5.Web/app/views/CBuild/curriculum-builder-detail.html @@ -11,7 +11,6 @@ .CBLeft-Sidebar { width: 300px; padding-top: 0px; - height: 89vh; background: #222; padding-top: 20px; position: absolute !important; @@ -35,62 +34,78 @@ } .CBLeft-Sidebar.active { - left: -268px; + left: -272px; } #CBDetailPageDiv { - margin-top:60px; + margin-top:45px; + } + .treetoolicon + { + width:41px; }
    -
    +