From 5806fa8f51dce0c74c98af7f35ecd610d09eaf46 Mon Sep 17 00:00:00 2001 From: DF1E Date: Wed, 9 Jul 2014 10:43:01 +0200 Subject: [PATCH] make history item translatable --- src/acr/browser/lightning/BrowserApp.java | 11 +++++++++++ src/acr/browser/lightning/HistoryPageVariables.java | 2 +- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/src/acr/browser/lightning/BrowserApp.java b/src/acr/browser/lightning/BrowserApp.java index 3b01e4f..f59c4ab 100644 --- a/src/acr/browser/lightning/BrowserApp.java +++ b/src/acr/browser/lightning/BrowserApp.java @@ -1,7 +1,18 @@ package acr.browser.lightning; import android.app.Application; +import android.content.Context; public class BrowserApp extends Application { + private static Context context; + + public void onCreate() { + super.onCreate(); + context = getApplicationContext(); + } + + public static Context getAppContext() { + return context; + } } diff --git a/src/acr/browser/lightning/HistoryPageVariables.java b/src/acr/browser/lightning/HistoryPageVariables.java index 1abf411..f2d95aa 100644 --- a/src/acr/browser/lightning/HistoryPageVariables.java +++ b/src/acr/browser/lightning/HistoryPageVariables.java @@ -4,7 +4,7 @@ package acr.browser.lightning; public class HistoryPageVariables { - public static final String Heading = "History
"; + public static final String Heading = "" + BrowserApp.getAppContext().getString(R.string.action_history)+ "
"; public static final String Part1 = "

"; public static final String Part3 = "

";