Changeset 643
- Timestamp:
- 12/18/13 15:01:19 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/expeditee/items/Picture.java
r610 r643 67 67 68 68 private Point _end = new Point(0, 0); 69 70 private boolean _flipX = false; 71 private boolean _flipY = false; 69 72 70 73 private boolean _showCropping = false; … … 152 155 } catch (Exception e) { 153 156 } 157 158 if(size.toLowerCase().contains("flipx")) { 159 _flipX = true; 160 } 161 162 if(size.toLowerCase().contains("flipy")) { 163 _flipY = true; 164 } 154 165 155 166 try { … … 357 368 } 358 369 359 g.drawImage(_image, x, y, endX, endY, cropStartX, cropStartY, cropEndX, cropEndY, _imageObserver); 370 System.out.println(_flipX + " " + _flipY); 371 372 int sx = _flipX ? cropEndX : cropStartX; 373 int ex = _flipX ? cropStartX : cropEndX; 374 int sy = _flipY ? cropEndY : cropStartY; 375 int ey = _flipY ? cropStartY : cropEndY; 376 g.drawImage(_image, x, y, endX, endY, sx, sy, ex, ey, _imageObserver); 360 377 361 378 cropStartY = 0; … … 700 717 newText.append(" ").append(_end.x).append(" ").append(_end.y); 701 718 } 719 720 if(_flipX) { 721 newText.append(" flipX"); 722 } 723 if(_flipY) { 724 newText.append(" flipY"); 725 } 702 726 703 727 _source.setText(newText.toString()); … … 736 760 super.scale(scale, originX, originY); 737 761 } 762 763 public void setFlipX(boolean flip) { 764 _flipX = flip; 765 } 766 767 public void setFlipY(boolean flip) { 768 _flipY = flip; 769 } 770 771 public boolean getFlipX() { 772 return _flipX; 773 } 774 775 public boolean getFlipY() { 776 return _flipY; 777 } 738 778 739 779 }
Note:
See TracChangeset
for help on using the changeset viewer.