Downloads

Download tar.gz 22.66 KB
MD5: c36ad28cb07f55446b8812f3df8a922c
SHA-1: 300c719032f1f50fd06b0ce0a895a591aaa6f0e4
SHA-256: ba544e0bc2fdf829631cefd5980c57895777fac1c4f2152a2e5b3cae0720a8a0
Download zip 30.96 KB
MD5: 9f7b1520c35e182040f6474cb6c5e1bc
SHA-1: 258487af2062204d95c17a360f6607e1b24a91d5
SHA-256: 4ad33c556631100a7f43aed5701cac06ee9dbea1efef2d1733cc97b4eaf4fc46

Release notes

Notes

While thinking about feature request #625176: Let admin adjust path and property weight we realized that it's implementation will require fundamental changes to ThemeKey's architecture.
That's why we started a new branch to develop ThemeKey 6.x-2.x. Now it's time to release the first alpha version of ThemeKey 6.x-2.0.

These are the major changes to ThemeKey's architecture and API:

  • ThemeKey's theme switching rules consisted of two parts: custom paths and properties. First custom paths had been checked for matches against the current path to apply a custom theme. Only if no path matched, rules based on properties were applied. Beside this disadvantage the order in which paths or properties were checked depended on hardcoded wighting functions.
    ThemeKey 6.x-2.x removes the separation of custom paths from properties. Custom paths are now treated like properties. Therefor a new property called drupal:path was introduced. Using this approach it was also possible to kick out all the hardcoded wighting functions and replace them by the implementation of feature request #625176: Let admin adjust path and property weight.
  • Along with the removal of the hardcoded wighting functions hook_themekey_properties() has been changed accordingly. The attributes related to wighting called 'multiple' and 'weight' had been removed.
  • Within ThemeKey 6.x-2.x it's not required anymore to turn every single property on or off. Now ThemeKey automatically detects which properties are in use and detects the values for the properties right when they're needed
  • Within ThemeKey 6.x-2.x it's possible to enable or disable Theme Switching Rules. So if you want to turn of a rule temporally you don't need to delete it anymore.

For those who're still using ThemeKey 6.x-1.1 I'll repeat some major changes introduced by ThemeKey 6.x-1.2 which is currently in beta state. These changes are part of ThemeKey 6.x-2.x as well:

  • ThemeKey UI has been completely rewritten. Themes assigned to nodes are no longer stored as ThemeKey properties or paths but in a new table called themekey_ui_node_theme. The information is now handled via regular usage of hook_nodeapi. This is the only way to keep the feature scale with a large amount of nodes using it. This change also introduces full support of drupal's node revision system! If you already use ThemeKey UI all your ThemeKey properties related to this feature will be migrated automatically. BTW ThemeKey UI is not a perfect name for this additional module anymore but I decided to keep it.
  • The ThemeKey property value detection algorithm wasn't very smart and contained some hacks. For beta5 this algorithm was completely replaced by a new recursive one which should be faster and don't require any new hacks for new properties in the future.
  • "Discover all node properties for selection" was incompatible to some modules. In the worst case it caused fatal errors. I didn't see any chance to reimplement it in a robust way until the final release 6.x-1.2. Additionally I don't really see the usage of this feature for a wide range of users. So I decided to simply remove it from ThemeKey. For those who need it, it will be easier and more safe for their drupal installation to implement a special property using ThemeKey's API instead of keeping the old dangerous generic approach.
  • There was an internal feature for turning attributes of common objects into ThemeKey properties. Until now this feature was only used for node objects. But it turned out that the generic algorithm was erroneous if it was used for different kind of objects. So I decided to turn the generic implementation into a specific one fore node objects to get rid of potential bugs if someone uses this API

Feedback is still welcome! Especially from long time users of ThemeKey ...

Bug Fixes

New Features

Created by: mkalkbrenner
Created on: 24 Nov 2009 at 22:01 UTC
Last updated: 25 Nov 2009 at 09:03 UTC
New features
Unsupported

Other releases