1 package com.lamatek.tags.google; 2 3 import javax.servlet.jsp.tagext.Tag ; 4 import javax.servlet.jsp.tagext.TagSupport ; 5 6 15 public class GoogleMapOverviewTag extends TagSupport { 16 17 int width = 200; 18 int height = 200; 19 int x = 0; 20 int y = 0; 21 boolean placed = false; 22 26 public int doStartTag() { 27 Tag tag = this; 28 while (tag.getParent() != null) { 29 if (tag.getParent() instanceof GoogleMapTag) { 30 ((GoogleMapTag) tag.getParent()).setOverviewControl(this); 31 return EVAL_PAGE; 32 } 33 tag = tag.getParent(); 34 } 35 return EVAL_PAGE; 36 } 37 42 public int getHeight() { 43 return height; 44 } 45 50 public void setHeight(int height) { 51 this.height = height; 52 } 53 58 public int getWidth() { 59 return width; 60 } 61 66 public void setWidth(int width) { 67 this.width = width; 68 } 69 74 public int getX() { 75 return x; 76 } 77 82 public void setX(int x) { 83 this.x = x; 84 placed = true; 85 } 86 91 public int getY() { 92 return y; 93 } 94 99 public void setY(int y) { 100 this.y = y; 101 placed = true; 102 } 103 109 public boolean wasPlaced() { 110 return placed; 111 } 112 } 113 | Popular Tags |