相关疑难解决方法(0)

继承自jQuery UI对话框并调用重写方法

下面的简单代码描述了我的问题(至少我跳过这样):

$.widget("ui.mydialog", $.ui.dialog, {
  _create: function() {
    // How to call _create method of dialog?
  }
});
Run Code Online (Sandbox Code Playgroud)

我尝试$.ui.dialog.prototype._create()从上面的create方法中调用,但在Firebug中得到以下错误:

this.element is undefined
this.originalTitle = this.element.attr('title');
jquery...5667348 (line 5864)
Run Code Online (Sandbox Code Playgroud)

我怎么称呼那种"超级"方法呢?

jQuery UI版本1.8.8

javascript jquery inheritance overriding jquery-ui

7
推荐指数
1
解决办法
6872
查看次数

标签 统计

inheritance ×1

javascript ×1

jquery ×1

jquery-ui ×1

overriding ×1