jQuery错误:";this.rc不是一个函数;(例如,在调整大小时使用OpenLayers)
尝试附加调整大小事件时遇到此问题:jQuery错误:";this.rc不是一个函数;(例如,在调整大小时使用OpenLayers),jquery,openlayers-3,Jquery,Openlayers 3,尝试附加调整大小事件时遇到此问题: $( '.ui-resizable' ).resize( map.updateSize ) // causes the error "this.rc is not a function" 使用OpenLayers 3.3.0和jQuery 1.11.3但随后的最终成功了: $( '.ui-resizable' ).resize( function(){ map.updateSize(); } ) 所以我猜map.updateSize对于jQuery来说是
$( '.ui-resizable' ).resize( map.updateSize ) // causes the error "this.rc is not a function"
使用OpenLayers 3.3.0和jQuery 1.11.3但随后的最终成功了:
$( '.ui-resizable' ).resize( function(){ map.updateSize(); } )
所以我猜map.updateSize
对于jQuery来说是一个“不合适的函数”,现在被包装在一些匿名函数中