Module: check_mk
Branch: master
Commit: 4df0a2481717621a70afae7b8419d2d780b326b5
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=4df0a248171762…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Thu Apr 19 12:17:58 2012 +0200
View Editor: Fixed jump to top of the page after moving painters during editing views
---
ChangeLog | 2 ++
web/htdocs/htmllib.py | 2 +-
web/htdocs/views.py | 6 +++---
3 files changed, 6 insertions(+), 4 deletions(-)
diff --git a/ChangeLog b/ChangeLog
index 00fac6d..d68f4a9 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -2,6 +2,8 @@
Multisite:
* FIX: allow web plugins to be byte compiled (*.pyc). Those
are preferred over *.py if existing
+ * View Editor: Fixed jump to top of the page after moving painters during
+ editing views
1.2.0b2:
Core:
diff --git a/web/htdocs/htmllib.py b/web/htdocs/htmllib.py
index 4163ec0..2a3b036 100644
--- a/web/htdocs/htmllib.py
+++ b/web/htdocs/htmllib.py
@@ -365,7 +365,7 @@ class html:
if onclick:
onclick = 'onclick="%s" ' % onclick
- url = "#"
+ url = "javascript:void(0)"
if style:
style = 'style="%s" ' % style
diff --git a/web/htdocs/views.py b/web/htdocs/views.py
index d4f48af..0bd61ea 100644
--- a/web/htdocs/views.py
+++ b/web/htdocs/views.py
@@ -750,13 +750,13 @@ def view_edit_column(n, var_prefix, maxnum, allowed, joined = []):
# Buttons for deleting and moving around
html.write('<td class="cebuttons" rowspan=5>')
- html.icon_button("#", _("Delete this column"),
"delete", onclick="delete_view_column(this);")
+ html.icon_button("javascript:void(0)", _("Delete this column"),
"delete", onclick="delete_view_column(this);")
display = n == 1 and 'display:none;' or ''
- html.icon_button("#", _("Move this column up"), "up",
onclick="move_column_up(this);",
+ html.icon_button("javascript:void(0)", _("Move this column up"),
"up", onclick="move_column_up(this);",
id="%sup_%d" % (var_prefix, n), style=display)
display = n == maxnum - 1 and 'display:none;' or ''
- html.icon_button("#", _("Move this column down"),
"down", onclick="move_column_down(this);",
+ html.icon_button("javascript:void(0)", _("Move this column
down"), "down", onclick="move_column_down(this);",
id="%sdown_%d" % (var_prefix, n), style=display)
html.write('</td>')