+ and - control current entry font size (fix #272)

This commit is contained in:
Athou
2013-06-26 13:11:53 +02:00
parent e0ea822333
commit 790c3bce14
27 changed files with 471 additions and 399 deletions

View File

@@ -655,6 +655,7 @@ function($scope, $stateParams, $http, $route, $window, EntryService, SettingsSer
$scope.errorCount = 0;
$scope.timestamp = 0;
$scope.entries = [];
$scope.font_size = 0;
$scope.settingsService = SettingsService;
$scope.$watch('settingsService.settings.readingMode', function(newValue,
@@ -900,7 +901,7 @@ function($scope, $stateParams, $http, $route, $window, EntryService, SettingsSer
}
}
};
Mousetrap.bind('j', function(e) {
$scope.$apply(function() {
$scope.navigationMode = 'keyboard';
@@ -986,6 +987,19 @@ function($scope, $stateParams, $http, $route, $window, EntryService, SettingsSer
$scope.markAll();
});
});
Mousetrap.bind('+', function(e) {
$scope.$apply(function() {
$scope.font_size = Math.min($scope.font_size + 1, 5);
});
});
Mousetrap.bind('-', function(e) {
$scope.$apply(function() {
$scope.font_size = Math.max($scope.font_size - 1, 0);
});
});
Mousetrap.bind('?', function(e) {
$scope.$apply(function() {
$scope.shortcutsModal = true;