正在查看: St.John's v1.0.9 应用的 NotificationHelpActivity.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
正在查看: St.John's v1.0.9 应用的 NotificationHelpActivity.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
package com.mcb.stjohnsemschool.activity;
import android.os.Bundle;
import android.view.MenuItem;
import android.webkit.WebChromeClient;
import android.webkit.WebView;
import android.webkit.WebViewClient;
import androidx.appcompat.app.AppCompatActivity;
import com.google.firebase.analytics.FirebaseAnalytics;
public class NotificationHelpActivity extends AppCompatActivity {
private static final String TAG = "com.mcb.stjohnsemschool.activity.NotificationHelpActivity";
private WebView webView;
protected void onCreate(Bundle bundle) {
super.onCreate(bundle);
setContentView(R.layout.activity_webview);
getSupportActionBar().setTitle("Notifications Help");
getSupportActionBar().setDisplayHomeAsUpEnabled(true);
String stringExtra = getIntent().getStringExtra("URL");
getSupportActionBar().setDisplayHomeAsUpEnabled(true);
getSupportActionBar().setDisplayShowHomeEnabled(true);
getSupportActionBar().setHomeButtonEnabled(true);
WebView webView = (WebView) findViewById(2131364517);
this.webView = webView;
webView.getSettings().setLoadsImagesAutomatically(true);
this.webView.getSettings().setJavaScriptCanOpenWindowsAutomatically(true);
this.webView.getSettings().setBuiltInZoomControls(true);
this.webView.getSettings().setDomStorageEnabled(true);
this.webView.setWebViewClient(new WebViewClient());
this.webView.getSettings().setJavaScriptEnabled(true);
this.webView.setWebChromeClient(new WebChromeClient());
this.webView.setScrollBarStyle(0);
this.webView.loadUrl(stringExtra);
}
public boolean onOptionsItemSelected(MenuItem menuItem) {
if (menuItem.getItemId() == 16908332) {
finish();
return true;
}
return super.onOptionsItemSelected(menuItem);
}
public void onBackPressed() {
if (this.webView.canGoBack()) {
this.webView.goBack();
} else {
super.onBackPressed();
}
}
protected void onResume() {
super.onResume();
String string = getSharedPreferences("", 0).getString("usernamekey", "");
Bundle bundle = new Bundle();
bundle.putString("user_name", string);
FirebaseAnalytics.getInstance(this).logEvent("PAGE_NOTIFICATION_HELP", bundle);
}
}