ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ababiic...@apache.org
Subject ambari git commit: AMBARI-14588 Update spinner.(ababiichuk)
Date Fri, 08 Jan 2016 11:58:29 GMT
Repository: ambari
Updated Branches:
  refs/heads/branch-2.2 16b75fdea -> de221faff


AMBARI-14588 Update spinner.(ababiichuk)


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

Branch: refs/heads/branch-2.2
Commit: de221faffbe1debb7161e4328b68a97f2237a5b8
Parents: 16b75fd
Author: ababiichuk <ababiichuk@hortonworks.com>
Authored: Fri Jan 8 12:14:05 2016 +0200
Committer: ababiichuk <ababiichuk@hortonworks.com>
Committed: Fri Jan 8 12:14:05 2016 +0200

----------------------------------------------------------------------
 LICENSE.txt                                     |  19 -----------
 ambari-web/app/assets/img/spinner.gif           | Bin 11435 -> 0 bytes
 .../progress_popup_controller.js                |   2 +-
 ambari-web/app/mixins/common/reload_popup.js    |  20 +++++++----
 ambari-web/app/styles/application.less          |  27 ++++++++-------
 .../app/styles/enhanced_service_dashboard.less  |   4 ++-
 ambari-web/app/styles/stack_versions.less       |   3 ++
 .../common/assign_master_components.hbs         |   2 +-
 .../templates/common/configs/service_config.hbs |   8 ++---
 .../common/configs/services_config.hbs          |   2 +-
 .../widgets/test_db_connection_widget.hbs       |   4 ++-
 .../common/form/check_db_connection.hbs         |   4 ++-
 .../templates/common/host_progress_popup.hbs    |   6 ++--
 .../common/modal_popups/alerts_popup.hbs        |   4 +--
 .../modal_popups/widget_browser_popup.hbs       |   4 +--
 ambari-web/app/templates/common/progress.hbs    |   2 +-
 .../templates/common/rolling_restart_view.hbs   |   2 +-
 .../templates/common/widget/gauge_widget.hbs    |   2 +-
 .../templates/common/widget/graph_widget.hbs    |   2 +-
 .../templates/common/widget/number_widget.hbs   |   2 +-
 .../templates/common/widget/template_widget.hbs |   2 +-
 .../nameNode/rollbackHA/step1.hbs               |   2 +-
 .../admin/highAvailability/nameNode/step3.hbs   |   2 +-
 .../highAvailability/resourceManager/step3.hbs  |   2 +-
 .../highAvailability/resourceManager/wizard.hbs |   2 +-
 .../app/templates/main/admin/kerberos.hbs       |   2 +-
 .../app/templates/main/admin/kerberos/step2.hbs |   2 +-
 .../app/templates/main/admin/kerberos/step3.hbs |   2 +-
 .../app/templates/main/admin/security.hbs       |   2 +-
 .../templates/main/admin/security/add/step3.hbs |   2 +-
 .../templates/main/admin/serviceAccounts.hbs    |   2 +-
 .../stack_upgrade/stack_upgrade_wizard.hbs      |  12 +++----
 .../main/admin/stack_upgrade/upgrade_group.hbs  |   2 +-
 .../admin/stack_upgrade/upgrade_options.hbs     |   2 +-
 .../main/admin/stack_upgrade/upgrade_task.hbs   |   2 +-
 .../admin/stack_upgrade/upgrade_version_box.hbs |   2 +-
 .../main/admin/stack_upgrade/versions.hbs       |   2 +-
 ambari-web/app/templates/main/alerts.hbs        |   2 +-
 .../main/alerts/definition_details.hbs          |   4 +--
 .../main/alerts/manage_alert_groups_popup.hbs   |   2 +-
 .../alerts/manage_alert_notifications_popup.hbs |   2 +-
 .../app/templates/main/charts/heatmap.hbs       |   4 +--
 .../main/charts/heatmap/heatmap_rack.hbs        |   4 ++-
 .../templates/main/dashboard/config_history.hbs |   2 +-
 .../main/dashboard/widgets/hbase_links.hbs      |   4 +--
 .../main/dashboard/widgets/hdfs_links.hbs       |   2 +-
 .../main/dashboard/widgets/pie_chart.hbs        |   2 +-
 .../main/dashboard/widgets/simple_text.hbs      |   2 +-
 .../templates/main/dashboard/widgets/uptime.hbs |   2 +-
 .../main/dashboard/widgets/yarn_links.hbs       |   4 +--
 ambari-web/app/templates/main/host.hbs          |   2 +-
 ambari-web/app/templates/main/host/add.hbs      |   2 +-
 .../app/templates/main/host/configs_service.hbs |   2 +-
 ambari-web/app/templates/main/host/details.hbs  |   2 +-
 .../app/templates/main/host/host_alerts.hbs     |   2 +-
 .../app/templates/main/service/info/configs.hbs |   2 +-
 .../main/service/info/configs_save_popup.hbs    |   2 +-
 .../app/templates/main/service/info/summary.hbs |   2 +-
 ambari-web/app/templates/main/service/item.hbs  |   4 +--
 .../manage_configuration_groups_popup.hbs       |   2 +-
 .../app/templates/main/service/reassign.hbs     |   2 +-
 .../service/widgets/create/step2_add_metric.hbs |   2 +-
 .../templates/wizard/bootstrap_call_popup.hbs   |   2 +-
 ambari-web/app/templates/wizard/step3.hbs       |   2 +-
 ambari-web/app/templates/wizard/step7.hbs       |   2 +-
 .../wizard/step9/step9HostTasksLogPopup.hbs     |   2 +-
 ambari-web/app/views.js                         |   1 +
 ambari-web/app/views/common/global/spinner.js   |  32 ++++++++++++++++++
 .../test/mixins/common/reload_popup_test.js     |  33 ++++++++++---------
 69 files changed, 169 insertions(+), 130 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/LICENSE.txt
----------------------------------------------------------------------
diff --git a/LICENSE.txt b/LICENSE.txt
index 14f884e..e0ad2d1 100644
--- a/LICENSE.txt
+++ b/LICENSE.txt
@@ -683,25 +683,6 @@ COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
 IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
 CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 
-
-For SpiffyGif (ambari-web/app/assets/img/spinner.gif,
-contrib/views/hive/src/main/resources/ui/hive-web/tests/img/spinner.gif)
-
-Home:   http://spiffygif.com
-Author:  https://twitter.com/sean_holbert
-License: SpiffyGif License
-
-You are free to copy and redistribute any images generated from SpiffyGif in any medium or format, even commercially.
-You are permitted to remix, transform, and build upon images generated from SpiffyGif for any purpose, even commercially.
-
-THIS SOFTWARE AND GENERATED IMAGE FILES ARE PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
-AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
-AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
-FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
-PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
-AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
-ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
 For simplejson (ambari-common/src/main/python/ambari_simplejson)
 
 simplejson is dual-licensed software. It is available under the terms

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/assets/img/spinner.gif
----------------------------------------------------------------------
diff --git a/ambari-web/app/assets/img/spinner.gif b/ambari-web/app/assets/img/spinner.gif
deleted file mode 100644
index e921e36..0000000
Binary files a/ambari-web/app/assets/img/spinner.gif and /dev/null differ

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/controllers/main/admin/highAvailability/progress_popup_controller.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/controllers/main/admin/highAvailability/progress_popup_controller.js b/ambari-web/app/controllers/main/admin/highAvailability/progress_popup_controller.js
index c723bf1..0c15dd6 100644
--- a/ambari-web/app/controllers/main/admin/highAvailability/progress_popup_controller.js
+++ b/ambari-web/app/controllers/main/admin/highAvailability/progress_popup_controller.js
@@ -87,7 +87,7 @@ App.HighAvailabilityProgressPopupController = Ember.Controller.extend({
         primary: false,
         secondary: false,
         bodyClass: Ember.View.extend({
-          template: Ember.Handlebars.compile('<div class="spinner"></div>')
+          template: Ember.Handlebars.compile('{{view App.SpinnerView}}')
         })
       });
       this.set('spinnerPopup', loadingPopup);

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/mixins/common/reload_popup.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/mixins/common/reload_popup.js b/ambari-web/app/mixins/common/reload_popup.js
index 539d1d5..32bb301 100644
--- a/ambari-web/app/mixins/common/reload_popup.js
+++ b/ambari-web/app/mixins/common/reload_popup.js
@@ -22,18 +22,26 @@ App.ReloadPopupMixin = Em.Mixin.create({
 
   reloadPopup: null,
 
-  showReloadPopup: function () {
-    var self = this;
+
+  popupText: function(text) {
+    return text || Em.I18n.t('app.reloadPopup.text');
+  },
+
+  showReloadPopup: function (text) {
+    var self = this,
+      bodyText = this.popupText(text);
     if (!this.get('reloadPopup')) {
       this.set('reloadPopup', App.ModalPopup.show({
         primary: null,
         secondary: null,
         showFooter: false,
         header: this.t('app.reloadPopup.header'),
-        body: "<div id='reload_popup' class='alert alert-info'><div class='spinner'><span>" +
-          this.t('app.reloadPopup.text') + "</span></div></div><div><a href='javascript:void(null)' onclick='location.reload();'>" +
-          this.t('app.reloadPopup.link') + "</a></div>",
-        encodeBody: false,
+        bodyClass: Ember.View.extend({
+          template: Ember.Handlebars.compile("<div id='reload_popup' class='alert alert-info'>" +
+            "{{view App.SpinnerView}}" +
+            "<div><span>" + bodyText + "</span><a href='javascript:void(null)' onclick='location.reload();'>"
+            + this.t('app.reloadPopup.link') + "</a></div>")
+        }),
         onClose: function () {
           self.set('reloadPopup', null);
           this._super();

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/styles/application.less
----------------------------------------------------------------------
diff --git a/ambari-web/app/styles/application.less b/ambari-web/app/styles/application.less
index cf7c59a..c461eeb 100644
--- a/ambari-web/app/styles/application.less
+++ b/ambari-web/app/styles/application.less
@@ -1086,13 +1086,19 @@ h1 {
 .spinner {
   width: @spinner-default-width;
   height: @spinner-default-height;
-  background: url("/img/spinner.gif");
   margin: 0 auto;
+  i {
+    color: #555;
+    font-size: 2.5em;
+  }
 
   &.service-button-spinner {
     width: @spinner-small-width;
     height: @spinner-small-height;
     background-size: cover;
+    i {
+      font-size: 1em;
+    }
   }
 }
 
@@ -1368,6 +1374,9 @@ h1 {
       width: @spinner-small-width;
       height: @spinner-small-height;
       background-size: cover;
+      i {
+        font-size: 1em;
+      }
     }
     .icon-ok-sign, .icon-warning-sign {
       font-size: 27px;
@@ -2753,7 +2762,9 @@ table.graphs {
         height: 105px;
         border: 1px solid silver;
         color: #ffffff;
-        background: url(/img/spinner.gif) no-repeat center center;
+        i {
+          font-size: 4em;
+        }
       }
     }
     .thumbnail .widget-content-isNA{ // for pie chart n\a
@@ -4615,7 +4626,9 @@ ul.inline li {
   height: 157px;
   border: 1px solid silver;
   margin: 20px 15px 10px 15px;
-  background: url(/img/spinner.gif) no-repeat center center;
+  i {
+    font-size: 4em;
+  }
 }
 
 /* TIME RANGE WIDGET END */
@@ -4842,14 +4855,6 @@ li.break {
   }
 }
 
-#reload_popup {
-  .spinner {
-    padding: 8px 35px 0 42px;
-    width: auto;
-    background: url(/img/spinner.gif) no-repeat;
-  }
-}
-
 /*
 .progress-striped .bar {
   background-color: #A5A5A5;

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/styles/enhanced_service_dashboard.less
----------------------------------------------------------------------
diff --git a/ambari-web/app/styles/enhanced_service_dashboard.less b/ambari-web/app/styles/enhanced_service_dashboard.less
index c033ee6..f04ba02 100644
--- a/ambari-web/app/styles/enhanced_service_dashboard.less
+++ b/ambari-web/app/styles/enhanced_service_dashboard.less
@@ -137,7 +137,9 @@
         width: 90%;
         height: 100px;
         border: 1px solid #eee;
-        background: url(/img/spinner.gif) no-repeat center center;
+        i {
+          font-size: 4em;
+        }
       }
       .chart-container{
         margin: -4px 8px 0 8px;

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/styles/stack_versions.less
----------------------------------------------------------------------
diff --git a/ambari-web/app/styles/stack_versions.less b/ambari-web/app/styles/stack_versions.less
index 8529606..b06ec8f 100644
--- a/ambari-web/app/styles/stack_versions.less
+++ b/ambari-web/app/styles/stack_versions.less
@@ -400,6 +400,9 @@
         width: auto;
         height: @spinner-small-height;
         padding-left: @spinner-small-width + 4px;
+        i {
+          font-size: 1em;
+        }
         background-repeat: no-repeat;
         background-size: contain;
       }

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/common/assign_master_components.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/common/assign_master_components.hbs b/ambari-web/app/templates/common/assign_master_components.hbs
index f4687eb..f7cebed 100644
--- a/ambari-web/app/templates/common/assign_master_components.hbs
+++ b/ambari-web/app/templates/common/assign_master_components.hbs
@@ -135,7 +135,7 @@
       <div class="clearfix"></div>
     </div>
   {{else}}
-    <div class="spinner"></div>
+    {{view App.SpinnerView}}
   {{/if}}
   <div class="btn-area">
     <a class="btn pull-left installer-back-btn" {{action back}}>&larr; {{t common.back}}</a>

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/common/configs/service_config.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/common/configs/service_config.hbs b/ambari-web/app/templates/common/configs/service_config.hbs
index eaa1220..c8fcb9b 100644
--- a/ambari-web/app/templates/common/configs/service_config.hbs
+++ b/ambari-web/app/templates/common/configs/service_config.hbs
@@ -67,7 +67,7 @@
           {{/each}}
         </ul>
       {{else}}
-        <div class="pull-left spinner"></div>
+        {{view App.SpinnerView classNames="pull-left"}}
       {{/if}}
 		</span>
     {{#isAccessible ADMIN}}
@@ -88,7 +88,7 @@
   {{#if allVersionsLoaded}}
     {{view App.ConfigHistoryFlowView serviceBinding="selectedService"}}
   {{else}}
-    <div class="spinner"></div>
+    {{view App.SpinnerView}}
   {{/if}}
 {{/if}}
 
@@ -142,7 +142,7 @@
                 </div>
               {{/each}}
             {{else}}
-              <div class="spinner"></div>
+              {{view App.SpinnerView}}
             {{/if}}
           {{else}}
               {{! Render Enhanced Config Section }}
@@ -168,5 +168,5 @@
     </div>
   {{/if}}
 {{else}}
-  <div class="spinner"></div>
+  {{view App.SpinnerView}}
 {{/if}}

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/common/configs/services_config.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/common/configs/services_config.hbs b/ambari-web/app/templates/common/configs/services_config.hbs
index cc1c3b0..ffdf0ed 100644
--- a/ambari-web/app/templates/common/configs/services_config.hbs
+++ b/ambari-web/app/templates/common/configs/services_config.hbs
@@ -29,7 +29,7 @@
       {{/each}}
     </ul>
 {{else}}
-    <div class="spinner"></div>
+    {{view App.SpinnerView}}
 {{/if}}
 {{#if hasChangedDependencies}}
   <div class="alert alert-warning">

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/common/configs/widgets/test_db_connection_widget.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/common/configs/widgets/test_db_connection_widget.hbs b/ambari-web/app/templates/common/configs/widgets/test_db_connection_widget.hbs
index 1cd4aaf..78626c0 100644
--- a/ambari-web/app/templates/common/configs/widgets/test_db_connection_widget.hbs
+++ b/ambari-web/app/templates/common/configs/widgets/test_db_connection_widget.hbs
@@ -27,7 +27,9 @@
         <div class="pull-left connection-result mll">
           <a {{bindAttr class="view.isConnectionSuccess:mute:action"}} {{action showLogsPopup target="view"}}>{{view.responseCaption}}</a>
         </div>
-        <div {{bindAttr class=":spinner :mll :pull-left view.isConnecting::hide"}}></div>
+        {{#if view.isConnecting}}
+          {{view App.SpinnerView classNames="mll pull-left"}}
+        {{/if}}
         <i {{bindAttr class=":pull-right view.isConnectionSuccess:icon-ok-sign:icon-warning-sign view.isRequestResolved::hide"}}></i>
       </div>
     </div>

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/common/form/check_db_connection.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/common/form/check_db_connection.hbs b/ambari-web/app/templates/common/form/check_db_connection.hbs
index a044289..c6efacd 100644
--- a/ambari-web/app/templates/common/form/check_db_connection.hbs
+++ b/ambari-web/app/templates/common/form/check_db_connection.hbs
@@ -25,7 +25,9 @@
         <div class="pull-left connection-result mll">
           <a {{bindAttr class="view.isConnectionSuccess:mute:action"}} {{action showLogsPopup target="view"}}>{{view.responseCaption}}</a>
         </div>
-        <div {{bindAttr class=":spinner :mll :pull-left view.isConnecting::hide"}}></div>
+        {{#if view.isConnecting}}
+          {{view App.SpinnerView classNames="mll pull-left"}}
+        {{/if}}
         <i {{bindAttr class=":pull-right view.isConnectionSuccess:icon-ok-sign:icon-warning-sign view.isRequestResolved::hide"}}></i>
       </div>
     </div>

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/common/host_progress_popup.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/common/host_progress_popup.hbs b/ambari-web/app/templates/common/host_progress_popup.hbs
index 8a74e72..9a5cf30 100644
--- a/ambari-web/app/templates/common/host_progress_popup.hbs
+++ b/ambari-web/app/templates/common/host_progress_popup.hbs
@@ -137,7 +137,7 @@
         {{/if}}
       </div>
     {{else}}
-      <div class="spinner"></div>
+      {{view App.SpinnerView}}
     {{/if}}
   </div>
 
@@ -234,11 +234,11 @@
         </div>
       </div>
     {{else}}
-      <div class="spinner"></div>
+      {{view App.SpinnerView}}
     {{/if}}
   </div>
 {{else}}
-  <div class="spinner"></div>
+  {{view App.SpinnerView}}
 {{/if}}
 </div>
 {{#if view.isPaginate}}

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/common/modal_popups/alerts_popup.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/common/modal_popups/alerts_popup.hbs b/ambari-web/app/templates/common/modal_popups/alerts_popup.hbs
index 5b235de..06a1b94 100644
--- a/ambari-web/app/templates/common/modal_popups/alerts_popup.hbs
+++ b/ambari-web/app/templates/common/modal_popups/alerts_popup.hbs
@@ -56,7 +56,7 @@
     </div>
 
     <div {{bindAttr class="view.filteringComplete:hidden :table-overlay"}}>
-      <div class="spinner"></div>
+      {{view App.SpinnerView}}
     </div>
 
     {{#if view.isPaginate}}
@@ -74,7 +74,7 @@
       </div>
     {{/if}}
   {{else}}
-    <div class="spinner"></div>
+    {{view App.SpinnerView}}
   {{/if}}
 </div>
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/common/modal_popups/widget_browser_popup.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/common/modal_popups/widget_browser_popup.hbs b/ambari-web/app/templates/common/modal_popups/widget_browser_popup.hbs
index 3396cb6..3af0461 100644
--- a/ambari-web/app/templates/common/modal_popups/widget_browser_popup.hbs
+++ b/ambari-web/app/templates/common/modal_popups/widget_browser_popup.hbs
@@ -96,10 +96,10 @@
     </div>
 
     <div class="table-overlay">
-       <div class="spinner"></div>
+       {{view App.SpinnerView}}
     </div>
   {{else}}
-      <div class="spinner"></div>
+      {{view App.SpinnerView}}
   {{/if}}
 </div>
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/common/progress.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/common/progress.hbs b/ambari-web/app/templates/common/progress.hbs
index 8e122cb..1de6d78 100644
--- a/ambari-web/app/templates/common/progress.hbs
+++ b/ambari-web/app/templates/common/progress.hbs
@@ -67,7 +67,7 @@
       {{/view}}
     {{/each}}
   {{else}}
-    <div class="spinner"></div>
+    {{view App.SpinnerView}}
   {{/if}}
   <div class="btn-area">
     {{#if view.showBackButton}}

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/common/rolling_restart_view.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/common/rolling_restart_view.hbs b/ambari-web/app/templates/common/rolling_restart_view.hbs
index 93efdb5..92dff50 100644
--- a/ambari-web/app/templates/common/rolling_restart_view.hbs
+++ b/ambari-web/app/templates/common/rolling_restart_view.hbs
@@ -68,7 +68,7 @@
 
     </table>
   {{else}}
-    <div class="spinner"></div>
+    {{view App.SpinnerView}}
   {{/if}}
   {{#if view.errors}}
     <div class="alert alert-error">

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/common/widget/gauge_widget.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/common/widget/gauge_widget.hbs b/ambari-web/app/templates/common/widget/gauge_widget.hbs
index d31d743..8fd2ee9 100644
--- a/ambari-web/app/templates/common/widget/gauge_widget.hbs
+++ b/ambari-web/app/templates/common/widget/gauge_widget.hbs
@@ -53,6 +53,6 @@
       </div>
     {{/if}}
   {{else}}
-    <div class="spinner"></div>
+    {{view App.SpinnerView}}
   {{/if}}
 </div>

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/common/widget/graph_widget.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/common/widget/graph_widget.hbs b/ambari-web/app/templates/common/widget/graph_widget.hbs
index 062253a..cfce0b2 100644
--- a/ambari-web/app/templates/common/widget/graph_widget.hbs
+++ b/ambari-web/app/templates/common/widget/graph_widget.hbs
@@ -39,6 +39,6 @@
     <div class="content"> {{view view.graphView}}</div>
 
   {{else}}
-    <div class="spinner"></div>
+    {{view App.SpinnerView}}
   {{/if}}
 </div>

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/common/widget/number_widget.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/common/widget/number_widget.hbs b/ambari-web/app/templates/common/widget/number_widget.hbs
index 2a82891..934044c 100644
--- a/ambari-web/app/templates/common/widget/number_widget.hbs
+++ b/ambari-web/app/templates/common/widget/number_widget.hbs
@@ -39,6 +39,6 @@
       </div>
     {{/if}}
   {{else}}
-    <div class="spinner"></div>
+    {{view App.SpinnerView}}
   {{/if}}
 </div>

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/common/widget/template_widget.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/common/widget/template_widget.hbs b/ambari-web/app/templates/common/widget/template_widget.hbs
index 2d2bff7..8c0dfeb9 100644
--- a/ambari-web/app/templates/common/widget/template_widget.hbs
+++ b/ambari-web/app/templates/common/widget/template_widget.hbs
@@ -39,6 +39,6 @@
       </div>
     {{/if}}
   {{else}}
-    <div class="spinner"></div>
+    {{view App.SpinnerView}}
   {{/if}}
 </div>

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/admin/highAvailability/nameNode/rollbackHA/step1.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/admin/highAvailability/nameNode/rollbackHA/step1.hbs b/ambari-web/app/templates/main/admin/highAvailability/nameNode/rollbackHA/step1.hbs
index 7e92a5c..16330b9 100644
--- a/ambari-web/app/templates/main/admin/highAvailability/nameNode/rollbackHA/step1.hbs
+++ b/ambari-web/app/templates/main/admin/highAvailability/nameNode/rollbackHA/step1.hbs
@@ -45,6 +45,6 @@
           <a {{bindAttr class=":btn controller.isNameServiceIdValid::disabled :btn-success :pull-right"}} {{action done target="view"}}>{{t common.next}} &rarr;</a>
       </div>
   {{else}}
-      <div class="spinner"></div>
+      {{view App.SpinnerView}}
   {{/if}}
 </div>

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/admin/highAvailability/nameNode/step3.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/admin/highAvailability/nameNode/step3.hbs b/ambari-web/app/templates/main/admin/highAvailability/nameNode/step3.hbs
index a3123ba..1fc5ee5 100644
--- a/ambari-web/app/templates/main/admin/highAvailability/nameNode/step3.hbs
+++ b/ambari-web/app/templates/main/admin/highAvailability/nameNode/step3.hbs
@@ -71,7 +71,7 @@
   {{{t admin.highAvailability.wizard.step3.confirm.config.body}}}
   {{view App.ServiceConfigView isNotEditableBinding="controller.isNotEditable"}}
 {{else}}
-  <div class="spinner"></div>
+  {{view App.SpinnerView}}
 {{/if}}
 </div>
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/admin/highAvailability/resourceManager/step3.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/admin/highAvailability/resourceManager/step3.hbs b/ambari-web/app/templates/main/admin/highAvailability/resourceManager/step3.hbs
index 2446f13..302e003 100644
--- a/ambari-web/app/templates/main/admin/highAvailability/resourceManager/step3.hbs
+++ b/ambari-web/app/templates/main/admin/highAvailability/resourceManager/step3.hbs
@@ -50,7 +50,7 @@
     {{view App.ServiceConfigView}}
   </div>
 {{else}}
-  <div class="spinner"></div>
+  {{view App.SpinnerView}}
 {{/if}}
 
 <div class="btn-area">

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/admin/highAvailability/resourceManager/wizard.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/admin/highAvailability/resourceManager/wizard.hbs b/ambari-web/app/templates/main/admin/highAvailability/resourceManager/wizard.hbs
index 9032d4b..a524282 100644
--- a/ambari-web/app/templates/main/admin/highAvailability/resourceManager/wizard.hbs
+++ b/ambari-web/app/templates/main/admin/highAvailability/resourceManager/wizard.hbs
@@ -36,7 +36,7 @@
             {{#if view.isLoaded}}
               {{outlet}}
             {{else}}
-                <div class="spinner"></div>
+                {{view App.SpinnerView}}
             {{/if}}
           </div>
       </div>

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/admin/kerberos.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/admin/kerberos.hbs b/ambari-web/app/templates/main/admin/kerberos.hbs
index 3dbc4d0..899b82e 100644
--- a/ambari-web/app/templates/main/admin/kerberos.hbs
+++ b/ambari-web/app/templates/main/admin/kerberos.hbs
@@ -63,5 +63,5 @@
     </div>
   {{/if}}
 {{else}}
-  <div class="spinner"></div>
+  {{view App.SpinnerView}}
 {{/if}}

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/admin/kerberos/step2.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/admin/kerberos/step2.hbs b/ambari-web/app/templates/main/admin/kerberos/step2.hbs
index ebfd35a..000593e 100644
--- a/ambari-web/app/templates/main/admin/kerberos/step2.hbs
+++ b/ambari-web/app/templates/main/admin/kerberos/step2.hbs
@@ -26,7 +26,7 @@
     {{#if isConfigsLoaded}}
       {{view App.ServicesConfigView}}
     {{else}}
-      <div class="spinner"></div>
+      {{view App.SpinnerView}}
     {{/if}}
 
     <div class="btn-area">

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/admin/kerberos/step3.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/admin/kerberos/step3.hbs b/ambari-web/app/templates/main/admin/kerberos/step3.hbs
index a3a45a6..7e576b8 100644
--- a/ambari-web/app/templates/main/admin/kerberos/step3.hbs
+++ b/ambari-web/app/templates/main/admin/kerberos/step3.hbs
@@ -77,7 +77,7 @@
             </div>
         {{/if}}
       {{else}}
-          <div class="spinner"></div>
+          {{view App.SpinnerView}}
       {{/if}}
         <div class="btn-area">
           {{#if view.showBackButton}}

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/admin/security.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/admin/security.hbs b/ambari-web/app/templates/main/admin/security.hbs
index 2355937..1179698 100644
--- a/ambari-web/app/templates/main/admin/security.hbs
+++ b/ambari-web/app/templates/main/admin/security.hbs
@@ -39,5 +39,5 @@
     </div>
   {{/if}}
 {{else}}
-  <div class="spinner"></div>
+  {{view App.SpinnerView}}
 {{/if}}

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/admin/security/add/step3.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/admin/security/add/step3.hbs b/ambari-web/app/templates/main/admin/security/add/step3.hbs
index b57c6fd..016b805 100644
--- a/ambari-web/app/templates/main/admin/security/add/step3.hbs
+++ b/ambari-web/app/templates/main/admin/security/add/step3.hbs
@@ -27,5 +27,5 @@
     </div>
   </div>
 {{else}}
-    <div class="spinner"></div>
+    {{view App.SpinnerView}}
 {{/if}}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/admin/serviceAccounts.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/admin/serviceAccounts.hbs b/ambari-web/app/templates/main/admin/serviceAccounts.hbs
index c54379e..ab0a0a6 100644
--- a/ambari-web/app/templates/main/admin/serviceAccounts.hbs
+++ b/ambari-web/app/templates/main/admin/serviceAccounts.hbs
@@ -45,6 +45,6 @@
       <p>{{t admin.misc.nothingToShow}}</p>
     {{/if}}
   {{else}}
-    <div class="spinner"></div>
+    {{view App.SpinnerView}}
   {{/if}}
 </div>

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/admin/stack_upgrade/stack_upgrade_wizard.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/admin/stack_upgrade/stack_upgrade_wizard.hbs b/ambari-web/app/templates/main/admin/stack_upgrade/stack_upgrade_wizard.hbs
index c502644..fbeb670 100644
--- a/ambari-web/app/templates/main/admin/stack_upgrade/stack_upgrade_wizard.hbs
+++ b/ambari-web/app/templates/main/admin/stack_upgrade/stack_upgrade_wizard.hbs
@@ -49,7 +49,7 @@
                     {{view App.upgradeTaskView contentBinding="view.taskDetails" outsideViewBinding="view.outsideView"}}
                   </div>
                 {{else}}
-                  <div class="clear spinner"></div>
+                  {{view App.SpinnerView classNames="clear"}}
                 {{/if}}
               {{else}}
                 <a href="#" class="pull-right" {{action toggleDetails target="view"}}>{{t admin.stackUpgrade.dialog.details.open}}</a>
@@ -69,7 +69,7 @@
                       {{view App.upgradeTaskView contentBinding="view.taskDetails" outsideViewBinding="view.outsideView"}}
                     </div>
                   {{else}}
-                    <div class="clear spinner"></div>
+                    {{view App.SpinnerView classNames="clear"}}
                   {{/if}}
                 {{else}}
                     <a href="#" class="pull-right" {{action toggleDetails target="view"}}>{{t admin.stackUpgrade.dialog.details.open}}</a>
@@ -139,7 +139,7 @@
                 <div>{{t admin.stackUpgrade.finalize.message.testServices}}</div>
               {{/if}}
             {{else}}
-              <div class="spinner"></div>
+              {{view App.SpinnerView}}
             {{/if}}
             <label class="message">
               {{view Em.Checkbox checkedBinding="view.isManualDone"}}
@@ -206,7 +206,7 @@
                   {{t admin.stackUpgrade.failedHosts.message}}
                     <a href="#" {{action showFailedHosts target="view"}}>{{view.failedHostsMessage}}</a>
                 {{else}}
-                  <div class="spinner"></div>
+                  {{view App.SpinnerView}}
                 {{/if}}
               </p>
               <p>
@@ -281,7 +281,7 @@
                 </div>
               {{/if}}
             {{else}}
-                <div class="spinner"></div>
+                {{view App.SpinnerView}}
             {{/if}}
 
               <label class="message">
@@ -341,6 +341,6 @@
     {{/if}}
   </div>
   {{#unless view.isLoaded}}
-    <div class="spinner"></div>
+    {{view App.SpinnerView}}
   {{/unless}}
 </div>

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/admin/stack_upgrade/upgrade_group.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/admin/stack_upgrade/upgrade_group.hbs b/ambari-web/app/templates/main/admin/stack_upgrade/upgrade_group.hbs
index 60cf553..7b62599 100644
--- a/ambari-web/app/templates/main/admin/stack_upgrade/upgrade_group.hbs
+++ b/ambari-web/app/templates/main/admin/stack_upgrade/upgrade_group.hbs
@@ -69,7 +69,7 @@
             {{/each}}
           </div>
         {{else}}
-          <div class="spinner"></div>
+          {{view App.SpinnerView}}
         {{/if}}
       {{/if}}
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/admin/stack_upgrade/upgrade_options.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/admin/stack_upgrade/upgrade_options.hbs b/ambari-web/app/templates/main/admin/stack_upgrade/upgrade_options.hbs
index 4bb9db6..268ea1d 100644
--- a/ambari-web/app/templates/main/admin/stack_upgrade/upgrade_options.hbs
+++ b/ambari-web/app/templates/main/admin/stack_upgrade/upgrade_options.hbs
@@ -32,7 +32,7 @@
             {{#unless view.isInUpgradeWizard}}
               {{#if method.isCheckRequestInProgress}}
                 <div class="method-precheck-message checking">
-                  <div class="spinner">{{t admin.stackVersions.version.upgrade.upgradeOptions.preCheck.msg.checking}}</div>
+                  {{view App.SpinnerView message="admin.stackVersions.version.upgrade.upgradeOptions.preCheck.msg.checking"}}
                 </div>
               {{else}}
                 <div {{bindAttr class=":method-precheck-message method.precheckResultsMessageClass"}}>

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/admin/stack_upgrade/upgrade_task.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/admin/stack_upgrade/upgrade_task.hbs b/ambari-web/app/templates/main/admin/stack_upgrade/upgrade_task.hbs
index 92455d9..66cbe80 100644
--- a/ambari-web/app/templates/main/admin/stack_upgrade/upgrade_task.hbs
+++ b/ambari-web/app/templates/main/admin/stack_upgrade/upgrade_task.hbs
@@ -64,6 +64,6 @@
       </div>
     </div>
   {{else}}
-    <div class="spinner"></div>
+    {{view App.SpinnerView}}
   {{/if}}
 {{/if}}

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/admin/stack_upgrade/upgrade_version_box.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/admin/stack_upgrade/upgrade_version_box.hbs b/ambari-web/app/templates/main/admin/stack_upgrade/upgrade_version_box.hbs
index 1bc81c5..0505289 100644
--- a/ambari-web/app/templates/main/admin/stack_upgrade/upgrade_version_box.hbs
+++ b/ambari-web/app/templates/main/admin/stack_upgrade/upgrade_version_box.hbs
@@ -72,7 +72,7 @@
     {{/if}}
   {{/if}}
   {{#if view.stateElement.isSpinner}}
-    <div {{bindAttr class="view.stateElement.class"}}></div>
+    {{view App.SpinnerView}}
   {{/if}}
 </div>
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/admin/stack_upgrade/versions.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/admin/stack_upgrade/versions.hbs b/ambari-web/app/templates/main/admin/stack_upgrade/versions.hbs
index 0e69339..2e66f52 100644
--- a/ambari-web/app/templates/main/admin/stack_upgrade/versions.hbs
+++ b/ambari-web/app/templates/main/admin/stack_upgrade/versions.hbs
@@ -50,6 +50,6 @@
       {{/if}}
     {{/each}}
   {{else}}
-    <div class="spinner"></div>
+    {{view App.SpinnerView}}
   {{/if}}
 </div>

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/alerts.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/alerts.hbs b/ambari-web/app/templates/main/alerts.hbs
index 8e056c4..4fda6a3 100644
--- a/ambari-web/app/templates/main/alerts.hbs
+++ b/ambari-web/app/templates/main/alerts.hbs
@@ -105,7 +105,7 @@
       <tr>
         <td class="first"></td>
         <td colspan="2">
-          <div class="spinner"></div>
+          {{view App.SpinnerView}}
         </td>
         <td colspan="2"></td>
       </tr>

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/alerts/definition_details.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/alerts/definition_details.hbs b/ambari-web/app/templates/main/alerts/definition_details.hbs
index 4b0f1d7..2df3fb0 100644
--- a/ambari-web/app/templates/main/alerts/definition_details.hbs
+++ b/ambari-web/app/templates/main/alerts/definition_details.hbs
@@ -231,7 +231,7 @@
         </div>
 
       {{else}}
-        <div class="spinner"></div>
+        {{view App.SpinnerView}}
       {{/if}}
 
     </div>
@@ -240,5 +240,5 @@
 
   </div>
 {{else}}
-  <div class="spinner"></div>
+  {{view App.SpinnerView}}
 {{/if}}

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/alerts/manage_alert_groups_popup.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/alerts/manage_alert_groups_popup.hbs b/ambari-web/app/templates/main/alerts/manage_alert_groups_popup.hbs
index 2d7366a..0c79b1c 100644
--- a/ambari-web/app/templates/main/alerts/manage_alert_groups_popup.hbs
+++ b/ambari-web/app/templates/main/alerts/manage_alert_groups_popup.hbs
@@ -92,5 +92,5 @@
     </div>
   </div>
 {{else}}
-  <div class="spinner"></div>
+  {{view App.SpinnerView}}
 {{/if}}

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/alerts/manage_alert_notifications_popup.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/alerts/manage_alert_notifications_popup.hbs b/ambari-web/app/templates/main/alerts/manage_alert_notifications_popup.hbs
index b0fa709..5f208a1 100644
--- a/ambari-web/app/templates/main/alerts/manage_alert_notifications_popup.hbs
+++ b/ambari-web/app/templates/main/alerts/manage_alert_notifications_popup.hbs
@@ -128,5 +128,5 @@
     </div>
   </div>
 {{else}}
-  <div class="spinner"></div>
+  {{view App.SpinnerView}}
 {{/if}}

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/charts/heatmap.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/charts/heatmap.hbs b/ambari-web/app/templates/main/charts/heatmap.hbs
index a66e4f2..43f3709 100644
--- a/ambari-web/app/templates/main/charts/heatmap.hbs
+++ b/ambari-web/app/templates/main/charts/heatmap.hbs
@@ -47,11 +47,11 @@
             {{view activeWidget.viewClass contentBinding="activeWidget" racksBinding = "racks" idBinding="activeWidget.id"}}
           </div>
         {{else}}
-          <div class="spinner"></div>
+          {{view App.SpinnerView}}
         {{/if}}
       </div>
     </div>
   {{else}}
-    <div class="spinner"></div>
+    {{view App.SpinnerView}}
   {{/if}}
 </div>

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/charts/heatmap/heatmap_rack.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/charts/heatmap/heatmap_rack.hbs b/ambari-web/app/templates/main/charts/heatmap/heatmap_rack.hbs
index c59abc7..c3fe9fe 100644
--- a/ambari-web/app/templates/main/charts/heatmap/heatmap_rack.hbs
+++ b/ambari-web/app/templates/main/charts/heatmap/heatmap_rack.hbs
@@ -47,5 +47,7 @@
         </div>
     {{/each}}
   </div>
-  <div {{bindAttr  class="view.rack.isLoaded:hidden :spinner"}}></div>
+  {{#unless view.rack.isLoaded}}
+    {{view App.SpinnerView}}
+  {{/unless}}
 </div>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/dashboard/config_history.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/dashboard/config_history.hbs b/ambari-web/app/templates/main/dashboard/config_history.hbs
index d20c514..0e2fcba 100644
--- a/ambari-web/app/templates/main/dashboard/config_history.hbs
+++ b/ambari-web/app/templates/main/dashboard/config_history.hbs
@@ -80,7 +80,7 @@
         </tr>
       {{/if}}
     {{else}}
-      <tr><td colspan="5"><div class="spinner"></div></td></tr>
+      <tr><td colspan="5">{{view App.SpinnerView}}</td></tr>
     {{/if}}
     </tbody>
 </table>

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/dashboard/widgets/hbase_links.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/dashboard/widgets/hbase_links.hbs b/ambari-web/app/templates/main/dashboard/widgets/hbase_links.hbs
index 1b6ab6c..d5e0174 100644
--- a/ambari-web/app/templates/main/dashboard/widgets/hbase_links.hbs
+++ b/ambari-web/app/templates/main/dashboard/widgets/hbase_links.hbs
@@ -84,7 +84,7 @@
                       {{/each}}
                     {{/if}}
                   {{else}}
-                    <div class="spinner"></div>
+                    {{view App.SpinnerView}}
                   {{/if}}
                 </ul>
               </div>
@@ -92,7 +92,7 @@
           {{/if}}
         </div>
       {{else}}
-        <div class="spinner"></div>
+        {{view App.SpinnerView}}
       {{/if}}
     </li>
   </ul>

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/dashboard/widgets/hdfs_links.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/dashboard/widgets/hdfs_links.hbs b/ambari-web/app/templates/main/dashboard/widgets/hdfs_links.hbs
index 847aa10..83d49b1 100644
--- a/ambari-web/app/templates/main/dashboard/widgets/hdfs_links.hbs
+++ b/ambari-web/app/templates/main/dashboard/widgets/hdfs_links.hbs
@@ -105,7 +105,7 @@
                     {{/each}}
                   {{/if}}
                 {{else}}
-                  <div class="spinner"></div>
+                  {{view App.SpinnerView}}
                 {{/if}}
               </ul>
           </div>

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/dashboard/widgets/pie_chart.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/dashboard/widgets/pie_chart.hbs b/ambari-web/app/templates/main/dashboard/widgets/pie_chart.hbs
index d5a7720..1ba2e57 100644
--- a/ambari-web/app/templates/main/dashboard/widgets/pie_chart.hbs
+++ b/ambari-web/app/templates/main/dashboard/widgets/pie_chart.hbs
@@ -48,7 +48,7 @@
           <div class="widget-content-isNA">{{t services.service.summary.notAvailable}}</div>
         {{/if}}
       {{else}}
-        <div class="spinner"></div>
+        {{view App.SpinnerView}}
       {{/if}}
     </li>
   </ul>

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/dashboard/widgets/simple_text.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/dashboard/widgets/simple_text.hbs b/ambari-web/app/templates/main/dashboard/widgets/simple_text.hbs
index ddf9697..b181aee 100644
--- a/ambari-web/app/templates/main/dashboard/widgets/simple_text.hbs
+++ b/ambari-web/app/templates/main/dashboard/widgets/simple_text.hbs
@@ -41,7 +41,7 @@
         </div>
         <div {{bindAttr class=":widget-content view.hoverContentTopClass"}}>{{view.content}}</div>
       {{else}}
-        <div class="spinner"></div>
+        {{view App.SpinnerView}}
       {{/if}}
     </li>
   </ul>

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/dashboard/widgets/uptime.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/dashboard/widgets/uptime.hbs b/ambari-web/app/templates/main/dashboard/widgets/uptime.hbs
index b4e2100..6ee51fe 100644
--- a/ambari-web/app/templates/main/dashboard/widgets/uptime.hbs
+++ b/ambari-web/app/templates/main/dashboard/widgets/uptime.hbs
@@ -46,7 +46,7 @@
           </div>
         {{/if}}
       {{else}}
-        <div class="spinner"></div>
+        {{view App.SpinnerView}}
       {{/if}}
     </li>
   </ul>

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/dashboard/widgets/yarn_links.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/dashboard/widgets/yarn_links.hbs b/ambari-web/app/templates/main/dashboard/widgets/yarn_links.hbs
index 739dab3..b6f1087 100644
--- a/ambari-web/app/templates/main/dashboard/widgets/yarn_links.hbs
+++ b/ambari-web/app/templates/main/dashboard/widgets/yarn_links.hbs
@@ -72,7 +72,7 @@
                       {{/each}}
                     {{/if}}
                   {{else}}
-                    <div class="spinner"></div>
+                    {{view App.SpinnerView}}
                   {{/if}}
                 </ul>
               </div>
@@ -80,7 +80,7 @@
           {{/if}}
         </div>
       {{else}}
-        <div class="spinner"></div>
+        {{view App.SpinnerView}}
       {{/if}}
     </li>
   </ul>

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/host.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/host.hbs b/ambari-web/app/templates/main/host.hbs
index f6bab03..817afe5 100644
--- a/ambari-web/app/templates/main/host.hbs
+++ b/ambari-web/app/templates/main/host.hbs
@@ -161,7 +161,7 @@
   </table>
 
   <div {{bindAttr class="view.filteringComplete:hidden :table-overlay"}}>
-    <div class="spinner"></div>
+    {{view App.SpinnerView}}
   </div>
 
   <div class="page-bar">

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/host/add.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/host/add.hbs b/ambari-web/app/templates/main/host/add.hbs
index 745ebd7..77110d9 100644
--- a/ambari-web/app/templates/main/host/add.hbs
+++ b/ambari-web/app/templates/main/host/add.hbs
@@ -42,7 +42,7 @@
             {{#if view.isLoaded}}
               {{outlet}}
             {{else}}
-                <div class="spinner"></div>
+                {{view App.SpinnerView}}
             {{/if}}
           </div>
       </div>

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/host/configs_service.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/host/configs_service.hbs b/ambari-web/app/templates/main/host/configs_service.hbs
index c41d09b..46d7ab5 100644
--- a/ambari-web/app/templates/main/host/configs_service.hbs
+++ b/ambari-web/app/templates/main/host/configs_service.hbs
@@ -21,6 +21,6 @@
     <div class="clearfix"></div>
     {{view App.ServiceConfigView canEditBinding="view.isConfigsEditable" filterBinding="controller.filter" columnsBinding="controller.filterColumns"}}
   {{else}}
-    <div class="spinner"></div>
+    {{view App.SpinnerView}}
   {{/if}}
 </div>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/host/details.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/host/details.hbs b/ambari-web/app/templates/main/host/details.hbs
index bcb087b..63e81eb 100644
--- a/ambari-web/app/templates/main/host/details.hbs
+++ b/ambari-web/app/templates/main/host/details.hbs
@@ -69,5 +69,5 @@
     </div>
   </div>
 {{else}}
-  <div class="spinner"></div>
+  {{view App.SpinnerView}}
 {{/if}}

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/host/host_alerts.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/host/host_alerts.hbs b/ambari-web/app/templates/main/host/host_alerts.hbs
index 19d44d7..e15b395 100644
--- a/ambari-web/app/templates/main/host/host_alerts.hbs
+++ b/ambari-web/app/templates/main/host/host_alerts.hbs
@@ -71,7 +71,7 @@
     </table>
 
   {{else}}
-    <div class="spinner"></div>
+    {{view App.SpinnerView}}
   {{/if}}
 
   <div class="page-bar">

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/service/info/configs.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/service/info/configs.hbs b/ambari-web/app/templates/main/service/info/configs.hbs
index 77739cf..139bf61 100644
--- a/ambari-web/app/templates/main/service/info/configs.hbs
+++ b/ambari-web/app/templates/main/service/info/configs.hbs
@@ -60,6 +60,6 @@
       {{/unless}}
     {{/isAccessible}}
   {{else}}
-    <div class="spinner"></div>
+    {{view App.SpinnerView}}
   {{/if}}
 </div>

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/service/info/configs_save_popup.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/service/info/configs_save_popup.hbs b/ambari-web/app/templates/main/service/info/configs_save_popup.hbs
index ed85c95..508135c 100644
--- a/ambari-web/app/templates/main/service/info/configs_save_popup.hbs
+++ b/ambari-web/app/templates/main/service/info/configs_save_popup.hbs
@@ -48,5 +48,5 @@
       </table>
   {{/if}}
 {{else}}
-  <div class="spinner"></div>
+  {{view App.SpinnerView}}
 {{/if}}

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/service/info/summary.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/service/info/summary.hbs b/ambari-web/app/templates/main/service/info/summary.hbs
index 037ab16..79c56e6 100644
--- a/ambari-web/app/templates/main/service/info/summary.hbs
+++ b/ambari-web/app/templates/main/service/info/summary.hbs
@@ -64,7 +64,7 @@
     {{#if view.serviceSummaryView}}
       {{view view.serviceSummaryView}}
     {{else}}
-      <div class="spinner"></div>
+      {{view App.SpinnerView}}
     {{/if}}
   </div>
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/service/item.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/service/item.hbs b/ambari-web/app/templates/main/service/item.hbs
index b13b1c2..52726fe 100644
--- a/ambari-web/app/templates/main/service/item.hbs
+++ b/ambari-web/app/templates/main/service/item.hbs
@@ -43,7 +43,7 @@
                   {{/each}}
                 {{/if}}
               {{else}}
-                <div class="spinner"></div>
+                {{view App.SpinnerView}}
               {{/if}}
            </ul>
           </li>
@@ -102,7 +102,7 @@
           </li>
           {{/each}}
         {{else}}
-          <div class="spinner service-button-spinner"></div>
+          {{view App.SpinnerView classNames="service-button-spinner"}}
         {{/if}}
       </ul>
     </div>

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/service/manage_configuration_groups_popup.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/service/manage_configuration_groups_popup.hbs b/ambari-web/app/templates/main/service/manage_configuration_groups_popup.hbs
index 06e09ad..d0fd103 100644
--- a/ambari-web/app/templates/main/service/manage_configuration_groups_popup.hbs
+++ b/ambari-web/app/templates/main/service/manage_configuration_groups_popup.hbs
@@ -92,5 +92,5 @@
         </div>
     </div>
   {{else}}
-    <div class="spinner"></div>
+    {{view App.SpinnerView}}
   {{/if}}

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/service/reassign.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/service/reassign.hbs b/ambari-web/app/templates/main/service/reassign.hbs
index 510fbda..2477229 100644
--- a/ambari-web/app/templates/main/service/reassign.hbs
+++ b/ambari-web/app/templates/main/service/reassign.hbs
@@ -40,7 +40,7 @@
             {{#if view.isLoaded}}
               {{outlet}}
             {{else}}
-                <div class="spinner"></div>
+                {{view App.SpinnerView}}
             {{/if}}
           </div>
       </div>

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/main/service/widgets/create/step2_add_metric.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/service/widgets/create/step2_add_metric.hbs b/ambari-web/app/templates/main/service/widgets/create/step2_add_metric.hbs
index 030ebcd..adaacff 100644
--- a/ambari-web/app/templates/main/service/widgets/create/step2_add_metric.hbs
+++ b/ambari-web/app/templates/main/service/widgets/create/step2_add_metric.hbs
@@ -53,7 +53,7 @@
         </li>
       {{/each}}
     {{else}}
-      <div class="spinner"></div>
+      {{view App.SpinnerView}}
     {{/if}}
   </ul>
 </div>

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/wizard/bootstrap_call_popup.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/wizard/bootstrap_call_popup.hbs b/ambari-web/app/templates/wizard/bootstrap_call_popup.hbs
index eb282a1..06135dc 100644
--- a/ambari-web/app/templates/wizard/bootstrap_call_popup.hbs
+++ b/ambari-web/app/templates/wizard/bootstrap_call_popup.hbs
@@ -30,5 +30,5 @@
     <div>
       {{t installer.step2.bootStrap.inProgress}}
     </div>
-    <div class="spinner"></div>
+    {{view App.SpinnerView}}
 {{/if}}

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/wizard/step3.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/wizard/step3.hbs b/ambari-web/app/templates/wizard/step3.hbs
index b34c64d..7492b6a 100644
--- a/ambari-web/app/templates/wizard/step3.hbs
+++ b/ambari-web/app/templates/wizard/step3.hbs
@@ -145,7 +145,7 @@
     {{view.message}}
     <a href="#" {{action hostWarningsPopup warnings target="controller"}}>{{view.linkText}}</a>
     {{#unless isWarningsLoaded}}
-      <div class="spinner"></div>
+      {{view App.SpinnerView}}
     {{/unless}}
   </div>
   <div class="btn-area">

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/wizard/step7.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/wizard/step7.hbs b/ambari-web/app/templates/wizard/step7.hbs
index 130f6cf..c0442e5 100644
--- a/ambari-web/app/templates/wizard/step7.hbs
+++ b/ambari-web/app/templates/wizard/step7.hbs
@@ -26,7 +26,7 @@
   {{#if isConfigsLoaded}}
     {{view App.ServicesConfigView}}
   {{else}}
-    <div class="spinner"></div>
+    {{view App.SpinnerView}}
   {{/if}}
 
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/templates/wizard/step9/step9HostTasksLogPopup.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/wizard/step9/step9HostTasksLogPopup.hbs b/ambari-web/app/templates/wizard/step9/step9HostTasksLogPopup.hbs
index 9886a3a..259782e 100644
--- a/ambari-web/app/templates/wizard/step9/step9HostTasksLogPopup.hbs
+++ b/ambari-web/app/templates/wizard/step9/step9HostTasksLogPopup.hbs
@@ -87,7 +87,7 @@
               </div>
           </div>
       {{else}}
-        <div class="spinner"></div>
+        {{view App.SpinnerView}}
       {{/if}}
     </div>
   {{/if}}

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/views.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/views.js b/ambari-web/app/views.js
index d784565..859d602 100644
--- a/ambari-web/app/views.js
+++ b/ambari-web/app/views.js
@@ -20,6 +20,7 @@
 // load all views here
 
 require('views/application');
+require('views/common/global/spinner');
 require('views/common/ajax_default_error_popup_body');
 require('views/common/chart');
 require('views/common/chart/pie');

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/app/views/common/global/spinner.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/views/common/global/spinner.js b/ambari-web/app/views/common/global/spinner.js
new file mode 100644
index 0000000..1a5beb0
--- /dev/null
+++ b/ambari-web/app/views/common/global/spinner.js
@@ -0,0 +1,32 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+var App = require('app');
+
+App.SpinnerView = Em.View.extend({
+  classNames: 'spinner',
+  message: '',
+
+  translated: function() {
+    return this.get('message') ? Em.I18n.t(this.get('message')) : '';
+  }.property('message'),
+
+  template: function() {
+    return Em.Handlebars.compile('<i class="icon-spinner icon-spin"></i>' + this.get('translated'));
+  }.property()
+});

http://git-wip-us.apache.org/repos/asf/ambari/blob/de221faf/ambari-web/test/mixins/common/reload_popup_test.js
----------------------------------------------------------------------
diff --git a/ambari-web/test/mixins/common/reload_popup_test.js b/ambari-web/test/mixins/common/reload_popup_test.js
index 28c865a..570a792 100644
--- a/ambari-web/test/mixins/common/reload_popup_test.js
+++ b/ambari-web/test/mixins/common/reload_popup_test.js
@@ -28,24 +28,25 @@ describe('App.ReloadPopupMixin', function () {
     obj = Em.Object.create(App.ReloadPopupMixin);
   });
 
-  describe('#showReloadPopup', function () {
-
-    var mockObj = {
-      key: 'value'
-    };
-
-    beforeEach(function () {
-      sinon.stub(App.ModalPopup, 'show').returns(mockObj);
-    });
-
-    afterEach(function () {
-      App.ModalPopup.show.restore();
+  describe('#popupText', function () {
+    var cases = [
+      {
+        result: Em.I18n.t('app.reloadPopup.text'),
+        title: 'should show modal popup with default message'
+      },
+      {
+        text: 'text',
+        result: 'text',
+        title: 'should show modal popup with custom message'
+      }
+    ];
+
+    cases.forEach(function (item) {
+      it(item.title, function () {
+        expect(obj.popupText(item.text)).to.equal(item.result);
+      });
     });
 
-    it('should show modal popup', function () {
-      obj.showReloadPopup();
-      expect(obj.get('reloadPopup')).to.eql(mockObj);
-    });
   });
 
   describe('#closeReloadPopup', function () {


Mime
View raw message