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

Side by Side Diff: chrome/android/java/src/org/chromium/chrome/browser/physicalweb/PhysicalWebDiagnosticsPage.java

Issue 2651553005: Remove ListUrlsActivity (Closed)
Patch Set: Removing ListUrlsActivity Tests Created 3 years, 10 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 unified diff | Download patch
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 package org.chromium.chrome.browser.physicalweb; 5 package org.chromium.chrome.browser.physicalweb;
6 6
7 import android.app.Activity; 7 import android.app.Activity;
8 import android.content.res.Resources; 8 import android.content.res.Resources;
9 import android.os.Build; 9 import android.os.Build;
10 import android.text.Html; 10 import android.text.Html;
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
55 mIndeterminateColor = colorToHexValue(ApiCompatibilityUtils.getColor(res ources, 55 mIndeterminateColor = colorToHexValue(ApiCompatibilityUtils.getColor(res ources,
56 R.color.physical_web_diags_indeterminate_color)); 56 R.color.physical_web_diags_indeterminate_color));
57 57
58 LayoutInflater inflater = LayoutInflater.from(activity); 58 LayoutInflater inflater = LayoutInflater.from(activity);
59 mPageView = inflater.inflate(R.layout.physical_web_diagnostics, null); 59 mPageView = inflater.inflate(R.layout.physical_web_diagnostics, null);
60 60
61 mLaunchButton = (Button) mPageView.findViewById(R.id.physical_web_launch ); 61 mLaunchButton = (Button) mPageView.findViewById(R.id.physical_web_launch );
62 mLaunchButton.setOnClickListener(new View.OnClickListener() { 62 mLaunchButton.setOnClickListener(new View.OnClickListener() {
63 @Override 63 @Override
64 public void onClick(View v) { 64 public void onClick(View v) {
65 PhysicalWebUma.onActivityReferral(ListUrlsActivity.DIAGNOSTICS_R EFERER); 65 PhysicalWebUma.onActivityReferral(PhysicalWebUma.DIAGNOSTICS_REF ERER);
66 PhysicalWeb.showUrlList(); 66 PhysicalWeb.showUrlList();
67 } 67 }
68 }); 68 });
69 69
70 mDiagnosticsText = (TextView) mPageView.findViewById(R.id.physical_web_d iagnostics_text); 70 mDiagnosticsText = (TextView) mPageView.findViewById(R.id.physical_web_d iagnostics_text);
71 mDiagnosticsText.setAutoLinkMask(Linkify.WEB_URLS); 71 mDiagnosticsText.setAutoLinkMask(Linkify.WEB_URLS);
72 mDiagnosticsText.setText(Html.fromHtml(createDiagnosticsReportHtml())); 72 mDiagnosticsText.setText(Html.fromHtml(createDiagnosticsReportHtml()));
73 } 73 }
74 74
75 @Override 75 @Override
(...skipping 138 matching lines...) Expand 10 before | Expand all | Expand 10 after
214 } 214 }
215 215
216 private boolean isSdkVersionCorrect() { 216 private boolean isSdkVersionCorrect() {
217 return (Build.VERSION.SDK_INT >= Build.VERSION_CODES.KITKAT); 217 return (Build.VERSION.SDK_INT >= Build.VERSION_CODES.KITKAT);
218 } 218 }
219 219
220 private static String colorToHexValue(int color) { 220 private static String colorToHexValue(int color) {
221 return "#" + Integer.toHexString(color & 0x00ffffff); 221 return "#" + Integer.toHexString(color & 0x00ffffff);
222 } 222 }
223 } 223 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698