The variables used by the Media module have been cleaned up, moved into submodules as appropriate and renamespaced accordingly.
Variables were previously set and retrieved using a group of functions which wrapped variable_get()
and variable_set()
. The wrapper functions automatically namespaced media variables by adding a media__
prefix to the variable name and removed the requirement of specifying a default value if the variable has not been set by employing a static list of variable defaults.
In order to improve performance and streamline the Media module, the variable wrapper functions have been removed. With the removal of the wrapper functions, all calls to the media_variable_
functions were replaced with there core equivalents and the media variables were renamed to remove the extra underscore in their namespace prefix.
Before:
media_variable_get('icon_set');
media_variable_set('icon_set', 'custom');
After:
variable_get('media_icon_set', 'default');
variable_set('media_icon_set', 'custom');
With the Bulk Upload, Internet and WYSIWYG functionality split off into submodules, variables have been moved and renamed as appropriate. For example, the media_wysiwyg_title
variable was moved from Media into Media WYSIWYG and had its namespace changed accordingly to media_wysiwyg_wysiwyg_title
.
7.x-2.0-alpha3
Media
- media__wysiwyg_title
- media__wysiwyg_icon_title
- media__wysiwyg_default_view_mode
- media__wysiwyg_upload_directory
- media__wysiwyg_allowed_types
- media__wysiwyg_allowed_attributes
- media__wysiwyg_browser_plugins
- media__dialog_theme
- media__max_filesize
- media__debug
- media__file_list_size
- media__xml_cache_expire
- media__import_batch_size
- media__fromurl_supported_schemes
- media__icon_base_directory
- media__icon_set
- media__show_deprecated_view_modes
- media__show_file_type_rebuild_nag
- media__field_select_media_text
- media__field_remove_media_text
- media__browser_library_empty_message
- media__browser_pager_limit
- media__browser_viewtype_default
- media__display_types_migration_mess
7.x-2.0-alpha4
Media
- media_icon_base_directory
- media_icon_set
- media_show_deprecated_view_modes
Media Bulk Upload
- media_bulk_upload_import_batch_size
Media Internet
- media_internet_fromurl_supported_schemes
Media WYSIWYG
- media_wysiwyg_wysiwyg_title
- media_wysiwyg_wysiwyg_icon_title
- media_wysiwyg_wysiwyg_default_view_mode
- media_wysiwyg_wysiwyg_upload_directory
- media_wysiwyg_wysiwyg_allowed_types
- media_wysiwyg_wysiwyg_allowed_attributes
- media_wysiwyg_wysiwyg_browser_plugins