/*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation. Oracle designates this
* particular file as subject to the "Classpath" exception as provided
* by Oracle in the LICENSE file that accompanied this code.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
/**
* Autoscroller is responsible for generating synthetic mouse dragged
* events. It is the responsibility of the Component (or its MouseListeners)
* that receive the events to do the actual scrolling in response to the
* mouse dragged events.
*
* @author Dave Moore
* @author Scott Violet
*/
/**
* Global Autoscroller.
*/
// As there can only ever be one autoscroller active these fields are
// static. The Timer is recreated as necessary to target the appropriate
// Autoscroller instance.
//
// The public API, all methods are cover methods for an instance method
//
/**
* Stops autoscroll events from happening on the specified component.
*/
sharedInstance._stop(c);
}
/**
* Stops autoscroll events from happening on the specified component.
*/
return sharedInstance._isRunning(c);
}
/**
* Invoked when a mouse dragged event occurs, will start the autoscroller
* if necessary.
*/
}
Autoscroller() {
}
/**
* Starts the timer targeting the passed in component.
*/
if (component != c) {
}
component = c;
e.getY() + screenLocation.y,
e.getXOnScreen(),
e.getYOnScreen(),
e.getClickCount(), e.isPopupTrigger(),
}
}
}
//
// Methods mirror the public static API
//
/**
* Stops scrolling for the passed in widget.
*/
if (component == c) {
}
}
}
/**
* Returns true if autoscrolling is currently running for the specified
* widget.
*/
}
/**
*/
boolean stop = true;
}
if (stop) {
} else {
}
}
//
// ActionListener
//
/**
* ActionListener method. Invoked when the Timer fires. This will scroll
* if necessary.
*/
return;
}
}
}