Update to Drupal 8.0.0-rc3. For more information, see https://www.drupal.org/node/2608078
This commit is contained in:
parent
6419a031d7
commit
4afb23bbd3
762 changed files with 20080 additions and 6368 deletions
|
@ -89,7 +89,7 @@ class LocaleSettingsForm extends ConfigFormBase {
|
|||
}
|
||||
|
||||
/**
|
||||
* Implements \Drupal\Core\Form\FormInterface::validateForm().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function validateForm(array &$form, FormStateInterface $form_state) {
|
||||
parent::validateForm($form, $form_state);
|
||||
|
|
|
@ -54,14 +54,14 @@ class PoDatabaseReader implements PoReaderInterface {
|
|||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\Component\Gettext\PoMetadataInterface::getLangcode().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function getLangcode() {
|
||||
return $this->langcode;
|
||||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\Component\Gettext\PoMetadataInterface::setLangcode().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function setLangcode($langcode) {
|
||||
$this->langcode = $langcode;
|
||||
|
@ -87,7 +87,7 @@ class PoDatabaseReader implements PoReaderInterface {
|
|||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\Component\Gettext\PoMetadataInterface::getHeader().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function getHeader() {
|
||||
return new PoHeader($this->getLangcode());
|
||||
|
@ -162,7 +162,7 @@ class PoDatabaseReader implements PoReaderInterface {
|
|||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\Component\Gettext\PoReaderInterface::readItem().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function readItem() {
|
||||
if ($string = $this->readString()) {
|
||||
|
|
|
@ -68,14 +68,14 @@ class PoDatabaseWriter implements PoWriterInterface {
|
|||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\Component\Gettext\PoMetadataInterface::getLangcode().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function getLangcode() {
|
||||
return $this->langcode;
|
||||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\Component\Gettext\PoMetadataInterface::setLangcode().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function setLangcode($langcode) {
|
||||
$this->langcode = $langcode;
|
||||
|
@ -130,7 +130,7 @@ class PoDatabaseWriter implements PoWriterInterface {
|
|||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\Component\Gettext\PoMetadataInterface::getHeader().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function getHeader() {
|
||||
return $this->header;
|
||||
|
@ -179,7 +179,7 @@ class PoDatabaseWriter implements PoWriterInterface {
|
|||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\Component\Gettext\PoWriterInterface::writeItem().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function writeItem(PoItem $item) {
|
||||
if ($item->isPlural()) {
|
||||
|
@ -190,7 +190,7 @@ class PoDatabaseWriter implements PoWriterInterface {
|
|||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\Component\Gettext\PoWriterInterface::writeItems().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function writeItems(PoReaderInterface $reader, $count = -1) {
|
||||
$forever = $count == -1;
|
||||
|
|
|
@ -18,28 +18,28 @@ use Drupal\locale\LocaleString;
|
|||
*/
|
||||
class SourceString extends StringBase {
|
||||
/**
|
||||
* Implements Drupal\locale\StringInterface::isSource().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function isSource() {
|
||||
return isset($this->source);
|
||||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\locale\StringInterface::isTranslation().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function isTranslation() {
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\locale\LocaleString::getString().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function getString() {
|
||||
return isset($this->source) ? $this->source : '';
|
||||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\locale\LocaleString::setString().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function setString($string) {
|
||||
$this->source = $string;
|
||||
|
@ -47,7 +47,7 @@ class SourceString extends StringBase {
|
|||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\locale\LocaleString::isNew().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function isNew() {
|
||||
return empty($this->lid);
|
||||
|
|
|
@ -40,7 +40,7 @@ class TranslationsStream extends LocalStream {
|
|||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\Core\StreamWrapper\LocalStream::getDirectoryPath()
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
function getDirectoryPath() {
|
||||
return \Drupal::config('locale.settings')->get('translation.path');
|
||||
|
|
|
@ -67,14 +67,14 @@ abstract class StringBase implements StringInterface {
|
|||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\locale\StringInterface::getId().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function getId() {
|
||||
return isset($this->lid) ? $this->lid : NULL;
|
||||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\locale\StringInterface::setId().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function setId($lid) {
|
||||
$this->lid = $lid;
|
||||
|
@ -82,14 +82,14 @@ abstract class StringBase implements StringInterface {
|
|||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\locale\StringInterface::getVersion().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function getVersion() {
|
||||
return isset($this->version) ? $this->version : NULL;
|
||||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\locale\StringInterface::setVersion().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function setVersion($version) {
|
||||
$this->version = $version;
|
||||
|
@ -97,14 +97,14 @@ abstract class StringBase implements StringInterface {
|
|||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\locale\StringInterface::getPlurals().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function getPlurals() {
|
||||
return explode(LOCALE_PLURAL_DELIMITER, $this->getString());
|
||||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\locale\StringInterface::setPlurals().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function setPlurals($plurals) {
|
||||
$this->setString(implode(LOCALE_PLURAL_DELIMITER, $plurals));
|
||||
|
@ -112,14 +112,14 @@ abstract class StringBase implements StringInterface {
|
|||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\locale\StringInterface::getStorage().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function getStorage() {
|
||||
return isset($this->storage) ? $this->storage : NULL;
|
||||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\locale\StringInterface::setStorage().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function setStorage($storage) {
|
||||
$this->storage = $storage;
|
||||
|
@ -127,7 +127,7 @@ abstract class StringBase implements StringInterface {
|
|||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\locale\StringInterface::setValues().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function setValues(array $values, $override = TRUE) {
|
||||
foreach ($values as $key => $value) {
|
||||
|
@ -139,7 +139,7 @@ abstract class StringBase implements StringInterface {
|
|||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\locale\StringInterface::getValues().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function getValues(array $fields) {
|
||||
$values = array();
|
||||
|
@ -152,7 +152,7 @@ abstract class StringBase implements StringInterface {
|
|||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\locale\StringInterface::getLocation().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function getLocations($check_only = FALSE) {
|
||||
if (!isset($this->locations) && !$check_only) {
|
||||
|
@ -165,7 +165,7 @@ abstract class StringBase implements StringInterface {
|
|||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\locale\StringInterface::addLocation().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function addLocation($type, $name) {
|
||||
$this->locations[$type][$name] = TRUE;
|
||||
|
@ -173,7 +173,7 @@ abstract class StringBase implements StringInterface {
|
|||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\locale\StringInterface::hasLocation().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function hasLocation($type, $name) {
|
||||
$locations = $this->getLocations();
|
||||
|
@ -181,7 +181,7 @@ abstract class StringBase implements StringInterface {
|
|||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\locale\LocaleString::save().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function save() {
|
||||
if ($storage = $this->getStorage()) {
|
||||
|
@ -194,7 +194,7 @@ abstract class StringBase implements StringInterface {
|
|||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\locale\LocaleString::delete().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function delete() {
|
||||
if (!$this->isNew()) {
|
||||
|
|
|
@ -45,7 +45,7 @@ class TranslationString extends StringBase {
|
|||
protected $isNew;
|
||||
|
||||
/**
|
||||
* Overrides Drupal\locale\StringBase::__construct().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function __construct($values = array()) {
|
||||
parent::__construct($values);
|
||||
|
@ -72,28 +72,28 @@ class TranslationString extends StringBase {
|
|||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\locale\StringInterface::isSource().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function isSource() {
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\locale\StringInterface::isTranslation().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function isTranslation() {
|
||||
return !empty($this->lid) && !empty($this->language) && isset($this->translation);
|
||||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\locale\StringInterface::getString().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function getString() {
|
||||
return isset($this->translation) ? $this->translation : '';
|
||||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\locale\StringInterface::setString().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function setString($string) {
|
||||
$this->translation = $string;
|
||||
|
@ -101,14 +101,14 @@ class TranslationString extends StringBase {
|
|||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\locale\StringInterface::isNew().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function isNew() {
|
||||
return $this->isNew;
|
||||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\locale\StringInterface::save().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function save() {
|
||||
parent::save();
|
||||
|
@ -117,7 +117,7 @@ class TranslationString extends StringBase {
|
|||
}
|
||||
|
||||
/**
|
||||
* Implements Drupal\locale\StringInterface::delete().
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function delete() {
|
||||
parent::delete();
|
||||
|
|
Reference in a new issue