Permalink
Browse files

deprecate setMouseControlled, replace with setActive

  • Loading branch information...
1 parent cf4c218 commit 76dc44ef1a1b8a428066a650ccc7460b9edefcb1 @jdf committed Sep 16, 2010
Showing with 5 additions and 14 deletions.
  1. +1 −1 README.textile
  2. +3 −12 src/peasy/PeasyCam.java
  3. +1 −1 web/index.html
View
@@ -25,7 +25,7 @@ PeasyCam(PApplet parent, double distance); // look at 0,0,0</pre>
h3. Methods
-<pre>camera.setMouseControlled(boolean isMouseControlled); // default true
+<pre>camera.setActive(boolean active); // false to make this camera stop responding to mouse
// reassign particular drag gestures, or set them to null
camera.setLeftDragHandler(PeasyDragHandler handler);
View
@@ -102,7 +102,7 @@ public void handleWheel(final int delta) {
private final PMatrix3D originalMatrix; // for HUD restore
- public final String VERSION = "0.9";
+ public final String VERSION = "0.91";
public PeasyCam(final PApplet parent, final double distance) {
this(parent, 0, 0, 0, distance);
@@ -209,19 +209,10 @@ public boolean isActive() {
* </table>
*
* @param isMouseControlled
+ * @deprecated use {@link #setActive(boolean)}
*/
public void setMouseControlled(final boolean isMouseControlled) {
- if (isMouseControlled) {
- leftDragHandler = rotateHandler;
- rightDraghandler = zoomHandler;
- centerDragHandler = panHandler;
- wheelHandler = zoomWheelHandler;
- } else {
- leftDragHandler = null;
- rightDraghandler = null;
- centerDragHandler = null;
- wheelHandler = null;
- }
+ setActive(isMouseControlled);
}
public double getWheelScale() {
View
@@ -200,7 +200,7 @@
</pre>
<h3>Methods</h3>
-<pre class="prettyprint">camera.setMouseControlled(boolean isMouseControlled); // default true
+<pre class="prettyprint">camera.setActive(boolean active); // false to make this camera stop responding to mouse
// reassign particular drag gestures, or set them to null
camera.setLeftDragHandler(PeasyDragHandler handler);

0 comments on commit 76dc44e

Please sign in to comment.