mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/RevisionSlider
synced 2024-11-15 11:40:43 +00:00
f5d9347d93
Bug: T135837 Change-Id: I0ccc34751765f1f98dd29426d4efb3f3419f3932
33 lines
558 B
JavaScript
33 lines
558 B
JavaScript
( function ( mw, $ ) {
|
|
var Pointer = function ( id ) {
|
|
this.view = new mw.libs.revisionSlider.PointerView( this, id );
|
|
};
|
|
|
|
$.extend( Pointer.prototype, {
|
|
/**
|
|
* @type {int}
|
|
*/
|
|
position: 0,
|
|
|
|
/**
|
|
* @type {PointerView}
|
|
*/
|
|
view: null,
|
|
|
|
setPosition: function ( p ) {
|
|
this.position = p;
|
|
},
|
|
|
|
getPosition: function () {
|
|
return this.position;
|
|
},
|
|
|
|
getView: function () {
|
|
return this.view;
|
|
}
|
|
} );
|
|
|
|
mw.libs.revisionSlider = mw.libs.revisionSlider || {};
|
|
mw.libs.revisionSlider.Pointer = Pointer;
|
|
}( mediaWiki, jQuery ) );
|