/* */ package quicktime.app.display;
/* */
/* */ import java.awt.event.MouseEvent;
/* */ import quicktime.QTException;
/* */ import quicktime.QTRuntimeException;
/* */ import quicktime.QTSession;
/* */ import quicktime.app.actions.MouseController;
/* */ import quicktime.app.actions.MouseResponder;
/* */ import quicktime.app.spaces.Space;
/* */ import quicktime.qd.Region;
/* */
/* */ /** @deprecated */
/* */ public class GroupController extends MouseController
/* */ {
/* */ private GroupDrawable group;
/* */ private QTDrawable current;
/* 54 */ private boolean isActive = false;
/* */
/* */ /** @deprecated */
/* */ public GroupController(MouseResponder paramMouseResponder, boolean paramBoolean)
/* */ {
/* 48 */ super(paramMouseResponder, paramBoolean);
/* */ }
/* */
/* */ /** @deprecated */
/* */ public Space getSpace()
/* */ {
/* 63 */ return this.group;
/* */ }
/* */
/* */ /** @deprecated */
/* */ protected void setTargetSpace(Space paramSpace)
/* */ {
/* 73 */ this.group = ((GroupDrawable)paramSpace);
/* */ }
/* */
/* */ /** @deprecated */
/* */ protected Object getSelected(MouseEvent paramMouseEvent)
/* */ throws QTException
/* */ {
/* 85 */ this.current = ((QTDrawable)this.group.hitTest(paramMouseEvent.getX(), paramMouseEvent.getY()));
/* 86 */ if ((isWholespace()) || (hasMember(this.current))) return this.current;
/* 87 */ return null;
/* */ }
/* */
/* */ /** @deprecated */
/* */ protected void deactivateResponder()
/* */ {
/* 99 */ this.current = null;
/* 100 */ this.isActive = false;
/* 101 */ super.deactivateResponder();
/* */ }
/* */
/* */ /** @deprecated */
/* */ protected void responderActivated()
/* */ {
/* 109 */ this.isActive = true;
/* */ }
/* */
/* */ /** @deprecated */
/* */ public void mouseDragged(MouseEvent paramMouseEvent)
/* */ {
/* 121 */ if (!this.isActive) return;
/* */ try
/* */ {
/* 124 */ synchronized (this.group) {
/* 125 */ MouseResponder localMouseResponder = getResponder();
/* 126 */ if ((localMouseResponder.isInterested(4)) && (localMouseResponder.isActive())) {
/* 127 */ QTDrawable localQTDrawable = this.current;
/* 128 */ doDragTarget(paramMouseEvent);
/* 129 */ this.current = localQTDrawable;
/* */
/* 131 */ Region localRegion1 = new Region(this.current.getDisplayBounds());
/* 132 */ localMouseResponder.mouseDragged(paramMouseEvent);
/* */
/* 134 */ Region localRegion2 = new Region(this.current.getDisplayBounds());
/* 135 */ Region localRegion3 = localRegion1.union(localRegion2).diff(localRegion2);
/* 136 */ if (!localRegion3.empty()) {
/* 137 */ this.group.redrawMember(this.current, localRegion3);
/* */ }
/* 139 */ if (!this.group.hasMember(this.current))
/* 140 */ deactivateResponder();
/* */ }
/* */ }
/* */ } catch (QTException localQTException) {
/* 144 */ QTRuntimeException.handleOrThrow(new QTRuntimeException(localQTException), this, "mouseDragged");
/* */ }
/* */ }
/* */
/* */ static
/* */ {
/* 33 */ if ((QTSession.isCurrentOS(4)) && (QTSession.getJavaVersion() >= 65540))
/* 34 */ throw new QTRuntimeException("Unsupported on Mac OS X and Java 1.4 and higher.");
/* */ }
/* */ }
/* Location: Z:\System\Library\Java\Extensions\QTJava.zip
* Qualified Name: quicktime.app.display.GroupController
* JD-Core Version: 0.6.2
*/