-
-
Notifications
You must be signed in to change notification settings - Fork 136
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
9f303ca
commit 6524709
Showing
12 changed files
with
623 additions
and
3 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,226 @@ | ||
################# | ||
## Eclipse | ||
################# | ||
|
||
*.pydevproject | ||
.project | ||
.metadata | ||
.nuget | ||
bin/ | ||
tmp/ | ||
*.tmp | ||
*.bak | ||
*.swp | ||
*~.nib | ||
local.properties | ||
.classpath | ||
.settings/ | ||
.loadpath | ||
*.userprefs | ||
|
||
# External tool builders | ||
.externalToolBuilders/ | ||
|
||
# Locally stored "Eclipse launch configurations" | ||
*.launch | ||
|
||
# CDT-specific | ||
.cproject | ||
|
||
# PDT-specific | ||
.buildpath | ||
|
||
|
||
################# | ||
## Visual Studio | ||
################# | ||
|
||
## Ignore Visual Studio temporary files, build results, and | ||
## files generated by popular Visual Studio add-ons. | ||
|
||
# User-specific files | ||
*.suo | ||
*.user | ||
*.sln.docstates | ||
|
||
# Build results | ||
|
||
[Dd]ebug/ | ||
[Rr]elease/ | ||
x64/ | ||
build/ | ||
[Bb]in/ | ||
[Oo]bj/ | ||
[Cc]omponents/ | ||
[Pp]ackages/ | ||
|
||
# MSTest test Results | ||
[Tt]est[Rr]esult*/ | ||
[Bb]uild[Ll]og.* | ||
|
||
*_i.c | ||
*_p.c | ||
*.ilk | ||
*.meta | ||
*.obj | ||
*.pch | ||
*.pdb | ||
*.pgc | ||
*.pgd | ||
*.rsp | ||
*.sbr | ||
*.tlb | ||
*.tli | ||
*.tlh | ||
*.tmp | ||
*.tmp_proj | ||
*.log | ||
*.vspscc | ||
*.vssscc | ||
.builds | ||
*.pidb | ||
*.log | ||
*.scc | ||
|
||
# Visual C++ cache files | ||
ipch/ | ||
*.aps | ||
*.ncb | ||
*.opensdf | ||
*.sdf | ||
*.cachefile | ||
|
||
# Visual Studio profiler | ||
*.psess | ||
*.vsp | ||
*.vspx | ||
|
||
# Guidance Automation Toolkit | ||
*.gpState | ||
|
||
# ReSharper is a .NET coding add-in | ||
_ReSharper*/ | ||
*.[Rr]e[Ss]harper | ||
|
||
# TeamCity is a build add-in | ||
_TeamCity* | ||
|
||
# DotCover is a Code Coverage Tool | ||
*.dotCover | ||
|
||
# NCrunch | ||
*.ncrunch* | ||
.*crunch*.local.xml | ||
|
||
# Installshield output folder | ||
[Ee]xpress/ | ||
|
||
# DocProject is a documentation generator add-in | ||
DocProject/buildhelp/ | ||
DocProject/Help/*.HxT | ||
DocProject/Help/*.HxC | ||
DocProject/Help/*.hhc | ||
DocProject/Help/*.hhk | ||
DocProject/Help/*.hhp | ||
DocProject/Help/Html2 | ||
DocProject/Help/html | ||
|
||
# Click-Once directory | ||
publish/ | ||
|
||
# Publish Web Output | ||
*.Publish.xml | ||
*.pubxml | ||
|
||
# NuGet Packages Directory | ||
## TODO: If you have NuGet Package Restore enabled, uncomment the next line | ||
#packages/ | ||
|
||
# Windows Azure Build Output | ||
csx | ||
*.build.csdef | ||
|
||
# Windows Store app package directory | ||
AppPackages/ | ||
|
||
# Others | ||
sql/ | ||
*.Cache | ||
ClientBin/ | ||
[Ss]tyle[Cc]op.* | ||
~$* | ||
*~ | ||
*.dbmdl | ||
*.[Pp]ublish.xml | ||
*.pfx | ||
*.publishsettings | ||
|
||
# RIA/Silverlight projects | ||
Generated_Code/ | ||
|
||
# Backup & report files from converting an old project file to a newer | ||
# Visual Studio version. Backup files are not needed, because we have git ;-) | ||
_UpgradeReport_Files/ | ||
Backup*/ | ||
UpgradeLog*.XML | ||
UpgradeLog*.htm | ||
|
||
# SQL Server files | ||
App_Data/*.mdf | ||
App_Data/*.ldf | ||
|
||
############# | ||
## Windows detritus | ||
############# | ||
|
||
# Windows image file caches | ||
Thumbs.db | ||
ehthumbs.db | ||
|
||
# Folder config file | ||
Desktop.ini | ||
|
||
# Recycle Bin used on file shares | ||
$RECYCLE.BIN/ | ||
|
||
# Mac crap | ||
.DS_Store | ||
|
||
############# | ||
Git | ||
############# | ||
|
||
*.orig | ||
|
||
############# | ||
## Python | ||
############# | ||
|
||
*.py[co] | ||
|
||
# Packages | ||
*.egg | ||
*.egg-info | ||
dist/ | ||
build/ | ||
eggs/ | ||
parts/ | ||
var/ | ||
sdist/ | ||
develop-eggs/ | ||
.installed.cfg | ||
|
||
# Installer logs | ||
pip-log.txt | ||
|
||
# Unit test / coverage reports | ||
.coverage | ||
.tox | ||
|
||
#Translations | ||
*.mo | ||
|
||
#Mr Developer | ||
.mr.developer.cfg | ||
|
||
XamarinEvolve.userprefs |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Licensed under the Apache License, Version 2.0 |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<package xmlns="http://schemas.microsoft.com/packaging/2010/07/nuspec.xsd"> | ||
<metadata minClientVersion="2.8.1"> | ||
<id>Refractored.MvvmHelpers</id> | ||
<version>1.0.0</version> | ||
<title>Mvvm Helpers for Xamarin and Windows</title> | ||
<authors>James Montemagno</authors> | ||
<owners>James Montemagno</owners> | ||
<licenseUrl>https://raw.githubusercontent.com/jamesmontemagno/mvvm-helpers/master/LICENSE.md</licenseUrl> | ||
<projectUrl>https://github.com/jamesmontemagno/mvvm-helpers</projectUrl> | ||
<iconUrl></iconUrl> | ||
<requireLicenseAcceptance>false</requireLicenseAcceptance> | ||
<description> | ||
Collection of Mvvm Helpers such as ObservableRangeCollection, BaseViewModel, Grouping, and others. | ||
</description> | ||
<summary>Collection of Mvvm Helpers such as ObservableRangeCollection, BaseViewModel, Grouping, and others.</summary> | ||
<tags>permissions, plugin permissions, permission plugin, xamarin, pcl, xam.pcl, plugin, plugin for xamarin, windows phone, winphone, wp8, winrt, android, xamarin.forms, ios</tags> | ||
<dependencies> | ||
</dependencies> | ||
<releaseNotes> | ||
</releaseNotes> | ||
</metadata> | ||
<files> | ||
<!--Core--> | ||
<file src="MvvmHelpers\bin\Release\MvvmHelpers.dll" target="lib\portable-net45+wp8+wpa81+win8+MonoAndroid10+MonoTouch10+Xamarin.iOS10+UAP10\MvvmHelpers.dll" /> | ||
<file src="MvvmHelpers\bin\Release\MvvmHelpers.xml" target="lib\portable-net45+wp8+wpa81+win8+MonoAndroid10+MonoTouch10+Xamarin.iOS10+UAP10\MvvmHelpers.xml" /> | ||
<file src="MvvmHelpers\bin\Release\MvvmHelpers.pdb" target="lib\portable-net45+wp8+wpa81+win8+MonoAndroid10+MonoTouch10+Xamarin.iOS10+UAP10\MvvmHelpers.pdb" /> | ||
</files> | ||
</package> |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
|
||
Microsoft Visual Studio Solution File, Format Version 12.00 | ||
# Visual Studio 2012 | ||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MvvmHelpers", "MVVMHelpers\MvvmHelpers.csproj", "{41755AC7-8160-4857-8AA7-6EDCD76923EA}" | ||
EndProject | ||
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{93B692A1-FE26-4A59-B906-0CBADB102B8F}" | ||
ProjectSection(SolutionItems) = preProject | ||
MvvmHelpers.nuspec = MvvmHelpers.nuspec | ||
EndProjectSection | ||
EndProject | ||
Global | ||
GlobalSection(SolutionConfigurationPlatforms) = preSolution | ||
Debug|Any CPU = Debug|Any CPU | ||
Release|Any CPU = Release|Any CPU | ||
EndGlobalSection | ||
GlobalSection(ProjectConfigurationPlatforms) = postSolution | ||
{41755AC7-8160-4857-8AA7-6EDCD76923EA}.Debug|Any CPU.ActiveCfg = Debug|Any CPU | ||
{41755AC7-8160-4857-8AA7-6EDCD76923EA}.Debug|Any CPU.Build.0 = Debug|Any CPU | ||
{41755AC7-8160-4857-8AA7-6EDCD76923EA}.Release|Any CPU.ActiveCfg = Release|Any CPU | ||
{41755AC7-8160-4857-8AA7-6EDCD76923EA}.Release|Any CPU.Build.0 = Release|Any CPU | ||
EndGlobalSection | ||
GlobalSection(NestedProjects) = preSolution | ||
EndGlobalSection | ||
EndGlobal |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,86 @@ | ||
namespace MvvmHelpers | ||
{ | ||
/// <summary> | ||
/// Base view model. | ||
/// </summary> | ||
public class BaseViewModel : ObservableObject | ||
{ | ||
string title = string.Empty; | ||
|
||
/// <summary> | ||
/// Gets or sets the title. | ||
/// </summary> | ||
/// <value>The title.</value> | ||
public string Title | ||
{ | ||
get { return title; } | ||
set { SetProperty(ref title, value); } | ||
} | ||
|
||
string subTitle = string.Empty; | ||
|
||
/// <summary> | ||
/// Gets or sets the subtitle. | ||
/// </summary> | ||
/// <value>The subtitle.</value> | ||
public string Subtitle | ||
{ | ||
get { return subTitle; } | ||
set { SetProperty(ref subTitle, value); } | ||
} | ||
|
||
string icon = string.Empty; | ||
|
||
/// <summary> | ||
/// Gets or sets the icon. | ||
/// </summary> | ||
/// <value>The icon.</value> | ||
public string Icon | ||
{ | ||
get { return icon; } | ||
set { SetProperty(ref icon, value); } | ||
} | ||
|
||
bool isBusy; | ||
|
||
/// <summary> | ||
/// Gets or sets a value indicating whether this instance is busy. | ||
/// </summary> | ||
/// <value><c>true</c> if this instance is busy; otherwise, <c>false</c>.</value> | ||
public bool IsBusy | ||
{ | ||
get { return isBusy; } | ||
set | ||
{ | ||
if (SetProperty(ref isBusy, value)) | ||
IsNotBusy = !isBusy; | ||
} | ||
} | ||
|
||
bool isNotBusy = true; | ||
|
||
/// <summary> | ||
/// Gets or sets a value indicating whether this instance is not busy. | ||
/// </summary> | ||
/// <value><c>true</c> if this instance is not busy; otherwise, <c>false</c>.</value> | ||
public bool IsNotBusy | ||
{ | ||
get { return isNotBusy; } | ||
private set { SetProperty(ref isNotBusy, value); } | ||
} | ||
|
||
bool canLoadMore = true; | ||
|
||
/// <summary> | ||
/// Gets or sets a value indicating whether this instance can load more. | ||
/// </summary> | ||
/// <value><c>true</c> if this instance can load more; otherwise, <c>false</c>.</value> | ||
public bool CanLoadMore | ||
{ | ||
get { return canLoadMore; } | ||
set { SetProperty(ref canLoadMore, value); } | ||
} | ||
} | ||
} | ||
|
||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
using System.Collections.ObjectModel; | ||
using System.Collections.Generic; | ||
|
||
namespace MvvmHelpers | ||
{ | ||
public class Grouping<T, TV> : ObservableCollection<TV> | ||
{ | ||
public T Key { get; private set; } | ||
|
||
public Grouping(T key, IList<TV> items) | ||
{ | ||
Key = key; | ||
foreach (var item in items) | ||
Items.Add(item); | ||
} | ||
} | ||
} | ||
|
Oops, something went wrong.