[Basilisk] Issue MoonchildProductions/UXP#516 - Remove named function syntax from basilisk/base.

This commit is contained in:
athenian200 2020-03-06 10:24:34 -06:00 committed by Roy Tam
commit b31901aa3f
24 changed files with 294 additions and 294 deletions

View file

@ -15,7 +15,7 @@ var gPage = {
/**
* Initializes the page.
*/
init: function Page_init() {
init: function() {
// Add ourselves to the list of pages to receive notifications.
gAllPages.register(this);
@ -41,7 +41,7 @@ var gPage = {
/**
* Listens for notifications specific to this page.
*/
observe: function Page_observe(aSubject, aTopic, aData) {
observe: function(aSubject, aTopic, aData) {
if (aTopic == "nsPref:changed") {
gCustomize.updateSelected();
@ -100,7 +100,7 @@ var gPage = {
* Internally initializes the page. This runs only when/if the feature
* is/gets enabled.
*/
_init: function Page_init() {
_init: function() {
if (this._initialized)
return;
@ -137,7 +137,7 @@ var gPage = {
* Updates the 'page-disabled' attributes of the respective DOM nodes.
* @param aValue Whether the New Tab Page is enabled or not.
*/
_updateAttributes: function Page_updateAttributes(aValue) {
_updateAttributes: function(aValue) {
// Set the nodes' states.
let nodeSelector = "#newtab-grid, #newtab-search-container";
for (let node of document.querySelectorAll(nodeSelector)) {
@ -160,14 +160,14 @@ var gPage = {
/**
* Handles unload event
*/
_handleUnloadEvent: function Page_handleUnloadEvent() {
_handleUnloadEvent: function() {
gAllPages.unregister(this);
},
/**
* Handles all page events.
*/
handleEvent: function Page_handleEvent(aEvent) {
handleEvent: function(aEvent) {
switch (aEvent.type) {
case "load":
this.onPageVisibleAndLoaded();