|
iTx Technologies offre gratuitement
|
||
[Vue de la source] [Imprimer] [Statistique du projet]
(aucune description)
| Taille du fichier: | 1143 lignes (41 kb) |
| Inclus ou requis: | 2 fois |
| Réferencé: | 0 fois |
| Inclus ou requis: | 3 fichiers include/utils/sugar_file_utils.php jssource/jsmin.php include/SugarTheme/cssmin.php |
SugarTheme:: (26 methods):
__construct()
__destruct()
__toString()
__get()
__isset()
clearCache()
getThemeDefFields()
getFilePath()
getImagePath()
getCSSPath()
getJSPath()
getTemplatePath()
getDefaultFilePath()
getDefaultImagePath()
getDefaultCSSPath()
getDefaultTemplatePath()
getDefaultJSPath()
getCSS()
getJS()
getTemplate()
getImage()
getImageURL()
_getImageFileName()
getCSSURL()
getJSURL()
getAllImages()
SugarThemeRegistry:: (12 methods):
__construct()
add()
remove()
get()
current()
exists()
set()
buildRegistry()
availableThemes()
unAvailableThemes()
allThemes()
clearAllCaches()
Classe: SugarTheme - X-Ref
Class that provides tools for working with a theme.| __construct($defaults) X-Ref |
| Constructor Sets the theme properties from the defaults passed to it, and loads the file path cache from an external cache param: $defaults string defaults for the current theme |
| __destruct() X-Ref |
| Destructor Here we'll write out the internal file path caches to an external cache of some sort. |
| __toString() X-Ref |
| Specifies what is returned when the object is cast to a string, in this case it will be the theme directory name. return: string theme directory name |
| __get($key) X-Ref |
| Generic public accessor method for all the properties of the theme ( which are kept protected ) return: string |
| __isset($key) X-Ref |
| Aucune description |
| clearCache() X-Ref |
| Clears out the caches used for this themes |
| getThemeDefFields() X-Ref |
| Return array of all valid fields that can be specified in the themedef.php file return: array |
| getFilePath() X-Ref |
| Returns the file path of the current theme return: string |
| getImagePath() X-Ref |
| Returns the image path of the current theme return: string |
| getCSSPath() X-Ref |
| Returns the css path of the current theme return: string |
| getJSPath() X-Ref |
| Returns the javascript path of the current theme return: string |
| getTemplatePath() X-Ref |
| Returns the tpl path of the current theme return: string |
| getDefaultFilePath() X-Ref |
| Returns the file path of the theme defaults return: string |
| getDefaultImagePath() X-Ref |
| Returns the image path of the theme defaults return: string |
| getDefaultCSSPath() X-Ref |
| Returns the css path of the theme defaults return: string |
| getDefaultTemplatePath() X-Ref |
| Returns the template path of the theme defaults return: string |
| getDefaultJSPath() X-Ref |
| Returns the javascript path of the theme defaults return: string |
| getCSS($color = null,$font = null) X-Ref |
| Returns CSS for the current theme. param: $color string optional, specifies the css color file to use if the theme supports it; defaults to cookie value or theme default param: $font string optional, specifies the css font file to use if the theme supports it; defaults to cookie value or theme default return: string HTML code |
| getJS() X-Ref |
| Returns javascript for the current theme return: string HTML code |
| getTemplate($templateName) X-Ref |
| Returns the path for the tpl file in the current theme. If not found in the current theme, will revert to looking in the base theme. param: string $templateName tpl file name return: string path of tpl file to include |
| getImage($imageName,$other_attributes = '',$width = null,$height = null) X-Ref |
| Returns an image tag for the given image. param: string $image image name param: string $other_attributes optional, other attributes to add to the image tag, not cached param: string $width optional, defaults to the actual image's width param: string $height optional, defaults to the actual image's height return: string HTML image tag |
| getImageURL($imageName,$addJSPath = true) X-Ref |
| Returns the URL for an image in the current theme. If not found in the current theme, will revert to looking in the base theme. param: string $imageName image file name param: bool $addJSPath call getJSPath() with the results to add some unique image tracking support return: string path to image |
| _getImageFileName($imageName) X-Ref |
| Checks for an image using all of the accepted image extensions param: string $imageName image file name return: string path to image |
| getCSSURL($cssFileName,$addJSPath = true) X-Ref |
| Returns the URL for the css file in the current theme. If not found in the current theme, will revert to looking in the base theme. param: string $cssFileName css file name param: bool $addJSPath call getJSPath() with the results to add some unique image tracking support return: string path of css file to include |
| getJSURL($jsFileName,$addJSPath = true) X-Ref |
| Returns the URL for an image in the current theme. If not found in the current theme, will revert to looking in the base theme. param: string $jsFileName js file name param: bool $addJSPath call getJSPath() with the results to add some unique image tracking support return: string path to js file |
| getAllImages() X-Ref |
| Returns an array of all of the images available for the current theme return: array |
Classe: SugarThemeRegistry - X-Ref
Registry for all the current classes in the system| __construct() X-Ref |
| Disable the constructor since this will be a singleton |
| add(array $themedef) X-Ref |
| Adds a new theme to the registry param: $themedef array |
| remove($themeName) X-Ref |
| Removes a new theme from the registry param: $themeName string |
| get($themeName) X-Ref |
| Returns a theme object in the registry specified by the given $themeName param: $themeName string |
| current() X-Ref |
| Returns the current theme object |
| exists($themeName) X-Ref |
| Returns true if a theme object specified by the given $themeName exists in the registry param: $themeName string return: bool |
| set($themeName) X-Ref |
| Sets the given $themeName to be the current theme param: $themeName string |
| buildRegistry() X-Ref |
| Builds the theme registry |
| availableThemes() X-Ref |
| Returns an array of available themes. Designed to be absorbed into get_select_options_with_id() return: array |
| unAvailableThemes() X-Ref |
| Returns an array of un-available themes. Designed used with the theme selector in the admin panel return: array |
| allThemes() X-Ref |
| Returns an array of all themes found in the current installation return: array |
| clearAllCaches() X-Ref |
| Clears out the cached path locations for all themes |
|
|
|
|