Skip to content

Instantly share code, notes, and snippets.

Newtron Labs NewtronLabs

Block or report user

Report or block NewtronLabs

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@NewtronLabs
NewtronLabs / build.gradle
Created May 18, 2019
Android Gradle Setup
View build.gradle
buildscript {
repositories {
jcenter()
maven { url "http://code.newtronlabs.com:8081/artifactory/libs-release-local" }
}
dependencies {
classpath 'com.android.tools.build:gradle:3.3.2'
classpath 'com.newtronlabs.android:plugin:2.0.4-alpha'
}
}
View app.gradle
dependencies {
compileOnly 'com.newtronlabs.easypermissions:easypermissions:2.8.2'
}
@NewtronLabs
NewtronLabs / EasyPermissionsExample1.kt
Last active May 18, 2019
Easy Permissions Example 1 Kotlin
View EasyPermissionsExample1.kt
class ExampleService : Service(), IPermissionsListener {
override fun onCreate() {
super.onCreate()
// Will request all permissions from the Manifest automatically.
EasyPermissions.getInstance().requestPermissions(this)
}
override fun onCompleted(grantedPermissions: Set<String>, deniedPermissions: Set<String>) {}
@NewtronLabs
NewtronLabs / EasyPermissionsExample1.java
Created May 18, 2019
Easy Permissions Example 1 Java
View EasyPermissionsExample1.java
public class ExampleService extends Service implements IPermissionsListener {
@Override
public void onCreate() {
super.onCreate();
// Will request all permissions from the Manifest automatically.
EasyPermissions.getInstance().requestPermissions(this);
}
@Override
@NewtronLabs
NewtronLabs / EasyPermissionsExample2.kt
Last active May 18, 2019
Easy Permissions Example 2 Kotlin
View EasyPermissionsExample2.kt
EasyPermissions.getInstance().requestPermissions(this,
Manifest.permission.ACCESS_FINE_LOCATION,
Manifest.permission.CAMERA,
Manifest.permission.CALL_PHONE,
Manifest.permission.WRITE_EXTERNAL_STORAGE
)
@NewtronLabs
NewtronLabs / EasyPermissionsExample2.java
Created May 18, 2019
Easy Permissions Example 2 Java
View EasyPermissionsExample2.java
EasyPermissions.getInstance().requestPermissions(this,
Manifest.permission.ACCESS_FINE_LOCATION,
Manifest.permission.CAMERA,
Manifest.permission.CALL_PHONE,
Manifest.permission.WRITE_EXTERNAL_STORAGE
);
@NewtronLabs
NewtronLabs / Newtron Labs Library License.md
Last active Nov 29, 2019
Newtron Labs Library License
View Newtron Labs Library License.md

Newtron Labs Library License

This Newtron Labs library, binaries and source code can only be used in accordance with Freeware license. That is, freeware may be used without payment, but may not be modified. The developer of the library retains all rights to change, alter, adapt, and/or distribute the software. Newtron Labs is not liable for any damages and/or losses incurred during the use of one of its libraries.

You may not decompile, reverse engineer, pull apart, or otherwise attempt to dissect the source code, algorithm, technique or other information from the binary code of a Newtron Labs’ library unless it is authorized by existing applicable law and only to the extent authorized by such law. In the event that such a law applies, user may only attempt the foregoing if: (1) user has contacted Newtron Labs to request such information and Newtron Labs has failed to respond in a reasonable time, or (2) reverse engineering is strictly necessary to obtain such information and Newtron Labs has failed to repl

You can’t perform that action at this time.