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 partial class AppDelegate : UIApplicationDelegate | |
{ | |
public SummaryDialogViewController Summary2; | |
public EntryDialogViewController EntryDVC; | |
public SettingsDialogViewController SettingsDVC; | |
public UITabBarController tabBar; | |
public UIView MainView; | |
public UIViewController[] tabControllers; |
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.Dialog; | |
using MonoTouch.UIKit; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Drawing; | |
namespace TravelBudget | |
{ | |
//BaseDialogViewController just inherits off DialogViewController |
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
// copied from StyledStringElement, I think. | |
// mostly just gets the cell, puts a background on it (which also gets rid of the default | |
// rounded corners etc) and sets the colours on the _existing_ cell.TextLabel and cell.DetailTextLabel | |
public class BackgroundStringElement : StyledStringElement, IElementSizing | |
{ | |
//if you make a new element, you NEED to put in a unique identifier, and use it in the DequeueReusableCell. | |
static NSString skey = new NSString("BackgroundStringElement"); | |
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 InvoiceElement : StyledStringElement, IElementSizing | |
{ | |
private Contact contact; | |
private Invoice invoice; | |
static NSString skey = new NSString("InvoiceElement"); | |
public InvoiceElement(Invoice invoice, Contact contact, NSAction ontapped) : base("", ontapped) | |
{ | |
this.contact = contact; |
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 MonoTouch.Foundation; | |
Task.Factory.StartNew(() => { | |
Console.WriteLine ("ping"); | |
Thread.Sleep(4000); | |
Console.WriteLine ("pong"); | |
return "from the thread"; |
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.Diagnostics; | |
using System.Linq; | |
using System.Text; | |
using System.IO; | |
using System.Threading; | |
using System.Web; | |
using System.Web.Caching; |
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 BTDateElement : EntryElement | |
{ | |
public bool minDateSet = false; | |
public bool maxDateSet = false; | |
private DateTime _minDate, _maxDate; | |
public DateTime MinDate | |
{ | |
get { return _minDate; } | |
set { _minDate = value; minDateSet = true; } | |
} |
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 EditingSource : DialogViewController.Source | |
{ | |
RecordsDialogViewController tvc = null; | |
public EditingSource(RecordsDialogViewController dvc) : base(dvc) | |
{ | |
tvc = dvc; | |
} | |
public override bool CanEditRow (UITableView tableView, NSIndexPath indexPath) |
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
//most of the non-declared variables here are at the class level - eg window is: | |
// UIWindow window | |
// etc. | |
window = new UIWindow (UIScreen.MainScreen.Bounds); | |
UIApplication.SharedApplication.StatusBarStyle = UIStatusBarStyle.BlackOpaque; | |
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 BTPinchGestureRecognizer : UIPinchGestureRecognizer | |
{ | |
public BTPinchGestureRecognizer(NSObject target, Selector action) : base(target, action) | |
{ | |
ShouldReceiveTouch += (sender, touch) => { | |
//if (touch.View is UISlider || touch.View is MPVolumeView) return false; | |
return true; | |
}; | |