Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
itminedu
synnefo
Commits
6e3c3c30
Commit
6e3c3c30
authored
Apr 01, 2011
by
Dimitris Moraitis
Browse files
improve positioning of confirm box & update actions on select all/none
parent
1984f6c9
Changes
3
Hide whitespace changes
Inline
Side-by-side
ui/templates/list.html
View file @
6e3c3c30
...
...
@@ -61,6 +61,7 @@ $("table thead tr th#selection :checkbox").live('change', function() {
$
(
"
ul.dropdown-selector li.select-all a
"
).
live
(
'
click
'
,
function
()
{
$
(
"
:checkbox
"
).
attr
(
"
checked
"
,
true
);
$
(
"
.dropdown-selector
"
).
slideToggle
(
'
medium
'
);
updateActions
();
return
false
;
});
...
...
@@ -68,6 +69,7 @@ $("ul.dropdown-selector li.select-all a").live('click', function() {
$
(
"
ul.dropdown-selector li.select-none a
"
).
live
(
'
click
'
,
function
()
{
$
(
"
:checkbox
"
).
attr
(
"
checked
"
,
false
);
$
(
"
.dropdown-selector
"
).
slideToggle
(
'
medium
'
);
updateActions
();
return
false
;
});
...
...
@@ -75,6 +77,7 @@ $("ul.dropdown-selector li.select-none a").live('click', function() {
$
(
"
ul.dropdown-selector li.select-group a
"
).
live
(
'
click
'
,
function
()
{
$
(
"
:checkbox
"
).
attr
(
"
checked
"
,
true
);
$
(
"
.dropdown-selector
"
).
slideToggle
(
'
medium
'
);
updateActions
();
return
false
;
});
...
...
@@ -289,6 +292,15 @@ if (flavors.length == 0) {
// set the label of the multiple buttons
$
(
'
div.confirm_multiple button.yes
'
).
text
(
'
Confirm
'
);
$
(
'
div.confirm_multiple button.no
'
).
text
(
'
Cancel
'
);
// reposition multiple confirmation box on window resize
$
(
window
).
resize
(
function
(){
if
(
this
.
innerHeight
-
200
<
$
(
'
#machinesview
'
).
height
())
$
(
'
.confirm_multiple
'
).
addClass
(
'
fixed
'
);
else
$
(
'
.confirm_multiple
'
).
removeClass
(
'
fixed
'
);
});
// start updating vm list
update_vms
(
UPDATE_INTERVAL
);
...
...
ui/templates/machines.html
View file @
6e3c3c30
...
...
@@ -446,11 +446,4 @@ if (flavors.length > 0) {
// create tabs for main menu
$
(
"
ul.tabs
"
).
tabs
(
"
div.panes ul
"
);
$
(
window
).
resize
(
function
(){
if
(
this
.
innerHeight
-
200
<
$
(
'
#machinesview
'
).
height
())
$
(
'
.confirm_multiple
'
).
addClass
(
'
fixed
'
);
else
$
(
'
.confirm_multiple
'
).
removeClass
(
'
fixed
'
);
});
</script>
ui/templates/standard.html
View file @
6e3c3c30
...
...
@@ -246,7 +246,7 @@ function update_machines_view(data){
}
// set confirm box position
if
(
window
.
innerHeight
-
2
0
0
<
$
(
'
#machinesview
'
).
height
())
if
(
window
.
innerHeight
-
2
2
0
<
$
(
'
#machinesview
'
).
height
())
$
(
'
.confirm_multiple
'
).
addClass
(
'
fixed
'
);
else
$
(
'
.confirm_multiple
'
).
removeClass
(
'
fixed
'
);
...
...
@@ -277,6 +277,15 @@ if (flavors.length == 0) {
// set the label of the multiple buttons
$
(
'
div.confirm_multiple button.yes
'
).
text
(
'
Confirm All
'
);
$
(
'
div.confirm_multiple button.no
'
).
text
(
'
Cancel All
'
);
// reposition multiple confirmation box on window resize
$
(
window
).
resize
(
function
(){
if
(
this
.
innerHeight
-
220
<
$
(
'
#machinesview
'
).
height
())
$
(
'
.confirm_multiple
'
).
addClass
(
'
fixed
'
);
else
$
(
'
.confirm_multiple
'
).
removeClass
(
'
fixed
'
);
});
// start updating vm list
update_vms
(
UPDATE_INTERVAL
);
</script>
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