This file contains hidden or 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
/** | |
* Class describing a SingleLineLinearLayout | |
*/ | |
open class SingleLineLinearLayout @JvmOverloads constructor( | |
context: Context, | |
attrs: AttributeSet? = null, | |
defStyleAttr: Int = 0 | |
) : LinearLayout(context, attrs, defStyleAttr) { | |
var isChildRemoving = false |
This file contains hidden or 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
/** | |
* @author Simone Bellotti | |
*/ | |
public class SuggestionSearchView extends LinearLayout { | |
private static final String TAG = "SuggestionSearchView"; | |
private static final double COS_45 = Math.cos(Math.toRadians(45)); | |
private static final boolean DEFAULT_ENABLED_BACK = true; | |
private static final boolean DEFAULT_WAIT_KEYBOARD_FOR_COLLAPSE = true; |
This file contains hidden or 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
public class ViewStubExt { | |
/** | |
* Deflates the view inflated by {@link ViewStub#inflate()} | |
* and replace it with a new {@link ViewStub} in its parent. | |
* | |
* @param view the view lazily inflated previously | |
* @return the new ViewStub with backed parameters | |
* | |
*/ |
This file contains hidden or 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
/** | |
* @author Simone Bellotti | |
*/ | |
public class TextStyler { | |
/** | |
* Returns a CharSequence that concatenates the specified array of CharSequence | |
* objects and then applies a list of zero or more tags to the entire range. | |
* | |
* @param content an array of character sequences to apply a style to |
This file contains hidden or 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 es.cloudey.pagespeed.util; | |
import java.util.HashMap; | |
import java.util.Map; | |
import android.os.Bundle; | |
import android.os.Parcelable; | |
public class CollectionUtils { | |
public static Bundle toBundle(Map<String, ? extends Parcelable> input) { |
This file contains hidden or 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 it.immobiliare.getrix.utils; | |
import android.Manifest; | |
import android.app.Activity; | |
import android.content.pm.PackageManager; | |
import android.support.v4.app.ActivityCompat; | |
import android.support.v4.content.ContextCompat; | |
import android.widget.Toast; | |
/** |
This file contains hidden or 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.os.Build; | |
import android.os.Environment; | |
import android.os.StatFs; | |
import java.io.File; | |
public class MemoryUtils { | |
public final static int MIN_SIZE_MB = 100; |
This file contains hidden or 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.animation.Animator; | |
import android.animation.AnimatorInflater; | |
import android.content.Context; | |
import android.view.View; | |
import android.view.ViewGroup; | |
import android.view.animation.AnimationUtils; | |
import android.widget.ArrayAdapter; | |
import it.tgs.wow.light.R; | |
/** |
This file contains hidden or 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.Activity; | |
import android.widget.Toast; | |
/** | |
* Created with IntelliJ IDEA. | |
* User: SimoneBellotti | |
* Date: 23/12/2014 | |
* Time: 17.26 | |
*/ |
This file contains hidden or 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.util.regex.Matcher; | |
import java.util.regex.Pattern; | |
/** | |
* Created by SimoneBellotti on 30/04/14. | |
*/ | |
public class Validator { | |
private static Pattern pattern; | |
private static Matcher matcher; |
NewerOlder