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

Side by Side Diff: mojo/shell/android/apk/src/org/chromium/mojo_shell_apk/MojoShellActivity.java

Issue 217283005: [Android] Fix a few issues related to old lib deletion. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: take cjhopman's comments Created 6 years, 8 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 | Annotate | Revision Log
« no previous file with comments | « content/shell/android/shell_apk/src/org/chromium/content_shell_apk/ContentShellActivity.java ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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.mojo_shell_apk; 5 package org.chromium.mojo_shell_apk;
6 6
7 import android.app.Activity; 7 import android.app.Activity;
8 import android.app.AlertDialog; 8 import android.app.AlertDialog;
9 import android.content.DialogInterface; 9 import android.content.DialogInterface;
10 import android.content.Intent; 10 import android.content.Intent;
11 import android.os.Bundle; 11 import android.os.Bundle;
12 import android.util.Log; 12 import android.util.Log;
13 import android.widget.EditText; 13 import android.widget.EditText;
14 14
15 import org.chromium.base.library_loader.LibraryLoader; 15 import org.chromium.base.library_loader.LibraryLoader;
16 import org.chromium.base.library_loader.ProcessInitException; 16 import org.chromium.base.library_loader.ProcessInitException;
17 17
18 /** 18 /**
19 * Activity for managing the Mojo Shell. 19 * Activity for managing the Mojo Shell.
20 */ 20 */
21 public class MojoShellActivity extends Activity { 21 public class MojoShellActivity extends Activity {
22 private static final String TAG = "MojoShellActivity"; 22 private static final String TAG = "MojoShellActivity";
23 23
24 @Override 24 @Override
25 protected void onCreate(final Bundle savedInstanceState) { 25 protected void onCreate(final Bundle savedInstanceState) {
26 super.onCreate(savedInstanceState); 26 super.onCreate(savedInstanceState);
27 27
28 try { 28 try {
29 LibraryLoader.ensureInitialized(null); 29 LibraryLoader.ensureInitialized();
30 } catch (ProcessInitException e) { 30 } catch (ProcessInitException e) {
31 Log.e(TAG, "libmojo_shell initialization failed.", e); 31 Log.e(TAG, "libmojo_shell initialization failed.", e);
32 finish(); 32 finish();
33 return; 33 return;
34 } 34 }
35 35
36 MojoMain.init(this); 36 MojoMain.init(this);
37 37
38 String appUrl = getUrlFromIntent(getIntent()); 38 String appUrl = getUrlFromIntent(getIntent());
39 if (appUrl == null) { 39 if (appUrl == null) {
(...skipping 18 matching lines...) Expand all
58 58
59 private static String getUrlFromIntent(Intent intent) { 59 private static String getUrlFromIntent(Intent intent) {
60 return intent != null ? intent.getDataString() : null; 60 return intent != null ? intent.getDataString() : null;
61 } 61 }
62 62
63 private void startWithURL(String url) { 63 private void startWithURL(String url) {
64 MojoMain.start(this, url); 64 MojoMain.start(this, url);
65 Log.i(TAG, "Mojo started: " + url); 65 Log.i(TAG, "Mojo started: " + url);
66 } 66 }
67 } 67 }
OLDNEW
« no previous file with comments | « content/shell/android/shell_apk/src/org/chromium/content_shell_apk/ContentShellActivity.java ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698