* @link http://wp-dreams.com, http://codecanyon.net/user/anago/portfolio
* @copyright Copyright (c) 2018, Ernest Marcinko
*/
private $is_gradient, $grad_type, $leftcolor, $rightcolor, $rotation;
function getType() {
parent::getType();
$this->processData();
?>
leftcolor);
new wpdreamsColorPickerDummy('rightcolor_' . self::$_instancenumber, "", $this->rightcolor);
?>
data = str_replace("\n", "", $this->data);
if ( preg_match("/(.*?)-(.*?)-(.*?)-(.*)/", $this->data, $matches) ) {
$this->grad_type = $matches[1];
$this->rotation = $matches[2];
if ($this->rotation == null || $this->rotation == '') $this->rotation = 0;
$this->leftcolor = wpdreams_admin_hex2rgb($matches[3]);
$this->rightcolor = wpdreams_admin_hex2rgb($matches[4]);
} else {
$this->grad_type = 0;
$this->rotation = 180;
$this->leftcolor = $this->data;
$this->rightcolor = $this->data;
}
$this->data = $this->grad_type . '-' . $this->rotation . '-' . $this->leftcolor . '-' . $this->rightcolor;
}
final function getData() {
return $this->data;
}
}
}