mirror of
https://github.com/awfixers-stuff/OwnDroid.git
synced 2026-03-23 19:15:58 +00:00
Use dialog to set some password options
This commit is contained in:
@@ -39,8 +39,8 @@ fun uriToStream(
|
||||
if(stream != null) { operation(stream) }
|
||||
stream?.close()
|
||||
}
|
||||
catch(e: FileNotFoundException) { Toast.makeText(context, R.string.file_not_exist, Toast.LENGTH_SHORT).show() }
|
||||
catch(e: IOException) { Toast.makeText(context, R.string.io_exception, Toast.LENGTH_SHORT).show() }
|
||||
catch(_: FileNotFoundException) { Toast.makeText(context, R.string.file_not_exist, Toast.LENGTH_SHORT).show() }
|
||||
catch(_: IOException) { Toast.makeText(context, R.string.io_exception, Toast.LENGTH_SHORT).show() }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -52,7 +52,7 @@ fun writeClipBoard(context: Context, string: String):Boolean{
|
||||
val clipboardManager = context.getSystemService(Context.CLIPBOARD_SERVICE) as ClipboardManager
|
||||
try {
|
||||
clipboardManager.setPrimaryClip(ClipData.newPlainText("", string))
|
||||
}catch(e:Exception){
|
||||
} catch(_:Exception) {
|
||||
return false
|
||||
}
|
||||
return true
|
||||
|
||||
Reference in New Issue
Block a user