Skip to content

Commit

Permalink
Merge pull request eclipse-che#2340 from eclipse/improveSlider
Browse files Browse the repository at this point in the history
change basic measurement unit for RAM after model changed
  • Loading branch information
Oleksii Orel authored Sep 6, 2016
2 parents 3be7700 + 372cb6b commit 6c5f8cb
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ export class CheWorkspaceRamAllocationSliderController {
$scope.$watch(() => {
return this.ngModel;
}, () => {
this.inputVal = this.init(this.ngModel / 1024);
this.inputVal = this.init(this.ngModel / Math.pow(1024,3));
});
}

Expand All @@ -47,7 +47,7 @@ export class CheWorkspaceRamAllocationSliderController {
if (!this.inputVal) {
return;
}
this.ngModel = this.inputVal * 1024;
this.ngModel = this.inputVal * Math.pow(1024,3);

this.$timeout(() => {
this.cheOnChange();
Expand Down

0 comments on commit 6c5f8cb

Please sign in to comment.