Skip to content

Instantly share code, notes, and snippets.

View markjulmar's full-sized avatar

Mark Smith markjulmar

View GitHub Profile
@markjulmar
markjulmar / gist:0831db8f4a5c3d0700f3
Created July 1, 2014 16:55
Creating a Color in XAML
<?xml version="1.0" encoding="UTF-8" ?>
<ContentPage x:Class="TestXaml.MainPage"
xmlns="http://xamarin.com/schemas/2014/forms"
xmlns:me="clr-namespace:TestXaml;assembly=TestXaml"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml">
<StackLayout Spacing="10">
<StackLayout.Resources>
<ResourceDictionary>
@markjulmar
markjulmar / AnimateCells
Last active August 29, 2015 14:22
Fancy UITableViewCell animations
// To get some fancy animation for your UITableViewCells
// (converted from ObjC code found at http://www.thinkandbuild.it/animating-uitableview-cells/):
// Put this into the UITableViewDelegate
public override void WillDisplay (UITableView tableView, UITableViewCell cell, NSIndexPath indexPath)
{
CATransform3D rotation = CATransform3D.MakeRotation( (90.0f*(float)Math.PI)/180f, 0.0f, 0.7f, 0.4f);
rotation.m34 = 1.0f/ -600f;
cell.Layer.ShadowColor = UIColor.Black.CGColor;
cell.Layer.ShadowOffset = new SizeF (10, 10);
@markjulmar
markjulmar / build.txt
Created October 16, 2015 17:04
AOT-VS-Fail Build Output
This file has been truncated, but you can view the full file.
1>Project 'ProtocolAssistDevice' is not up to date. Error (0x8000FFFF).
Restoring NuGet packages...
To prevent NuGet from restoring packages during build, open the Visual Studio Options dialog, click on the Package Manager node and uncheck 'Allow NuGet to download missing packages during build.'
NuGet package restore finished.
1>------ Build started: Project: ProtocolAssistDevice, Configuration: Debug Any CPU ------
1>Build started 10/16/2015 11:59:02 AM.
1>Environment at start of build:
1>ALLUSERSPROFILE = C:\ProgramData
1>ANDROID_NDK_PATH = C:\Users\mark\Documents\Android\ndk\android-ndk-r10d
1>APPDATA = C:\Users\mark\AppData\Roaming
@markjulmar
markjulmar / gist:898d60f3ab6fbe7eea45
Last active October 17, 2015 22:32
Rebuild Verbose - AOT Error
This file has been truncated, but you can view the full file.
1>Project 'ProtocolAssistDevice.iOS' is not up to date. Missing output file 'C:\Users\mark\Desktop\Error\ProtocolAssistDevice\ProtocolAssistDevice.iOS\bin\iPhone\Debug\ProtocolAssistDeviceiOS.exe'.
1>------ Build started: Project: ProtocolAssistDevice.iOS, Configuration: Debug iPhone ------
1>Build started 10/17/2015 5:30:06 PM.
1>Environment at start of build:
1>ALLUSERSPROFILE = C:\ProgramData
1>ANDROID_NDK_PATH = C:\Users\mark\Documents\Android\ndk\android-ndk-r10d
1>APPDATA = C:\Users\mark\AppData\Roaming
1>CommonProgramFiles = C:\Program Files (x86)\Common Files
1>CommonProgramFiles(x86) = C:\Program Files (x86)\Common Files
1>CommonProgramW6432 = C:\Program Files\Common Files
@markjulmar
markjulmar / gist:28ee50416bcd8fafa10f
Created October 17, 2015 22:35
MTouch Commandline
1> Tool /Library/Frameworks/Xamarin.iOS.framework/Versions/Current/bin/mtouch execution started with arguments: --cache /Users/mark/Library/Caches/Xamarin/mtbs/builds/ProtocolAssistDeviceiOS/eea55df6b5e29402e5ed20c6a48dc92b/obj/iPhone/Debug/build-iphone8.1-9.0.2/mtouch-cache --dev /Users/mark/Library/Caches/Xamarin/mtbs/builds/ProtocolAssistDeviceiOS/eea55df6b5e29402e5ed20c6a48dc92b/bin/iPhone/Debug/build-iphone8.1-9.0.2/ProtocolAssistDeviceiOS.app --executable ProtocolAssistDeviceiOS --debug --linksdkonly --sdkroot /Applications/Xcode.app/Contents/Developer --sdk 9.0 --targetver 9.0 --aot-options=-O=-float32 --abi=armv7 --symbollist /Users/mark/Library/Caches/Xamarin/mtbs/builds/ProtocolAssistDeviceiOS/eea55df6b5e29402e5ed20c6a48dc92b/obj/iPhone/Debug/build-iphone8.1-9.0.2/mtouch-symbols.list --dsym=no -v -v -v -r /Library/Frameworks/Xamarin.iOS.framework/Versions/Current/lib/mono/Xamarin.iOS/mscorlib.dll -r /Users/mark/Library/Caches/Xamarin/mtbs/builds/ProtocolAssistDeviceiOS/eea55df6b5e29402e5ed20c6a48dc
@markjulmar
markjulmar / gist:d91a00e03fc255141058
Last active December 7, 2015 20:31
PickerCollection
using System;
using Xamarin.Forms;
using System.Collections;
using System.Diagnostics;
namespace MusicSearch.Infrastructure
{
public class PickerBindBehavior : Behavior<Picker>
{
Picker associatedPicker;
@markjulmar
markjulmar / Xamarin.Auth.diff
Created February 18, 2016 16:08
Fix double-processing of redirect_uri
--- a/src/Xamarin.Auth/OAuth2Authenticator.cs
+++ b/src/Xamarin.Auth/OAuth2Authenticator.cs
@@ -235,7 +235,7 @@ namespace Xamarin.Auth
using Xamarin.Forms;
using System.Threading.Tasks;
using System;
using System.Collections.Generic;
namespace GreatQuotes.Services
{
public class NavigationService
{
private static readonly Task TaskCompleted = Task.FromResult(0);
INFO [2016-04-12 11:10:50Z]: Starting Xamarin Studio 6.0 (build 4968)
INFO [2016-04-12 11:10:50Z]: Running on Mono 4.4.0 (mono-4.4.0-branch/a3fabf1) (64-bit)
INFO [2016-04-12 11:10:50Z]: Operating System: Mac OS X 10.11.4
Darwin Marks-MBP-2.local 15.4.0 Darwin Kernel Version 15.4.0
Fri Feb 26 22:08:05 PST 2016
root:xnu-3248.40.184~3/RELEASE_X86_64 x86_64
INFO [2016-04-12 11:10:50Z]: GTK: Using gtkrc from /Applications/Xamarin Studio.app/Contents/Resources/lib/monodevelop/bin/gtkrc.mac
2016-04-12 11:10:50.723 XamarinStudio[85523:25920012] *** WARNING: Method userSpaceScaleFactor in class NSView is deprecated on 10.7 and later. It should not be used in new applications. Use convertRectToBacking: instead.
INFO [2016-04-12 11:10:50Z]: Using GTK+ 2.24.23
INFO [2016-04-12 11:10:51Z]: Add-in loaded: MonoDevelop.Core
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Threading.Tasks;
using CastMyVote.Models;
using CastMyVote.Services;
using CastMyVote.ViewModels;
using Xamarin.Forms;