Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
F
flot
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
HS-public
flot
Commits
49c312c3
Commit
49c312c3
authored
May 28, 2013
by
David Schnur
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix lines incorrectly broken before an operator.
parent
b8905be5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
28 additions
and
31 deletions
+28
-31
jquery.flot.js
jquery.flot.js
+14
-16
jquery.flot.pie.js
jquery.flot.pie.js
+4
-3
jquery.flot.stack.js
jquery.flot.stack.js
+4
-4
jquery.flot.threshold.js
jquery.flot.threshold.js
+1
-2
jquery.flot.time.js
jquery.flot.time.js
+5
-6
No files found.
jquery.flot.js
View file @
49c312c3
...
...
@@ -1191,10 +1191,10 @@ Licensed under the MIT license.
// a little bit of line specific stuff that
// perhaps shouldn't be here, but lacking
// better means...
if
(
insertSteps
&&
k
>
0
&&
points
[
k
-
ps
]
!=
null
&&
points
[
k
-
ps
]
!=
points
[
k
]
&&
points
[
k
-
ps
+
1
]
!=
points
[
k
+
1
])
{
if
(
insertSteps
&&
k
>
0
&&
points
[
k
-
ps
]
!=
null
&&
points
[
k
-
ps
]
!=
points
[
k
]
&&
points
[
k
-
ps
+
1
]
!=
points
[
k
+
1
])
{
// copy the point to make room for a middle point
for
(
m
=
0
;
m
<
ps
;
++
m
)
{
points
[
k
+
ps
+
m
]
=
points
[
k
+
m
];
...
...
@@ -2084,11 +2084,11 @@ Licensed under the MIT license.
xoff
=
yoff
=
0
;
if
(
isNaN
(
v
)
||
v
<
axis
.
min
||
v
>
axis
.
max
if
(
isNaN
(
v
)
||
v
<
axis
.
min
||
v
>
axis
.
max
||
(
// skip those lying on the axes if we got a border
||
(
t
==
"full"
&&
((
typeof
bw
==
"object"
&&
bw
[
axis
.
position
]
>
0
)
||
bw
>
0
)
&&
(
v
==
axis
.
min
||
v
==
axis
.
max
)
))
{
t
==
"full"
&&
((
typeof
bw
==
"object"
&&
bw
[
axis
.
position
]
>
0
)
||
bw
>
0
)
&&
(
v
==
axis
.
min
||
v
==
axis
.
max
)
))
{
continue
;
}
...
...
@@ -2997,10 +2997,11 @@ Licensed under the MIT license.
// clear auto-highlights
for
(
var
i
=
0
;
i
<
highlights
.
length
;
++
i
)
{
var
h
=
highlights
[
i
];
if
(
h
.
auto
==
eventname
&&
!
(
item
&&
h
.
series
==
item
.
series
&&
if
(
h
.
auto
==
eventname
&&
!
(
item
&&
h
.
series
==
item
.
series
&&
h
.
point
[
0
]
==
item
.
datapoint
[
0
]
&&
h
.
point
[
1
]
==
item
.
datapoint
[
1
]))
{
h
.
point
[
1
]
==
item
.
datapoint
[
1
]
))
{
unhighlight
(
h
.
series
,
h
.
point
);
}
}
...
...
@@ -3061,7 +3062,6 @@ Licensed under the MIT license.
var
i
=
indexOfHighlight
(
s
,
point
);
if
(
i
==
-
1
)
{
highlights
.
push
({
series
:
s
,
point
:
point
,
auto
:
auto
});
triggerRedrawOverlay
();
}
else
if
(
!
auto
)
{
highlights
[
i
].
auto
=
false
;
...
...
@@ -3087,7 +3087,6 @@ Licensed under the MIT license.
var
i
=
indexOfHighlight
(
s
,
point
);
if
(
i
!=
-
1
)
{
highlights
.
splice
(
i
,
1
);
triggerRedrawOverlay
();
}
}
...
...
@@ -3095,8 +3094,7 @@ Licensed under the MIT license.
function
indexOfHighlight
(
s
,
p
)
{
for
(
var
i
=
0
;
i
<
highlights
.
length
;
++
i
)
{
var
h
=
highlights
[
i
];
if
(
h
.
series
==
s
&&
h
.
point
[
0
]
==
p
[
0
]
&&
h
.
point
[
1
]
==
p
[
1
])
{
if
(
h
.
series
===
s
&&
h
.
point
[
0
]
===
p
[
0
]
&&
h
.
point
[
1
]
===
p
[
1
])
{
return
i
;
}
}
...
...
jquery.flot.pie.js
View file @
49c312c3
...
...
@@ -564,9 +564,10 @@ More detail and specific examples can be found in the included HTML file.
function
isPointInPoly
(
poly
,
pt
)
{
for
(
var
c
=
false
,
i
=
-
1
,
l
=
poly
.
length
,
j
=
l
-
1
;
++
i
<
l
;
j
=
i
)
{
((
poly
[
i
][
1
]
<=
pt
[
1
]
&&
pt
[
1
]
<
poly
[
j
][
1
])
||
(
poly
[
j
][
1
]
<=
pt
[
1
]
&&
pt
[
1
]
<
poly
[
i
][
1
]))
&&
(
pt
[
0
]
<
(
poly
[
j
][
0
]
-
poly
[
i
][
0
])
*
(
pt
[
1
]
-
poly
[
i
][
1
])
/
(
poly
[
j
][
1
]
-
poly
[
i
][
1
])
+
poly
[
i
][
0
])
&&
(
c
=
!
c
);
((
poly
[
i
][
1
]
<=
pt
[
1
]
&&
pt
[
1
]
<
poly
[
j
][
1
])
||
(
poly
[
j
][
1
]
<=
pt
[
1
]
&&
pt
[
1
]
<
poly
[
i
][
1
]))
&&
(
pt
[
0
]
<
(
poly
[
j
][
0
]
-
poly
[
i
][
0
])
*
(
pt
[
1
]
-
poly
[
i
][
1
])
/
(
poly
[
j
][
1
]
-
poly
[
i
][
1
])
+
poly
[
i
][
0
])
&&
(
c
=
!
c
);
}
return
c
;
}
...
...
jquery.flot.stack.js
View file @
49c312c3
...
...
@@ -176,10 +176,10 @@ charts or filled areas).
}
// maintain the line steps invariant
if
(
withsteps
&&
l
!=
newpoints
.
length
&&
l
>
0
&&
newpoints
[
l
]
!=
null
&&
newpoints
[
l
]
!=
newpoints
[
l
-
ps
]
&&
newpoints
[
l
+
1
]
!=
newpoints
[
l
-
ps
+
1
])
{
if
(
withsteps
&&
l
!=
newpoints
.
length
&&
l
>
0
&&
newpoints
[
l
]
!=
null
&&
newpoints
[
l
]
!=
newpoints
[
l
-
ps
]
&&
newpoints
[
l
+
1
]
!=
newpoints
[
l
-
ps
+
1
])
{
for
(
m
=
0
;
m
<
ps
;
++
m
)
{
newpoints
[
l
+
ps
+
m
]
=
newpoints
[
l
+
m
];
}
...
...
jquery.flot.threshold.js
View file @
49c312c3
...
...
@@ -77,8 +77,7 @@ You may need to check for this in hover events.
p
=
newpoints
;
}
if
(
addCrossingPoints
&&
prevp
!=
p
&&
x
!=
null
&&
i
>
0
&&
origpoints
[
i
-
ps
]
!=
null
)
{
if
(
addCrossingPoints
&&
prevp
!=
p
&&
x
!=
null
&&
i
>
0
&&
origpoints
[
i
-
ps
]
!=
null
)
{
var
interx
=
x
+
(
below
-
y
)
*
(
x
-
origpoints
[
i
-
ps
])
/
(
y
-
origpoints
[
i
-
ps
+
1
]);
prevp
.
push
(
interx
);
prevp
.
push
(
below
);
...
...
jquery.flot.time.js
View file @
49c312c3
...
...
@@ -224,9 +224,9 @@ API.txt for details.
}
for
(
var
i
=
0
;
i
<
spec
.
length
-
1
;
++
i
)
{
if
(
axis
.
delta
<
(
spec
[
i
][
0
]
*
timeUnitSize
[
spec
[
i
][
1
]]
+
spec
[
i
+
1
][
0
]
*
timeUnitSize
[
spec
[
i
+
1
][
1
]])
/
2
&&
spec
[
i
][
0
]
*
timeUnitSize
[
spec
[
i
][
1
]]
>=
minSize
)
{
if
(
axis
.
delta
<
(
spec
[
i
][
0
]
*
timeUnitSize
[
spec
[
i
][
1
]]
+
spec
[
i
+
1
][
0
]
*
timeUnitSize
[
spec
[
i
+
1
][
1
]])
/
2
&&
spec
[
i
][
0
]
*
timeUnitSize
[
spec
[
i
][
1
]]
>=
minSize
)
{
break
;
}
}
...
...
@@ -335,8 +335,7 @@ API.txt for details.
d
.
setDate
(
1
);
var
start
=
d
.
getTime
();
d
.
setMonth
(
d
.
getMonth
()
+
(
unit
==
"quarter"
?
3
:
1
));
d
.
setMonth
(
d
.
getMonth
()
+
(
unit
==
"quarter"
?
3
:
1
));
var
end
=
d
.
getTime
();
d
.
setTime
(
v
+
carry
*
timeUnitSize
.
hour
+
(
end
-
start
)
*
tickSize
);
carry
=
d
.
getHours
();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment