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
<?xml version="1.0" encoding="utf-8"?> | |
<selector xmlns:android="http://schemas.android.com/apk/res/android"> | |
<item android:state_pressed="true"> | |
<layer-list> | |
<!-- Drop Shadow Stack --> | |
<item> | |
<shape> | |
<padding | |
android:bottom="1dp" |
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 MySwipeLayout : SwipeRefreshLayout { | |
public constructor(context: Context) : super(context) | |
public constructor(context: Context, attrs: AttributeSet) : super(context, attrs) | |
var appBarLayout: AppBarLayout? = null | |
override fun onAttachedToWindow() { | |
super<SwipeRefreshLayout>.onAttachedToWindow() |
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
@Nullable | |
@Override | |
public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { | |
SwipeRefreshLayout rv = (SwipeRefreshLayout) inflater.inflate( | |
R.layout.fragment_cheese_list, container, false); | |
rv.setOnRefreshListener(new SwipeRefreshLayout.OnRefreshListener() { | |
@Override | |
public void onRefresh() { | |
} |
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
val color = getResources().getString(R.color.some_color).replace("#ff", "#") | |
val terms = getString(R.string.register_terms, color) | |
termsText.setText(Html.fromHtml(terms)) |
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
trait GmailAuthenticator : ActionBarActivity { | |
companion object { | |
val TAG = javaClass<GmailAuthenticator>().getName() | |
val PLAY_SERVICES_RESOLUTION_REQUEST = 9000 | |
val REQUEST_CODE_PICK_ACCOUNT = 1000 | |
val REQUEST_CODE_RECOVER_FROM_PLAY_SERVICES_ERROR = 1001 | |
val AUDIENCE = "audience:...." | |
} |
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.TimeZone | |
import android.text.format.Time | |
import java.text.SimpleDateFormat | |
import java.text.DateFormat | |
/** | |
* Created by loop on 24/11/14. | |
*/ | |
/** |
NewerOlder