package NET.worlds.scape; class PitchWidget extends WidgetButton { public PitchWidget(ToolBar toolbar) { super(toolbar, "pitch.gif", "Pitch"); } @Override public String drag(boolean initialDrag, float deltax, float deltay) { if (Math.abs(deltax) > Math.abs(deltay)) { deltay = 0.0F; } Transform t = Transform.make(); this.applyWorldTransform(initialDrag, t.spin(this.getWorldAxis(1, 0, 0), -deltay)); t.recycle(); return "Pitch"; } }