mirror of
https://github.com/chillerlan/php-qrcode.git
synced 2026-08-27 18:48:13 +00:00
:octocat: added QRMatrix::M_*_DARK constants for convenience
This commit is contained in:
@@ -18,32 +18,32 @@ try{
|
||||
|
||||
$moduleValues = [
|
||||
// finder
|
||||
(QRMatrix::M_FINDER | QRMatrix::IS_DARK) => $_POST['m_finder_dark'],
|
||||
QRMatrix::M_FINDER => $_POST['m_finder_light'],
|
||||
(QRMatrix::M_FINDER_DOT | QRMatrix::IS_DARK) => $_POST['m_finder_dot_dark'],
|
||||
QRMatrix::M_FINDER_DARK => $_POST['m_finder_dark'],
|
||||
QRMatrix::M_FINDER_DOT => $_POST['m_finder_dot_dark'],
|
||||
QRMatrix::M_FINDER => $_POST['m_finder_light'],
|
||||
// alignment
|
||||
(QRMatrix::M_ALIGNMENT | QRMatrix::IS_DARK) => $_POST['m_alignment_dark'],
|
||||
QRMatrix::M_ALIGNMENT => $_POST['m_alignment_light'],
|
||||
QRMatrix::M_ALIGNMENT_DARK => $_POST['m_alignment_dark'],
|
||||
QRMatrix::M_ALIGNMENT => $_POST['m_alignment_light'],
|
||||
// timing
|
||||
(QRMatrix::M_TIMING | QRMatrix::IS_DARK) => $_POST['m_timing_dark'],
|
||||
QRMatrix::M_TIMING => $_POST['m_timing_light'],
|
||||
QRMatrix::M_TIMING_DARK => $_POST['m_timing_dark'],
|
||||
QRMatrix::M_TIMING => $_POST['m_timing_light'],
|
||||
// format
|
||||
(QRMatrix::M_FORMAT | QRMatrix::IS_DARK) => $_POST['m_format_dark'],
|
||||
QRMatrix::M_FORMAT => $_POST['m_format_light'],
|
||||
QRMatrix::M_FORMAT_DARK => $_POST['m_format_dark'],
|
||||
QRMatrix::M_FORMAT => $_POST['m_format_light'],
|
||||
// version
|
||||
(QRMatrix::M_VERSION | QRMatrix::IS_DARK) => $_POST['m_version_dark'],
|
||||
QRMatrix::M_VERSION => $_POST['m_version_light'],
|
||||
QRMatrix::M_VERSION_DARK => $_POST['m_version_dark'],
|
||||
QRMatrix::M_VERSION => $_POST['m_version_light'],
|
||||
// data
|
||||
(QRMatrix::M_DATA | QRMatrix::IS_DARK) => $_POST['m_data_dark'],
|
||||
QRMatrix::M_DATA => $_POST['m_data_light'],
|
||||
QRMatrix::M_DATA_DARK => $_POST['m_data_dark'],
|
||||
QRMatrix::M_DATA => $_POST['m_data_light'],
|
||||
// darkmodule
|
||||
(QRMatrix::M_DARKMODULE | QRMatrix::IS_DARK) => $_POST['m_darkmodule_dark'],
|
||||
QRMatrix::M_DARKMODULE => $_POST['m_darkmodule_dark'],
|
||||
// separator
|
||||
QRMatrix::M_SEPARATOR => $_POST['m_separator_light'],
|
||||
QRMatrix::M_SEPARATOR => $_POST['m_separator_light'],
|
||||
// quietzone
|
||||
QRMatrix::M_QUIETZONE => $_POST['m_quietzone_light'],
|
||||
QRMatrix::M_QUIETZONE => $_POST['m_quietzone_light'],
|
||||
// logo
|
||||
QRMatrix::M_LOGO => $_POST['m_logo_light'],
|
||||
QRMatrix::M_LOGO => $_POST['m_logo_light'],
|
||||
];
|
||||
|
||||
$moduleValues = array_map(function($v){
|
||||
|
||||
Reference in New Issue
Block a user