diff --git a/app/build.gradle b/app/build.gradle index 9942a3d6..7ec0178b 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -51,7 +51,7 @@ android { } dependencies { - implementation 'com.simplemobiletools:commons:5.12.10' + implementation 'com.simplemobiletools:commons:5.12.11' implementation 'com.github.Stericson:RootTools:df729dcb13' implementation 'com.github.Stericson:RootShell:1.6' implementation 'com.alexvasilkov:gesture-views:2.5.2' diff --git a/app/src/main/kotlin/com/simplemobiletools/filemanager/pro/activities/SplashActivity.kt b/app/src/main/kotlin/com/simplemobiletools/filemanager/pro/activities/SplashActivity.kt index 3d010a2d..2af6cfdd 100644 --- a/app/src/main/kotlin/com/simplemobiletools/filemanager/pro/activities/SplashActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/filemanager/pro/activities/SplashActivity.kt @@ -7,7 +7,15 @@ class SplashActivity : BaseSplashActivity() { override fun getAppPackageName() = packageName override fun initActivity() { - startActivity(Intent(this, MainActivity::class.java)) + if (intent.action == Intent.ACTION_VIEW && intent.data != null) { + Intent(this, MainActivity::class.java).apply { + action = Intent.ACTION_VIEW + data = intent.data + startActivity(this) + } + } else { + startActivity(Intent(this, MainActivity::class.java)) + } finish() } } diff --git a/app/src/main/kotlin/com/simplemobiletools/filemanager/pro/adapters/ItemsAdapter.kt b/app/src/main/kotlin/com/simplemobiletools/filemanager/pro/adapters/ItemsAdapter.kt index 0d63418c..37ff2fe5 100644 --- a/app/src/main/kotlin/com/simplemobiletools/filemanager/pro/adapters/ItemsAdapter.kt +++ b/app/src/main/kotlin/com/simplemobiletools/filemanager/pro/adapters/ItemsAdapter.kt @@ -1,10 +1,18 @@ package com.simplemobiletools.filemanager.pro.adapters +import android.annotation.SuppressLint +import android.app.PendingIntent import android.content.ClipData import android.content.ClipboardManager import android.content.Context +import android.content.Intent import android.content.pm.PackageManager +import android.content.pm.ShortcutInfo +import android.content.pm.ShortcutManager import android.graphics.drawable.Drawable +import android.graphics.drawable.Icon +import android.graphics.drawable.LayerDrawable +import android.net.Uri import android.view.Menu import android.view.View import android.view.ViewGroup @@ -17,12 +25,14 @@ import com.simplemobiletools.commons.dialogs.* import com.simplemobiletools.commons.extensions.* import com.simplemobiletools.commons.helpers.CONFLICT_OVERWRITE import com.simplemobiletools.commons.helpers.CONFLICT_SKIP +import com.simplemobiletools.commons.helpers.isNougatMR1Plus import com.simplemobiletools.commons.models.FileDirItem import com.simplemobiletools.commons.models.RadioItem import com.simplemobiletools.commons.views.FastScroller import com.simplemobiletools.commons.views.MyRecyclerView import com.simplemobiletools.filemanager.pro.R import com.simplemobiletools.filemanager.pro.activities.SimpleActivity +import com.simplemobiletools.filemanager.pro.activities.SplashActivity import com.simplemobiletools.filemanager.pro.dialogs.CompressAsDialog import com.simplemobiletools.filemanager.pro.extensions.* import com.simplemobiletools.filemanager.pro.helpers.* @@ -67,6 +77,7 @@ class ItemsAdapter(activity: SimpleActivity, var listItems: MutableList shareFiles() R.id.cab_hide -> toggleFileVisibility(true) R.id.cab_unhide -> toggleFileVisibility(false) + R.id.cab_create_shortcut -> createShortcut() R.id.cab_copy_path -> copyPath() R.id.cab_set_as -> setAs() R.id.cab_open_with -> openWith() @@ -216,6 +228,37 @@ class ItemsAdapter(activity: SimpleActivity, var listItems: MutableList) { if (File(path).isDirectory) { val shouldShowHidden = activity.config.shouldShowHidden diff --git a/app/src/main/res/drawable-hdpi/ic_folder_big.png b/app/src/main/res/drawable-hdpi/ic_folder_big.png new file mode 100644 index 00000000..887bad76 Binary files /dev/null and b/app/src/main/res/drawable-hdpi/ic_folder_big.png differ diff --git a/app/src/main/res/drawable-xhdpi/ic_folder_big.png b/app/src/main/res/drawable-xhdpi/ic_folder_big.png new file mode 100644 index 00000000..d5142e47 Binary files /dev/null and b/app/src/main/res/drawable-xhdpi/ic_folder_big.png differ diff --git a/app/src/main/res/drawable-xxhdpi/ic_folder_big.png b/app/src/main/res/drawable-xxhdpi/ic_folder_big.png new file mode 100644 index 00000000..269cec8e Binary files /dev/null and b/app/src/main/res/drawable-xxhdpi/ic_folder_big.png differ diff --git a/app/src/main/res/drawable-xxxhdpi/ic_folder_big.png b/app/src/main/res/drawable-xxxhdpi/ic_folder_big.png new file mode 100644 index 00000000..3239c0f4 Binary files /dev/null and b/app/src/main/res/drawable-xxxhdpi/ic_folder_big.png differ diff --git a/app/src/main/res/drawable/shortcut_folder.xml b/app/src/main/res/drawable/shortcut_folder.xml new file mode 100644 index 00000000..8fe4f057 --- /dev/null +++ b/app/src/main/res/drawable/shortcut_folder.xml @@ -0,0 +1,17 @@ + + + + + + + + + + + diff --git a/app/src/main/res/menu/cab.xml b/app/src/main/res/menu/cab.xml index 9dce1679..feccd802 100644 --- a/app/src/main/res/menu/cab.xml +++ b/app/src/main/res/menu/cab.xml @@ -31,6 +31,10 @@ android:icon="@drawable/ic_unhide" android:title="@string/unhide" app:showAsAction="ifRoom"/> +