Skip to content

Commit 4b33479

Browse files
committed
Changed kivy dir name
1 parent b2759ff commit 4b33479

File tree

1 file changed

+17
-17
lines changed

1 file changed

+17
-17
lines changed

pythonforandroid/bootstraps/sdl2/build/src/org/kivy/android/PythonActivity.java

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -48,9 +48,9 @@ public class PythonActivity extends SDLActivity {
4848
private Bundle mMetaData = null;
4949
private PowerManager.WakeLock mWakeLock = null;
5050

51-
public String getKivyRoot() {
52-
String kivy_root = getFilesDir().getAbsolutePath() + "/app";
53-
return kivy_root;
51+
public String getAppRoot() {
52+
String app_root = getFilesDir().getAbsolutePath() + "/app";
53+
return app_root;
5454
}
5555

5656

@@ -59,26 +59,26 @@ protected void onCreate(Bundle savedInstanceState) {
5959
Log.v(TAG, "My oncreate running");
6060
resourceManager = new ResourceManager(this);
6161
this.showLoadingScreen();
62-
File kivy_root_file = new File(getKivyRoot());
62+
File app_root_file = new File(getAppRoot());
6363

6464
Log.v(TAG, "Ready to unpack");
65-
unpackData("private", kivy_root_file);
65+
unpackData("private", app_root_file);
6666

6767
Log.v(TAG, "About to do super onCreate");
6868
super.onCreate(savedInstanceState);
6969
Log.v(TAG, "Did super onCreate");
7070

7171
this.mActivity = this;
7272

73-
String kivy_root_dir = getKivyRoot();
73+
String app_root_dir = getAppRoot();
7474
String mFilesDirectory = mActivity.getFilesDir().getAbsolutePath();
7575
Log.v(TAG, "Setting env vars for start.c and Python to use");
7676
SDLActivity.nativeSetEnv("ANDROID_PRIVATE", mFilesDirectory);
77-
SDLActivity.nativeSetEnv("ANDROID_ARGUMENT", kivy_root_dir);
78-
SDLActivity.nativeSetEnv("ANDROID_APP_PATH", kivy_root_dir);
77+
SDLActivity.nativeSetEnv("ANDROID_ARGUMENT", app_root_dir);
78+
SDLActivity.nativeSetEnv("ANDROID_APP_PATH", app_root_dir);
7979
SDLActivity.nativeSetEnv("ANDROID_ENTRYPOINT", "main.pyo");
80-
SDLActivity.nativeSetEnv("PYTHONHOME", kivy_root_dir);
81-
SDLActivity.nativeSetEnv("PYTHONPATH", kivy_root_dir + ":" + kivy_root_dir + "/lib");
80+
SDLActivity.nativeSetEnv("PYTHONHOME", app_root_dir);
81+
SDLActivity.nativeSetEnv("PYTHONPATH", app_root_dir + ":" + app_root_dir + "/lib");
8282

8383
try {
8484
Log.v(TAG, "Access to our meta-data...");
@@ -101,9 +101,9 @@ protected void onCreate(Bundle savedInstanceState) {
101101
}
102102

103103
public void loadLibraries() {
104-
String kivy_root = new String(getKivyRoot());
105-
File kivy_root_file = new File(kivy_root);
106-
PythonUtil.loadLibraries(kivy_root_file);
104+
String app_root = new String(getAppRoot());
105+
File app_root_file = new File(app_root);
106+
PythonUtil.loadLibraries(app_root_file);
107107
}
108108

109109
public void recursiveDelete(File f) {
@@ -277,12 +277,12 @@ public static void start_service(String serviceTitle, String serviceDescription,
277277
Intent serviceIntent = new Intent(PythonActivity.mActivity, PythonService.class);
278278
String argument = PythonActivity.mActivity.getFilesDir().getAbsolutePath();
279279
String filesDirectory = argument;
280-
String kivy_root_dir = PythonActivity.mActivity.getKivyRoot();
280+
String app_root_dir = PythonActivity.mActivity.getAppRoot();
281281
serviceIntent.putExtra("androidPrivate", argument);
282-
serviceIntent.putExtra("androidArgument", kivy_root_dir);
282+
serviceIntent.putExtra("androidArgument", app_root_dir);
283283
serviceIntent.putExtra("serviceEntrypoint", "service/main.pyo");
284-
serviceIntent.putExtra("pythonHome", kivy_root_dir);
285-
serviceIntent.putExtra("pythonPath", kivy_root_dir + ":" + kivy_root_dir + "/lib");
284+
serviceIntent.putExtra("pythonHome", app_root_dir);
285+
serviceIntent.putExtra("pythonPath", app_root_dir + ":" + app_root_dir + "/lib");
286286
serviceIntent.putExtra("serviceTitle", serviceTitle);
287287
serviceIntent.putExtra("serviceDescription", serviceDescription);
288288
serviceIntent.putExtra("pythonServiceArgument", pythonServiceArgument);

0 commit comments

Comments
 (0)