Skip to content

Commit

Permalink
first commit
Browse files Browse the repository at this point in the history
  • Loading branch information
GabrielBRDeveloper committed Feb 9, 2023
1 parent 21564b2 commit ea3401b
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
5 changes: 3 additions & 2 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools">
<uses-permission
android:name="com.android.launcher.permission.INSTALL_SHORTCUT" />

<uses-permission android:name="com.android.launcher.permission.INSTALL_SHORTCUT" />
<uses-permission android:name="android.permission.INTERNET"/>

<application
android:allowBackup="true"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package br.com.nullexcept.webappmanager.app;

import android.Manifest;
import android.content.Context;
import android.content.Intent;
import android.content.SharedPreferences;
Expand All @@ -8,6 +9,7 @@
import android.graphics.BitmapFactory;
import android.media.Image;
import android.net.Uri;
import android.os.Build;
import android.os.Bundle;
import android.view.KeyEvent;
import android.view.View;
Expand Down Expand Up @@ -53,6 +55,12 @@ protected void onCreate(@Nullable Bundle savedInstanceState) {
checkAndCreateDatabase();
super.onCreate(savedInstanceState);
setContentView(R.layout.main_activity);
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M) {
requestPermissions(new String[]{
Manifest.permission.INSTALL_SHORTCUT,
Manifest.permission.INTERNET
},10);
}
if (savedInstanceState == null){
loadList();
findViewById(R.id.create).setOnClickListener((vw)->{
Expand Down

0 comments on commit ea3401b

Please sign in to comment.