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
/** | |
* Arrayadapter (for Android) with text filtering for the use with a TextWatcher. | |
* Note: the objects in the List need a valid toString() method. | |
* @author Tobias Schürg | |
* | |
*/ | |
public class FilteredArrayAdapter extends ArrayAdapter<ImageObject> { |
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 java.text.SimpleDateFormat; | |
import java.util.Date; | |
public class Timezone { | |
public static void main(String[] args) { | |
String tzOffset = new SimpleDateFormat("Z").format(new Date()); | |
System.out.println("Your timezone offset: " + tzOffset); | |
} | |
} |
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
*.acn | |
*.acr | |
*.alg | |
*.aux | |
*.bbl | |
*.blg | |
*.dvi | |
*.glg | |
*.glo | |
*.gls |
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.res.Resources; | |
import android.content.res.TypedArray; | |
import android.graphics.Color; | |
import android.graphics.PorterDuff; | |
import android.graphics.drawable.Drawable; | |
import android.os.Build; | |
import android.os.Bundle; | |
import android.support.annotation.ColorInt; | |
import android.support.annotation.NonNull; |
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.app.DatePickerDialog; | |
import android.content.Context; | |
import android.os.Build; | |
import android.support.annotation.NonNull; | |
import android.support.annotation.Nullable; | |
import android.support.annotation.RequiresApi; | |
import android.support.annotation.StyleRes; | |
import android.support.v7.view.ContextThemeWrapper; |
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
package com.tobiasschuerg | |
import android.content.SharedPreferences | |
import com.google.gson.Gson | |
import com.google.gson.GsonBuilder | |
import kotlin.properties.ReadWriteProperty | |
import kotlin.reflect.KProperty | |
class GsonDelegatePref<T>( | |
private val prefs: SharedPreferences, |