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
8e2f09a9
Commit
8e2f09a9
authored
Sep 28, 2013
by
David Schnur
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #1141 from nschonni/0.9-jshint-indent4
0.9 jshint indent4
parents
d76e1cb2
678ff275
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
95 additions
and
63 deletions
+95
-63
.jshintrc
.jshintrc
+2
-1
jquery.flot.js
jquery.flot.js
+43
-43
jquery.flot.time.js
jquery.flot.time.js
+50
-19
No files found.
.jshintrc
View file @
8e2f09a9
...
@@ -19,5 +19,6 @@
...
@@ -19,5 +19,6 @@
},
},
"browser": true,
"browser": true,
"jquery": true
"jquery": true,
"indent": 4
}
}
jquery.flot.js
View file @
8e2f09a9
...
@@ -701,26 +701,26 @@ Licensed under the MIT license.
...
@@ -701,26 +701,26 @@ Licensed under the MIT license.
},
},
hooks
:
{}
hooks
:
{}
},
},
surface
=
null
,
// the canvas for the plot itself
surface
=
null
,
// the canvas for the plot itself
overlay
=
null
,
// canvas for interactive stuff on top of plot
overlay
=
null
,
// canvas for interactive stuff on top of plot
eventHolder
=
null
,
// jQuery object that events should be bound to
eventHolder
=
null
,
// jQuery object that events should be bound to
ctx
=
null
,
octx
=
null
,
ctx
=
null
,
octx
=
null
,
xaxes
=
[],
yaxes
=
[],
xaxes
=
[],
yaxes
=
[],
plotOffset
=
{
left
:
0
,
right
:
0
,
top
:
0
,
bottom
:
0
},
plotOffset
=
{
left
:
0
,
right
:
0
,
top
:
0
,
bottom
:
0
},
plotWidth
=
0
,
plotHeight
=
0
,
plotWidth
=
0
,
plotHeight
=
0
,
hooks
=
{
hooks
=
{
processOptions
:
[],
processOptions
:
[],
processRawData
:
[],
processRawData
:
[],
processDatapoints
:
[],
processDatapoints
:
[],
processOffset
:
[],
processOffset
:
[],
drawBackground
:
[],
drawBackground
:
[],
drawSeries
:
[],
drawSeries
:
[],
draw
:
[],
draw
:
[],
bindEvents
:
[],
bindEvents
:
[],
drawOverlay
:
[],
drawOverlay
:
[],
shutdown
:
[]
shutdown
:
[]
},
},
plot
=
this
;
plot
=
this
;
// public functions
// public functions
plot
.
setData
=
setData
;
plot
.
setData
=
setData
;
...
@@ -1387,17 +1387,17 @@ Licensed under the MIT license.
...
@@ -1387,17 +1387,17 @@ Licensed under the MIT license.
var
delta
;
var
delta
;
switch
(
s
.
bars
.
align
)
{
switch
(
s
.
bars
.
align
)
{
case
"left"
:
case
"left"
:
delta
=
0
;
delta
=
0
;
break
;
break
;
case
"right"
:
case
"right"
:
delta
=
-
s
.
bars
.
barWidth
;
delta
=
-
s
.
bars
.
barWidth
;
break
;
break
;
case
"center"
:
case
"center"
:
delta
=
-
s
.
bars
.
barWidth
/
2
;
delta
=
-
s
.
bars
.
barWidth
/
2
;
break
;
break
;
default
:
default
:
throw
new
Error
(
"Invalid bar alignment: "
+
s
.
bars
.
align
);
throw
new
Error
(
"Invalid bar alignment: "
+
s
.
bars
.
align
);
}
}
if
(
s
.
bars
.
horizontal
)
{
if
(
s
.
bars
.
horizontal
)
{
...
@@ -2869,17 +2869,17 @@ Licensed under the MIT license.
...
@@ -2869,17 +2869,17 @@ Licensed under the MIT license.
var
barLeft
;
var
barLeft
;
switch
(
series
.
bars
.
align
)
{
switch
(
series
.
bars
.
align
)
{
case
"left"
:
case
"left"
:
barLeft
=
0
;
barLeft
=
0
;
break
;
break
;
case
"right"
:
case
"right"
:
barLeft
=
-
series
.
bars
.
barWidth
;
barLeft
=
-
series
.
bars
.
barWidth
;
break
;
break
;
case
"center"
:
case
"center"
:
barLeft
=
-
series
.
bars
.
barWidth
/
2
;
barLeft
=
-
series
.
bars
.
barWidth
/
2
;
break
;
break
;
default
:
default
:
throw
new
Error
(
"Invalid bar alignment: "
+
series
.
bars
.
align
);
throw
new
Error
(
"Invalid bar alignment: "
+
series
.
bars
.
align
);
}
}
var
fillStyleCallback
=
series
.
bars
.
fill
?
function
(
bottom
,
top
)
{
return
getFillStyle
(
series
.
bars
,
series
.
color
,
bottom
,
top
);
}
:
null
;
var
fillStyleCallback
=
series
.
bars
.
fill
?
function
(
bottom
,
top
)
{
return
getFillStyle
(
series
.
bars
,
series
.
color
,
bottom
,
top
);
}
:
null
;
...
@@ -3103,7 +3103,7 @@ Licensed under the MIT license.
...
@@ -3103,7 +3103,7 @@ Licensed under the MIT license.
my
>=
y
+
barLeft
&&
my
<=
y
+
barRight
)
:
my
>=
y
+
barLeft
&&
my
<=
y
+
barRight
)
:
(
mx
>=
x
+
barLeft
&&
mx
<=
x
+
barRight
&&
(
mx
>=
x
+
barLeft
&&
mx
<=
x
+
barRight
&&
my
>=
Math
.
min
(
b
,
y
)
&&
my
<=
Math
.
max
(
b
,
y
)))
{
my
>=
Math
.
min
(
b
,
y
)
&&
my
<=
Math
.
max
(
b
,
y
)))
{
item
=
[
i
,
j
/
ps
];
item
=
[
i
,
j
/
ps
];
}
}
}
}
}
}
...
...
jquery.flot.time.js
View file @
8e2f09a9
...
@@ -69,25 +69,56 @@ API.txt for details.
...
@@ -69,25 +69,56 @@ API.txt for details.
if
(
escape
)
{
if
(
escape
)
{
switch
(
c
)
{
switch
(
c
)
{
case
"a"
:
c
=
""
+
dayNames
[
d
.
getDay
()];
break
;
case
"a"
:
case
"b"
:
c
=
""
+
monthNames
[
d
.
getMonth
()];
break
;
c
=
""
+
dayNames
[
d
.
getDay
()];
case
"d"
:
c
=
leftPad
(
d
.
getDate
());
break
;
break
;
case
"e"
:
c
=
leftPad
(
d
.
getDate
(),
" "
);
break
;
case
"b"
:
case
"h"
:
// For back-compat with 0.7; remove in 1.0
c
=
""
+
monthNames
[
d
.
getMonth
()];
case
"H"
:
c
=
leftPad
(
hours
);
break
;
break
;
case
"I"
:
c
=
leftPad
(
hours12
);
break
;
case
"d"
:
case
"l"
:
c
=
leftPad
(
hours12
,
" "
);
break
;
c
=
leftPad
(
d
.
getDate
());
case
"m"
:
c
=
leftPad
(
d
.
getMonth
()
+
1
);
break
;
break
;
case
"M"
:
c
=
leftPad
(
d
.
getMinutes
());
break
;
case
"e"
:
// quarters not in Open Group's strftime specification
c
=
leftPad
(
d
.
getDate
(),
" "
);
case
"q"
:
break
;
c
=
""
+
(
Math
.
floor
(
d
.
getMonth
()
/
3
)
+
1
);
break
;
case
"h"
:
// For back-compat with 0.7; remove in 1.0
case
"S"
:
c
=
leftPad
(
d
.
getSeconds
());
break
;
case
"H"
:
case
"y"
:
c
=
leftPad
(
d
.
getFullYear
()
%
100
);
break
;
c
=
leftPad
(
hours
);
case
"Y"
:
c
=
""
+
d
.
getFullYear
();
break
;
break
;
case
"p"
:
c
=
(
isAM
)
?
(
""
+
"am"
)
:
(
""
+
"pm"
);
break
;
case
"I"
:
case
"P"
:
c
=
(
isAM
)
?
(
""
+
"AM"
)
:
(
""
+
"PM"
);
break
;
c
=
leftPad
(
hours12
);
case
"w"
:
c
=
""
+
d
.
getDay
();
break
;
break
;
case
"l"
:
c
=
leftPad
(
hours12
,
" "
);
break
;
case
"m"
:
c
=
leftPad
(
d
.
getMonth
()
+
1
);
break
;
case
"M"
:
c
=
leftPad
(
d
.
getMinutes
());
break
;
// quarters not in Open Group's strftime specification
case
"q"
:
c
=
""
+
(
Math
.
floor
(
d
.
getMonth
()
/
3
)
+
1
);
break
;
case
"S"
:
c
=
leftPad
(
d
.
getSeconds
());
break
;
case
"y"
:
c
=
leftPad
(
d
.
getFullYear
()
%
100
);
break
;
case
"Y"
:
c
=
""
+
d
.
getFullYear
();
break
;
case
"p"
:
c
=
(
isAM
)
?
(
""
+
"am"
)
:
(
""
+
"pm"
);
break
;
case
"P"
:
c
=
(
isAM
)
?
(
""
+
"AM"
)
:
(
""
+
"PM"
);
break
;
case
"w"
:
c
=
""
+
d
.
getDay
();
break
;
}
}
r
.
push
(
c
);
r
.
push
(
c
);
escape
=
false
;
escape
=
false
;
...
...
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