当前位置: 首页>>代码示例>>C#>>正文


C# Foundation类代码示例

本文整理汇总了C#中Foundation的典型用法代码示例。如果您正苦于以下问题:C# Foundation类的具体用法?C# Foundation怎么用?C# Foundation使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


Foundation类属于命名空间,在下文中一共展示了Foundation类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: GetCell

 public override UITableViewCell GetCell(UITableView tableView, Foundation.NSIndexPath indexPath)
 {
     var cell = (PlayInfoCell)tableView.DequeueReusableCell(CELL_IDENT);
     var item = tableItems[indexPath.Row];
     cell.SetInformation(item, (indexPath.Row + 1));
     return cell;
 }
开发者ID:Kethsar,项目名称:CS235IM,代码行数:7,代码来源:PlayDataSource.cs

示例2: GetSizeForItem

		public override CoreGraphics.CGSize GetSizeForItem (UICollectionView collectionView, UICollectionViewLayout layout, Foundation.NSIndexPath indexPath)
		{
			if (Master.MaxHeight != 0) {
				return new CoreGraphics.CGSize ((Master.View.Frame.Size.Width - 10) / 3, Master.MaxHeight);
			}
			return new CoreGraphics.CGSize ((Master.View.Frame.Size.Width - padding - 10) / 3, (Master.View.Frame.Size.Width - padding - 10) / 3 + differential);
		}
开发者ID:natevarghese,项目名称:XamarinTen,代码行数:7,代码来源:UserFeedCollectionViewDelegateFlowLayout.cs

示例3: WillDisplay

 public override void WillDisplay(UITableView tableView, UITableViewCell cell, Foundation.NSIndexPath indexPath)
 {
     //			cell.SeparatorInset = UIEdgeInsets.Zero;
     //			cell.PreservesSuperviewLayoutMargins = false;
     //			cell.LayoutMargins = UIEdgeInsets.Zero;
     //
 }
开发者ID:ctsxamarintraining,项目名称:cts440202,代码行数:7,代码来源:TripTableSOurce.cs

示例4: TouchesCancelled

		/// <summary>
		/// Called when the touches are cancelled due to a phone call, etc.
		/// </summary>
		public override void TouchesCancelled (Foundation.NSSet touches, UIEvent evt)
		{
			base.TouchesCancelled (touches, evt);
			// we fail the recognizer so that there isn't unexpected behavior
			// if the application comes back into view
			base.State = UIGestureRecognizerState.Failed;
		}
开发者ID:CBrauer,项目名称:monotouch-samples,代码行数:10,代码来源:CheckmarkGestureRecognizer.cs

示例5: InitalizeWithEmptyBuffer

		public void InitalizeWithEmptyBuffer()
		{
			using (var foundation = new Foundation())
			{
				var stream = new DefaultMemoryOutputStream(new byte[] { });
			}
		}
开发者ID:kpko,项目名称:PhysX.Net,代码行数:7,代码来源:DefaultMemoryOutputStreamTest.cs

示例6: GetHeightForRow

		public override nfloat GetHeightForRow (UITableView tableView, Foundation.NSIndexPath indexPath)
		{
			if (!data.IsList && indexPath.Section == 0) {
				return indexPath.Row == 0 ? 66.0f : 22.0f;
			}
			return 44.0f;
		}
开发者ID:mono,项目名称:Continuous,代码行数:7,代码来源:ObjectInspector.cs

示例7: ShouldStartLoad

		public override bool ShouldStartLoad (UIWebView webView, Foundation.NSUrlRequest request, UIWebViewNavigationType navigationType)
		{
			WebNavigationEvent navEvent = WebNavigationEvent.NewPage;
			switch (navigationType) {
			case UIWebViewNavigationType.LinkClicked:
				navEvent = WebNavigationEvent.NewPage;
				break;
			case UIWebViewNavigationType.FormSubmitted:
				navEvent = WebNavigationEvent.NewPage;
				break;
			case UIWebViewNavigationType.Reload:
				navEvent = WebNavigationEvent.Refresh;
				break;
			case UIWebViewNavigationType.FormResubmitted:
				navEvent = WebNavigationEvent.NewPage;
				break;
			case UIWebViewNavigationType.Other:
				navEvent = WebNavigationEvent.NewPage;
				break;
			}

			lastEvent = navEvent;

			Console.WriteLine ("[Custom Delegate] Url: {0}", request.Url);
			Console.WriteLine ("[Custom Delegate] MainDocUrl: {0}", request.MainDocumentURL);
			return true;
		}
开发者ID:ChandrakanthBCK,项目名称:customer-success-samples,代码行数:27,代码来源:WebViewCustomRenderer.cs

示例8: DefaultResolutionPipeline

        public DefaultResolutionPipeline(Foundation foundation, IServiceLocatorAdapter adapter, IServiceLocatorStore store)
            : base(foundation, adapter, store)
        {
            var pipeline = new PostResolutionPipeline(foundation, adapter, store);

            Add(new AdapterPipelineItem(foundation, adapter, store, pipeline));
        }
开发者ID:adamjmoon,项目名称:Siege,代码行数:7,代码来源:DefaultResolutionPipeline.cs

示例9: SelectionDidChange

 public override void SelectionDidChange (Foundation.NSNotification notification)
 {
     if (_callback != null)
     {
         _callback.SelectionDidChange();
     }
 }
开发者ID:SubtitleEdit,项目名称:subtitleedit-mac,代码行数:7,代码来源:StringListTableDelegate.cs

示例10: GetCell

        public override UITableViewCell GetCell(UITableView tableView, Foundation.NSIndexPath indexPath)
        {
            cell = tableView.DequeueReusableCell ("instaReuseCell") as InstaTabControllerCell;
            cell.UpdateCell(mData [indexPath.Row].UserName, UIImage.FromFile (mData[indexPath.Row].ImageName),mData [indexPath.Row].Detail,mData [indexPath.Row].NumLikes, mData [indexPath.Row].NumComments,mData [indexPath.Row].PostDate,UIImage.FromFile (mData[indexPath.Row].PostImage) );

            return cell;
        }
开发者ID:poojagaonkar,项目名称:PGDemoIOS,代码行数:7,代码来源:InstaTableSource.cs

示例11: FinishedLaunching

		public override void FinishedLaunching (Foundation.NSObject notification)
		{
			if (mainFormFunc != null)
				main_form = mainFormFunc ();
			main_form.m_helper.MakeKeyAndOrderFront (this);
			main_form.m_helper.DidChangeScreen += delegate(object sender, EventArgs e) { main_form.m_helper.Display (); };
		}
开发者ID:Clancey,项目名称:MonoMac.Windows.Form,代码行数:7,代码来源:ApplicationContext.cs

示例12: GetCell

		public override UITableViewCell GetCell (UITableView tableView, Foundation.NSIndexPath indexPath)
		{
			UITableViewCell cell = tableView.DequeueReusableCell ( strCellIdentifier ) ?? new UITableViewCell ( UITableViewCellStyle.Default , strCellIdentifier );
			cell.TextLabel.Text = lstContacts [indexPath.Row].strContactName;
			cell.TextLabel.Font = UIFont.SystemFontOfSize (12);
			return cell;
		}
开发者ID:suchithm,项目名称:SqliteDemo.iOS,代码行数:7,代码来源:ContactListTableSource.cs

示例13: TouchesBegan

		public override void TouchesBegan (Foundation.NSSet touches, UIKit.UIEvent evt)
		{

			swiped = false;
			UITouch touch = touches.AnyObject as UITouch ;
			lastPoint = touch.LocationInView (this);
		}
开发者ID:CrossGeeks,项目名称:Xamarin.Samples,代码行数:7,代码来源:NativeDrawView.cs

示例14: FactoryResolutionPipeline

        public FactoryResolutionPipeline(Foundation foundation, IServiceLocatorAdapter adapter, IServiceLocatorStore store)
        {
            var pipeline = new PostResolutionPipeline(foundation, adapter, store);

            Add(new ConditionalPipelineItem(foundation, adapter, store, pipeline));
            Add(new DefaultPipelineItem(foundation, adapter, store, pipeline));
        }
开发者ID:rexwhitten,项目名称:Siege,代码行数:7,代码来源:FactoryResolutionPipeline.cs

示例15: TouchesMoved

		/// <summary>
		/// Called when the fingers move
		/// </summary>
		public override void TouchesMoved (Foundation.NSSet touches, UIEvent evt)
		{
			base.TouchesMoved (touches, evt);

			// if we haven't already failed
			if(base.State != UIGestureRecognizerState.Failed) {

				// get the current and previous touch point
				CGPoint newPoint = (touches.AnyObject as UITouch).LocationInView (View);
				CGPoint previousPoint = (touches.AnyObject as UITouch).PreviousLocationInView (View);

				// if we're not already on the upstroke
				if(!strokeUp) {

					// if we're moving down, just continue to set the midpoint at
					// whatever point we're at. when we start to stroke up, it'll stick
					// as the last point before we upticked
					if (newPoint.X >= previousPoint.X && newPoint.Y >= previousPoint.Y)
						midpoint = newPoint;
					// if we're stroking up (moving right x and up y [y axis is flipped])
					else if (newPoint.X >= previousPoint.X && newPoint.Y <= previousPoint.Y)
						strokeUp = true;
					// otherwise, we fail the recognizer
					else
						base.State = UIGestureRecognizerState.Failed;
				}
			}

			Console.WriteLine (base.State.ToString ());
		}
开发者ID:CBrauer,项目名称:monotouch-samples,代码行数:33,代码来源:CheckmarkGestureRecognizer.cs


注:本文中的Foundation类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。