1717 *******/
1818
1919/*
20- * ClassLoaderProgressMonitor is optional for show classes loading progress.
20+ * ClassLoaderProgressMonitor is optional. It's used to display class loading
21+ * progress so that user know that background loading is still processing.
2122 *
2223 * Example:
23- <script type="text/javascript" src="../net.sf.j2s.java.core/src/java/lang/ClassLoaderProgressMonitor.js"></script>
24+ <script type="text/javascript"
25+ src="../net.sf.j2s.java.core/src/java/lang/ClassLoaderProgressMonitor.js">
26+ </script>
2427<script>
2528...
2629ClazzLoader.scriptLoading = function (file) {
@@ -29,9 +32,9 @@ ClazzLoader.scriptLoading = function (file) {
2932ClazzLoader.scriptLoaded = function (file) {
3033 ClassLoaderProgressMonitor.showStatus (file + " loaded.", true);
3134};
32- ClazzLoader.loadClass ("org.java2script.notepad .Notepad", function () {
33- ClassLoaderProgressMonitor.showStatus("org.java2script.notepad .Notepad loaded.", true);
34- org.java2script.notepad .Notepad.main([]);
35+ ClazzLoader.loadClass ("com.example .Notepad", function () {
36+ ClassLoaderProgressMonitor.showStatus("com.example .Notepad loaded.", true);
37+ com.example .Notepad.main([]);
3538});
3639</script>
3740 */
@@ -62,16 +65,17 @@ clpm.DEFAULT_OPACITY = 75;
6265 this . fadeOutTimer = null ;
6366 }
6467 this . fadeAlpha = alpha ;
65- if ( navigator . userAgent . toString ( ) . toLowerCase ( ) . indexOf ( "msie" ) != - 1 ) {
68+ if ( navigator . userAgent . toLowerCase ( ) . indexOf ( "msie" ) != - 1 ) {
6669 this . monitorEl . style . filter = "Alpha(Opacity=" + alpha + ")" ;
6770 } else {
6871 this . monitorEl . style . opacity = alpha / 100.0 ;
6972 }
7073} ;
7174/* private */ clpm . createHandle = function ( ) {
7275 var div = document . createElement ( "DIV" ) ;
73- div . style . cssText = "position:absolute;top:4px;left:4px;padding:2px 8px;z-index:3333;"
74- + "background-color:#8e0000;color:yellow;font-family:Arial, sans-serif;" ;
76+ div . style . cssText = "position:absolute;top:4px;left:4px;padding:2px 8px;"
77+ + "z-index:3333;background-color:#8e0000;color:yellow;"
78+ + "font-family:Arial, sans-serif;white-space:nowrap;" ;
7579 div . onmouseover = function ( ) {
7680 this . style . display = "none" ;
7781 } ;
@@ -111,7 +115,8 @@ clpm.DEFAULT_OPACITY = 75;
111115 if ( dua . indexOf ( "Opera" ) == - 1 && document . all ) {
112116 return ( pcHeight == 0 ) ? bcScrollTop : pcScrollTop ;
113117 } else if ( dua . indexOf ( "Gecko" ) != - 1 ) {
114- return ( pcHeight == p . offsetHeight && pcHeight == p . scrollHeight ) ? bcScrollTop : pcScrollTop ;
118+ return ( pcHeight == p . offsetHeight
119+ && pcHeight == p . scrollHeight ) ? bcScrollTop : pcScrollTop ;
115120 }
116121 return bcScrollTop ;
117122} ;
0 commit comments