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 interface IPromise | |
{ | |
/// <summary> | |
/// Attaches a callback to be executed when the Deferred is resolved | |
/// </summary> | |
IPromise Done(Action callback); | |
/// <summary> | |
/// Attaches a callback to be executed when the Deferred is rejected | |
/// </summary> | |
IPromise Fail(Action<Exception> callback); |
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
/* | |
Inject the IComponentContext in the property of every BaseController | |
In BaseController I'll use IComponentContext to resolve services that are non singleton(i.e. datacontext dependency that | |
use per request lifetime scope) | |
*/ | |
static void SetDependencyResolverAndConfig(Action<ContainerBuilder> config) | |
{ | |
var builder = new ContainerBuilder(); | |
builder.RegisterApiControllers(Assembly.GetExecutingAssembly()) | |
.OnActivated((e) => |
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 void DismissKeyboard(UIView view) | |
{ | |
if (AppManager.IsKeyboardVisible) | |
{ | |
var text = new UITextField(RectangleF.Empty); | |
view.AddSubview(text); | |
text.BecomeFirstResponder(); | |
text.ResignFirstResponder(); | |
text.RemoveFromSuperview(); | |
text.Dispose(); |
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.ObjCRuntime; | |
[assembly: LinkWith ("libATMHudSDK.a", LinkTarget.Simulator | LinkTarget.ArmV7, ForceLoad = true, Frameworks="AudioToolbox QuartzCore CoreGraphics")] |