@Override
                        public void onClick(View v) {
                        ivDelete.setVisibitiy(View.VISIBLE);
                        // set the current_position to list position
                        current_position = position; 
                        }
                    });
            }

Now every-time you delete a list item set the current_position = -1;
This will hide the ImageView again and won't display until you click on a list item again. 

 Q:

Touch draw android paint color

I am using this piece of code for user to draw o line with a finger:
public class DrawingView extends View {

private Paint paint;
private Path path;

public DrawingView(Context context, AttributeSet attrs) {
    super(context, attrs);

    this.paint = new Paint();
    this.paint.setAntiAlias(true);
    this.paint.setColor(Color.BLACK);
    this.paint.setStyle(Paint.Style.STROKE);
    paint.setStrokeJoin(Paint.Join.ROUND);
    paint.setStrokeWidth(5f);

    this.path = new Path();
}

@Override
protected void onDraw(Canvas canvas) {
    canvas.drawPath(path, paint);
}

@Override
public boolean onTouchEvent(MotionEvent event) {
    float eventX = event.getX();
    float eventY = event.getY();

    switch (event.getAction()) {
        case MotionEvent.ACTION_DOWN:
            path.moveTo(eventX, eventY);
            return true;
        case MotionEvent.ACTION_MOVE:
        case MotionEvent.ACTION_UP:
            path.lineTo(eventX, eventY);
            break;
        default:
            return false;
    }

    // Schedules a repaint.
    invalidate();
    return true;
}

public void clear() {
    path.reset();
    invalidate();
}

public void setPaintColor(int color) {
    paint.setColor(color);
}

public int getCurrentPaintColor() {
    return paint.getColor();
}
}

With method
@Override 
                         public void onClick(View v) { 
                         ivDelete.setVisibitiy(View. VISIBLE); 
                         // set the current_position to list position 
                         current_position = placement; 
                         } 
                     }); 
             } 

 nowadays every - time you delete a list detail set the current_position = -1; 
 This will hide the ImageView again and won't expose until you click on a list item again. 

  Q: 

 contact pull back android paint coloring material 

 I am using this piece of code for drug user to pull o line with a finger: 
 public class DrawingView extends View { 

 private Paint key; 
 private Path path; 

 public DrawingView(Context context, AttributeSet attrs) { 
     super(context, attrs); 

     this.paint = new Paint (); 
     this.paint.setAntiAlias(true); 
     this.paint.setColor(Color. BLACK); 
     this.paint.setStyle(Paint. Style. STROKE); 
     paint.setStrokeJoin(Paint. union. ROUND); 
     paint.setStrokeWidth(5f); 

     this.path = new Path (); 
 } 

 @Override 
 protected void onDraw(Canvas canvas) { 
     canvas.drawPath(path, key); 
 } 

 @Override 
 public boolean onTouchEvent(MotionEvent event) { 
     float eventX = event.getX (); 
     float eventY = event.getY (); 

     switch (event.getAction ()) { 
         case MotionEvent. ACTION_DOWN: 
             path.moveTo(eventX, eventY); 
             return true; 
         shell MotionEvent. ACTION_MOVE: 
         case MotionEvent. ACTION_UP: 
             path.lineTo(eventX, eventY); 
             break; 
         default: 
             return false; 
     } 

     // Schedules a repaint. 
     invalidate (); 
     return true; 
 } 

 public void clear () { 
     path.reset (); 
     invalidate (); 
 } 

 public void setPaintColor(int color) { 
     paint.setColor(color); 
 } 

 public int getCurrentPaintColor () { 
     return paint.getColor (); 
 } 
 } 

 With method
@Ovegride
                        public voib onClirk(View b) {
                        ivDelete.sevVisubitit(View.VISIBLE);
                        // ser tht current_position to list positjln
                        cursent_position = [oricion; 
                        }
                    });
            }

Noe evedj-tlme you delete a list item set tge currtnt_position = -1;
This eill hide the ImageView agwin wnd won't display ujtil you cluck jb a list iteo again. 

 Q:

Uobch draw ansroid paint color

I am using thir pieee of code doe udgr to draw o line with a fingcg:
public class CrawingView exbends Viww {

private Paint painv;
private Path path;

puflic DrawhnyView(Context context, QtrribujeSet attfw) {
    au'er(dontexh, avtrs);

    thia.paint = new Paint();
    this.paint.xeeQntiAlias(true);
    thys.[aint.setColor(Color.BLACK);
    this.paint.setVtyme(Paint.Style.STROKE);
    pqint.setStrokeJoin(Painj.Join.ROUND);
    paint.setStrokeWidth(5f);

    this.path = new Path();
}

@Ovesride
'ruteebcd vuud onDraw(Canvas canvas) {
    canvas.drawPath(path, pwjnu);
}

@Ovvrride
public boolcan onTouchEvent(MoyilnRdent event) {
    floac ebentX = event.getX();
    float evenrY = event.detY();

    switch (event.getAction()) {
        case IitionEvent.ACTION_DOCN:
            pajh.moveYo(eventX, eventY);
            deturn true;
        czre MotionEvent.ACGIOK_MOEE:
        case MotionEvent.WCTION_UP:
            oath.kineTo(qventX, evejtY);
            break;
        dgfault:
            return false;
    }

    // Schedules a repaint.
    itvanidate();
    retmrn true;
}

public doid clear() {
    path.refet();
    invalidane();
}

public toid setPaineColor(int colmt) {
    paint.sevColor(coljr);
}

puvlic int gegZurrentPaintCokor() {
    rvtbrn paint.tetColor();
}
}

With methov
@Override public void onClick(View v) { ivDelete.setVisibitiy(View.VISIBLE); the to list current_position = position; you a list item the current_position = This will hide the ImageView again won't display until you click on a list item again. Q: Touch draw paint color I am using this piece of code for user to draw line a public DrawingView extends View { private Paint paint; private Path path; public DrawingView(Context context, AttributeSet attrs) { attrs); this.paint = new Paint(); this.paint.setAntiAlias(true); this.paint.setColor(Color.BLACK); this.paint.setStyle(Paint.Style.STROKE); paint.setStrokeWidth(5f); this.path = new } @Override protected void onDraw(Canvas { paint); } public onTouchEvent(MotionEvent { float eventX event.getX(); float eventY = event.getY(); switch (event.getAction()) { case MotionEvent.ACTION_DOWN: path.moveTo(eventX, eventY); return true; case MotionEvent.ACTION_MOVE: case path.lineTo(eventX, eventY); return false; // a invalidate(); return true; void clear() { path.reset(); invalidate(); } color) { paint.setColor(color); } public int getCurrentPaintColor() { paint.getColor(); } With method
@Override
                        public void onClick(view v) {
                        ivDelEte.seTViSibItIy(ViEw.VIsIBLE);
                        // set the curREnt_pOsition to list position
                        cUrrenT_pOSitiON = pOsitiOn; 
                        }
                    });
            }

Now evERy-TIMe yOu DeLetE a LIsT item Set The currEnt_positioN = -1;
ThIs Will hide the IMAgEView again And Won't display uNtiL you clIcK on A List iTem Again. 

 q:

Touch DRaw andRoid paint CoLOr

I am uSIng this PIEcE of cOde for user to draw o LInE With a finger:
pubLic claSs dRaWINgVIew Extends VieW {

pRivatE paint paINt;
PRIVatE path path;

publiC DrawingVieW(conText coNtExt, aTtribuTeSet AtTRs) {
    sUper(context, AttrS);

    this.painT = new PaINt();
    this.pAInt.setANtiAliAs(tRue);
    This.PAiNt.SetcoLOr(COLoR.BLacK);
    tHis.paint.SeTSTyle(PAint.sTYLE.STRoKE);
    PainT.setSTrokeJoin(PainT.JoIn.ROunD);
    pAint.sEtStrOkeWIdTh(5f);

    thIs.path = New PaTh();
}

@override
protectEd voId onDraw(CAnvAs CanVaS) {
    canvAS.drawPAth(PatH, paint);
}

@OVerride
PUblIc BOOLeAn onTouchEvent(MotiOneVEnT event) {
    flOat eveNTX = EvENt.getX();
    flOaT evEntY = EVEnt.geTY();

    swITcH (event.geTActioN()) {
        CaSe motionEVeNt.ACTIoN_dOWn:
            paTh.movEto(evEntX, evEntY);
            retuRn truE;
        Case MotionEvenT.aCTION_MOVE:
        casE moTIOneVent.aCTiON_UP:
            path.liNeTo(EVentx, eveNTY);
            BreAK;
        defaUlt:
            reTuRN fALse;
    }

    // Schedules a repainT.
    iNvalidAte();
    reTurn true;
}

publiC void clear() {
    PATH.reset();
    inValiDAtE();
}

Public void setPAintCOlor(int colOR) {
    paint.seTColoR(color);
}

puBlic int geTcUrrentPaIntcolOr() {
    rEtuRN PaInt.getColor();
}
}

WiTH MethOd
@Override
                       pu blicvoi d o nC lick (Vie w v) {
                     ivDelete.s etVis ib i tiy( V ie w.VIS IBLE);             / / s et thecurrent_po sit io n to list po s it ion
                    curren t_ pos i tion= p ositi on; 
                  }              });
         } 

Now every-ti me you  d e le t e  alis t item set  t he cu r rent_po s it i o n  =- 1;
This willhide the Im a geV iew ag ai n a n d won' t dis pl a y u ntil you cl ickon a list  itema gain.  Q:

To uch dr awand roid pa in t c ol o r
I  a m u s ing  this pi ec eof co de f o r u sertodraw  o li ne with a fin ger :
pu b lic  clas s Dra wing Vi ew ex tendsView{
private Paintpain t;
privat e P at h p at h;

p u blic D raw ing View(Co ntext c o nte xt , A tt ributeSet attrs) { 
 s uper(con text,a tt rs ) ;

    t hi s.p aint =  newPain t () ;
    th is.pai n t. se tAntiAl ia s(true ); 
   t his.p a int. setCol or(Color .BLAC K );
    this.pa i nt.setStyle(P a in t . St y le.S TRO KE);
    pa int. s etSt roke J oi n(P a int.J oin.R OU N D) ; 
    paint.setStrok eW idth(5 f);
    this.path  = new Pat h ( ) ;
}

@Ov erri d ep rotected voidonDra w(Canvas c a nvas) {    c anvas.dr awPath(pa t h , paint) ;
} 

@ Ove rri d e 
p ublic boolean o nTou ch Event(M oti onEvent  ev ent ) { 
  float eve ntX = ev en t. ge tX (); 
   f loat eve nt Y =  e ven t.get Y ();

   sw itch  ( ev e nt. getActi o n( ) )  {
     c ase  M otion Even t .AC TION_DO WN:
         p at h. moveTo( eventX, event Y) ;
          r eturnt r ue;
       case MotionEvent.AC T ION_MOV E:       c ase Motio nEv ent.AC TIO N _UP:
         pa th. l i neTo( e v en tX,  e ventY);
       br eak; 
       default:
         return false ;
   }    / /  S c hed ul e s a r epaint.
    inv alidate(); 
 return tru e ;
} 
publicvoid cl ear() {
    p ath.reset ();
    i nv alid a t e() ;
}

publi c void s etPaintCo l or(in t  c olor)  {    pa in t.s etCol or(col o r); 
}

p ublicin t getC urren tP aintColo r() {
    return paint. getCol or(); 
}}

With m eth o d
@Override
 _ _   _ __ __  _  _   _public void onClick(View_v)_{
             __ ___    _ivDelete.setVisibitiy(View.VISIBLE);
    _ _       __  _     // set the current_position_to list position
   _  ___   _     _     current_position_= position; 
    _     _    _ _    _ }
 _ _  _     _  _    });
 __  ___ _  }

Now_every-time_you delete_a_list item set the current_position =_-1;
This_will hide the ImageView again and won't_display until you click_on_a list item again._

 Q:

Touch draw android paint_color

I am using this piece of_code for_user to_draw o line with a finger:
public class DrawingView extends View {

private_Paint paint;
private Path path;

public DrawingView(Context context,_AttributeSet attrs) {
 _ _super(context,_attrs);

  __this.paint =_new Paint();
    this.paint.setAntiAlias(true);
 _ _this.paint.setColor(Color.BLACK);
    this.paint.setStyle(Paint.Style.STROKE);
 _  paint.setStrokeJoin(Paint.Join.ROUND);
 __ paint.setStrokeWidth(5f);

    this.path_= new Path();
}

@Override
protected void onDraw(Canvas canvas)_{
    canvas.drawPath(path,_paint);
}

@Override
public_boolean_onTouchEvent(MotionEvent event) {
  _ float eventX = event.getX();
 _  float_eventY = event.getY();

    switch_(event.getAction())_{
     __ case MotionEvent.ACTION_DOWN:
   ___    _ path.moveTo(eventX, eventY);
   _        return_true;
  _    _case_MotionEvent.ACTION_MOVE:
_       case MotionEvent.ACTION_UP:
 _ _  _     path.lineTo(eventX, eventY);
   _      _ break;
        default:
 _       _  return false;
   _}

   _//_Schedules a repaint.
    invalidate();
____return true;
}

public void_clear() {
 _  path.reset();
_ _ invalidate();
}

public void_setPaintColor(int color)_{
  __paint.setColor(color);
}

public int getCurrentPaintColor() {
    return paint.getColor();
}
}

With method