Skip to content

Commit

Permalink
use new locale method names
Browse files Browse the repository at this point in the history
  • Loading branch information
ddelbondio committed Oct 1, 2006
1 parent 28747d8 commit e640e42
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion src/translation/AgaviCurrencyFormatter.class.php
Expand Up @@ -84,8 +84,20 @@ public function translate($message, $domain, $locale)
public function localeChanged($newLocale)
{
if(!$this->hasCustomFormat) {
$this->parseFormatString($newLocale->getNumberFormat());
$this->parseFormatString($newLocale->getCurrencyFormat('__default'));
}
if($currency = $newLocale->getLocaleCurrency()) {
if($symbol = $newLocale->getCurrencySymbol($currency)) {
$this->currencySymbol = $symbol;
} else {
$this->currencySymbol = $currency;
}
}
}

public function getCurrencySymbol()
{
return $this->currencySymbol;
}
}

Expand Down

0 comments on commit e640e42

Please sign in to comment.