Project

General

Profile

« Previous | Next » 

Revision adc117e0

Added by Leszek Koltunski about 8 years ago

Effects3D: improvements

View differences:

src/main/java/org/distorted/examples/effects3d/Effects3DActivity.java
540 540

  
541 541
  public void remove(View v)
542 542
    {
543
    //android.util.Log.e("effects3D", "removing!");
544

  
545
    int numEffects = mEffects.size();
546
    Effects3DEffect effect;
547

  
548
    for(int i=0; i<numEffects; i++)
543
    for(Effects3DEffect effect: mEffects)
549 544
      {
550
      effect = mEffects.get(i);
551

  
552 545
      if( effect.thisView(v) )
553 546
        {
554
        android.util.Log.e("effects3D", "effect: "+i);
555

  
556 547
        LinearLayout layout = (LinearLayout)findViewById(R.id.effects3dlayout);
557 548
        View view;
558 549

  
......
565 556

  
566 557
        long id = effect.getId();
567 558
        mObject.abortEffect(id);
568
        mEffects.remove(i);
559
        mEffects.remove(effect);
560

  
561
        resetData();
569 562

  
570 563
        break;
571 564
        }

Also available in: Unified diff