SimpleMachines/SMF2.1 — pull request #923 by MissAllSunday (2013-11-20 23:21:24+00:00)
Title: Theme stuff

A bigger refactor for installing and overall handling themes.

- Separates the 3 options to install themes into 3 different functions.
- Adds a helper file with, well, helper functions.
- Adds more checks for common mistakes.
- Removes some old code when copying a file from another based on theme, I haven't see any theme based on another then other than the default one so the copy a file feature goes straight to the default theme now.
- A couple of hooks, just because.
- Saves some queries on specific cases, no more inner joins either.
- A small template change to separate the 3 install options.
- Adds a enable/disable feature, themes marked as enable will be the only ones eligibles to use.
- When deleting a theme it also gets deleted from the Themes folder.
- Sets $modSettings['enableThemes'] for a quick and easy way to get all enabled themes.
- The version tag now holds the theme version rather than the forum's one.
- Themes made for 2.0 or lower would not be installed.
- Themes now require a tag.
- When a theme is installed via a package, it gets dumped on a temp dir first, if the install fails it gets removed, on success it renames the temp dir to the new theme's name.