mirror of
https://github.com/inverse-inc/sogo.git
synced 2026-07-15 05:14:53 +00:00
(js,css) Improve keyboard shortcuts
- Defined some hotkeys in all modules; - Added generation of cheat sheet.
This commit is contained in:
@@ -212,7 +212,7 @@
|
||||
this.$$cards = [];
|
||||
}
|
||||
this.idsMap = {};
|
||||
this.$cards = []; // TODO Keep the "selected" state of cards
|
||||
this.$cards = [];
|
||||
// Extend instance with all attributes of data except headers
|
||||
angular.forEach(data, function(value, key) {
|
||||
if (key != 'headers' && key != 'cards') {
|
||||
@@ -370,6 +370,16 @@
|
||||
return _.find(this.$cards, function(card) { return card.id == _this.selectedCard; });
|
||||
};
|
||||
|
||||
/**
|
||||
* @function $selectedCardIndex
|
||||
* @memberof AddressBook.prototype
|
||||
* @desc Return the index of the currently visible card.
|
||||
* @returns a number or undefined if no card is selected
|
||||
*/
|
||||
AddressBook.prototype.$selectedCardIndex = function() {
|
||||
return _.indexOf(_.map(this.$cards, 'id'), this.selectedCard);
|
||||
};
|
||||
|
||||
/**
|
||||
* @function $selectedCards
|
||||
* @memberof AddressBook.prototype
|
||||
|
||||
Reference in New Issue
Block a user