mirror of
https://github.com/mon/BemaniPatcher.git
synced 2026-08-01 14:10:40 -07:00
Add tooltip support and tooltips
This commit is contained in:
+7
-1
@@ -8,12 +8,18 @@ var StandardPatch = function(options) {
|
||||
this.name = options.name;
|
||||
this.shortname = options.shortname;
|
||||
this.patches = options.patches;
|
||||
this.tooltip = options.tooltip;
|
||||
};
|
||||
|
||||
StandardPatch.prototype.createUI = function(parent) {
|
||||
var id = this.shortname;
|
||||
var label = this.name;
|
||||
parent.append('<div class="patch"><input type="checkbox" id="' + id + '"><label for="' + id + '">' + label + '</label></div>');
|
||||
var patch = $('<div>', {'class' : 'patch'});
|
||||
patch.append('<input type="checkbox" id="' + id + '"><label for="' + id + '">' + label + '</label>');
|
||||
if(this.tooltip) {
|
||||
patch.append('<span class="tooltip">' + this.tooltip + '</div>');
|
||||
}
|
||||
parent.append(patch);
|
||||
};
|
||||
|
||||
StandardPatch.prototype.updateUI = function(file) {
|
||||
|
||||
Reference in New Issue
Block a user