public class MainActivity extends Activity {
Handler handler;
TextView tvTest;
int cnt = 0;
@Override
protected void onCreate(Bundle savedInstanceState) {
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
val player = ExoPlayerFactory.newSimpleInstance(context, DefaultTrackSelector()) | |
val rawDataSource = RawResourceDataSource(context) | |
// open the /raw resource file | |
rawDataSource.open(DataSpec(RawResourceDataSource.buildRawResourceUri(R.raw.brown))) | |
// create a media source with the raw DataSource | |
val mediaSource = ExtractorMediaSource.Factory(DataSource.Factory { rawDataSource }) | |
.createMediaSource(rawDataSource.uri) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//download data.ab (encrypted) and DONOT GIVE ANY PASSWORD when prompted | |
adb backup -f ~/data.ab -noapk app.package.name | |
//decrypt and extract the data.ab [this worked most of the time except for few instances ] | |
//this will output all the contents of app into 'apps' directory | |
dd if=data.ab bs=1 skip=24 | python -c "import zlib,sys;sys.stdout.write(zlib.decompress(sys.stdin.read()))" | tar -xvf - | |
//SOURCE: http://blog.shvetsov.com/2013/02/access-android-app-data-without-root.html |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Created by https://www.gitignore.io/api/android,intellij | |
### Android ### | |
# Built application files | |
*.apk | |
*.ap_ | |
# Files for the Dalvik VM | |
*.dex |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Download this file using PowerShell v3 under Windows with the following comand | |
# Invoke-WebRequest https://gist.githubusercontent.com/kmorcinek/2710267/raw/ -OutFile .gitignore | |
# User-specific files | |
*.suo | |
*.user | |
*.sln.docstates | |
# Build results |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<ScrollView | |
xmlns:android="http://schemas.android.com/apk/res/android" | |
xmlns:tools="http://schemas.android.com/tools" | |
android:layout_width="match_parent" | |
android:layout_height="match_parent"> | |
<RelativeLayout | |
android:layout_width="fill_parent" | |
android:layout_height="wrap_content" | |
> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="utf-8"?> | |
<FrameLayout | |
android:id="@+id/details_view_container" | |
xmlns:android="http://schemas.android.com/apk/res/android" | |
xmlns:tools="http://schemas.android.com/tools" | |
xmlns:app="http://schemas.android.com/apk/res-auto" | |
android:layout_width="match_parent" | |
android:layout_height="match_parent" | |
app:layout_behavior="@string/appbar_scrolling_view_behavior" | |
tools:showIn="@layout/activity_details_view" |