void LayoutDoc_Closed(object sender, EventArgs e) { LayoutDocument layoutDoc = sender as LayoutDocument; IViewHolder viewHolder = layoutDoc.Content as IViewHolder; IView view = viewHolder.view; RemoveView(view); }
public override void setCoord(MapPoint mapPt) { string coord = string.Format("X = {0}, Z = {1}", Math.Round(mapPt.X, 2), Math.Round(mapPt.Y, 2)); IViewHolder viewHolder = _parent as IViewHolder; if (viewHolder != null) { viewHolder.setCoord(coord); } }
private void CreateViewHolder() { try { m_viewHolder = new ViewHolder <IDebuggerSprinterView>("Debugger"); } catch (Exception ex) { Logger.Error(ex); } }
private void CreateViewHolder() { try { m_viewHolder = new ViewHolder <IFddDebugView>( "WD1793", new Argument("debugTarget", m_wd)); } catch (Exception ex) { Logger.Error(ex); } }
private void CreateViewHolder() { try { m_viewHolder = new ViewHolder <IMemoryMapView>( "Memory Map", new Argument("memory", this)); } catch (Exception ex) { Logger.Error(ex); } }
private void CreateViewHolder() { try { m_viewHolder = new ViewHolder <ITapeView>( "Tape", new Argument("tapeDevice", this)); } catch (Exception ex) { Logger.Error(ex); } }
public override View GetView(int position, View convertView, ViewGroup parent) { IViewHolder viewHolder; View view = convertView; if (view == null) { if (isGrid) { view = layoutInflater.Inflate(Resource.Layout.simple_grid_item, parent, false); } else { view = layoutInflater.Inflate(Resource.Layout.simple_list_item, parent, false); } viewHolder = new IViewHolder() { textView = view.FindViewById <TextView>(Resource.Id.text_view), imageView = view.FindViewById <ImageView>(Resource.Id.image_view) }; view.Tag = viewHolder; } else { viewHolder = (IViewHolder)view.Tag; } Context context = parent.Context; switch (position) { case 0: viewHolder.textView.Text = context.GetString(Resource.String.google_plus_title); viewHolder.imageView.SetImageResource(Resource.Drawable.ic_google_plus_icon); break; case 1: viewHolder.textView.Text = context.GetString(Resource.String.google_maps_title); viewHolder.imageView.SetImageResource(Resource.Drawable.ic_google_maps_icon); break; default: viewHolder.textView.Text = context.GetString(Resource.String.google_messenger_title); viewHolder.imageView.SetImageResource(Resource.Drawable.ic_google_messenger_icon); break; } return(view); }
public virtual void setCoord(MapPoint mapPt) { string format = "X = {0}, Y = {1}"; if (eMap.MapType == EngineeringMapType.GeneralProfileMap) { format = "X = {0}, Z = {1}"; } string coord = string.Format(format, Math.Round(mapPt.X, 2), Math.Round(mapPt.Y, 2)); IViewHolder viewHolder = _parent as IViewHolder; if (viewHolder != null) { viewHolder.setCoord(coord); } }
public DropEvent(InventoryComponent carrier, InventorySlotResource slot, IViewHolder viewHolder) { this.carrier = carrier; this.slot = slot; this.viewHolder = viewHolder; }
public PickUpEvent(InventoryComponent carrier, CarriableComponent carried, IViewHolder viewHolder) { this.carrier = carrier; this.carried = carried; this.viewHolder = viewHolder; }