consistently use title case when formatting counts

This commit is contained in:
rolux 2013-07-18 08:14:14 +00:00
parent 5e3e4de939
commit f8179ea48a
6 changed files with 10 additions and 11 deletions

View file

@ -66,7 +66,7 @@ pandora.ui.clipsView = function(videoRatio) {
init: function(data) { init: function(data) {
var items = data.items; var items = data.items;
$status.html( $status.html(
Ox.toTitleCase(Ox.formatCount(items, 'Clip')) Ox.toTitleCase(Ox.formatCount(items, 'clip'))
); );
} }
}); });

View file

@ -157,7 +157,7 @@ pandora.ui.documentsDialog = function(options) {
.bindEvent({ .bindEvent({
init: function(data) { init: function(data) {
$status.html( $status.html(
Ox.formatCount(data.items, 'file') Ox.toTitleCase(Ox.formatCount(data.items, 'file'))
); );
}, },
load: function() { load: function() {

View file

@ -6,7 +6,6 @@ pandora.ui.namesDialog = function() {
var height = Math.round((window.innerHeight - 48) * 0.9), var height = Math.round((window.innerHeight - 48) * 0.9),
width = 576 + Ox.UI.SCROLLBAR_SIZE, width = 576 + Ox.UI.SCROLLBAR_SIZE,
numberOfNames = 0,
$findInput = Ox.Input({ $findInput = Ox.Input({
changeOnKeypress: true, changeOnKeypress: true,
@ -73,8 +72,9 @@ pandora.ui.namesDialog = function() {
}) })
.bindEvent({ .bindEvent({
init: function(data) { init: function(data) {
numberOfNames = data.items; $status.html(
$status.html(Ox.formatCount(numberOfNames, 'name')); Ox.toTitleCase(Ox.formatCount(data.items, 'name'))
);
}, },
open: function(data) { open: function(data) {
$list.find('.OxItem.OxSelected > .OxCell.OxColumnSortname') $list.find('.OxItem.OxSelected > .OxCell.OxColumnSortname')

View file

@ -246,7 +246,7 @@ pandora.ui.navigationView = function(type, videoRatio) {
} }
function updateStatusbar(items) { function updateStatusbar(items) {
$status.html(Ox.toTitleCase(Ox.formatCount(items, 'Clip'))); $status.html(Ox.toTitleCase(Ox.formatCount(items, 'clip')));
} }
if (type == 'map') { if (type == 'map') {

View file

@ -4,7 +4,6 @@ pandora.ui.titlesDialog = function() {
var height = Math.round((window.innerHeight - 48) * 0.9), var height = Math.round((window.innerHeight - 48) * 0.9),
width = 512 + Ox.UI.SCROLLBAR_SIZE, width = 512 + Ox.UI.SCROLLBAR_SIZE,
numberOfTitles = 0,
$findInput = Ox.Input({ $findInput = Ox.Input({
changeOnKeypress: true, changeOnKeypress: true,
@ -62,8 +61,9 @@ pandora.ui.titlesDialog = function() {
}) })
.bindEvent({ .bindEvent({
init: function(data) { init: function(data) {
numberOfTitles = data.items; $status.html(
$status.html(Ox.formatCount(numberOfTitles, 'title')); Ox.toTitleCase(Ox.formatCount(data.items, 'title'))
);
}, },
open: function(data) { open: function(data) {
$list.find('.OxItem.OxSelected > .OxCell.OxColumnSorttitle') $list.find('.OxItem.OxSelected > .OxCell.OxColumnSorttitle')

View file

@ -922,9 +922,8 @@ pandora.ui.usersDialog = function() {
function setTo() { function setTo() {
var recipients = getTo().length; var recipients = getTo().length;
//fixme shoule be No not no from formatCount here
$mailForm.values({ $mailForm.values({
to: Ox.formatCount(recipients, 'recipient') to: Ox.formatCount(recipients, 'recipient').replace('no', 'No')
}); });
} }