Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
pve-manager
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
Administrator
pve-manager
Commits
d98d8f35
Commit
d98d8f35
authored
Feb 14, 2012
by
Dietmar Maurer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix LogViewer updates
Seems ExtJS onShow/onHide wrappers does not work for panels.
parent
90c352e7
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
42 additions
and
47 deletions
+42
-47
changelog.Debian
debian/changelog.Debian
+6
-0
defines.mk
defines.mk
+1
-1
LogView.js
www/manager/panel/LogView.js
+32
-45
TaskViewer.js
www/manager/window/TaskViewer.js
+3
-1
No files found.
debian/changelog.Debian
View file @
d98d8f35
pve-manager (2.0-24) unstable; urgency=low
* fix log viewer (correctly refresh display)
-- Proxmox Support Team <support@proxmox.com> Tue, 14 Feb 2012 09:01:07 +0100
pve-manager (2.0-23) unstable; urgency=low
* fix openvz live migration
...
...
defines.mk
View file @
d98d8f35
...
...
@@ -2,7 +2,7 @@ RELEASE=2.0
VERSION=2.0
PACKAGE=pve-manager
PACKAGERELEASE=2
3
PACKAGERELEASE=2
4
BINDIR=${DESTDIR}/usr/bin
PERLLIBDIR=${DESTDIR}/usr/share/perl5
...
...
www/manager/panel/LogView.js
View file @
d98d8f35
...
...
@@ -116,11 +116,13 @@ Ext.define('PVE.panel.LogView', {
}
var
viewEnd
=
parseInt
(((
top
+
me
.
getHeight
())
/
me
.
lineHeight
)
+
1
,
10
);
var
info
=
me
.
viewInfo
;
if
(
info
&&
!
force
)
{
if
(
viewStart
>=
info
.
start
&&
viewEnd
<=
info
.
end
)
{
return
;
}
}
var
line
=
parseInt
((
top
/
me
.
lineHeight
)
-
(
me
.
pageSize
/
2
)
+
10
,
10
);
if
(
line
<
0
)
{
line
=
0
;
...
...
@@ -143,21 +145,24 @@ Ext.define('PVE.panel.LogView', {
},
20
);
},
onShow
:
function
()
{
/*jslint confusion: true */
initComponent
:
function
()
{
var
me
=
this
;
me
.
callParent
(
arguments
);
var
target
=
me
.
getTargetEl
();
target
.
dom
.
scrollTop
=
me
.
savedScrollTop
;
if
(
!
me
.
url
)
{
throw
"
no url specified
"
;
}
me
.
dataCmp
=
Ext
.
create
(
'
Ext.Component
'
,
{
style
:
'
font:normal 11px tahoma, arial, verdana, sans-serif;
'
+
'
line-height:
'
+
me
.
lineHeight
.
toString
()
+
'
px; white-space: pre;
'
});
me
.
task
=
Ext
.
TaskManager
.
start
({
run
:
function
()
{
if
(
!
me
.
scrollToEnd
||
!
me
.
viewInfo
)
{
if
(
!
me
.
isVisible
()
||
!
me
.
scrollToEnd
||
!
me
.
viewInfo
)
{
return
;
}
var
maxDown
=
me
.
getMaxDown
();
if
(
maxDown
>
0
)
{
return
;
...
...
@@ -167,48 +172,30 @@ Ext.define('PVE.panel.LogView', {
},
interval
:
1000
});
},
onHide
:
function
()
{
var
me
=
this
;
var
target
=
me
.
getTargetEl
();
// Hack: chrome reset scrollTop to 0, so we save/restore
me
.
savedScrollTop
=
target
.
dom
.
scrollTop
;
if
(
me
.
task
)
{
Ext
.
TaskManager
.
stop
(
me
.
task
);
}
me
.
callParent
(
arguments
);
},
onDestroy
:
function
()
{
var
me
=
this
;
if
(
me
.
task
)
{
Ext
.
TaskManager
.
stop
(
me
.
task
);
}
me
.
callParent
(
arguments
);
},
initComponent
:
function
()
{
var
me
=
this
;
if
(
!
me
.
url
)
{
throw
"
no url specified
"
;
}
me
.
dataCmp
=
Ext
.
create
(
'
Ext.Component
'
,
{
style
:
'
font:normal 11px tahoma, arial, verdana, sans-serif;
'
+
'
line-height:
'
+
me
.
lineHeight
.
toString
()
+
'
px; white-space: pre;
'
});
Ext
.
apply
(
me
,
{
autoScroll
:
true
,
layout
:
'
auto
'
,
items
:
me
.
dataCmp
,
bodyStyle
:
'
padding: 5px;
'
bodyStyle
:
'
padding: 5px;
'
,
listeners
:
{
show
:
function
()
{
var
target
=
me
.
getTargetEl
();
if
(
target
&&
target
.
dom
)
{
target
.
dom
.
scrollTop
=
me
.
savedScrollTop
;
}
},
beforehide
:
function
()
{
// Hack: chrome reset scrollTop to 0, so we save/restore
var
target
=
me
.
getTargetEl
();
if
(
target
&&
target
.
dom
)
{
me
.
savedScrollTop
=
target
.
dom
.
scrollTop
;
}
},
destroy
:
function
()
{
Ext
.
TaskManager
.
stop
(
me
.
task
);
}
}
});
me
.
callParent
();
...
...
www/manager/window/TaskViewer.js
View file @
d98d8f35
...
...
@@ -121,7 +121,9 @@ Ext.define('PVE.window.TaskViewer', {
}]
});
me
.
callParent
();
me
.
callParent
();
logView
.
fireEvent
(
'
show
'
,
logView
);
}
});
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