• Post Reply Bookmark Topic Watch Topic
  • New Topic

Loop with an arraylist  RSS feed

 
bobby town
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have created a method Rectangle and added a loop in my class Resizer (MouseAdapter) but impossible to resize the rectangles of the arraylist independantly !



 
Stuart A. Burkett
Ranch Hand
Posts: 679
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Why have you got two for loops that only loop once ?
The code in both loops appears to be identical, so just use

or if you want to resize all the rectangles in the list

Have you debugged your code to see if the resizing code is actually being called ?
 
bobby town
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I want to resize one rectangle and the other after independantly.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!