Plugin Directory

Changeset 2592120


Ignore:
Timestamp:
09/01/2021 01:39:28 PM (4 years ago)
Author:
veks
Message:

обновление 2.3.0

Location:
button-visually-impaired/trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • button-visually-impaired/trunk/Button-visually-impaired.php

    r2592115 r2592120  
    7171     */
    7272    register_activation_hook( BVI_FILE, function () {
    73         Bvi\Core\Activate::getInstance()->registerActive();
     73        Bvi\Core\Activate::getInstance()->activation();
    7474    } );
    7575}
  • button-visually-impaired/trunk/include/src/Core/Activate.php

    r2592115 r2592120  
    3838         * Activate plugin.
    3939         */
    40         public function registerActive() {
    41             $this->setOption( Option::getInstance()->options() )->registerOption();
     40        public function activation() {
     41            $this->setOption( [
     42                'bviActive'         => 'false',
     43                'bviScriptLocation' => 'false',
     44                'bviTheme'          => 'white',
     45                'bviFont'           => 'arial',
     46                'bviFontSize'       => '16',
     47                'bviLetterSpacing'  => 'normal',
     48                'bviLineHeight'     => 'normal',
     49                'bviImages'         => 'true',
     50                'bviReload'         => 'false',
     51                'bviSpeech'         => 'true',
     52                'bviBuiltElements'  => 'true',
     53                'bviPanelHide'      => 'false',
     54                'bviPanelFixed'     => 'true',
     55                'bviLang'           => 'ru-RU',
     56                'bviLinkText'       => 'Версия сайта для слабовидящих',
     57                'bviLinkColor'      => '#ffffff',
     58                'bviLinkBg'         => '#e53935',
     59            ] )->registerOption();
    4260        }
    4361    }
  • button-visually-impaired/trunk/include/src/Core/Upgrade.php

    r2592116 r2592120  
    6161        public function updatePlugin() {
    6262            if ( get_transient( 'bvi_updated' ) && current_user_can( 'administrator' ) ) {
    63                 $this->setOption( Option::getInstance()->options() )->registerOption();
     63                Activate::getInstance()->activation();
    6464            }
    6565        }
Note: See TracChangeset for help on using the changeset viewer.