Skip to content

YY. Control

控件抽象类,一般项目中用不到,主要用来进行插件开发

creation

  • constructor(options)

method

getMap()

getPosition()

  • 获取位置
  • 返回值: Object

setPosition(position)

  • 设置位置
  • 参数
    • {String||Object} position: 'top-left','top-right','bottom-left','bottom-right' 或者 {top:40px,right:20px},.............
  • 返回值: this

getContainer()

  • 获取所在的 Dom 容器
  • 返回值: Dom

getDOM()

  • 获取自身的 dom 元素
  • 返回值: Dom

show()

控件的显示和隐藏

  • 显示
  • 返回值: this

hide()

控件的显示和隐藏

  • 隐藏
  • 返回值: this

isVisible()

  • 是否可见
  • 返回值: Boolean

remove()

  • 移除
  • 返回值: this

This document is generated by vitepress and Edit by deyihu