Page Menu
Home
Code
Search
Configure Global Search
Log In
Files
F391246
DataSelection.js
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Subscribers
None
DataSelection.js
View Options
/*
Copyright (c) 2004-2009, The Dojo Foundation All Rights Reserved.
Available via Academic Free License >= 2.1 OR the modified BSD license.
see: http://dojotoolkit.org/license for details
*/
if
(
!
dojo
.
_hasResource
[
"dojox.grid.DataSelection"
]){
dojo
.
_hasResource
[
"dojox.grid.DataSelection"
]
=
true
;
dojo
.
provide
(
"dojox.grid.DataSelection"
);
dojo
.
require
(
"dojox.grid.Selection"
);
dojo
.
declare
(
"dojox.grid.DataSelection"
,
dojox
.
grid
.
Selection
,{
getFirstSelected
:
function
(){
var
_1
=
dojox
.
grid
.
Selection
.
prototype
.
getFirstSelected
.
call
(
this
);
if
(
_1
==-
1
){
return
null
;
}
return
this
.
grid
.
getItem
(
_1
);
},
getNextSelected
:
function
(
_2
){
var
_3
=
this
.
grid
.
getItemIndex
(
_2
);
var
_4
=
dojox
.
grid
.
Selection
.
prototype
.
getNextSelected
.
call
(
this
,
_3
);
if
(
_4
==-
1
){
return
null
;
}
return
this
.
grid
.
getItem
(
_4
);
},
getSelected
:
function
(){
var
_5
=
[];
for
(
var
i
=
0
,
l
=
this
.
selected
.
length
;
i
<
l
;
i
++
){
if
(
this
.
selected
[
i
]){
_5
.
push
(
this
.
grid
.
getItem
(
i
));
}
}
return
_5
;
},
addToSelection
:
function
(
_6
){
if
(
this
.
mode
==
"none"
){
return
;
}
var
_7
=
null
;
if
(
typeof
_6
==
"number"
||
typeof
_6
==
"string"
){
_7
=
_6
;
}
else
{
_7
=
this
.
grid
.
getItemIndex
(
_6
);
}
dojox
.
grid
.
Selection
.
prototype
.
addToSelection
.
call
(
this
,
_7
);
},
deselect
:
function
(
_8
){
if
(
this
.
mode
==
"none"
){
return
;
}
var
_9
=
null
;
if
(
typeof
_8
==
"number"
||
typeof
_8
==
"string"
){
_9
=
_8
;
}
else
{
_9
=
this
.
grid
.
getItemIndex
(
_8
);
}
dojox
.
grid
.
Selection
.
prototype
.
deselect
.
call
(
this
,
_9
);
},
deselectAll
:
function
(
_a
){
var
_b
=
null
;
if
(
_a
||
typeof
_a
==
"number"
){
if
(
typeof
_a
==
"number"
||
typeof
_a
==
"string"
){
_b
=
_a
;
}
else
{
_b
=
this
.
grid
.
getItemIndex
(
_a
);
}
dojox
.
grid
.
Selection
.
prototype
.
deselectAll
.
call
(
this
,
_b
);
}
else
{
this
.
inherited
(
arguments
);
}
}});
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sat, Feb 22, 20:21 (1 d, 1 h ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
26460
Default Alt Text
DataSelection.js (1 KB)
Attached To
rZED Zed
Event Timeline
Log In to Comment