Esempio n. 1
0
        public override void OnBindViewHolder(RecyclerView.ViewHolder holder, int position)
        {
            ItemViewHolder          vh = holder as ItemViewHolder;
            AllocationMsgDetailItem allocationMsgDetailItem;

            allocationMsgDetailItem = items[position];

            vh.textViewTop.Text = items[position].getItem_part_no();
            string center = items[position].getItem_ima021() + " " + items[position].getItem_qty() + " " + items[position].getItem_sfa12();
            string bottom = items[position].getItem_src_stock_no() + " " + items[position].getItem_src_locate_no();

            vh.textViewCenter.Text = center;
            vh.textViewBottom.Text = bottom;
            //holder.textViewScan.setText(items.get(position).getItem_scan_desc());

            if (allocationMsgDetailItem.isChecked())
            {
                vh.imageView.Visibility = ViewStates.Visible;
            }
            else
            {
                vh.imageView.Visibility = ViewStates.Gone;
            }

            if (allocationMsgDetailItem.isSelected())
            {
                vh.ItemView.SetBackgroundColor(Android.Graphics.Color.Rgb(0x4d, 0x90, 0xfe));
            }
            else
            {
                vh.ItemView.SetBackgroundColor(Android.Graphics.Color.Transparent);
            }
        }
        public override void OnBindViewHolder(RecyclerView.ViewHolder holder, int position)
        {
            ItemViewHolder        vh = holder as ItemViewHolder;
            ProductionStorageItem productionStorageItem;

            productionStorageItem = items[position];

            String topString    = context.GetString(Resource.String.production_storage_part_no) + " " + productionStorageItem.getPart_no();
            String centerString = context.GetString(Resource.String.production_storage_qty) + " " + productionStorageItem.getQty() + " " + productionStorageItem.getStock_unit();
            String bottomString = context.GetString(Resource.String.production_storage_locate_no_def) + " " + productionStorageItem.getLocate_no() + "     " +
                                  context.GetString(Resource.String.production_storage_locate_no) + " " + productionStorageItem.getLocate_no_scan();

            vh.textViewTop.Text    = topString;
            vh.textViewCenter.Text = centerString;
            vh.textViewBottom.Text = bottomString;

            if (productionStorageItem.isSelected())
            {
                //Log.e(TAG, ""+position+" is selected.");
                //view.setSelected(true);
                vh.ItemView.SetBackgroundColor(Android.Graphics.Color.Rgb(0x4d, 0x90, 0xfe));
            }
            else
            {
                //Log.e(TAG, ""+position+" clear.");
                //view.setSelected(false);
                vh.ItemView.SetBackgroundColor(Android.Graphics.Color.Transparent);
            }
        }
        public override RecyclerView.ViewHolder OnCreateViewHolder(ViewGroup parent, int viewType)
        {
            View           view           = LayoutInflater.From(parent.Context).Inflate(Resource.Layout.item_main, parent, false);
            ItemViewHolder itemViewHolder = new ItemViewHolder(view);

            return(itemViewHolder);
        }
Esempio n. 4
0
        public override RecyclerView.ViewHolder OnCreateViewHolder(ViewGroup parent, int viewType)
        {
            View           itemView = LayoutInflater.From(parent.Context).Inflate(Resource.Layout.items_list_item, parent, false);
            ItemViewHolder vh       = new ItemViewHolder(itemView, OnClick);

            return(vh);
        }
Esempio n. 5
0

        
Esempio n. 6
0
        public override RecyclerView.ViewHolder OnCreateViewHolder(ViewGroup parent, int viewType)
        {
            Log.Debug(TAG, "OnCreateViewHolder");
            View           view       = LayoutInflater.From(parent.Context).Inflate(layoutResourceId, parent, false);
            ItemViewHolder viewHolder = new ItemViewHolder(view);

            return(viewHolder);
        }
            public override void OnBindViewHolder(RecyclerView.ViewHolder holder, int position)
            {
                ItemViewHolder vh = holder as ItemViewHolder;

                Item item = items [position];

                vh.Name.Text = item.Name;
            }
Esempio n. 8
0
        public override void OnBindViewHolder(RecyclerView.ViewHolder holder, int position)
        {
            ItemViewHolder viewHolder = holder as ItemViewHolder;

            viewHolder.ItemTextView.Text  = _items[position].Name;
            viewHolder.PriceTextView.Text = _items[position].Price.ToString("C");
            viewHolder.SetItemClickListener(this);
        }
Esempio n. 9
0
        OnCreateViewHolder(ViewGroup parent, int viewType)
        {
            View itemView = LayoutInflater.From(parent.Context).
                            Inflate(Resource.Layout.row_item, parent, false);

            ItemViewHolder vh = new ItemViewHolder(itemView, this);

            return(vh);
        }
        public override void OnBindViewHolder(ViewHolder viewHolder, int position)
        {
            ServiceItem    item           = Items[position];
            ItemViewHolder itemViewHolder = (ItemViewHolder)viewHolder;

            itemViewHolder.CircledImageView.SetCircleColor(item.Status == ServiceStatuses.CHAIR ? color : transparent);
            itemViewHolder.ListTypeTextView.Text = item.ListTypeChar;
            itemViewHolder.DetailTextView.Text   =
                string.Format("{0}\n{1}", item.ScheduleDate.ToShortTimeString(), item.FullName);
        }
Esempio n. 11
0
        public override void OnBindViewHolder(RecyclerView.ViewHolder holder, int position)
        {
            ItemViewHolder   vh = holder as ItemViewHolder;
            SearchDetailItem searchDetailItem;

            searchDetailItem = items[position];

            vh.itemHeader.Text  = searchDetailItem.getHeader();
            vh.itemContent.Text = searchDetailItem.getContent();
        }
        public override void OnBindViewHolder(RecyclerView.ViewHolder holder, int position)
        {
            ItemViewHolder vh = holder as ItemViewHolder;
            AllocationSendMsgDetailItem allocationSendMsgDetailItem;

            allocationSendMsgDetailItem = items[position];


            vh.itemHeader.Text  = allocationSendMsgDetailItem.getHeader();
            vh.itemContent.Text = allocationSendMsgDetailItem.getContent();
        }
Esempio n. 13
0
        public override RecyclerView.ViewHolder OnCreateViewHolder(ViewGroup parent, int viewType)
        {
            View     row      = LayoutInflater.From(parent.Context).Inflate(Resource.Layout.view_row, parent, false);
            TextView txtItem  = row.FindViewById <TextView>(Resource.Id.txtItem);
            TextView txtPrice = row.FindViewById <TextView>(Resource.Id.txtPrice);

            ItemViewHolder viewHolder = new ItemViewHolder(row)
            {
                ItemTextView = txtItem, PriceTextView = txtPrice
            };

            return(viewHolder);
        }
        /// <summary>
        /// Let's create view for Item template
        /// </summary>
        /// <param name="parent"></param>
        /// <returns></returns>
        /// <remarks>
        /// We use Android's internal Android.Resource.Layout.SimpleListItem2 resource.
        /// You can change this with your custom XML Layout
        /// </remarks>
        public override RecyclerView.ViewHolder OnCreateItemViewHolder(ViewGroup parent)
        {
            View row = LayoutInflater.
                       From(parent.Context).
                       Inflate(Android.Resource.Layout.SimpleListItem2, parent, false);

            var viewHolder = new ItemViewHolder(row);

            viewHolder.txvOtherInfo.SetTextSize(Android.Util.ComplexUnitType.Sp, 10);
            viewHolder.txvOtherInfo.SetTextColor(Android.Graphics.Color.LightGray);

            return(viewHolder);
        }
Esempio n. 15
0
        private async void DisplayImage(ItemViewHolder vh, Item item)
        {
            System.Diagnostics.Debug.WriteLine("ItemAdapter.DisplayImage()");

            if (!string.IsNullOrEmpty(item.ImageFilename))
            {
                Java.IO.File imageFile = new Java.IO.File(AndroidHelper._dir, item.ImageFilename);

                // Display
                try
                {
                    await ImageService.Instance.LoadFile(imageFile.Path).DownSampleInDip(48).Transform(new CircleTransformation()).IntoAsync(vh.Image);

                    /* might be useful...
                     * ImageService.Instance.LoadUrl(urlToImage)
                     *          .Retry(3, 200)
                     *          .DownSample(300, 300)
                     *          .Transform(new CircleTransformation())
                     *          .Transform(new GrayscaleTransformation())
                     *          .LoadingPlaceholder(Config.LoadingPlaceholderPath, ImageSource.ApplicationBundle) <----
                     *          .ErrorPlaceholder(Config.ErrorPlaceholderPath, ImageSource.ApplicationBundle) <----
                     *          .Into(_imgDisplay);
                     */
                    vh.Image.Visibility = ViewStates.Visible;
                }
                catch (Exception e)
                {
                    System.Diagnostics.Debug.WriteLine(e);
                }
            }
            else
            {
                vh.Image.Visibility = ViewStates.Gone;

                if (!vh.HasAligned)
                {
                    // push quantityholder over dp width of image + marginleft + marginright
                    LinearLayout.LayoutParams iPar = (LinearLayout.LayoutParams)vh.Image.LayoutParameters;
                    int shift = iPar.LeftMargin + iPar.Width + iPar.RightMargin;

                    LinearLayout.LayoutParams qPar = (LinearLayout.LayoutParams)vh.QuantityHolder.LayoutParameters;

                    qPar.LeftMargin += shift;

                    vh.QuantityHolder.LayoutParameters = qPar;

                    vh.HasAligned = true;
                }
            }
        }
Esempio n. 16
0
        public override void OnBindViewHolder(RecyclerView.ViewHolder holder, int position)
        {
            ItemViewHolder    vh = holder as ItemViewHolder;
            AllocationMsgItem allocationMsgItem;

            allocationMsgItem = items[position];

            vh.itemTitle.Text = allocationMsgItem.getWork_order();

            if (allocationMsgItem.isSelected())
            {
                vh.ItemView.SetBackgroundColor(Android.Graphics.Color.Rgb(0x4d, 0x90, 0xfe));
            }
            else
            {
                vh.ItemView.SetBackgroundColor(Android.Graphics.Color.Transparent);
            }
        }
Esempio n. 17
0
        public override void OnBindViewHolder(RecyclerView.ViewHolder holder, int position)
        {
            ItemViewHolder vh = holder as ItemViewHolder;

            vh.Image.SetImageBitmap(items[position].itemImage);
            vh.Name.Text     = items[position].itemName;
            vh.Rating.Rating = items[position].itemRating;
            vh.Category.Text = items[position].itemCategory;
            vh.Price.Text    = items[position].itemPrice.ToString();
            if (items[position].itemStoreCount <= 0)
            {
                vh.outOfStock.Visibility = ViewStates.Visible;
            }
            else
            {
                vh.outOfStock.Visibility = ViewStates.Invisible;
            }
        }
Esempio n. 18
0
        private void FormatCell(ItemViewHolder vh, bool selected)
        {
            System.Diagnostics.Debug.WriteLine("ItemAdapter.FormatCell()");

            if (selected)
            {
                vh.SetBackgroundColor(new Color(ContextCompat.GetColor(context, Resource.Color.accent)));
                vh.Name.SetTextColor(Color.White);
                vh.DatePurchased.SetTextColor(Color.White);
                vh.Quantity.SetTextColor(Color.White);
            }
            else
            {
                vh.SetBackgroundColor(Color.White);
                vh.Name.SetTextColor(Color.Black);
                vh.DatePurchased.SetTextColor(Color.Black);
                vh.Quantity.SetTextColor(Color.Black);
            }
        }
        public override void OnBindViewHolder(RecyclerView.ViewHolder holder, int position)
        {
            base.OnBindViewHolder(holder, position);

            if (holder is ItemViewHolder)
            {
                ItemViewHolder itemViewHolder = (ItemViewHolder)holder;
                var            relatesBean    = relates[position];//.get(position);
                var            dd             = "http://d.hiphotos.baidu.com/image/pic/item/d000baa1cd11728bc4388fe7c5fcc3cec2fd2cd9.jpg";

                var requestOptions = new RequestOptions();
                requestOptions.Placeholder(Resource.Drawable.I1);
                requestOptions.CenterCrop();
                requestOptions.DontAnimate();
                requestOptions.Error(Resource.Drawable.I7);
                requestOptions.CircleCrop();

                Glide.With(holder.ItemView)
                .Load(dd)
                .Apply(requestOptions)
                .Into(itemViewHolder.mVideoPic);
                //.i
                //.with(getContext())
                //    .load(relatesBean.getPic())
                //    .centerCrop()
                //    .diskCacheStrategy(DiskCacheStrategy.ALL)
                //    .placeholder(R.drawable.bili_default_image_tv)
                //    .dontAnimate()
                //    .into(itemViewHolder.mVideoPic);

                itemViewHolder.mVideoTitle.Text   = "Test"; // relatesBean.getTitle();//.setText(relatesBean.getTitle());
                itemViewHolder.mVideoPlayNum.Text = "10";   // relatesBean.getStat().getView().ToString();//.setText(
                //NumberUtil.converString(relatesBean.getStat().getView()));
                itemViewHolder.mVideoReviewNum.Text = "0";  // relatesBean.getStat().getView().ToString();//setText(
                                                            // NumberUtil.converString(relatesBean.getStat().getDanmaku()));
                itemViewHolder.mUpName.Text = "Someone";    // relatesBean.getOwner().getName();// setText(relatesBean.getOwner().getName());
            }
        }
 public override RecyclerView.ViewHolder OnCreateViewHolder (ViewGroup parent, int viewType)
 {
     View view = LayoutInflater.From(parent.Context).Inflate(Resource.Layout.item_main, parent, false);
     ItemViewHolder itemViewHolder = new ItemViewHolder(view);
     return itemViewHolder;
 }
 public ViewOnClickListener(ItemViewHolder itemHolder, string sectionTitle)
 {
     this._itemHolder   = itemHolder;
     this._sectionTitle = sectionTitle;
 }
			public override RecyclerView.ViewHolder OnCreateViewHolder (ViewGroup parent, int viewType)
			{
				View itemView = LayoutInflater.From (parent.Context).
					Inflate (Resource.Layout.ItemView, parent, false);

				ItemViewHolder vh = new ItemViewHolder (itemView); //, OnClick); 
				return vh;
			}
Esempio n. 26
0
        OnBindViewHolder(RecyclerView.ViewHolder holder, int position)
        {
            System.Diagnostics.Debug.WriteLine("ItemAdapter.OnBindViewHolder()");

            Item item = items[position];

            ItemViewHolder vh = holder as ItemViewHolder;

            vh.Name.Text = item.Name;

            if (item.DatePurchased.Year > 1)
            {
                vh.DatePurchased.Text = string.Format("Purchased on " + item.DatePurchased.ToShortDateString());
            }
            else
            {
                vh.DatePurchased.Visibility = ViewStates.Gone;
            }

            /*
             * if ((fragment != null && !InventoryFragment.IsEditing) || fragment == null)
             * {
             *  selectedPositions.Clear();
             *  selectedItems.Clear();
             *
             *  DisplayImage(vh, item);
             *  FormatCell(vh, false);
             *
             *  vh.QuantityUp.Alpha = 1;
             *  vh.QuantityDown.Alpha = 1;
             *
             *  if (item.Quantity > -1)
             *  {
             *      vh.QuantityHolder.Visibility = ViewStates.Visible;
             *      vh.QuantityHolder.Alpha = 1;
             *
             *      // Prevents clicks being fired multiple times following
             *      // a notifydatasetchanged(), etc.
             *      if (!vh.HasClickEvent)
             *      {
             *          vh.QuantityUp.Click += (o, e) =>
             *          {
             *              item.Quantity++;
             *              vh.Quantity.Text = item.Quantity.ToString();
             *
             *              SaveItemAndUpdateShoppingList(item);
             *          };
             *
             *          vh.QuantityDown.Click += (o, e) =>
             *          {
             *              if (item.Quantity > 0)
             *              {
             *                  item.Quantity--;
             *                  vh.Quantity.Text = item.Quantity.ToString();
             *
             *                  SaveItemAndUpdateShoppingList(item);
             *              }
             *          };
             *
             *          vh.HasClickEvent = true;
             *      }
             *
             *      vh.Quantity.Text = item.Quantity.ToString();
             *  }
             *  else
             *  {
             *      vh.QuantityHolder.Visibility = ViewStates.Gone;
             *  }
             * }
             * else if (fragment != null && InventoryFragment.IsEditing)
             * {
             *  if (item.Quantity > -1)
             *  {
             *      vh.QuantityUp.Alpha = 0;
             *      vh.QuantityDown.Alpha = 0;
             *  }
             *  else
             *  {
             *      vh.QuantityHolder.Visibility = ViewStates.Gone;
             *  }
             *
             *  if (selectedPositions.Contains(position))
             *  {
             *      FormatCell(vh, true);
             *  }
             *  else
             *  {
             *      FormatCell(vh, false);
             *  }
             * }
             */
        }
Esempio n. 27
0
        public override void OnBindViewHolder(RecyclerView.ViewHolder holder, int position)
        {
            current_BindViewHolder = position;

            ItemViewHolder        vh = holder as ItemViewHolder;
            AllocationSendMsgItem allocationSendMsgItem;

            allocationSendMsgItem = items[position];

            Log.Debug(TAG, "OnBindViewHolder = " + position + ", allocationSendMsgItem.getIndex() = " + allocationSendMsgItem.getIndex());
            is_Bind = true;

            vh.index             = allocationSendMsgItem.getIndex();
            vh.itemHeader.Text   = allocationSendMsgItem.getHeader();
            vh.itemContent.Text  = allocationSendMsgItem.getContent();
            vh.itemEditText.Text = allocationSendMsgItem.getContent();

            allocationSendMsgItem.setTextView(vh.itemContent);
            allocationSendMsgItem.setEditText(vh.itemEditText);
            allocationSendMsgItem.setSpinner(vh.itemSpinner);



            vh.ItemView.SetBackgroundColor(Android.Graphics.Color.Transparent);

            if (allocationSendMsgItem.getHeader().Equals(context.GetString(Resource.String.allocation_send_message_to_material_work_order)) ||
                allocationSendMsgItem.getHeader().Equals(context.GetString(Resource.String.allocation_send_message_to_material_staging_area)) ||
                allocationSendMsgItem.getHeader().Equals(context.GetString(Resource.String.allocation_send_message_to_material_rate)))
            {
                vh.itemEditText.Visibility = ViewStates.Visible;
                vh.itemContent.Visibility  = ViewStates.Gone;
                vh.itemSpinner.Visibility  = ViewStates.Gone;

                vh.itemEditText.SetTag(Resource.Id.itemContentEditText, position);
                if (vh.allocationSendTextWatcher != null)
                {
                    vh.itemEditText.RemoveTextChangedListener(vh.allocationSendTextWatcher);
                }
                vh.allocationSendTextWatcher = new AllocationSendTextWatcher(vh.itemEditText, context, items, position, allocationSendMsgItem.getIndex());
                vh.itemEditText.AddTextChangedListener(vh.allocationSendTextWatcher);
            }
            else if (allocationSendMsgItem.getHeader().Equals(context.GetString(Resource.String.allocation_send_message_to_material_stock_locate)) ||
                     allocationSendMsgItem.getHeader().Equals(context.GetString(Resource.String.allocation_send_message_to_material_date_year_month_day)) ||
                     allocationSendMsgItem.getHeader().Equals(context.GetString(Resource.String.allocation_send_message_to_material_date_hour)) ||
                     allocationSendMsgItem.getHeader().Equals(context.GetString(Resource.String.allocation_send_message_to_material_date_minute))
                     )

            {
                vh.itemSpinner.SetTag(Resource.Id.itemContentSpinner, position);
                vh.itemSpinner.Visibility  = ViewStates.Visible;
                vh.itemContent.Visibility  = ViewStates.Gone;
                vh.itemEditText.Visibility = ViewStates.Gone;

                if (allocationSendMsgItem.getHeader().Equals(context.GetString(Resource.String.allocation_send_message_to_material_date_year_month_day)))
                {
                    vh.itemSpinner.Adapter = AllocationSendMsgToReserveWarehouseFragment.dateAdapter;
                }
                else if (allocationSendMsgItem.getHeader().Equals(context.GetString(Resource.String.allocation_send_message_to_material_date_hour)))
                {
                    vh.itemSpinner.Adapter = AllocationSendMsgToReserveWarehouseFragment.hourAdapter;
                }
                else if (allocationSendMsgItem.getHeader().Equals(context.GetString(Resource.String.allocation_send_message_to_material_date_minute)))
                {
                    vh.itemSpinner.Adapter = AllocationSendMsgToReserveWarehouseFragment.minAdapter;
                    //holder.itemSpinner.setSelection(minutes);
                }
                else if (allocationSendMsgItem.getHeader().Equals(context.GetString(Resource.String.allocation_send_message_to_material_stock_locate)))
                {
                    vh.itemSpinner.Adapter = AllocationSendMsgToReserveWarehouseFragment.locateAdapter;
                    //holder.itemSpinner.setSelection(minutes);
                }
            }
            else if (allocationSendMsgItem.getHeader().Equals(context.GetString(Resource.String.allocation_send_message_to_material_predict_production_quantity)) ||
                     allocationSendMsgItem.getHeader().Equals(context.GetString(Resource.String.allocation_send_message_to_material_real_production_quantity)))
            {
                //view.setBackgroundColor(Color.rgb(0xff, 0xd6, 0x00));
                vh.itemContent.Visibility  = ViewStates.Visible;
                vh.itemEditText.Visibility = ViewStates.Gone;
                vh.itemSpinner.Visibility  = ViewStates.Gone;

                vh.ItemView.SetBackgroundColor(Android.Graphics.Color.Rgb(0xff, 0xd6, 0x00));
            }
            else
            {
                vh.itemContent.Visibility  = ViewStates.Visible;
                vh.itemEditText.Visibility = ViewStates.Gone;
                vh.itemSpinner.Visibility  = ViewStates.Gone;
            }

            //Log.Debug(TAG, "==== spinner start ====");

            for (int i = 0; i < vh.itemSpinner.Count; i++)
            {
                //Log.Debug(TAG, "content = " + allocationSendMsgItem.getContent() + " possition = " + vh.itemSpinner.GetItemAtPosition(i).ToString());
                if (allocationSendMsgItem.getContent().Equals(vh.itemSpinner.GetItemAtPosition(i).ToString()))
                {
                    vh.itemSpinner.SetSelection(i);
                    break;
                }
            }
            //Log.Debug(TAG, "==== spinner end ====");
        }
Esempio n. 28
0
 public override RecyclerView.ViewHolder OnCreateViewHolder(ViewGroup parent, int viewType)
 {
     return(ItemViewHolder.Create(parent));
 }
Esempio n. 29
0
        public override void OnBindViewHolder(RecyclerView.ViewHolder holder, int position)
        {
            ItemViewHolder          vh = holder as ItemViewHolder;
            AllocationMsgStatusItem allocationMsgStatusItem;

            allocationMsgStatusItem = items[position];

            vh.textViewIndex.Text  = (position + 1).ToString();
            vh.textViewTop.Text    = items[position].getItem_SFA03();
            vh.textViewCenter.Text = items[position].getItem_IMA021();

            Log.Debug(TAG, "getItem_IMG10 = " + items[position].getItem_IMG10());
            float aw1_float;

            if (items[position].getItem_IMG10() != null && items[position].getItem_IMG10().Length > 0)
            {
                aw1_float = float.Parse(items[position].getItem_IMG10());
            }
            else
            {
                aw1_float = 0;
            }
            int aw1 = (int)aw1_float;
            int aw2;

            if (items[position].getItem_MOVED_QTY() != null && items[position].getItem_MOVED_QTY().Length > 0)
            {
                aw2 = int.Parse(items[position].getItem_MOVED_QTY());
            }
            else
            {
                aw2 = 0;
            }
            int aw3;

            if (items[position].getItem_SFA05() != null && items[position].getItem_SFA05().Length > 0)
            {
                aw3 = int.Parse(items[position].getItem_SFA05());
            }
            else
            {
                aw3 = 0;
            }
            int aw4;

            if (items[position].getItem_TC_OBF013() != null && items[position].getItem_TC_OBF013().Length > 0 &&
                !items[position].getItem_TC_OBF013().Equals("N"))
            {
                Log.Debug(TAG, "getItem_TC_OBF013() = " + items[position].getItem_TC_OBF013());
                aw4 = int.Parse(items[position].getItem_TC_OBF013());
            }
            else
            {
                aw4 = 0;
            }
            float aw5_float;

            if (items[position].getItem_MESS_QTY() != null && items[position].getItem_MESS_QTY().Length > 0)
            {
                aw5_float = float.Parse(items[position].getItem_MESS_QTY());
            }
            else
            {
                aw5_float = 0;
            }

            int aw5 = (int)aw5_float;

            if (aw1 > (aw3 - aw2 - aw5))
            {
                aw1 = aw3 - aw2 - aw5;
                aw1 = aw1 < 0 ? 0 : aw1;
            }

            aw1 = aw1 > aw4 ? aw4 : aw1;
            string temp = context.GetString(Resource.String.allocation_send_message_to_material_status_detail_IMG10) + " " + aw1.ToString();

            vh.textViewBottom.Text = temp;

            if (allocationMsgStatusItem.isSelected())
            {
                vh.ItemView.SetBackgroundColor(Android.Graphics.Color.Rgb(0x4d, 0x90, 0xfe));
            }
            else
            {
                vh.ItemView.SetBackgroundColor(Android.Graphics.Color.Transparent);
            }
        }