protected function _cssBackground()
{
- $body = '';
-
- if ($this->_themeBoolean($this->theme->parametres->displayBackgroundDuringLoading)) {
- $body .= '#background,#splash{background-color:' . wsHTML5::colorToCSS($this->theme->parametres->backgroundColor) . ' !important;}';
- } else {
- $body .= '#background{transition:500ms opacity;visibility:hidden;opacity:0;background-color:' . wsHTML5::colorToCSS($this->theme->parametres->backgroundColor) . ' !important;}';
- $body .= '#splash{background-color:' . wsHTML5::colorToCSS($this->theme->parametres->loadingBackColor) . ' !important;}';
- }
-
- $body .= '#background,#splash{';
+ $body = '#background, #splash {';
switch ($this->theme->parametres->repeat) {
case wsTheme::REPEAT:
$body .= 'background-size:100% 100%;';
break;
}
+
if ($bi = $this->checkThemeImage($this->theme->parametres->backgroundImage)) {
$dbi = CubeIT_Image::getimagesize($bi);
$body .= 'bottom';
break;
}
+
$body .= ' ';
+
switch ($this->theme->parametres->backgroundHAlign) {
case wsTheme::LEFT:
$body .= 'left';
$body .= '}';
+
+ if ($this->_themeBoolean($this->theme->parametres->displayBackgroundDuringLoading)) {
+ $body .= '#background, #splash {
+ background-color:' . wsHTML5::colorToCSS($this->theme->parametres->backgroundColor) . ' !important;
+ }';
+ } else {
+ $body .= '#background {
+ transition: 500ms opacity;
+ visibility: hidden;
+ opacity: 0;
+ background-color:' . wsHTML5::colorToCSS($this->theme->parametres->backgroundColor) . ' !important;
+ }';
+
+ $body .= '#splash {
+ background-color:' . wsHTML5::colorToCSS($this->theme->parametres->loadingBackColor) . ' !important;
+ background-image: none;
+ }';
+ }
+
return $body;
}