Return-Path: X-Original-To: apmail-incubator-ambari-commits-archive@minotaur.apache.org Delivered-To: apmail-incubator-ambari-commits-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 06731E51B for ; Sat, 19 Jan 2013 01:40:54 +0000 (UTC) Received: (qmail 49633 invoked by uid 500); 19 Jan 2013 01:40:54 -0000 Delivered-To: apmail-incubator-ambari-commits-archive@incubator.apache.org Received: (qmail 49591 invoked by uid 500); 19 Jan 2013 01:40:53 -0000 Mailing-List: contact ambari-commits-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: ambari-dev@incubator.apache.org Delivered-To: mailing list ambari-commits@incubator.apache.org Received: (qmail 49584 invoked by uid 99); 19 Jan 2013 01:40:53 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 19 Jan 2013 01:40:53 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 19 Jan 2013 01:40:51 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id 1ABF72388900; Sat, 19 Jan 2013 01:40:31 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1435450 - in /incubator/ambari/trunk: CHANGES.txt ambari-web/app/routes/add_host_routes.js ambari-web/app/routes/add_service_routes.js ambari-web/app/views/common/modal_popup.js Date: Sat, 19 Jan 2013 01:40:30 -0000 To: ambari-commits@incubator.apache.org From: yusaku@apache.org X-Mailer: svnmailer-1.0.8-patched Message-Id: <20130119014031.1ABF72388900@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: yusaku Date: Sat Jan 19 01:40:30 2013 New Revision: 1435450 URL: http://svn.apache.org/viewvc?rev=1435450&view=rev Log: AMBARI-1225. Add Hosts wizard popup is too small. (yusaku) Modified: incubator/ambari/trunk/CHANGES.txt incubator/ambari/trunk/ambari-web/app/routes/add_host_routes.js incubator/ambari/trunk/ambari-web/app/routes/add_service_routes.js incubator/ambari/trunk/ambari-web/app/views/common/modal_popup.js Modified: incubator/ambari/trunk/CHANGES.txt URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/CHANGES.txt?rev=1435450&r1=1435449&r2=1435450&view=diff ============================================================================== --- incubator/ambari/trunk/CHANGES.txt (original) +++ incubator/ambari/trunk/CHANGES.txt Sat Jan 19 01:40:30 2013 @@ -17,6 +17,8 @@ Trunk (unreleased changes): IMPROVEMENTS + AMBARI-1225. Add Hosts wizard popup is too small. (yusaku) + AMBARI-1224. Drop the "all" option from Hosts > Component Filter and Jobs > Users Filter. (yusaku) Modified: incubator/ambari/trunk/ambari-web/app/routes/add_host_routes.js URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/routes/add_host_routes.js?rev=1435450&r1=1435449&r2=1435450&view=diff ============================================================================== --- incubator/ambari/trunk/ambari-web/app/routes/add_host_routes.js (original) +++ incubator/ambari/trunk/ambari-web/app/routes/add_host_routes.js Sat Jan 19 01:40:30 2013 @@ -44,6 +44,9 @@ module.exports = Em.Route.extend({ this.hide(); App.router.get('updateController').set('isWorking', true); router.transitionTo('hosts.index'); + }, + didInsertElement: function(){ + this.fitHeight(); } }); Modified: incubator/ambari/trunk/ambari-web/app/routes/add_service_routes.js URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/routes/add_service_routes.js?rev=1435450&r1=1435449&r2=1435450&view=diff ============================================================================== --- incubator/ambari/trunk/ambari-web/app/routes/add_service_routes.js (original) +++ incubator/ambari/trunk/ambari-web/app/routes/add_service_routes.js Sat Jan 19 01:40:30 2013 @@ -44,6 +44,9 @@ module.exports = Em.Route.extend({ this.hide(); App.router.get('updateController').set('isWorking', true); App.router.transitionTo('main.services') + }, + didInsertElement: function(){ + this.fitHeight(); } }); router.transitionTo('step' + addServiceController.get('currentStep')); Modified: incubator/ambari/trunk/ambari-web/app/views/common/modal_popup.js URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/views/common/modal_popup.js?rev=1435450&r1=1435449&r2=1435450&view=diff ============================================================================== --- incubator/ambari/trunk/ambari-web/app/views/common/modal_popup.js (original) +++ incubator/ambari/trunk/ambari-web/app/views/common/modal_popup.js Sat Jan 19 01:40:30 2013 @@ -73,6 +73,20 @@ App.ModalPopup = Ember.View.extend({ var block = this.$().find('#modal > .modal-body').first(); block.css('max-height', $(window).height()- block.offset().top - 300); // fix popup height } + }, + + fitHeight: function(){ + var popup = this.$().find('#modal'); + var block = this.$().find('#modal > .modal-body'); + var wh = $(window).height(); + + var top = wh * .05; + popup.css({ + 'top' : top + 'px', + 'marginTop' : 0 + }); + + block.css('max-height', $(window).height()- top * 2 - 100); } });