ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From onechipore...@apache.org
Subject ambari git commit: AMBARI-10758. JS error appears on scroll host configs page (onechiporenko)
Date Mon, 27 Apr 2015 10:22:39 GMT
Repository: ambari
Updated Branches:
  refs/heads/trunk fdf2e2ab1 -> 85e595b14


AMBARI-10758. JS error appears on scroll host configs page (onechiporenko)


Project: http://git-wip-us.apache.org/repos/asf/ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/85e595b1
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/85e595b1
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/85e595b1

Branch: refs/heads/trunk
Commit: 85e595b149e21002d3e3abbe0e234e983bda2713
Parents: fdf2e2a
Author: Oleg Nechiporenko <onechiporenko@apache.org>
Authored: Mon Apr 27 13:20:42 2015 +0300
Committer: Oleg Nechiporenko <onechiporenko@apache.org>
Committed: Mon Apr 27 13:20:42 2015 +0300

----------------------------------------------------------------------
 ambari-web/app/utils/pages/scroll_manager.js | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/85e595b1/ambari-web/app/utils/pages/scroll_manager.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/utils/pages/scroll_manager.js b/ambari-web/app/utils/pages/scroll_manager.js
index 16b08f6..9f9f48b8 100644
--- a/ambari-web/app/utils/pages/scroll_manager.js
+++ b/ambari-web/app/utils/pages/scroll_manager.js
@@ -73,7 +73,7 @@ App.ScrollManager = Em.Object.create({
       self.get('elements').forEach(function (element) {
         var defaultTop, defaultLeft;
         var infoBar = $(Em.get(element, 'updatedElementSelector'));
-        var versionSlider = $(Em.get(element, 'elementForLeftOffsetSelector'));
+        var elementForLeftOffset = $(Em.get(element, 'elementForLeftOffsetSelector'));
         var scrollTop = $(window).scrollTop();
         var scrollLeft = $(window).scrollLeft();
         if (!infoBar.length) {
@@ -81,7 +81,7 @@ App.ScrollManager = Em.Object.create({
         }
         defaultTop = (infoBar.get(0).getBoundingClientRect() && infoBar.get(0).getBoundingClientRect().top)
|| Em.get(element, 'defaultTop');
         // keep the version info bar always aligned to version slider
-        defaultLeft = (versionSlider.get(0).getBoundingClientRect() && versionSlider.get(0).getBoundingClientRect().left);
+        defaultLeft = elementForLeftOffset.get(0) && elementForLeftOffset.get(0).getBoundingClientRect()
&& elementForLeftOffset.get(0).getBoundingClientRect().left;
         infoBar.css(calculatePosition(Em.get(element, 'movedTop'), defaultTop, scrollTop,
defaultLeft, scrollLeft));
       });
     });


Mime
View raw message