2 * Copyright © 2016-2019 Soren Stoutner <soren@stoutner.com>.
4 * This file is part of Privacy Browser <https://www.stoutner.com/privacy-browser>.
6 * Privacy Browser is free software: you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation, either version 3 of the License, or
9 * (at your option) any later version.
11 * Privacy Browser is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
16 * You should have received a copy of the GNU General Public License
17 * along with Privacy Browser. If not, see <http://www.gnu.org/licenses/>.
20 package com.stoutner.privacybrowser.fragments;
22 import android.annotation.SuppressLint;
23 import android.content.Context;
24 import android.content.SharedPreferences;
25 import android.content.pm.PackageManager;
26 import android.content.pm.Signature;
27 import android.os.Build;
28 import android.os.Bundle;
29 import android.preference.PreferenceManager;
30 import android.text.SpannableStringBuilder;
31 import android.text.Spanned;
32 import android.text.style.ForegroundColorSpan;
33 import android.view.LayoutInflater;
34 import android.view.View;
35 import android.view.ViewGroup;
36 import android.webkit.WebView;
37 import android.widget.TextView;
39 import androidx.annotation.NonNull;
40 import androidx.fragment.app.Fragment;
42 import com.stoutner.privacybrowser.BuildConfig;
43 import com.stoutner.privacybrowser.R;
44 import com.stoutner.privacybrowser.activities.MainWebViewActivity;
46 import java.io.ByteArrayInputStream;
47 import java.io.InputStream;
48 import java.math.BigInteger;
49 import java.security.Principal;
50 import java.security.cert.CertificateException;
51 import java.security.cert.CertificateFactory;
52 import java.security.cert.X509Certificate;
53 import java.text.DateFormat;
54 import java.util.Date;
56 public class AboutTabFragment extends Fragment {
57 // Track the current tab number.
58 private int tabNumber;
60 // Store the tab number in the arguments bundle.
61 public static AboutTabFragment createTab(int tab) {
63 Bundle bundle = new Bundle();
65 // Store the tab number in the bundle.
66 bundle.putInt("Tab", tab);
68 // Add the bundle to the fragment.
69 AboutTabFragment aboutTabFragment = new AboutTabFragment();
70 aboutTabFragment.setArguments(bundle);
72 // Return the new fragment.
73 return aboutTabFragment;
77 public void onCreate(Bundle savedInstanceState) {
78 // Run the default commands.
79 super.onCreate(savedInstanceState);
81 // Remove the lint warning that `getArguments()` might be null.
82 assert getArguments() != null;
84 // Store the tab number in a class variable.
85 tabNumber = getArguments().getInt("Tab");
89 public View onCreateView(@NonNull LayoutInflater layoutInflater, ViewGroup container, Bundle savedInstanceState) {
90 // Create a tab layout view.
93 // Get a handle for the context and assert that it isn't null.
94 Context context = getContext();
95 assert context != null;
97 // Get a handle for the shared preferences.
98 SharedPreferences sharedPreferences = PreferenceManager.getDefaultSharedPreferences(context);
100 // Get the theme preference.
101 boolean darkTheme = sharedPreferences.getBoolean("dark_theme", false);
103 // Load the tabs. Tab numbers start at 0.
104 if (tabNumber == 0) { // Load the about tab.
105 // Setting false at the end of inflater.inflate does not attach the inflated layout as a child of container. The fragment will take care of attaching the root automatically.
106 tabLayout = layoutInflater.inflate(R.layout.about_tab_version, container, false);
108 // Get handles for the `TextViews`.
109 TextView versionTextView = tabLayout.findViewById(R.id.version);
110 TextView brandTextView = tabLayout.findViewById(R.id.brand);
111 TextView manufacturerTextView = tabLayout.findViewById(R.id.manufacturer);
112 TextView modelTextView = tabLayout.findViewById(R.id.model);
113 TextView deviceTextView = tabLayout.findViewById(R.id.device);
114 TextView bootloaderTextView = tabLayout.findViewById(R.id.bootloader);
115 TextView radioTextView = tabLayout.findViewById(R.id.radio);
116 TextView androidTextView = tabLayout.findViewById(R.id.android);
117 TextView securityPatchTextView = tabLayout.findViewById(R.id.security_patch);
118 TextView buildTextView = tabLayout.findViewById(R.id.build);
119 TextView webViewTextView = tabLayout.findViewById(R.id.webview);
120 TextView orbotTextView = tabLayout.findViewById(R.id.orbot);
121 TextView openKeychainTextView = tabLayout.findViewById(R.id.open_keychain);
122 TextView easyListTextView = tabLayout.findViewById(R.id.easylist);
123 TextView easyPrivacyTextView = tabLayout.findViewById(R.id.easyprivacy);
124 TextView fanboyAnnoyanceTextView = tabLayout.findViewById(R.id.fanboy_annoyance);
125 TextView fanboySocialTextView = tabLayout.findViewById(R.id.fanboy_social);
126 TextView ultraPrivacyTextView = tabLayout.findViewById(R.id.ultraprivacy);
127 TextView certificateIssuerDNTextView = tabLayout.findViewById(R.id.certificate_issuer_dn);
128 TextView certificateSubjectDNTextView = tabLayout.findViewById(R.id.certificate_subject_dn);
129 TextView certificateStartDateTextView = tabLayout.findViewById(R.id.certificate_start_date);
130 TextView certificateEndDateTextView = tabLayout.findViewById(R.id.certificate_end_date);
131 TextView certificateVersionTextView = tabLayout.findViewById(R.id.certificate_version);
132 TextView certificateSerialNumberTextView = tabLayout.findViewById(R.id.certificate_serial_number);
133 TextView certificateSignatureAlgorithmTextView = tabLayout.findViewById(R.id.certificate_signature_algorithm);
136 String version = getString(R.string.version) + " " + BuildConfig.VERSION_NAME + " (" + getString(R.string.version_code) + " " + Integer.toString(BuildConfig.VERSION_CODE) + ")";
137 String brandLabel = getString(R.string.brand) + " ";
138 String manufacturerLabel = getString(R.string.manufacturer) + " ";
139 String modelLabel = getString(R.string.model) + " ";
140 String deviceLabel = getString(R.string.device) + " ";
141 String bootloaderLabel = getString(R.string.bootloader) + " ";
142 String androidLabel = getString(R.string.android) + " ";
143 String buildLabel = getString(R.string.build) + " ";
144 String webViewLabel = getString(R.string.webview) + " ";
145 String easyListLabel = getString(R.string.easylist_label) + " ";
146 String easyPrivacyLabel = getString(R.string.easyprivacy_label) + " ";
147 String fanboyAnnoyanceLabel = getString(R.string.fanboy_annoyance_label) + " ";
148 String fanboySocialLabel = getString(R.string.fanboy_social_label) + " ";
149 String ultraPrivacyLabel = getString(R.string.ultraprivacy_label) + " ";
150 String issuerDNLabel = getString(R.string.issuer_dn) + " ";
151 String subjectDNLabel = getString(R.string.subject_dn) + " ";
152 String startDateLabel = getString(R.string.start_date) + " ";
153 String endDateLabel = getString(R.string.end_date) + " ";
154 String certificateVersionLabel = getString(R.string.certificate_version) + " ";
155 String serialNumberLabel = getString(R.string.serial_number) + " ";
156 String signatureAlgorithmLabel = getString(R.string.signature_algorithm) + " ";
158 // `webViewLayout` is only used to get the default user agent from `bare_webview`. It is not used to render content on the screen.
159 View webViewLayout = layoutInflater.inflate(R.layout.bare_webview, container, false);
160 WebView tabLayoutWebView = webViewLayout.findViewById(R.id.bare_webview);
161 String userAgentString = tabLayoutWebView.getSettings().getUserAgentString();
163 // Get the device's information and store it in strings.
164 String brand = Build.BRAND;
165 String manufacturer = Build.MANUFACTURER;
166 String model = Build.MODEL;
167 String device = Build.DEVICE;
168 String bootloader = Build.BOOTLOADER;
169 String radio = Build.getRadioVersion();
170 String android = Build.VERSION.RELEASE + " (" + getString(R.string.api) + " " + Integer.toString(Build.VERSION.SDK_INT) + ")";
171 String build = Build.DISPLAY;
172 // Select the substring that begins after `Chrome/` and goes until the next ` `.
173 String webView = userAgentString.substring(userAgentString.indexOf("Chrome/") + 7, userAgentString.indexOf(" ", userAgentString.indexOf("Chrome/")));
175 // Get the Orbot version name if Orbot is installed.
178 // Store the version name.
179 orbot = context.getPackageManager().getPackageInfo("org.torproject.android", 0).versionName;
180 } catch (PackageManager.NameNotFoundException exception) { // Orbot is not installed.
184 // Get the OpenKeychain version name if it is installed.
187 // Store the version name.
188 openKeychain = context.getPackageManager().getPackageInfo("org.sufficientlysecure.keychain", 0).versionName;
189 } catch (PackageManager.NameNotFoundException exception) { // OpenKeychain is not installed.
193 // Create a `SpannableStringBuilder` for the hardware and software `TextViews` that needs multiple colors of text.
194 SpannableStringBuilder brandStringBuilder = new SpannableStringBuilder(brandLabel + brand);
195 SpannableStringBuilder manufacturerStringBuilder = new SpannableStringBuilder(manufacturerLabel + manufacturer);
196 SpannableStringBuilder modelStringBuilder = new SpannableStringBuilder(modelLabel + model);
197 SpannableStringBuilder deviceStringBuilder = new SpannableStringBuilder(deviceLabel + device);
198 SpannableStringBuilder bootloaderStringBuilder = new SpannableStringBuilder(bootloaderLabel + bootloader);
199 SpannableStringBuilder androidStringBuilder = new SpannableStringBuilder(androidLabel + android);
200 SpannableStringBuilder buildStringBuilder = new SpannableStringBuilder(buildLabel + build);
201 SpannableStringBuilder webViewStringBuilder = new SpannableStringBuilder(webViewLabel + webView);
202 SpannableStringBuilder easyListStringBuilder = new SpannableStringBuilder(easyListLabel + MainWebViewActivity.easyListVersion);
203 SpannableStringBuilder easyPrivacyStringBuilder = new SpannableStringBuilder(easyPrivacyLabel + MainWebViewActivity.easyPrivacyVersion);
204 SpannableStringBuilder fanboyAnnoyanceStringBuilder = new SpannableStringBuilder(fanboyAnnoyanceLabel + MainWebViewActivity.fanboysAnnoyanceVersion);
205 SpannableStringBuilder fanboySocialStringBuilder = new SpannableStringBuilder(fanboySocialLabel + MainWebViewActivity.fanboysSocialVersion);
206 SpannableStringBuilder ultraPrivacyStringBuilder = new SpannableStringBuilder(ultraPrivacyLabel + MainWebViewActivity.ultraPrivacyVersion);
208 // Create the `blueColorSpan` variable.
209 ForegroundColorSpan blueColorSpan;
211 // Set `blueColorSpan` according to the theme. We have to use the deprecated `getColor()` until API >= 23.
213 //noinspection deprecation
214 blueColorSpan = new ForegroundColorSpan(getResources().getColor(R.color.blue_400));
216 //noinspection deprecation
217 blueColorSpan = new ForegroundColorSpan(getResources().getColor(R.color.blue_700));
220 // Setup the spans to display the device information in blue. `SPAN_INCLUSIVE_INCLUSIVE` allows the span to grow in either direction.
221 brandStringBuilder.setSpan(blueColorSpan, brandLabel.length(), brandStringBuilder.length(), Spanned.SPAN_INCLUSIVE_INCLUSIVE);
222 manufacturerStringBuilder.setSpan(blueColorSpan, manufacturerLabel.length(), manufacturerStringBuilder.length(), Spanned.SPAN_INCLUSIVE_INCLUSIVE);
223 modelStringBuilder.setSpan(blueColorSpan, modelLabel.length(), modelStringBuilder.length(), Spanned.SPAN_INCLUSIVE_INCLUSIVE);
224 deviceStringBuilder.setSpan(blueColorSpan, deviceLabel.length(), deviceStringBuilder.length(), Spanned.SPAN_INCLUSIVE_INCLUSIVE);
225 bootloaderStringBuilder.setSpan(blueColorSpan, bootloaderLabel.length(), bootloaderStringBuilder.length(), Spanned.SPAN_INCLUSIVE_INCLUSIVE);
226 androidStringBuilder.setSpan(blueColorSpan, androidLabel.length(), androidStringBuilder.length(), Spanned.SPAN_INCLUSIVE_INCLUSIVE);
227 buildStringBuilder.setSpan(blueColorSpan, buildLabel.length(), buildStringBuilder.length(), Spanned.SPAN_INCLUSIVE_INCLUSIVE);
228 webViewStringBuilder.setSpan(blueColorSpan, webViewLabel.length(), webViewStringBuilder.length(), Spanned.SPAN_INCLUSIVE_INCLUSIVE);
229 easyListStringBuilder.setSpan(blueColorSpan, easyListLabel.length(), easyListStringBuilder.length(), Spanned.SPAN_INCLUSIVE_EXCLUSIVE);
230 easyPrivacyStringBuilder.setSpan(blueColorSpan, easyPrivacyLabel.length(), easyPrivacyStringBuilder.length(), Spanned.SPAN_INCLUSIVE_INCLUSIVE);
231 fanboyAnnoyanceStringBuilder.setSpan(blueColorSpan, fanboyAnnoyanceLabel.length(), fanboyAnnoyanceStringBuilder.length(), Spanned.SPAN_INCLUSIVE_INCLUSIVE);
232 fanboySocialStringBuilder.setSpan(blueColorSpan, fanboySocialLabel.length(), fanboySocialStringBuilder.length(), Spanned.SPAN_INCLUSIVE_INCLUSIVE);
233 ultraPrivacyStringBuilder.setSpan(blueColorSpan, ultraPrivacyLabel.length(), ultraPrivacyStringBuilder.length(), Spanned.SPAN_INCLUSIVE_INCLUSIVE);
235 // Display the strings in the text boxes.
236 versionTextView.setText(version);
237 brandTextView.setText(brandStringBuilder);
238 manufacturerTextView.setText(manufacturerStringBuilder);
239 modelTextView.setText(modelStringBuilder);
240 deviceTextView.setText(deviceStringBuilder);
241 bootloaderTextView.setText(bootloaderStringBuilder);
242 androidTextView.setText(androidStringBuilder);
243 buildTextView.setText(buildStringBuilder);
244 webViewTextView.setText(webViewStringBuilder);
245 easyListTextView.setText(easyListStringBuilder);
246 easyPrivacyTextView.setText(easyPrivacyStringBuilder);
247 fanboyAnnoyanceTextView.setText(fanboyAnnoyanceStringBuilder);
248 fanboySocialTextView.setText(fanboySocialStringBuilder);
249 ultraPrivacyTextView.setText(ultraPrivacyStringBuilder);
251 // Build.VERSION.SECURITY_PATCH is only available for SDK_INT >= 23.
252 if (Build.VERSION.SDK_INT >= 23) {
253 String securityPatchLabel = getString(R.string.security_patch) + " ";
254 String securityPatch = Build.VERSION.SECURITY_PATCH;
255 SpannableStringBuilder securityPatchStringBuilder = new SpannableStringBuilder(securityPatchLabel + securityPatch);
256 securityPatchStringBuilder.setSpan(blueColorSpan, securityPatchLabel.length(), securityPatchStringBuilder.length(), Spanned.SPAN_INCLUSIVE_INCLUSIVE);
257 securityPatchTextView.setText(securityPatchStringBuilder);
258 } else { // SDK_INT < 23.
259 securityPatchTextView.setVisibility(View.GONE);
262 // Only populate the radio text view if there is a radio in the device.
263 if (!radio.isEmpty()) {
264 String radioLabel = getString(R.string.radio) + " ";
265 SpannableStringBuilder radioStringBuilder = new SpannableStringBuilder(radioLabel + radio);
266 radioStringBuilder.setSpan(blueColorSpan, radioLabel.length(), radioStringBuilder.length(), Spanned.SPAN_INCLUSIVE_INCLUSIVE);
267 radioTextView.setText(radioStringBuilder);
268 } else { // This device does not have a radio.
269 radioTextView.setVisibility(View.GONE);
272 // Only populate the Orbot text view if it is installed.
273 if (!orbot.isEmpty()) {
274 String orbotLabel = getString(R.string.orbot) + " ";
275 SpannableStringBuilder orbotStringBuilder = new SpannableStringBuilder(orbotLabel + orbot);
276 orbotStringBuilder.setSpan(blueColorSpan, orbotLabel.length(), orbotStringBuilder.length(), Spanned.SPAN_INCLUSIVE_INCLUSIVE);
277 orbotTextView.setText(orbotStringBuilder);
278 } else { // Orbot is not installed.
279 orbotTextView.setVisibility(View.GONE);
282 // Only populate the OpenKeychain text view if it is installed.
283 if (!openKeychain.isEmpty()) {
284 String openKeychainLabel = getString(R.string.openkeychain) + " ";
285 SpannableStringBuilder openKeychainStringBuilder = new SpannableStringBuilder(openKeychainLabel + openKeychain);
286 openKeychainStringBuilder.setSpan(blueColorSpan, openKeychainLabel.length(), openKeychainStringBuilder.length(), Spanned.SPAN_INCLUSIVE_INCLUSIVE);
287 openKeychainTextView.setText(openKeychainStringBuilder);
288 } else { //OpenKeychain is not installed.
289 openKeychainTextView.setVisibility(View.GONE);
292 // Display the package signature.
294 // Get the first package signature. Suppress the lint warning about the need to be careful in implementing comparison of certificates for security purposes.
295 @SuppressLint("PackageManagerGetSignatures") Signature packageSignature = getContext().getPackageManager().getPackageInfo(getContext().getPackageName(), PackageManager.GET_SIGNATURES).signatures[0];
297 // Convert the signature to a `byte[]` `InputStream`.
298 InputStream certificateByteArrayInputStream = new ByteArrayInputStream(packageSignature.toByteArray());
300 // Display the certificate information on the screen.
302 // Instantiate a `CertificateFactory`.
303 CertificateFactory certificateFactory = CertificateFactory.getInstance("X509");
305 // Generate an `X509Certificate`.
306 X509Certificate x509Certificate = (X509Certificate) certificateFactory.generateCertificate(certificateByteArrayInputStream);
308 // Store the individual sections of the certificate that we are interested in.
309 Principal issuerDNPrincipal = x509Certificate.getIssuerDN();
310 Principal subjectDNPrincipal = x509Certificate.getSubjectDN();
311 Date startDate = x509Certificate.getNotBefore();
312 Date endDate = x509Certificate.getNotAfter();
313 int certificateVersion = x509Certificate.getVersion();
314 BigInteger serialNumberBigInteger = x509Certificate.getSerialNumber();
315 String signatureAlgorithmNameString = x509Certificate.getSigAlgName();
317 // Create a `SpannableStringBuilder` for each `TextView` that needs multiple colors of text.
318 SpannableStringBuilder issuerDNStringBuilder = new SpannableStringBuilder(issuerDNLabel + issuerDNPrincipal.toString());
319 SpannableStringBuilder subjectDNStringBuilder = new SpannableStringBuilder(subjectDNLabel + subjectDNPrincipal.toString());
320 SpannableStringBuilder startDateStringBuilder = new SpannableStringBuilder(startDateLabel + DateFormat.getDateTimeInstance(DateFormat.MEDIUM, DateFormat.LONG).format(startDate));
321 SpannableStringBuilder endDataStringBuilder = new SpannableStringBuilder(endDateLabel + DateFormat.getDateTimeInstance(DateFormat.MEDIUM, DateFormat.LONG).format(endDate));
322 SpannableStringBuilder certificateVersionStringBuilder = new SpannableStringBuilder(certificateVersionLabel + certificateVersion);
323 SpannableStringBuilder serialNumberStringBuilder = new SpannableStringBuilder(serialNumberLabel + serialNumberBigInteger);
324 SpannableStringBuilder signatureAlgorithmStringBuilder = new SpannableStringBuilder(signatureAlgorithmLabel + signatureAlgorithmNameString);
326 // Setup the spans to display the device information in blue. `SPAN_INCLUSIVE_INCLUSIVE` allows the span to grow in either direction.
327 issuerDNStringBuilder.setSpan(blueColorSpan, issuerDNLabel.length(), issuerDNStringBuilder.length(), Spanned.SPAN_INCLUSIVE_INCLUSIVE);
328 subjectDNStringBuilder.setSpan(blueColorSpan, subjectDNLabel.length(), subjectDNStringBuilder.length(), Spanned.SPAN_INCLUSIVE_INCLUSIVE);
329 startDateStringBuilder.setSpan(blueColorSpan, startDateLabel.length(), startDateStringBuilder.length(), Spanned.SPAN_INCLUSIVE_INCLUSIVE);
330 endDataStringBuilder.setSpan(blueColorSpan, endDateLabel.length(), endDataStringBuilder.length(), Spanned.SPAN_INCLUSIVE_INCLUSIVE);
331 certificateVersionStringBuilder.setSpan(blueColorSpan, certificateVersionLabel.length(), certificateVersionStringBuilder.length(), Spanned.SPAN_INCLUSIVE_INCLUSIVE);
332 serialNumberStringBuilder.setSpan(blueColorSpan, serialNumberLabel.length(), serialNumberStringBuilder.length(), Spanned.SPAN_INCLUSIVE_INCLUSIVE);
333 signatureAlgorithmStringBuilder.setSpan(blueColorSpan, signatureAlgorithmLabel.length(), signatureAlgorithmStringBuilder.length(), Spanned.SPAN_INCLUSIVE_INCLUSIVE);
335 // Display the strings in the text boxes.
336 certificateIssuerDNTextView.setText(issuerDNStringBuilder);
337 certificateSubjectDNTextView.setText(subjectDNStringBuilder);
338 certificateStartDateTextView.setText(startDateStringBuilder);
339 certificateEndDateTextView.setText(endDataStringBuilder);
340 certificateVersionTextView.setText(certificateVersionStringBuilder);
341 certificateSerialNumberTextView.setText(serialNumberStringBuilder);
342 certificateSignatureAlgorithmTextView.setText(signatureAlgorithmStringBuilder);
343 } catch (CertificateException e) {
344 // Do nothing if there is a certificate error.
346 } catch (PackageManager.NameNotFoundException e) {
347 // Do nothing if `PackageManager` says Privacy Browser isn't installed.
349 } else { // load a `WebView` for all the other tabs. Tab numbers start at 0.
350 // Setting false at the end of inflater.inflate does not attach the inflated layout as a child of container. The fragment will take care of attaching the root automatically.
351 tabLayout = layoutInflater.inflate(R.layout.bare_webview, container, false);
353 // Get a handle for `tabWebView`.
354 WebView tabWebView = (WebView) tabLayout;
356 // Load the tabs according to the theme.
357 if (darkTheme) { // The dark theme is applied.
358 // Set the background color. The deprecated `.getColor()` must be used until the minimum API >= 23.
359 //noinspection deprecation
360 tabWebView.setBackgroundColor(getResources().getColor(R.color.gray_850));
364 tabWebView.loadUrl("file:///android_asset/" + getString(R.string.android_asset_path) + "/about_permissions_dark.html");
368 tabWebView.loadUrl("file:///android_asset/" + getString(R.string.android_asset_path) + "/about_privacy_policy_dark.html");
372 tabWebView.loadUrl("file:///android_asset/" + getString(R.string.android_asset_path) + "/about_changelog_dark.html");
376 tabWebView.loadUrl("file:///android_asset/" + getString(R.string.android_asset_path) + "/about_licenses_dark.html");
380 tabWebView.loadUrl("file:///android_asset/" + getString(R.string.android_asset_path) + "/about_contributors_dark.html");
384 tabWebView.loadUrl("file:///android_asset/" + getString(R.string.android_asset_path) + "/about_links_dark.html");
387 } else { // The light theme is applied.
390 tabWebView.loadUrl("file:///android_asset/" + getString(R.string.android_asset_path) + "/about_permissions_light.html");
394 tabWebView.loadUrl("file:///android_asset/" + getString(R.string.android_asset_path) + "/about_privacy_policy_light.html");
398 tabWebView.loadUrl("file:///android_asset/" + getString(R.string.android_asset_path) + "/about_changelog_light.html");
402 tabWebView.loadUrl("file:///android_asset/" + getString(R.string.android_asset_path) + "/about_licenses_light.html");
406 tabWebView.loadUrl("file:///android_asset/" + getString(R.string.android_asset_path) + "/about_contributors_light.html");
410 tabWebView.loadUrl("file:///android_asset/" + getString(R.string.android_asset_path) + "/about_links_light.html");
416 // Return the formatted `tabLayout`.