Instantly share code, notes, and snippets.
gitbash-basher
/ button_background_style.xml
Created
March 18, 2019 12:21
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" ?> | |
<selector xmlns:android="http://schemas.android.com/apk/res/android"> | |
<item android:state_pressed="true" > | |
<shape> | |
<solid android:color="#C1CDE2" /> | |
<corners android:radius="6dp" /> | |
<padding android:left="10dp" android:top="10dp" android:right="10dp" android:bottom="10dp" /> | |
</shape> | |
</item> | |
<item> |
gitbash-basher
/ CustomButtonRenderer.cs
Last active
April 19, 2019 09:19
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
using Android.Content; | |
using Android.Graphics; | |
using Android.Views; | |
using SampleCode.Custom; | |
using SampleCode.Droid.Custom; | |
using Xamarin.Forms; | |
using Xamarin.Forms.Platform.Android; | |
[assembly: ExportRenderer(typeof(CustomButton), typeof(CustomButtonRenderer))] | |
namespace SampleCode.Droid.Custom |