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
/* | |
First-off, huge thanks both Fenix and Buffer teams for the apps, I use them both | |
every day, and think they're brilliant! The only issue I have is that they don't | |
currently like to talk to eachother...if they did? That would be great! | |
Here's my analysis on why they currently don't: | |
******************************************************************************** |
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
@Override | |
public void onPropertiesChanged(Bundle properties) { | |
super.onPropertiesChanged(properties); | |
mLowBitAmbient = properties.getBoolean(PROPERTY_LOW_BIT_AMBIENT, false); | |
mBurnInProtection = properties.getBoolean(PROPERTY_BURN_IN_PROTECTION, | |
false); | |
} |
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
new AsyncTask<Integer, Void, Void>(){ | |
@Override | |
protected Void doInBackground(Integer... params) { | |
// main logic | |
return null; | |
} | |
}.execute(0); |
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
#!/bin/bash | |
# b.nelissen | |
# move contents of downloads folder to trash (I want a clean downloads folder every time I login) | |
mv ~/Downloads/* ~/.Trash/ |
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
private void failoverScreenshot(String desc) { | |
try { | |
Spoon.screenshot(getActivity(), desc); | |
} | |
catch (IllegalArgumentException e) { | |
Log.v(TAG, "Handled erroneous Spoon-Client screenshot exception."); | |
} |
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
import android.database.ContentObserver; | |
import android.os.Bundle; | |
import android.os.Handler; | |
import android.provider.Settings; | |
import android.provider.Settings.Global; | |
import android.support.v7.app.AppCompatActivity; | |
import android.util.Log; | |
import android.view.View; | |
import android.widget.Button; |
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
1) Concatenate a list of videos into one | |
ffmpeg -f concat -safe 0 -i tojoin.txt -c copy output.mp4 | |
// Format of tojoin.txt: | |
file 'file0.MP4' | |
file 'file1.MP4' | |
file 'etc.. | |
2) Scale down 4k video to |
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
// Items for spinner | |
val items = arrayOf("One", "Two", "Three", "Four", "Five") | |
// Alert with a spinner | |
alert("Example Alert") { | |
title = "Example Alert" | |
customView { | |
verticalLayout { | |
spinner { | |
adapter = ArrayAdapter(ctx, android.R.layout.simple_spinner_dropdown_item, countries) |
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
import android.annotation.SuppressLint | |
import android.content.* | |
import android.net.Uri | |
import android.os.Build | |
import android.os.Bundle | |
import android.provider.MediaStore | |
import android.util.Log | |
import android.widget.Button | |
import androidx.appcompat.app.AppCompatActivity | |
import java.io.File |