Browse Source

Merge pull request #95 from DF1E/master

make history item translatable
master
Anthony Restaino 11 years ago
parent
commit
690fde513a
  1. 11
      src/acr/browser/lightning/BrowserApp.java
  2. 2
      src/acr/browser/lightning/HistoryPageVariables.java

11
src/acr/browser/lightning/BrowserApp.java

@ -1,7 +1,18 @@
package acr.browser.lightning; package acr.browser.lightning;
import android.app.Application; import android.app.Application;
import android.content.Context;
public class BrowserApp extends Application { public class BrowserApp extends Application {
private static Context context;
public void onCreate() {
super.onCreate();
context = getApplicationContext();
}
public static Context getAppContext() {
return context;
}
} }

2
src/acr/browser/lightning/HistoryPageVariables.java

@ -4,7 +4,7 @@
package acr.browser.lightning; package acr.browser.lightning;
public class HistoryPageVariables { public class HistoryPageVariables {
public static final String Heading = "<!DOCTYPE html><html xmlns=\"http://www.w3.org/1999/xhtml\"><head><meta content=\"en-us\" http-equiv=\"Content-Language\" /><meta content=\"text/html; charset=utf-8\" http-equiv=\"Content-Type\" /><meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\"><title>History</title></head><style>body { background: #e1e1e1;}.box { vertical-align:middle;position:relative; display: block; margin: 10px;padding-left:10px;padding-right:10px;padding-top:5px;padding-bottom:5px; background-color:#fff;box-shadow: 0px 3px rgba( 0, 0, 0, 0.1 );font-family: Arial;color: #444;font-size: 12px;-moz-border-radius: 2px;-webkit-border-radius: 2px;border-radius: 2px;}.box a { width: 100%; height: 100%; position: absolute; left: 0; top: 0;}.black {color: black;font-size: 15px;font-family: Arial; white-space: nowrap; overflow: hidden;margin:auto; text-overflow: ellipsis; -o-text-overflow: ellipsis; -ms-text-overflow: ellipsis;}.font {color: gray;font-size: 10px;font-family: Arial; white-space: nowrap; overflow: hidden;margin:auto; text-overflow: ellipsis; -o-text-overflow: ellipsis; -ms-text-overflow: ellipsis;}</style><body><div id=\"content\">"; public static final String Heading = "<!DOCTYPE html><html xmlns=\"http://www.w3.org/1999/xhtml\"><head><meta content=\"en-us\" http-equiv=\"Content-Language\" /><meta content=\"text/html; charset=utf-8\" http-equiv=\"Content-Type\" /><meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\"><title>" + BrowserApp.getAppContext().getString(R.string.action_history)+ "</title></head><style>body { background: #e1e1e1;}.box { vertical-align:middle;position:relative; display: block; margin: 10px;padding-left:10px;padding-right:10px;padding-top:5px;padding-bottom:5px; background-color:#fff;box-shadow: 0px 3px rgba( 0, 0, 0, 0.1 );font-family: Arial;color: #444;font-size: 12px;-moz-border-radius: 2px;-webkit-border-radius: 2px;border-radius: 2px;}.box a { width: 100%; height: 100%; position: absolute; left: 0; top: 0;}.black {color: black;font-size: 15px;font-family: Arial; white-space: nowrap; overflow: hidden;margin:auto; text-overflow: ellipsis; -o-text-overflow: ellipsis; -ms-text-overflow: ellipsis;}.font {color: gray;font-size: 10px;font-family: Arial; white-space: nowrap; overflow: hidden;margin:auto; text-overflow: ellipsis; -o-text-overflow: ellipsis; -ms-text-overflow: ellipsis;}</style><body><div id=\"content\">";
public static final String Part1 = "<div class=\"box\"><a href=\""; public static final String Part1 = "<div class=\"box\"><a href=\"";
public static final String Part2 = "\"></a><p class=\"black\">"; public static final String Part2 = "\"></a><p class=\"black\">";
public static final String Part3 = "</p><p class=\"font\">"; public static final String Part3 = "</p><p class=\"font\">";

Loading…
Cancel
Save