Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(532)

Unified Diff: components/payments/currency_formatter.h

Issue 2629883004: [Payment Request] Update the CurrencyStringFormatter to call the native impl. (Closed)
Patch Set: CurrencyStringFormatter -> CurrencyFormatter Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: components/payments/currency_formatter.h
diff --git a/components/payments/currency_formatter.h b/components/payments/currency_formatter.h
index 06695a8479152385c5f30acfff5dd90df3fbd4ba..2794b37dccec65344dd464477185ae63e976f669 100644
--- a/components/payments/currency_formatter.h
+++ b/components/payments/currency_formatter.h
@@ -41,9 +41,14 @@ class CurrencyFormatter {
// formatter, this method will return |amount|.
base::string16 Format(const std::string& amount);
+ // Returns the formatted currency code (<= 6 characters including ellipsis if
+ // applicable).
+ std::string formatted_currency_code() { return formatted_currency_code_; }
+
private:
const icu::Locale locale_;
std::unique_ptr<icu::UnicodeString> currency_code_;
+ std::string formatted_currency_code_;
std::unique_ptr<icu::NumberFormat> icu_formatter_;
DISALLOW_COPY_AND_ASSIGN(CurrencyFormatter);
« no previous file with comments | « components/payments/android/currency_formatter_android.cc ('k') | components/payments/currency_formatter.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698