Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- private static final int LEFT_OFFSET = 30;
- private static final int TOP_OFFSET = 30;
- private static final int IMAGE_SIZE = 90;
- private GImage b1 = new GImage("1.jpg");
- private GImage b2 = new GImage("2.jpg");
- private GImage b3 = new GImage("3.jpg");
- private GImage b4 = new GImage("4.jpg");
- private GImage b5 = new GImage("5.jpg");
- private GImage b6 = new GImage("6.jpg");
- private GImage b7 = new GImage("7.jpg");
- private GImage b8 = new GImage("8.jpg");
- private GImage b9 = new GImage("9.jpg");
- private GImage b10 = new GImage("10.jpg");
- private GImage b11 = new GImage("11.jpg");
- private GImage b12 = new GImage("12.jpg");
- private void setBricks() {
- b1.setLocation(LEFT_OFFSET, TOP_OFFSET);
- b2.setLocation(LEFT_OFFSET + IMAGE_SIZE + BRICK_SEP, TOP_OFFSET);
- b3.setLocation(LEFT_OFFSET + 2 * (IMAGE_SIZE + BRICK_SEP), TOP_OFFSET);
- b4.setLocation(LEFT_OFFSET + 3 * (IMAGE_SIZE + BRICK_SEP), TOP_OFFSET);
- b5.setLocation(LEFT_OFFSET, TOP_OFFSET + b4.getHeight() + BRICK_SEP);
- b6.setLocation(LEFT_OFFSET + IMAGE_SIZE + BRICK_SEP, TOP_OFFSET + b4.getHeight() + BRICK_SEP);
- b7.setLocation(LEFT_OFFSET + 2 * (IMAGE_SIZE + BRICK_SEP), TOP_OFFSET + b4.getHeight() + BRICK_SEP);
- b8.setLocation(LEFT_OFFSET + 3 * (IMAGE_SIZE + BRICK_SEP), TOP_OFFSET + b4.getHeight() + BRICK_SEP);
- b9 .setLocation(LEFT_OFFSET, TOP_OFFSET + 2 * (b4.getHeight() + BRICK_SEP));
- b10.setLocation(LEFT_OFFSET + IMAGE_SIZE + BRICK_SEP, TOP_OFFSET + 2 * (b8.getHeight() + BRICK_SEP));
- b11.setLocation(LEFT_OFFSET + 2 * (IMAGE_SIZE + BRICK_SEP), TOP_OFFSET + 2 * (b8.getHeight() + BRICK_SEP));
- b12.setLocation(LEFT_OFFSET + 3 * (IMAGE_SIZE + BRICK_SEP), TOP_OFFSET + 2 * (b8.getHeight() + BRICK_SEP));
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement