Skip to content
This repository has been archived by the owner on Sep 19, 2024. It is now read-only.

Commit

Permalink
Bug fix attractor unit
Browse files Browse the repository at this point in the history
  • Loading branch information
alfredwassermann committed May 29, 2018
1 parent 3dc96c4 commit 6965cd3
Show file tree
Hide file tree
Showing 7 changed files with 9 additions and 15 deletions.
2 changes: 1 addition & 1 deletion COPYRIGHT
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
JSXGraph 0.99.7dev
JSXGraph 0.99.7

Copyright 2008-2018
Matthias Ehmann,
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "jsxgraph",
"description": "Interactive geometry, plotting, visualization",
"homepage": "http://jsxgraph.org",
"version": "0.99.7dev",
"version": "0.99.7",
"main": "distrib/jsxgraphcore.js",
"maintainers": [
{
Expand Down
2 changes: 1 addition & 1 deletion src/base/board.js
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ define([
// this.document = attributes.document || document;
if (Type.exists(attributes.document) && attributes.document !== false) {
this.document = attributes.document;
} else if (typeof document !== 'undefined' && Type.isObject(document)) {
} else if (document !== undefined && Type.isObject(document)) {
this.document = document;
}

Expand Down
2 changes: 1 addition & 1 deletion src/base/constants.js
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ define(['jxg'], function (JXG) {
var major = 0,
minor = 99,
patch = 7,
add = 'dev', //false, // 'dev',
add = false, // 'dev',
version = major + '.' + minor + '.' + patch + (add ? '-' + add : ''),
constants;

Expand Down
7 changes: 3 additions & 4 deletions src/base/coordselement.js
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,7 @@ define([
angle,
cp, c, invMat, newCoords, newPos,
doRound = false,
ev_sw, ev_sel,
ev_sw,
slide = this.slideObject;

this.needsUpdateFromParent = false;
Expand Down Expand Up @@ -470,8 +470,7 @@ define([
var p1c, p2c, r, lbda, c,
slide = this.slideObject,
baseangle, alpha, angle, beta,
delta = 2.0 * Math.PI,
newPos;
delta = 2.0 * Math.PI;

if (!this.needsUpdateFromParent) {
this.needsUpdateFromParent = true;
Expand Down Expand Up @@ -851,7 +850,7 @@ define([
projCoords = Geometry.projectPointToTurtle(this, el, this.board);
}

if (ev_a === 'screen') {
if (ev_au === 'screen') {
d = projCoords.distance(Const.COORDS_BY_SCREEN, this.coords);
} else {
d = projCoords.distance(Const.COORDS_BY_USER, this.coords);
Expand Down
2 changes: 0 additions & 2 deletions src/jsxgraph.js
Original file line number Diff line number Diff line change
Expand Up @@ -179,8 +179,6 @@ define([
renderer,
w, h, dimensions,
bbox, attr, axattr, axattr_x, axattr_y,
defaultaxesattr,
selectionattr,
board;

attributes = attributes || {};
Expand Down
7 changes: 2 additions & 5 deletions src/renderer/abstract.js
Original file line number Diff line number Diff line change
Expand Up @@ -295,7 +295,7 @@ define([

if (!isNaN(el.coords.scrCoords[2] + el.coords.scrCoords[1])) {
if (unit === 'user') {
size *= Math.sqrt(el.board.unitX * el.board.unitY)
size *= Math.sqrt(el.board.unitX * el.board.unitY);
}
size *= ((!el.board || !zoom) ?
1.0 : Math.sqrt(el.board.zoomX * el.board.zoomY));
Expand Down Expand Up @@ -767,10 +767,7 @@ define([
* @see JXG.AbstractRenderer#drawPolygon
*/
updatePolygon: function (el) {
var i;
//, len, polIsReal;

// here originally strokecolor wasn't updated but strokewidth was
// Here originally strokecolor wasn't updated but strokewidth was
// but if there's no strokecolor i don't see why we should update strokewidth.
this._updateVisual(el, {stroke: true, dash: true});
this.updatePolygonPrim(el.rendNode, el);
Expand Down

0 comments on commit 6965cd3

Please sign in to comment.