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
public static UIImage ScaleImage(UIImage image, int maxSize) | |
{ | |
UIImage res; | |
using (CGImage imageRef = image.CGImage) | |
{ | |
CGImageAlphaInfo alphaInfo = imageRef.AlphaInfo; | |
CGColorSpace colorSpaceInfo = CGColorSpace.CreateDeviceRGB(); | |
if (alphaInfo == CGImageAlphaInfo.None) |
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
void initCameraView(){ | |
NSError error = null; | |
captureSession = new AVCaptureSession(){ | |
SessionPreset=AVCaptureSession.Preset640x480 | |
}; | |
var device = AVCaptureDevice.DefaultDeviceWithMediaType(AVMediaType.Video); | |
var deviceInput = AVCaptureDeviceInput.FromDevice(device,out error); | |
if(error!=null){ | |
displayErrorOnMainQueueWithMessage(error,"Unable to setup capture"); | |
return; |
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 System; | |
using MonoTouch.UIKit; | |
using MonoTouch.Foundation; | |
using System.Drawing; | |
namespace TwinCoders.Utils | |
{ | |
public abstract partial class ParentViewController | |
{ |
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
else if (restRequest.ContentType == ContentTypes.MultipartFormData) | |
{ | |
var multipartPartFormDataContent = new MultipartFormDataContent(); | |
var contentJson = new StringContent(restRequest.GetRequestBody()); | |
multipartPartFormDataContent.Add(contentJson); | |
httpRequestMessage.Content = contentJson; | |
if (restRequest.Files.Any()) | |
foreach (var fileParameter in restRequest.Files) | |
{ |
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
1>Server command 'Build': application remote build failed | |
1>Command execution task ended with exception | |
1>Exception System.Net.WebException: The remote server returned an error: (500) Internal Server Error. | |
1>Exception details can be found in the log file | |
1> | |
1> | |
1>Remote build step failed. | |
1>Done building target "_BuildNativeApplication" in project "Travefy.Touch.csproj" -- FAILED. | |
1>Done building project "Travefy.Touch.csproj" -- FAILED. | |
1>Build FAILED. |
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
public class TextViewImeActionBinding : MvxAndroidTargetBinding | |
{ | |
private bool subscribed; | |
private ICommand _command; | |
protected TextView TextView | |
{ | |
get { return Target as TextView; } | |
} |
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
/// <summary> | |
/// Author: softlion (softlion@softlion.com) | |
/// </summary> | |
/// <remarks> | |
/// Thanks to: Stuart Lodge | |
/// </remarks> | |
public class MvxRadioGroupSelectedIndexBinding : MvxAndroidTargetBinding | |
{ | |
bool stopListeningCheckChanged = false; |
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
<TextView | |
local:MvxBind="Text PasswordConfirm; ImeAction RegisterCommand" | |
android:textAppearance="?android:attr/textAppearanceLarge" | |
android:layout_width="match_parent" | |
android:layout_height="wrap_content" | |
android:hint="Password" | |
android:inputType="textPassword" | |
android:imeOptions="actionSend" /> |
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 System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Text; | |
using Android.App; | |
using Android.Content; | |
using Android.OS; | |
using Android.Runtime; | |
using Android.Views; |
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
// MvxFileDownloadCache.cs | |
// (c) Copyright Cirrious Ltd. http://www.cirrious.com | |
// MvvmCross is licensed using Microsoft Public License (Ms-PL) | |
// Contributions and inspirations noted in readme.md and license.txt | |
// | |
// Project Lead - Stuart Lodge, @slodge, me@slodge.com | |
using System; | |
using System.Collections.Generic; | |
using System.Linq; |
OlderNewer