+switch (getExtensionMode()) {
+ case 'register': // Do stuff when installation is running
+ // Remove all other themes
+ addExtensionSql("DELETE LOW_PRIORITY FROM `{?_MYSQL_PREFIX?}_extensions` WHERE ext_name LIKE 'admintheme%'");
+ addExtensionSql("UPDATE `{?_MYSQL_PREFIX?}_admin_menu` SET `action`='stats' WHERE `what`='usr_online'");
+ addExtensionSql("UPDATE `{?_MYSQL_PREFIX?}_admin_menu` SET `action`='stats' WHERE `what`='email_stats'");
+ addExtensionSql("UPDATE `{?_MYSQL_PREFIX?}_admin_menu` SET `action`='misc' WHERE `what`='maintenance'");
+ break;
+
+ case 'remove': // Do stuff when removing extension
+ // SQL commands to run
+ addExtensionSql('');
+ break;