tlmarker1968

Untitled

Dec 19th, 2019
176
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 1.68 KB | None | 0 0
  1.         @Override
  2.         protected void onCreate(Bundle savedInstanceState) {
  3.             super.onCreate(savedInstanceState);
  4.             getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN, WindowManager.LayoutParams.FLAG_FULLSCREEN);
  5.             View decorView = getWindow().getDecorView();
  6.             decorView.setSystemUiVisibility(View.SYSTEM_UI_FLAG_FULLSCREEN);
  7.             setContentView(R.layout.activity_home);
  8.             etUsername = findViewById(R.id.etUsername);
  9.             etPassword = findViewById(R.id.etPassword);
  10.             TextView tvWarning = findViewById(R.id.tvWarning);
  11.             Button btnLogon = findViewById(R.id.btnLogon);
  12.             btnLogon.setOnClickListener(this);
  13.             @SuppressLint ("Recycle") Cursor cursor = getContentResolver().query(Uri.parse("content://com.phoenixhospman.install.ProviderSettings/settings"), null, null, null, null, null);
  14.             assert cursor != null;
  15.             if(cursor.moveToFirst()) {
  16.                 while(!cursor.isAfterLast()) {
  17.                     strCoName = cursor.getString(cursor.getColumnIndex("coname"));
  18.                     strApiUrl = cursor.getString(cursor.getColumnIndex("apiurl"));
  19.                     cursor.moveToNext();
  20.                 }
  21.             } else {
  22.                 Error("\nRequired setting missing.\nPlease (re)run Phoenix Install App");
  23.             }
  24.             if (strApiUrl != null) {
  25.                 managerLauncherApi = new ManagerLauncherApi(strApiUrl);
  26.             } else {
  27.                 Error("\nRequired setting missing.\nPlease (re)run Phoenix Install App");
  28.             }
  29.         tvWarning.setText(getString(R.string.warning, rtrim(strCoName) ));
  30.     }
Advertisement
Add Comment
Please, Sign In to add comment