Skip to content

Commit

Permalink
Added a option to disable the delete button
Browse files Browse the repository at this point in the history
  • Loading branch information
poldixd committed Feb 26, 2020
1 parent 46237d9 commit 313e128
Show file tree
Hide file tree
Showing 8 changed files with 13 additions and 0 deletions.
1 change: 1 addition & 0 deletions config/config.inc.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
$config['use_filter'] = true;
$config['default_imagefilter'] = 'plain';
$config['disabled_filters'] = array();
$config['allow_delete'] = true;
$config['polaroid_effect'] = false;
$config['polaroid_rotation'] = '0';
$config['take_frame'] = false;
Expand Down
2 changes: 2 additions & 0 deletions index.php
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,9 @@
<a href="#" class="btn imageFilter"><i class="fa fa-magic"></i> <span data-l10n="selectFilter"></span></a>
<?php endif; ?>

<?php if ($config['allow_delete']): ?>
<a href="#" class="btn deletebtn"><i class="fa fa-trash"></i> <span data-l10n="delete"></span></a>
<?php endif; ?>
</div>

<?php if ($config['use_qr']): ?>
Expand Down
5 changes: 5 additions & 0 deletions lib/configsetup.inc.php
Original file line number Diff line number Diff line change
Expand Up @@ -200,6 +200,11 @@
'environment' => 'Back facing camera'
],
'value' => $config['camera_mode']
],
'allow_delete' => [
'type' => 'checkbox',
'name' => 'allow_delete',
'value' => $config['allow_delete']
]
],
'jpeg_quality' => [
Expand Down
1 change: 1 addition & 0 deletions resources/lang/de.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ const L10N = {
'general_default_imagefilter': 'Standardbildfilter',
'default_imagefilter': 'Bildfilter auswählen',
'general_disabled_filters': 'Deaktivierte Bildfilter',
'allow_delete': 'Löschen des Bildes erlauben',
'general_collage_cntdwn_time': 'Collage-Countdown Timer in Sekunden',
'continuous_collage': 'Collage ohne Unterbrechung aufnehmen',
'delete': 'Löschen',
Expand Down
1 change: 1 addition & 0 deletions resources/lang/en.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ const L10N = {
'general_default_imagefilter': 'Default image filter',
'default_imagefilter': 'Choose image filter',
'general_disabled_filters': 'Disabled image filters',
'allow_delete': 'Allow deletion of the image',
'general_collage_cntdwn_time': 'Collage-countdown timer in seconds',
'continuous_collage': 'Take collage without interruption',
'delete': 'Delete',
Expand Down
1 change: 1 addition & 0 deletions resources/lang/es.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ const L10N = {
'general_default_imagefilter': 'Filtro de imagen predeterminado',
'default_imagefilter': 'Elegir filtro de imagen',
'general_disabled_filters': 'Filtros deshabilitados',
'allow_delete': 'Permitir la eliminación de la imagen',
'general_collage_cntdwn_time': 'Cuenta regresiva del collage en segundos',
'continuous_collage': 'Toma collage sin interrupción',
'delete': 'Eliminar',
Expand Down
1 change: 1 addition & 0 deletions resources/lang/fr.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ const L10N = {
'general_default_imagefilter': 'Filtre d\'image par défaut',
'default_imagefilter': 'Choisissez le filtre d\'image',
'general_disabled_filters': 'Filtres désactivés',
'allow_delete': 'Autoriser la suppression de l\'image',
'general_collage_cntdwn_time': 'Montage photo compte à rebours en secondes',
'continuous_collage': 'Prendre un photo montage sans interruption',
'delete': 'Effacer',
Expand Down
1 change: 1 addition & 0 deletions resources/lang/gr.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ const L10N = {
'general_default_imagefilter': 'Προεπιλεγμένο φίλτρο εικόνας',
'default_imagefilter': 'Επιλέξτε φίλτρο εικόνας',
'general_disabled_filters': 'Απενεργοποιημένα φίλτρα',
'allow_delete': 'Επιτρέψτε τη διαγραφή της εικόνας',
'general_collage_cntdwn_time': 'Χρονοδιακόπτης αντίστροφης μέτρησης φωτογραφιών σε δευτερόλεπτα',
'continuous_collage': 'Εγγραφή κολάζ χωρίς διακοπή',
'delete': 'διαγραφή',
Expand Down

0 comments on commit 313e128

Please sign in to comment.