Skip to content

Instantly share code, notes, and snippets.

@Jiiks
Created April 24, 2016 17:38
Show Gist options
  • Save Jiiks/3f68f9578dc0cbdfdfa69290924545a6 to your computer and use it in GitHub Desktop.
Save Jiiks/3f68f9578dc0cbdfdfa69290924545a6 to your computer and use it in GitHub Desktop.
bg image plugin
//META{"name":"bgImage"}*//
var bgImage = function () {};
bgImage.prototype.start = function () {
if($("#bgimage").length <= 0) {
$(".app").append($("<div/>", {id: "bgimage"}));
}
};
bgImage.prototype.load = function () {
if($("#bgimage").length <= 0) {
$(".app").append($("<div/>", {id: "bgimage"}));
}
};
bgImage.prototype.unload = function () {}
;
bgImage.prototype.stop = function () {
};
bgImage.prototype.onMessage = function () {
//called when a message is received
};
bgImage.prototype.onSwitch = function () {
//called when a server or channel is switched
};
bgImage.prototype.observer = function (e) {
//raw MutationObserver event for each mutation
};
bgImage.prototype.getSettingsPanel = function () {
return "<h3>Settings Panel</h3>";
};
bgImage.prototype.getName = function () {
return "Bg Image";
};
bgImage.prototype.getDescription = function () {
return "Add a bg image container";
};
bgImage.prototype.getVersion = function () {
return "0.1.0";
};
bgImage.prototype.getAuthor = function () {
return "Jiiks";
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment