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 SimpleSortingAlgorithm : ISortingAlghorithm | |
{ | |
private int _maxChanges = 3; | |
public SimpleSortingAlgorithm() { } | |
public ICollection<string> DoSort(string userInput, ICollection<string> inputStrings) | |
{ | |
var correctedStrings = new List<string>(); | |
foreach (string input in inputStrings) |
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 MyDataFetcher : IDataFetcher | |
{ | |
private MapsPlaceAutoComplete autoCompleteMaps = new MapsPlaceAutoComplete(); | |
public async Task PerformFetch(MBAutoCompleteTextField textfield, Action<ICollection<string>> completionHandler) | |
{ | |
var result = await autoCompleteMaps.AutoComplete(textfield.Text); | |
var strings = result.Select(rs => rs.description).ToList(); | |
completionHandler(strings); | |
} |
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
AutoCompleteTextField.Setup(this, new List<string>() { "customizable", "xamarin", "autocomplete", "ios" }); |
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
namespace MonkeyList.Droid | |
{ | |
public class Setup : MvxAndroidSetup | |
{ | |
//Default stuff goes here | |
protected override IEnumerable<Assembly> AndroidViewAssemblies => new List<Assembly>(base.AndroidViewAssemblies) | |
{ | |
typeof(MvvmCross.Droid.Support.V7.RecyclerView.MvxRecyclerView).Assembly | |
}; |
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"?> | |
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" | |
xmlns:local="http://schemas.android.com/apk/res-auto" | |
android:orientation="horizontal" | |
android:layout_width="match_parent" | |
android:layout_height="wrap_content" | |
android:padding="2dp"> | |
<android.support.v7.widget.CardView | |
android:layout_width="match_parent" | |
android:layout_height="match_parent" |
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"?> | |
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" | |
xmlns:local="http://schemas.android.com/apk/res-auto" | |
android:orientation="vertical" | |
android:layout_width="match_parent" | |
android:layout_height="match_parent" | |
android:background="@android:color/darker_gray"> | |
<MvxRecyclerView | |
android:id="@+id/my_recycler_view" | |
android:scrollbars="vertical" |
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
using Android.App; | |
using Android.OS; | |
using MvvmCross.Droid.Views; | |
namespace MonkeyList.Droid | |
{ | |
[Activity] | |
public class MonkeysView : MvxActivity | |
{ | |
protected override void OnCreate(Bundle bundle) |
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
using MvvmCross.Core.ViewModels; | |
namespace MonkeyList.Core.ViewModels | |
{ | |
public class MonkeysViewModel : MvxViewModel | |
{ | |
public MvxObservableCollection<Monkey> Monkeys => new MvxObservableCollection<Monkey>(); | |
public MonkeysViewModel() | |
{ |
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
namespace MonkeyList.Core | |
{ | |
public class Monkey | |
{ | |
public string Name { get; set; } | |
public string Location { get; set; } | |
public string Details { get; set; } | |
public string Image { get; set; } | |
} | |
} |
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
using System; | |
using MonkeyList.Core.ViewModels; | |
using MvvmCross.Binding.BindingContext; | |
using MvvmCross.Binding.iOS.Views; | |
using MvvmCross.iOS.Views; | |
using UIKit; | |
namespace MonkeyList.Core.iOS | |
{ | |
public partial class MonkeysView : MvxViewController<MonkeysViewModel> |