コード例 #1
0
ファイル: ImageTextCellHandler.cs プロジェクト: sami1971/Eto
        public override NSObject GetObjectValue(object dataItem)
        {
            var result = new MacImageData();

            if (Widget.TextBinding != null)
            {
                result.Text = (NSString)Convert.ToString(Widget.TextBinding.GetValue(dataItem));
            }
            if (Widget.ImageBinding != null)
            {
                var image = Widget.ImageBinding.GetValue(dataItem) as Image;
                result.Image = image != null ? ((IImageSource)image.Handler).GetImage() : null;
            }
            else
            {
                result.Image = null;
            }
            return(result);
        }
コード例 #2
0
 public MacImageData(MacImageData value)
 {
     this.Text  = value.Text;
     this.Image = value.Image;
 }
コード例 #3
0
		public MacImageData (MacImageData value)
		{
			this.Text = value.Text;
			this.Image = value.Image;
		}