You are here

public function ThemeGenerator::replaceSkinLogos in AT Tools 8.2

Same name and namespace in other branches
  1. 8.3 at_theme_generator/src/Theme/ThemeGenerator.php \Drupal\at_theme_generator\Theme\ThemeGenerator::replaceSkinLogos()

Copy logos from the skin source/base to the skin theme.

1 call to ThemeGenerator::replaceSkinLogos()
ThemeGeneratorTypes::skinGenerator in at_theme_generator/src/Theme/ThemeGeneratorTypes.php
Generate skin type theme.

File

at_theme_generator/src/Theme/ThemeGenerator.php, line 446

Class

ThemeGenerator
Generator form.

Namespace

Drupal\at_theme_generator\Theme

Code

public function replaceSkinLogos() {
  $skin_base_path = drupal_get_path('theme', $this->skin_base);
  foreach ([
    'svg',
    'png',
  ] as $ext) {
    $logo = $skin_base_path . '/logo.' . $ext;
    if (file_exists($logo)) {
      file_unmanaged_copy($logo, $this->target, FILE_EXISTS_REPLACE);
    }
  }
}