This file contains hidden or 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 System.Drawing; | |
using MonoTouch.CoreGraphics; | |
using MonoTouch.CoreAnimation; | |
namespace MTUtils | |
{ | |
public class Graphics | |
{ | |
static CGPath smallPath = MakeRoundedPath (48); |
This file contains hidden or 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.IO; | |
namespace Tables06 | |
{ | |
public class TempCache | |
{ | |
public readonly static string BaseDir = Path.Combine (Environment.GetFolderPath (Environment.SpecialFolder.Personal), ".."); | |
public readonly static string PicDir = Path.Combine (BaseDir, "Library/Caches/Pictures/"); | |
public readonly static string TmpDir = Path.Combine (BaseDir, "tmp/"); |
This file contains hidden or 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
/* | |
basedir/AppName.app Where the executables live. This is also the current working directory (Environment.CurrentDirectory). | |
basedir/Documents Where application-specific data files are stored. (This directory is backed up by iTunes.) | |
basedir/Library/Preferences Application-specific configuration settings. You should manage your settings using the NSUserDefaults class. (This directory is backed up by iTunes.) | |
basedir/Library/Caches Use this directory to store any cache data to be used across invocations of the application. | |
Your application is responsible for removing data files from this directory when it no longer needs them. | |
This file contains hidden or 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
/* | |
basedir/AppName.app Where the executables live. This is also the current working directory (Environment.CurrentDirectory). | |
basedir/Documents Where application-specific data files are stored. (This directory is backed up by iTunes.) | |
basedir/Library/Preferences Application-specific configuration settings. You should manage your settings using the NSUserDefaults class. (This directory is backed up by iTunes.) | |
basedir/Library/Caches Use this directory to store any cache data to be used across invocations of the application. | |
Your application is responsible for removing data files from this directory when it no longer needs them. | |
This file contains hidden or 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 bool hasFreeSpace() | |
{ | |
System.IO.DriveInfo[] drives = System.IO.DriveInfo.GetDrives(); | |
foreach (System.IO.DriveInfo drive in drives) { | |
if (drive.Name.ToString() == "/") | |
{ | |
if (drive.IsReady) { | |
Console.WriteLine(drive.AvailableFreeSpace); | |
if (drive.AvailableFreeSpace > 1000) |
This file contains hidden or 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 override void LayoutSubviews () | |
{ | |
// LayoutSubviews is called each time that we enter Editing Mode, So Lets Take This Opportunity To | |
// Show or Hide any elements we want | |
base.LayoutSubviews(); | |
if (this.Editing) | |
{ | |
this.DetailTextLabel.Hidden = true; | |
IntPtr sel = Selector.GetHandle ("description"); | |
//IntPtr sel = Selector.GetHandle ("class"); |
This file contains hidden or 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 override void Draw (RectangleF rect) | |
{ | |
base.Draw(rect); | |
UIImage img = UIImage.FromFile("Images/navigation_background.png"); | |
img.Draw(new RectangleF(0,0, 320,44)); | |
} |
This file contains hidden or 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; | |
using MonoTouch.UIKit; | |
using System.Drawing; | |
using MonoTouch.Foundation; | |
using System.Text; | |
using System.IO; | |
namespace MRB | |
{ |
This file contains hidden or 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; | |
using MonoTouch.UIKit; | |
using System.Drawing; | |
using MonoTouch.Foundation; | |
using MonoTouch.CoreGraphics; | |
using MonoTouch.ObjCRuntime; | |
namespace iDailyBooth |