⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 mapmove.js

📁 该程序详细的介绍了MapXtreme J的环境设置和基本操作。感觉不错
💻 JS
字号:
function box(){
	var newx
	var newy
	var framehigh
	var framewidth
	var frametop
	var frameleft
	framehigh=parseInt(document.all.mapframe.style.height)
	framewidth=parseInt(document.all.mapframe.style.width)
	frametop=parseInt(document.all.mapframe.style.top)
	frameleft=parseInt(document.all.mapframe.style.left)
	if(window.event.clientX>(frameleft+framewidth-2)){
		newx=frameleft+framewidth-2
	}
	else if(window.event.clientX<(frameleft+1)){
		newx=frameleft+1
	}
	else{
		newx=window.event.clientX
	}
	if(window.event.clientY>(frametop+framehigh-2)){
		newy=frametop+framehigh-2
	}
	else if(window.event.clientY<(frametop+1)){
		newy=frametop+1
	}
	else{
		newy=window.event.clientY
	}
	width=newx-oldx
	height=newy-oldy
	if(width<0&&height<0){
		document.all.seltable.style.left=newx
		document.all.seltable.style.top=newy
	}
	else if(width<0){
		document.all.seltable.style.left=newx
	}
	else if(height<0){
		document.all.seltable.style.top=newy
	}
	document.all.seltable.style.height=Math.abs(height)+1
	document.all.seltable.style.width=Math.abs(width)+1
}

function pan(){
	var newx
	var newy
	var picwidth
	var pichigh
	picwidth=parseInt(document.all.imgmap.style.width)
	pichigh=parseInt(document.all.imgmap.style.height)
	newx=startx+(window.event.clientX-oldx)
	newy=starty+(window.event.clientY-oldy)
	if (newx>picwidth) newx=picwidth
	if (newx<-picwidth) newx=-picwidth
	if (newy>pichigh) newy=pichigh
	if (newy<-pichigh) newy=-pichigh
	document.all.imgmap.style.left=newx
	document.all.imgmap.style.top=newy
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -