Changeset 80 for trunk/src/org/expeditee/gui/FrameGraphics.java
- Timestamp:
- 05/30/08 10:14:43 (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/expeditee/gui/FrameGraphics.java
r78 r80 16 16 import java.util.Collection; 17 17 import java.util.HashSet; 18 import java.util.Iterator; 18 19 import java.util.LinkedList; 19 20 import java.util.List; … … 73 74 74 75 // The link to the message frameset 75 public static Item MessageLink = new Text(-2, MESSAGES_FRAMESET_NAME);76 public static Item MessageLink = new Text(-2, "@" + MESSAGES_FRAMESET_NAME); 76 77 77 78 // creator for creating the message frames … … 98 99 FrameUtils.Parse(current); 99 100 DisplayIO.UpdateTitle(); 101 setMaxSize(new Dimension(_MaxSize.width, _MessageBuffer.getHeight() 102 + _MaxSize.height)); 100 103 Repaint(); 101 104 } … … 112 115 113 116 FrameUtils.Parse(DisplayIO.getCurrentFrame()); 117 DisplayIO.UpdateTitle(); 114 118 Repaint(); 115 119 } … … 133 137 _MaxSize = max; 134 138 135 // Mike assumes this is the height of the Message window? 136 _MaxSize.setSize(max.width, max.height - MESSAGE_BUFFER_HEIGHT); 139 // Hide the message buffer if in audience mode 140 int newMaxHeight = max.height 141 - (isAudienceMode() ? 0 : MESSAGE_BUFFER_HEIGHT); 142 if (newMaxHeight > 0) 143 _MaxSize.setSize(max.width, newMaxHeight); 144 137 145 if (DisplayIO.getCurrentFrame() != null) { 138 146 DisplayIO.getCurrentFrame().setBuffer(null); … … 140 148 } 141 149 142 _MessageBuffer = null; 143 144 for (int i = 0; i < Messages.length; i++) { 145 if (Messages[i] != null) { 146 Messages[i].setOffset(0, -_MaxSize.height); 147 Messages[i].setMaxSize(_MaxSize); 148 } 149 } 150 151 MessageLink.setOffset(0, -_MaxSize.height); 152 MessageLink.setMaxSize(_MaxSize); 153 MessageLink.setPosition(_MaxSize.width - MESSAGE_LINK_Y_OFFSET, 154 MESSAGE_LINK_X); 155 150 if (newMaxHeight > 0) { 151 _MessageBuffer = null; 152 153 for (int i = 0; i < Messages.length; i++) { 154 if (Messages[i] != null) { 155 Messages[i].setOffset(0, -_MaxSize.height); 156 Messages[i].setMaxSize(_MaxSize); 157 } 158 } 159 160 MessageLink.setOffset(0, -_MaxSize.height); 161 MessageLink.setMaxSize(_MaxSize); 162 MessageLink.setPosition(_MaxSize.width - MESSAGE_LINK_Y_OFFSET, 163 MESSAGE_LINK_X); 164 } 156 165 // Repaint(); 157 166 } … … 254 263 List<Item> copies = ItemUtils.CopyItems(vector.getItems()); 255 264 // FrameMouseActions 256 for (Item i : copies) { 265 Iterator<Item> iterator = copies.iterator(); 266 while(iterator.hasNext()){ 267 Item i = iterator.next(); 268 //Dont paint annotation items for @v 269 if (i.isAnnotation()){ 270 iterator.remove(); 271 continue; 272 } 273 i.setLinkMark(false); 274 i.setActionMark(false); 257 275 if (!(i instanceof Line)) { 258 276 i.setPosition((int) (i.getX() * scale + dx + 0.5), (int) (i … … 260 278 * scale + dy + 0.5)); 261 279 i.setThickness((int) (i.getThickness() * scale + 0.5)); 280 i.setArrowheadLength((int) (i.getArrowheadLength() * scale + 0.5)); 262 281 } 263 282 if (i instanceof Text) … … 419 438 420 439 if (isActualFrame) { 421 PaintItem(bg, toPaint.get FrameNameItem());440 PaintItem(bg, toPaint.getNameItem()); 422 441 } 423 442 … … 476 495 _MessageBuffer = ge.getDefaultScreenDevice() 477 496 .getDefaultConfiguration().createCompatibleVolatileImage( 478 _MaxSize.width, MESSAGE_BUFFER_HEIGHT); 497 _MaxSize.width, 498 (isAudienceMode() ? 0 : MESSAGE_BUFFER_HEIGHT)); 479 499 } 480 500 … … 507 527 g.drawImage(right, 0, 0, Item.DEFAULT_BACKGROUND, null); 508 528 } 509 // draw the message area 510 g.drawImage(_MessageBuffer, 0, _MaxSize.height, null); 529 // Dont display the message area in audience mode 530 if (!isAudienceMode()) { 531 // draw the message area 532 g.drawImage(_MessageBuffer, 0, _MaxSize.height, null); 533 } 511 534 g.dispose(); 512 535 … … 749 772 MessageLink.setLink(_creator.getCurrent()); 750 773 Repaint(); 774 775 System.out.println(message); 751 776 } 752 777
Note:
See TracChangeset
for help on using the changeset viewer.