Skip to content

Commit 91078e9

Browse files
committed
refactor: cleanup typos
1 parent 003bf4f commit 91078e9

File tree

7 files changed

+14
-14
lines changed

7 files changed

+14
-14
lines changed

framework/src/org/apache/cordova/Config.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ public static String getStartUrl() {
5454
}
5555

5656
public static String getErrorUrl() {
57-
return parser.getPreferences().getString("errorurl", null);
57+
return parser.getPreferences().getString("ErrorUrl", null);
5858
}
5959

6060
public static List<PluginEntry> getPluginEntries() {

framework/src/org/apache/cordova/CordovaActivity.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ public void onCreate(Bundle savedInstanceState) {
111111
// need to activate preferences before super.onCreate to avoid "requestFeature() must be called before adding content" exception
112112
loadConfig();
113113

114-
String logLevel = preferences.getString("loglevel", "ERROR");
114+
String logLevel = preferences.getString("LogLevel", "ERROR");
115115
LOG.setLogLevel(logLevel);
116116

117117
LOG.i(TAG, "Apache Cordova native platform version " + CordovaWebView.CORDOVA_VERSION + " is starting");

framework/src/org/apache/cordova/CordovaWebViewImpl.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -75,13 +75,13 @@ public class CordovaWebViewImpl implements CordovaWebView {
7575
private final Set<Integer> boundKeyCodes = new HashSet<>();
7676

7777
public static CordovaWebViewEngine createEngine(Context context, CordovaPreferences preferences) {
78-
String className = preferences.getString("webview", SystemWebViewEngine.class.getCanonicalName());
78+
String className = preferences.getString("WebView", SystemWebViewEngine.class.getCanonicalName());
7979
try {
8080
Class<?> webViewClass = Class.forName(className);
8181
Constructor<?> constructor = webViewClass.getConstructor(Context.class, CordovaPreferences.class);
8282
return (CordovaWebViewEngine) constructor.newInstance(context, preferences);
8383
} catch (Exception e) {
84-
throw new RuntimeException("Failed to create webview. ", e);
84+
throw new RuntimeException("Failed to create WebView. ", e);
8585
}
8686
}
8787

@@ -222,7 +222,7 @@ public void showWebPage(String url, boolean openExternal, boolean clearHistory,
222222
loadUrlIntoView(url, true);
223223
return;
224224
} else {
225-
LOG.w(TAG, "showWebPage: Refusing to load URL into webview since it is not in the <allow-navigation> allow list. URL=" + url);
225+
LOG.w(TAG, "showWebPage: Refusing to load URL into WebView since it is not in the <allow-navigation> allow list. URL=" + url);
226226
return;
227227
}
228228
}

framework/src/org/apache/cordova/CoreAndroid.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -273,7 +273,7 @@ public void exitApp() {
273273
private void initTelephonyReceiver() {
274274
IntentFilter intentFilter = new IntentFilter();
275275
intentFilter.addAction(TelephonyManager.ACTION_PHONE_STATE_CHANGED);
276-
//final CordovaInterface mycordova = this.cordova;
276+
//final CordovaInterface myCordova = this.cordova;
277277
this.telephonyReceiver = new BroadcastReceiver() {
278278

279279
@Override

framework/src/org/apache/cordova/NativeToJsMessageQueue.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -491,9 +491,9 @@ void buildJsMessage(StringBuilder sb) {
491491
case PluginResult.MESSAGE_TYPE_MULTIPART:
492492
int size = pluginResult.getMultipartMessagesSize();
493493
for (int i=0; i<size; i++) {
494-
PluginResult subresult = pluginResult.getMultipartMessage(i);
495-
JsMessage submessage = new JsMessage(subresult, jsPayloadOrCallbackId);
496-
submessage.buildJsMessage(sb);
494+
PluginResult subResult = pluginResult.getMultipartMessage(i);
495+
JsMessage subMessage = new JsMessage(subResult, jsPayloadOrCallbackId);
496+
subMessage.buildJsMessage(sb);
497497
if (i < (size-1)) {
498498
sb.append(",");
499499
}

framework/src/org/apache/cordova/engine/SystemWebChromeClient.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ Licensed to the Apache Software Foundation (ASF) under one
5959
*/
6060
public class SystemWebChromeClient extends WebChromeClient {
6161

62-
private static final int FILECHOOSER_RESULTCODE = 5173;
62+
private static final int FILE_CHOOSER_RESULT_CODE = 5173;
6363
private static final String LOG_TAG = "SystemWebChromeClient";
6464
private final long MAX_QUOTA = 100 * 1024 * 1024;
6565
protected final SystemWebViewEngine parentEngine;
@@ -294,7 +294,7 @@ public void onActivityResult(int requestCode, int resultCode, Intent intent) {
294294
}
295295
filePathsCallback.onReceiveValue(result);
296296
}
297-
}, chooserIntent, FILECHOOSER_RESULTCODE);
297+
}, chooserIntent, FILE_CHOOSER_RESULT_CODE);
298298
} catch (ActivityNotFoundException e) {
299299
LOG.w(LOG_TAG, "No activity found to handle file chooser intent.", e);
300300
filePathsCallback.onReceiveValue(null);

framework/src/org/apache/cordova/engine/SystemWebViewEngine.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -173,13 +173,13 @@ private void initWebViewSettings() {
173173
// The default is to use the module's debuggable state to decide if the WebView inspector
174174
// should be enabled. However, users can configure InspectableWebView preference to forcefully enable
175175
// or disable the WebView inspector.
176-
String inspectableWebview = preferences.getString("InspectableWebview", null);
176+
String inspectableWebView = preferences.getString("InspectableWebView", null);
177177
boolean shouldEnableInspector = false;
178-
if (inspectableWebview == null) {
178+
if (inspectableWebView == null) {
179179
ApplicationInfo appInfo = webView.getContext().getApplicationContext().getApplicationInfo();
180180
shouldEnableInspector = (appInfo.flags & ApplicationInfo.FLAG_DEBUGGABLE) != 0;
181181
}
182-
else if ("true".equals(inspectableWebview)) {
182+
else if ("true".equals(inspectableWebView)) {
183183
shouldEnableInspector = true;
184184
}
185185

0 commit comments

Comments
 (0)