From 65e33d6c195d56041056f39055a2f76a8fdcaa3e Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Fri, 27 May 2016 11:11:30 -0400 Subject: [PATCH 01/48] synchronize on capitalizing the word Auto. This should fix the losing of the checkboxes when you change a filter --- web/includes/actions.php | 28 +++++++++++++------------- web/skins/classic/views/filter.php | 14 ++++++------- web/skins/classic/views/filtersave.php | 16 +++++++-------- 3 files changed, 29 insertions(+), 29 deletions(-) diff --git a/web/includes/actions.php b/web/includes/actions.php index 4cd056116..7affee781 100644 --- a/web/includes/actions.php +++ b/web/includes/actions.php @@ -165,20 +165,20 @@ if ( !empty($action) ) $_REQUEST['filter']['sort_asc'] = validStr($_REQUEST['sort_asc']); $_REQUEST['filter']['limit'] = validInt($_REQUEST['limit']); $sql = "replace into Filters set Name = ".dbEscape($filterName).", Query = ".dbEscape(jsonEncode($_REQUEST['filter'])); - if ( !empty($_REQUEST['autoArchive']) ) - $sql .= ", AutoArchive = ".dbEscape($_REQUEST['autoArchive']); - if ( !empty($_REQUEST['autoVideo']) ) - $sql .= ", AutoVideo = ".dbEscape($_REQUEST['autoVideo']); - if ( !empty($_REQUEST['autoUpload']) ) - $sql .= ", AutoUpload = ".dbEscape($_REQUEST['autoUpload']); - if ( !empty($_REQUEST['autoEmail']) ) - $sql .= ", AutoEmail = ".dbEscape($_REQUEST['autoEmail']); - if ( !empty($_REQUEST['autoMessage']) ) - $sql .= ", AutoMessage = ".dbEscape($_REQUEST['autoMessage']); - if ( !empty($_REQUEST['autoExecute']) && !empty($_REQUEST['autoExecuteCmd']) ) - $sql .= ", AutoExecute = ".dbEscape($_REQUEST['autoExecute']).", AutoExecuteCmd = ".dbEscape($_REQUEST['autoExecuteCmd']); - if ( !empty($_REQUEST['autoDelete']) ) - $sql .= ", AutoDelete = ".dbEscape($_REQUEST['autoDelete']); + if ( !empty($_REQUEST['AutoArchive']) ) + $sql .= ", AutoArchive = ".dbEscape($_REQUEST['AutoArchive']); + if ( !empty($_REQUEST['AutoVideo']) ) + $sql .= ", AutoVideo = ".dbEscape($_REQUEST['AutoVideo']); + if ( !empty($_REQUEST['AutoUpload']) ) + $sql .= ", AutoUpload = ".dbEscape($_REQUEST['AutoUpload']); + if ( !empty($_REQUEST['AutoEmail']) ) + $sql .= ", AutoEmail = ".dbEscape($_REQUEST['AutoEmail']); + if ( !empty($_REQUEST['AutoMessage']) ) + $sql .= ", AutoMessage = ".dbEscape($_REQUEST['AutoMessage']); + if ( !empty($_REQUEST['AutoExecute']) && !empty($_REQUEST['AutoExecuteCmd']) ) + $sql .= ", AutoExecute = ".dbEscape($_REQUEST['AutoExecute']).", AutoExecuteCmd = ".dbEscape($_REQUEST['AutoExecuteCmd']); + if ( !empty($_REQUEST['AutoDelete']) ) + $sql .= ", AutoDelete = ".dbEscape($_REQUEST['AutoDelete']); if ( !empty($_REQUEST['background']) ) $sql .= ", Background = ".dbEscape($_REQUEST['background']); dbQuery( $sql ); diff --git a/web/skins/classic/views/filter.php b/web/skins/classic/views/filter.php index 870d873df..b042854b3 100644 --- a/web/skins/classic/views/filter.php +++ b/web/skins/classic/views/filter.php @@ -266,7 +266,7 @@ for ( $i = 0; isset($_REQUEST['filter']) && $i < count($_REQUEST['filter']['term - checked="checked" onclick="updateButtons( this )"/> + checked="checked" onclick="updateButtons( this )"/> - checked="checked" onclick="updateButtons( this )"/> + checked="checked" onclick="updateButtons( this )"/> - checked="checked" onclick="updateButtons( this )"/> + checked="checked" onclick="updateButtons( this )"/> - checked="checked" onclick="updateButtons( this )"/> + checked="checked" onclick="updateButtons( this )"/> - checked="checked" onclick="updateButtons( this )"/> + checked="checked" onclick="updateButtons( this )"/> - checked="checked"/>" size="32" maxlength="255" onchange="updateButtons( this )"/> + checked="checked"/>" size="32" maxlength="255" onchange="updateButtons( this )"/> - checked="checked" onclick="updateButtons( this )"/> + checked="checked" onclick="updateButtons( this )"/> diff --git a/web/skins/classic/views/filtersave.php b/web/skins/classic/views/filtersave.php index 83c803485..52ced4265 100644 --- a/web/skins/classic/views/filtersave.php +++ b/web/skins/classic/views/filtersave.php @@ -56,14 +56,14 @@ xhtmlHeaders(__FILE__, translate('SaveFilter') ); - - - - - - - - + + + + + + + +

From c4e5299943529f2682a3acc0301adcc75c107a20 Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Fri, 27 May 2016 12:45:04 -0400 Subject: [PATCH 02/48] sync up auto to Auto --- web/skins/classic/views/js/filter.js | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/web/skins/classic/views/js/filter.js b/web/skins/classic/views/js/filter.js index 300862640..5ed5d62f3 100644 --- a/web/skins/classic/views/js/filter.js +++ b/web/skins/classic/views/js/filter.js @@ -7,19 +7,19 @@ function updateButtons( element ) else { var canExecute = false; - if ( form.elements['autoArchive'].checked ) + if ( form.elements['AutoArchive'].checked ) canExecute = true; - else if ( typeof ZM_OPT_FFMPEG !== "undefined" && form.elements['autoVideo'].checked ) + else if ( typeof ZM_OPT_FFMPEG !== "undefined" && form.elements['AutoVideo'].checked ) canExecute = true; - else if ( typeof ZM_OPT_UPLOAD !== "undefined" && form.elements['autoUpload'].checked ) + else if ( typeof ZM_OPT_UPLOAD !== "undefined" && form.elements['AutoUpload'].checked ) canExecute = true; - else if ( typeof ZM_OPT_EMAIL !== "undefined" && form.elements['autoEmail'].checked ) + else if ( typeof ZM_OPT_EMAIL !== "undefined" && form.elements['AutoEmail'].checked ) canExecute = true; - else if ( typeof ZM_OPT_MESSAGE !== "undefined" && form.elements['autoMessage'].checked ) + else if ( typeof ZM_OPT_MESSAGE !== "undefined" && form.elements['AutoMessage'].checked ) canExecute = true; - else if ( form.elements['autoExecute'].checked && form.elements['autoExecuteCmd'].value != '' ) + else if ( form.elements['AutoExecute'].checked && form.elements['AutoExecuteCmd'].value != '' ) canExecute = true; - else if ( form.elements['autoDelete'].checked ) + else if ( form.elements['AutoDelete'].checked ) canExecute = true; form.elements['executeButton'].disabled = !canExecute; } From 101c93d422d9f802321b517e5828a586d76d5831 Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Fri, 27 May 2016 12:45:36 -0400 Subject: [PATCH 03/48] When the filter is not being loaded, copy the auto fields in the request params into the dbFilter object --- web/skins/classic/views/filter.php | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/web/skins/classic/views/filter.php b/web/skins/classic/views/filter.php index b042854b3..96a39eaef 100644 --- a/web/skins/classic/views/filter.php +++ b/web/skins/classic/views/filter.php @@ -48,6 +48,18 @@ if ( isset($dbFilter) ) unset( $_REQUEST['filter']['limit'] ); } +# reload is set when the dropdown is changed. +if ( isset( $_REQUEST['reload'] ) and ! $_REQUEST['reload'] ) { + $dbFilter['AutoArchive'] = isset( $_REQUEST['AutoArchive'] ); + $dbFilter['AutoExecute'] = isset( $_REQUEST['AutoExecute'] ); + $dbFilter['AutoExecuteCmd'] = $_REQUEST['AutoExecuteCmd']; + $dbFilter['AutoEmail'] = isset( $_REQUEST['AutoEmail'] ); + $dbFilter['AutoMessage'] = isset( $_REQUEST['AutoMessage'] ); + $dbFilter['AutoUpload'] = isset( $_REQUEST['AutoUpload'] ); + $dbFilter['AutoVideo'] = isset( $_REQUEST['AutoVideo'] ); + $dbFilter['AutoDelete'] = isset( $_REQUEST['AutoDelete'] ); +} + $conjunctionTypes = array( 'and' => translate('ConjAnd'), 'or' => translate('ConjOr') From 9f6f5100fe6368d760b5e151d941bb54c8b6b7e0 Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Sun, 29 May 2016 11:32:18 -0400 Subject: [PATCH 04/48] also copy Name from the request on update and only show delete button if it has a name --- web/skins/classic/views/filter.php | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/web/skins/classic/views/filter.php b/web/skins/classic/views/filter.php index 96a39eaef..c8f4d7554 100644 --- a/web/skins/classic/views/filter.php +++ b/web/skins/classic/views/filter.php @@ -58,6 +58,7 @@ if ( isset( $_REQUEST['reload'] ) and ! $_REQUEST['reload'] ) { $dbFilter['AutoUpload'] = isset( $_REQUEST['AutoUpload'] ); $dbFilter['AutoVideo'] = isset( $_REQUEST['AutoVideo'] ); $dbFilter['AutoDelete'] = isset( $_REQUEST['AutoDelete'] ); + $dbFilter['Name'] = $_REQUEST['filterName']; } $conjunctionTypes = array( @@ -333,9 +334,11 @@ if ( ZM_OPT_MESSAGE ) - - - + + + + + From b522371080db5a27edd03d9dff785ca710c8d527 Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Tue, 2 Aug 2016 12:02:07 -0400 Subject: [PATCH 05/48] include polygons for the other zones. --- web/skins/classic/views/zone.php | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/web/skins/classic/views/zone.php b/web/skins/classic/views/zone.php index a61e549d4..c16a3edf5 100644 --- a/web/skins/classic/views/zone.php +++ b/web/skins/classic/views/zone.php @@ -217,6 +217,21 @@ xhtmlHeaders(__FILE__, translate('Zone') );

+Id(), $zone['Id'] ) ); +} else { + $other_zones = dbFetchAll( 'SELECT * FROM Zones WHERE MonitorId = ?', NULL, array( $monitor->Id() ) ); +} +if ( count( $other_zones ) ) { + $html = ''; + foreach( $other_zones as $other_zone ) { + $other_zone['AreaCoords'] = preg_replace( '/\s+/', ',', $other_zone['Coords'] ); + $html .= ''; + } + echo $html; +} +?> Sorry, your browser does not support inline SVG From 8093470a2e5e27287fd459d9a02f6cb9644c30ff Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Tue, 2 Aug 2016 12:19:55 -0400 Subject: [PATCH 06/48] make only the editing polygon have a border. Set default for Type when creating a new zone --- web/skins/classic/css/classic/views/zone.css | 3 +++ web/skins/classic/css/dark/views/zone.css | 5 ++++- web/skins/classic/css/flat/views/zone.css | 3 +++ web/skins/classic/views/zone.php | 5 +++-- 4 files changed, 13 insertions(+), 3 deletions(-) diff --git a/web/skins/classic/css/classic/views/zone.css b/web/skins/classic/css/classic/views/zone.css index 52611f5ea..897ee50ee 100644 --- a/web/skins/classic/css/classic/views/zone.css +++ b/web/skins/classic/css/classic/views/zone.css @@ -95,6 +95,9 @@ } .zones polygon { fill-opacity: 0.25; + stroke-width: 0; +} +.zones polygon.Editing { stroke-width: 2px; } .Active { diff --git a/web/skins/classic/css/dark/views/zone.css b/web/skins/classic/css/dark/views/zone.css index 52611f5ea..884c8dbe0 100644 --- a/web/skins/classic/css/dark/views/zone.css +++ b/web/skins/classic/css/dark/views/zone.css @@ -95,7 +95,10 @@ } .zones polygon { fill-opacity: 0.25; - stroke-width: 2px; + stroke-width: 0; +} +.zones polygon.Editing { + stroke-width: 2px; } .Active { stroke: #ff0000; diff --git a/web/skins/classic/css/flat/views/zone.css b/web/skins/classic/css/flat/views/zone.css index 52611f5ea..54ea4eabf 100644 --- a/web/skins/classic/css/flat/views/zone.css +++ b/web/skins/classic/css/flat/views/zone.css @@ -95,6 +95,9 @@ } .zones polygon { fill-opacity: 0.25; + stroke-width: 0; +} +.zones polygon.Editing { stroke-width: 2px; } .Active { diff --git a/web/skins/classic/views/zone.php b/web/skins/classic/views/zone.php index c16a3edf5..c7875e08a 100644 --- a/web/skins/classic/views/zone.php +++ b/web/skins/classic/views/zone.php @@ -75,8 +75,9 @@ if ( !isset($newZone) ) else { $zone = array( - 'Name' => translate('New'), 'Id' => 0, + 'Name' => translate('New'), + 'Type' => 'Active', 'MonitorId' => $monitor->Id(), 'NumCoords' => 4, 'Coords' => sprintf( "%d,%d %d,%d, %d,%d %d,%d", $minX, $minY, $maxX, $minY, $maxX, $maxY, $minX, $maxY ), @@ -232,7 +233,7 @@ if ( count( $other_zones ) ) { echo $html; } ?> - + Sorry, your browser does not support inline SVG
From aa78b403a16604de0d97333454f3cf56ed50b0a1 Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Tue, 2 Aug 2016 12:33:41 -0400 Subject: [PATCH 07/48] zmaControl can take an id #, so need to move the check for local server test down. --- web/includes/functions.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/web/includes/functions.php b/web/includes/functions.php index 2b73160db..9b5d1e8f1 100644 --- a/web/includes/functions.php +++ b/web/includes/functions.php @@ -840,10 +840,10 @@ function zmcControl( $monitor, $mode=false ) { } function zmaControl( $monitor, $mode=false ) { + if ( !is_array( $monitor ) ) { + $monitor = dbFetchOne( "select C.*, M.* from Monitors as M left join Controls as C on (M.ControlId = C.Id ) where M.Id=?", NULL, array($monitor) ); + } if ( (!defined('ZM_SERVER_ID')) or ( ZM_SERVER_ID==$monitor['ServerId'] ) ) { - if ( !is_array( $monitor ) ) { - $monitor = dbFetchOne( "select C.*, M.* from Monitors as M left join Controls as C on (M.ControlId = C.Id ) where M.Id=?", NULL, array($monitor) ); - } if ( !$monitor || $monitor['Function'] == 'None' || $monitor['Function'] == 'Monitor' || $mode == "stop" ) { if ( ZM_OPT_CONTROL ) { daemonControl( "stop", "zmtrack.pl", "-m ".$monitor['Id'] ); @@ -873,7 +873,7 @@ function zmaControl( $monitor, $mode=false ) { daemonControl( "reload", "zma", "-m ".$monitor['Id'] ); } } - } + } // end if we are on the recording server } function initDaemonStatus() { From b822deeb8c12b204c96b44d92b4f115a40875436 Mon Sep 17 00:00:00 2001 From: Eric Relson Date: Tue, 2 Aug 2016 10:00:21 -0700 Subject: [PATCH 08/48] Minor API doc error fixes --- docs/api.rst | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/docs/api.rst b/docs/api.rst index 6d5396372..36467525a 100644 --- a/docs/api.rst +++ b/docs/api.rst @@ -89,7 +89,7 @@ This API changes monitor 1 to Modect and Enabled :: - curl -XPOST http://server/zm/api/monitors/1.json -d "Monitor[Function]=Modect&Monitor[Enabled]:true" + curl -XPOST http://server/zm/api/monitors/1.json -d "Monitor[Function]=Modect&Monitor[Enabled]=1" Add a monitor ^^^^^^^^^^^^^^ @@ -209,7 +209,7 @@ Return a list of events for a specific monitor Id =5 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: - curl -XGET http://server/zm/api/events/events/index/MonitorId:5.json`` + curl -XGET http://server/zm/api/events/index/MonitorId:5.json Note that the same pagination logic applies if the list is too long @@ -220,7 +220,7 @@ Return a list of events for a specific monitor within a specific date/time range :: - http://server/zm/api/events/events/index/MonitorId:5/StartTime >=:2015-05-15 18:43:56/EndTime <=:2015-05-16 18:43:56.json + http://server/zm/api/events/index/MonitorId:5/StartTime >=:2015-05-15 18:43:56/EndTime <=:2015-05-16 18:43:56.json To try this in CuRL, you need to URL escape the spaces like so: @@ -350,5 +350,5 @@ ZM APIs have various APIs that help you in determining host (aka ZM) daemon stat curl -XGET http://server/zm/api/host/daemonCheck.json # 1 = ZM running 0=not running curl -XGET http://server/zm/api/host/getLoad.json # returns current load of ZM - curl -XGET http://server/zm/api/host/getDiskPercent.json # returns in GB (not percentage), disk usage per monitor (that is, space taken to store various event related information,images etc. per monitor) `` + curl -XGET http://server/zm/api/host/getDiskPercent.json # returns in GB (not percentage), disk usage per monitor (that is, space taken to store various event related information,images etc. per monitor) From 02386565424a5fdee27ac980ef48592dee1d783c Mon Sep 17 00:00:00 2001 From: peruchi Date: Tue, 2 Aug 2016 15:36:40 -0300 Subject: [PATCH 09/48] Update file sock for multiserver Added the ZM_SERVER_ID in the creation the sock for not to give conflict in mode multi server. --- scripts/zmdc.pl.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/zmdc.pl.in b/scripts/zmdc.pl.in index b120e2846..b7e80120e 100644 --- a/scripts/zmdc.pl.in +++ b/scripts/zmdc.pl.in @@ -69,7 +69,7 @@ use IO::Handle; use autouse 'Pod::Usage'=>qw(pod2usage); #use Data::Dumper; -use constant SOCK_FILE => $Config{ZM_PATH_SOCKS}.'/zmdc.sock'; +use constant SOCK_FILE => $Config{ZM_PATH_SOCKS}.'/zmdc'.$Config{ZM_SERVER_ID}.'.sock'; $| = 1; From 0d85d3e60d6ed96a83a96c3c13745a252c6fe264 Mon Sep 17 00:00:00 2001 From: peruchi Date: Tue, 2 Aug 2016 16:26:27 -0300 Subject: [PATCH 10/48] Update zmdc.pl.in --- scripts/zmdc.pl.in | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/scripts/zmdc.pl.in b/scripts/zmdc.pl.in index b7e80120e..a9d770488 100644 --- a/scripts/zmdc.pl.in +++ b/scripts/zmdc.pl.in @@ -69,7 +69,12 @@ use IO::Handle; use autouse 'Pod::Usage'=>qw(pod2usage); #use Data::Dumper; -use constant SOCK_FILE => $Config{ZM_PATH_SOCKS}.'/zmdc'.$Config{ZM_SERVER_ID}.'.sock'; +if ( ! defined('ZM_SERVER_ID') ) { + use constant SOCK_FILE => $Config{ZM_PATH_SOCKS}.'/zmdc.sock'; +} +else { + use constant SOCK_FILE => $Config{ZM_PATH_SOCKS}.'/zmdc'.$Config{ZM_SERVER_ID}.'.sock'; +} $| = 1; From 177c2c741b521469b75d180e380429bf29ce5fe4 Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Sun, 7 Aug 2016 10:55:19 -0400 Subject: [PATCH 11/48] Fixes #1584. I've just copied the relevant functions from ffmpeg source. Please review carefully before merging. --- src/zm_ffmpeg.cpp | 50 +++++++++++++++++++++++++++++++++++++++++++++++ src/zm_ffmpeg.h | 11 ++++++++++- 2 files changed, 60 insertions(+), 1 deletion(-) diff --git a/src/zm_ffmpeg.cpp b/src/zm_ffmpeg.cpp index e7c9edbef..1874459f8 100644 --- a/src/zm_ffmpeg.cpp +++ b/src/zm_ffmpeg.cpp @@ -69,6 +69,55 @@ enum _AVPIXELFORMAT GetFFMPEGPixelFormat(unsigned int p_colours, unsigned p_subp return pf; } +/* The following is copied directly from newer ffmpeg. */ +#if LIBAVUTIL_VERSION_CHECK(52, 6, 0, 6, 0) +#else +static int parse_key_value_pair(AVDictionary **pm, const char **buf, + const char *key_val_sep, const char *pairs_sep, + int flags) +{ + char *key = av_get_token(buf, key_val_sep); + char *val = NULL; + int ret; + + if (key && *key && strspn(*buf, key_val_sep)) { + (*buf)++; + val = av_get_token(buf, pairs_sep); + } + + if (key && *key && val && *val) + ret = av_dict_set(pm, key, val, flags); + else + ret = AVERROR(EINVAL); + + av_freep(&key); + av_freep(&val); + + return ret; +} +int av_dict_parse_string(AVDictionary **pm, const char *str, + const char *key_val_sep, const char *pairs_sep, + int flags) + { + int ret; + + if (!str) + return 0; + + /* ignore STRDUP flags */ + flags &= ~(AV_DICT_DONT_STRDUP_KEY | AV_DICT_DONT_STRDUP_VAL); + + while (*str) { + if ((ret = parse_key_value_pair(pm, &str, key_val_sep, pairs_sep, flags)) < 0) + return ret; + + if (*str) + str++; + } + + return 0; + } +#endif #endif // HAVE_LIBAVUTIL #if HAVE_LIBSWSCALE && HAVE_LIBAVUTIL @@ -240,4 +289,5 @@ int SWScale::ConvertDefaults(const uint8_t* in_buffer, const size_t in_buffer_si } #endif // HAVE_LIBSWSCALE && HAVE_LIBAVUTIL + #endif // HAVE_LIBAVCODEC || HAVE_LIBAVUTIL || HAVE_LIBSWSCALE diff --git a/src/zm_ffmpeg.h b/src/zm_ffmpeg.h index 894408437..d727da7a4 100644 --- a/src/zm_ffmpeg.h +++ b/src/zm_ffmpeg.h @@ -32,6 +32,7 @@ extern "C" { #include #include #include +#include /* LIBAVUTIL_VERSION_CHECK checks for the right version of libav and FFmpeg * The original source is vlc (in modules/codec/avcodec/avcommon_compat.h) @@ -274,7 +275,15 @@ protected: #undef av_err2str #define av_err2str(errnum) av_make_error_string(errnum).c_str() - #endif // __cplusplus + /* The following is copied directly from newer ffmpeg */ + #if LIBAVUTIL_VERSION_CHECK(52, 6, 0, 0, 0) + #else + int av_dict_parse_string(AVDictionary **pm, const char *str, + const char *key_val_sep, const char *pairs_sep, + int flags); + #endif + +#endif // __cplusplus #endif // ( HAVE_LIBAVUTIL_AVUTIL_H || HAVE_LIBAVCODEC_AVCODEC_H || HAVE_LIBAVFORMAT_AVFORMAT_H || HAVE_LIBAVDEVICE_AVDEVICE_H ) From 3f713df8264baf6a1c187e1a864ff323152b5e18 Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Tue, 9 Aug 2016 13:14:10 -0400 Subject: [PATCH 12/48] bump libavutil version check as per @SteveGilvarry --- src/zm_ffmpeg.cpp | 2 +- src/zm_ffmpeg.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/zm_ffmpeg.cpp b/src/zm_ffmpeg.cpp index 1874459f8..def7ef0c3 100644 --- a/src/zm_ffmpeg.cpp +++ b/src/zm_ffmpeg.cpp @@ -70,7 +70,7 @@ enum _AVPIXELFORMAT GetFFMPEGPixelFormat(unsigned int p_colours, unsigned p_subp return pf; } /* The following is copied directly from newer ffmpeg. */ -#if LIBAVUTIL_VERSION_CHECK(52, 6, 0, 6, 0) +#if LIBAVUTIL_VERSION_CHECK(52, 7, 0, 17, 100) #else static int parse_key_value_pair(AVDictionary **pm, const char **buf, const char *key_val_sep, const char *pairs_sep, diff --git a/src/zm_ffmpeg.h b/src/zm_ffmpeg.h index d727da7a4..f1486c2ee 100644 --- a/src/zm_ffmpeg.h +++ b/src/zm_ffmpeg.h @@ -276,7 +276,7 @@ protected: #define av_err2str(errnum) av_make_error_string(errnum).c_str() /* The following is copied directly from newer ffmpeg */ - #if LIBAVUTIL_VERSION_CHECK(52, 6, 0, 0, 0) + #if LIBAVUTIL_VERSION_CHECK(52, 7, 0, 17, 100) #else int av_dict_parse_string(AVDictionary **pm, const char *str, const char *key_val_sep, const char *pairs_sep, From f6a46e4028967f3ae0c06c457f7f44ad2fd4c6d2 Mon Sep 17 00:00:00 2001 From: Andy Bauer Date: Wed, 10 Aug 2016 08:35:49 -0500 Subject: [PATCH 13/48] don't build the onvif libraries in travis --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index bb6536526..0ce739bef 100644 --- a/.travis.yml +++ b/.travis.yml @@ -39,7 +39,7 @@ before_script: - mysql -uroot -e "GRANT ALL ON zm.* TO 'zmuser'@'localhost' IDENTIFIED BY 'zmpass'"; - mysql -uroot -e "FLUSH PRIVILEGES" script: - - if [ "$ZM_BUILDMETHOD" = "cmake" ]; then cmake -DCMAKE_INSTALL_PREFIX="/usr"; fi + - if [ "$ZM_BUILDMETHOD" = "cmake" ]; then cmake -DZM_ONVIF=OFF -DCMAKE_INSTALL_PREFIX="/usr"; fi - make - sudo make install - if [ "$ZM_BUILDMETHOD" = "cmake" ]; then sudo ./zmlinkcontent.sh; fi From bc4923b555c0cfb590d69e5b94d531523d629049 Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Fri, 12 Aug 2016 13:50:18 -0400 Subject: [PATCH 14/48] use instead of for the frame object and pass to getImageSrc which expects an array --- web/skins/classic/views/frame.php | 32 +++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/web/skins/classic/views/frame.php b/web/skins/classic/views/frame.php index 29ddcc1d6..5988517c7 100644 --- a/web/skins/classic/views/frame.php +++ b/web/skins/classic/views/frame.php @@ -40,57 +40,57 @@ if ( !empty($fid) ) { } else { $frame = dbFetchOne( 'SELECT * FROM Frames WHERE EventId = ? AND Score = ?', NULL, array( $eid, $event['MaxScore'] ) ); } -$frame = new Frame( $frame ); +$Frame = new Frame( $frame ); $maxFid = $event['Frames']; $firstFid = 1; -$prevFid = $frame->FrameId()-1; -$nextFid = $frame->FrameId()+1; +$prevFid = $Frame->FrameId()-1; +$nextFid = $Frame->FrameId()+1; $lastFid = $maxFid; -$alarmFrame = $frame->Type()=='Alarm'; +$alarmFrame = $Frame->Type()=='Alarm'; if ( isset( $_REQUEST['scale'] ) ) $scale = validInt($_REQUEST['scale']); else $scale = max( reScale( SCALE_BASE, $event['DefaultScale'], ZM_WEB_DEFAULT_SCALE ), SCALE_BASE ); -$imageData = getImageSrc( $event, $frame->FrameId(), $scale, (isset($_REQUEST['show']) && $_REQUEST['show']=="capt") ); +$imageData = getImageSrc( $event, $frame, $scale, (isset($_REQUEST['show']) && $_REQUEST['show']=="capt") ); $imagePath = $imageData['thumbPath']; $eventPath = $imageData['eventPath']; -$dImagePath = sprintf( "%s/%0".ZM_EVENT_IMAGE_DIGITS."d-diag-d.jpg", $eventPath, $frame->FrameId() ); -$rImagePath = sprintf( "%s/%0".ZM_EVENT_IMAGE_DIGITS."d-diag-r.jpg", $eventPath, $frame->FrameId() ); +$dImagePath = sprintf( "%s/%0".ZM_EVENT_IMAGE_DIGITS."d-diag-d.jpg", $eventPath, $Frame->FrameId() ); +$rImagePath = sprintf( "%s/%0".ZM_EVENT_IMAGE_DIGITS."d-diag-r.jpg", $eventPath, $Frame->FrameId() ); $focusWindow = true; -xhtmlHeaders(__FILE__, translate('Frame')." - ".$event['Id']." - ".$frame->FrameId() ); +xhtmlHeaders(__FILE__, translate('Frame')." - ".$event['Id']." - ".$Frame->FrameId() ); ?>

-"> -<?php echo $frame->EventId().FrameId() ?>" class=""/> +"> +<?php echo $Frame->EventId().FrameId() ?>" class=""/>

-FrameId() > 1 ) { ?> +FrameId() > 1 ) { ?> -FrameId() > 1 ) { ?> +FrameId() > 1 ) { ?> -FrameId() < $maxFid ) { ?> +FrameId() < $maxFid ) { ?> -FrameId() < $maxFid ) { ?> +FrameId() < $maxFid ) { ?>

From 3dadcc8d32eabc413783d66e9ff76bd35568b1d0 Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Fri, 12 Aug 2016 15:14:51 -0400 Subject: [PATCH 15/48] add ability to pass show=capture or show=analyse to getImageSrc --- web/includes/Frame.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/web/includes/Frame.php b/web/includes/Frame.php index 707569157..661654d24 100644 --- a/web/includes/Frame.php +++ b/web/includes/Frame.php @@ -69,8 +69,8 @@ class Frame { } - public function getImageSrc( ) { - return $_SERVER['PHP_SELF'].'?view=image&fid='.$this->{'Id'}; + public function getImageSrc( $show='capture' ) { + return $_SERVER['PHP_SELF'].'?view=image&fid='.$this->{'Id'}.'&show='.$show;; } // end function getImageSrc public static function find( $parameters = array(), $limit = NULL ) { From bcb7dd1ba400a3ca861059f5f0515d0e35a1abb4 Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Fri, 12 Aug 2016 15:16:05 -0400 Subject: [PATCH 16/48] take optional show= to specify the analyse image or the capture image --- web/views/image.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/web/views/image.php b/web/views/image.php index 9bc242244..0135df7e0 100644 --- a/web/views/image.php +++ b/web/views/image.php @@ -61,18 +61,19 @@ $errorText = false; if ( empty($_REQUEST['path']) ) { if ( ! empty($_REQUEST['fid']) ) { + $show = empty($_REQUEST['show']) ? 'capture' : $_REQUEST['show']; if ( ! empty($_REQUEST['eid'] ) ) { $Event = new Event( $_REQUEST['eid'] ); $Frame = Frame::find_one( array( 'EventId' => $_REQUEST['eid'], 'FrameId' => $_REQUEST['fid'] ) ); if ( ! $Frame ) { Fatal("No Frame found for event(".$_REQUEST['eid'].") and frame id(".$_REQUEST['fid'].")"); } - $path = $Event->Path().'/'.sprintf("%'.0".ZM_EVENT_IMAGE_DIGITS.'d',$_REQUEST['fid']).'-capture.jpg'; + $path = $Event->Path().'/'.sprintf("%'.0".ZM_EVENT_IMAGE_DIGITS.'d',$_REQUEST['fid']).'-'.$show.'.jpg'; } else { # If we are only specifying fid, then the fid must be the primary key into the frames table. But when the event is specified, then it is the frame # $Frame = new Frame( $_REQUEST['fid'] ); $Event = new Event( $Frame->EventId() ); - $path = $Event->Path().'/'.sprintf("%'.0".ZM_EVENT_IMAGE_DIGITS.'d',$Frame->FrameId()).'-capture.jpg'; + $path = $Event->Path().'/'.sprintf("%'.0".ZM_EVENT_IMAGE_DIGITS.'d',$Frame->FrameId()).'-'.$show.'.jpg'; } } else { $errorText = "No image path"; From 9106675842a792ebb0480de6a71cb4d5f7a9c6a7 Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Fri, 12 Aug 2016 15:17:13 -0400 Subject: [PATCH 17/48] pass capture or analyse to getImageSrc --- web/skins/classic/views/frame.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/web/skins/classic/views/frame.php b/web/skins/classic/views/frame.php index 5988517c7..fa2108f46 100644 --- a/web/skins/classic/views/frame.php +++ b/web/skins/classic/views/frame.php @@ -79,8 +79,10 @@ xhtmlHeaders(__FILE__, translate('Frame')." - ".$event['Id']." - ".$Frame->Frame

-"> -<?php echo $Frame->EventId().FrameId() ?>" class=""/> + +"> + +<?php echo $Frame->EventId().FrameId() ?>" class=""/>

From 240336e3ec90730704cf395351fee7a5314551b7 Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Fri, 12 Aug 2016 15:20:21 -0400 Subject: [PATCH 18/48] silence error when Event has no StorageId set --- web/includes/Event.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/web/includes/Event.php b/web/includes/Event.php index 5ad1c4031..36125165a 100644 --- a/web/includes/Event.php +++ b/web/includes/Event.php @@ -28,7 +28,7 @@ class Event { } } // end function __construct public function Storage() { - return new Storage( $this->{'StorageId'} ); + return new Storage( isset($this->{'StorageId'}) ? $this->{'StorageId'} : NULL ); } public function __call( $fn, array $args){ if(isset($this->{$fn})){ From a0bc30d3fe70b6bcf23174fa2dc407a1ac71add5 Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Fri, 12 Aug 2016 15:40:47 -0400 Subject: [PATCH 19/48] fix the order of analyse/capture being passed --- web/skins/classic/views/frame.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/web/skins/classic/views/frame.php b/web/skins/classic/views/frame.php index fa2108f46..abb4a3cc7 100644 --- a/web/skins/classic/views/frame.php +++ b/web/skins/classic/views/frame.php @@ -82,7 +82,7 @@ xhtmlHeaders(__FILE__, translate('Frame')." - ".$event['Id']." - ".$Frame->Frame "> -<?php echo $Frame->EventId().FrameId() ?>" class=""/> +<?php echo $Frame->EventId().FrameId() ?>" class=""/>

From 31ca0954456fddcb308d4b3bedabc46758760ca7 Mon Sep 17 00:00:00 2001 From: Vikas Kedia Date: Mon, 15 Aug 2016 04:39:04 -0700 Subject: [PATCH 20/48] Update README.md --- utils/docker/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/utils/docker/README.md b/utils/docker/README.md index 4ca100b66..741039b3d 100644 --- a/utils/docker/README.md +++ b/utils/docker/README.md @@ -15,7 +15,7 @@ This is still a bit of a work in progress. 2. Build ZoneMinder container ```sudo docker build -t yourname/zoneminder github.com/ZoneMinder/ZoneMinder``` 3. Run it -```CID=$(sudo docker run -d -p 222:22 -p 8080:80 -name zoneminder yourname/zoneminder)``` +```CID=$(sudo docker run -d -p 222:22 -p 8080:80 --name zoneminder yourname/zoneminder)``` 4. Use it -- you can now SSH to port 222 on your host as user root with password root. You can also browse to your host on port 8080 to access the zoneminder web interface From 489594230839d2df62faedd86d106e495467ada5 Mon Sep 17 00:00:00 2001 From: Andy Bauer Date: Tue, 16 Aug 2016 09:49:45 -0500 Subject: [PATCH 21/48] update fedora rpm readme --- distros/fedora/README.Fedora | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/distros/fedora/README.Fedora b/distros/fedora/README.Fedora index 025699933..72f2554ba 100644 --- a/distros/fedora/README.Fedora +++ b/distros/fedora/README.Fedora @@ -97,6 +97,15 @@ New installs sudo systemctl enable zoneminder sudo systemctl start zoneminder +9. The Fedora repos have a ZoneMinder package available, but it does not + support ffmpeg or libvlc, which many modern IP cameras require. Most users + will want to prevent the ZoneMinder package in the Fedora repos from + overwriting the ZoneMinder package in zmrepo, during a future dnf update. To + prevent that from happening you must edit /etc/yum.repos.d/fedora.repo + and /etc/yum.repos.d/fedora-updates.repo. Add the line "exclude=zoneminder*" + without the quotes under the [fedora] and [fedora-updates] blocks, + respectively. + Upgrades ======== From 7b389a79a63a94f679032fe9fcf95495baf7331d Mon Sep 17 00:00:00 2001 From: peruchi Date: Wed, 17 Aug 2016 09:45:30 -0300 Subject: [PATCH 22/48] Update zmdc.pl.in --- scripts/zmdc.pl.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/zmdc.pl.in b/scripts/zmdc.pl.in index a9d770488..0f352b86a 100644 --- a/scripts/zmdc.pl.in +++ b/scripts/zmdc.pl.in @@ -69,7 +69,7 @@ use IO::Handle; use autouse 'Pod::Usage'=>qw(pod2usage); #use Data::Dumper; -if ( ! defined('ZM_SERVER_ID') ) { +if ( ! $Config{ZM_SERVER_HOST} ) { use constant SOCK_FILE => $Config{ZM_PATH_SOCKS}.'/zmdc.sock'; } else { From 50f55af68fa27d55f8890ac21243c1afd56173a3 Mon Sep 17 00:00:00 2001 From: peruchi Date: Wed, 17 Aug 2016 10:36:00 -0300 Subject: [PATCH 23/48] Update zmdc.pl.in --- scripts/zmdc.pl.in | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/scripts/zmdc.pl.in b/scripts/zmdc.pl.in index 0f352b86a..7f476ebc8 100644 --- a/scripts/zmdc.pl.in +++ b/scripts/zmdc.pl.in @@ -69,12 +69,7 @@ use IO::Handle; use autouse 'Pod::Usage'=>qw(pod2usage); #use Data::Dumper; -if ( ! $Config{ZM_SERVER_HOST} ) { - use constant SOCK_FILE => $Config{ZM_PATH_SOCKS}.'/zmdc.sock'; -} -else { - use constant SOCK_FILE => $Config{ZM_PATH_SOCKS}.'/zmdc'.$Config{ZM_SERVER_ID}.'.sock'; -} +use constant SOCK_FILE => $Config{ZM_PATH_SOCKS}.'/zmdc'.($Config{ZM_SERVER_ID}?$Config{ZM_SERVER_ID}:'').'.sock'; $| = 1; From 2d44531d1fb62fd95b2032377dc34e9e95293e45 Mon Sep 17 00:00:00 2001 From: David Sabbath Grits Date: Thu, 25 Aug 2016 14:24:14 +0200 Subject: [PATCH 24/48] add some more translation --- web/lang/pl_pl.php | 507 +++++++++++++++++++++++---------------------- 1 file changed, 261 insertions(+), 246 deletions(-) diff --git a/web/lang/pl_pl.php b/web/lang/pl_pl.php index 5f36dedac..36f6841f1 100644 --- a/web/lang/pl_pl.php +++ b/web/lang/pl_pl.php @@ -1,4 +1,4 @@ - dawid.kasza@gmail.com +// // Notes for Translators // 0. Get some credit, put your name in the line above (optional) // 1. When composing the language tokens in your language you should try and keep to roughly the @@ -50,7 +51,7 @@ // do this by default, uncomment this if required. // // Example -header( "Content-Type: text/html; charset=iso-8859-2" ); +header( "Content-Type: text/html; charset=utf-8" ); // You may need to change your locale here if your default one is incorrect for the // language described in this file, or if you have multiple languages supported. @@ -64,22 +65,36 @@ header( "Content-Type: text/html; charset=iso-8859-2" ); // threaded environment, if you get funny errors it may be this. // // Examples -// setlocale( 'LC_ALL', 'pl_PL' ); // All locale settings pre-4.3.0 -setlocale( LC_ALL, 'pl_PL' ); // All locale settings 4.3.0 and after -// setlocale( LC_CTYPE, 'pl_PL' ); // Character class settings 4.3.0 and after -// setlocale( LC_TIME, 'pl_PL' ); // Date and time formatting 4.3.0 and after +//setlocale( LC_ALL, 'pl_PL:UTF-8' ); // All locale settings pre-4.3.0 +// setlocale( LC_ALL, 'pl_PL:UTF-8' ); // All locale settings 4.3.0 and after +//setlocale( LC_CTYPE, 'pl_PL:UTF-8' ); // Character class settings 4.3.0 and after +//setlocale( LC_TIME, 'pl_PL:UTF-8' ); // Date and time formatting 4.3.0 and after + +// +// Date and time formats, specific to this language +// + +define( "DATE_FMT_CONSOLE_LONG", "%d.%m.%Y, %H:%M" ); // This is the main console date/time, date() or strftime() format +define( "DATE_FMT_CONSOLE_SHORT", "%H:%m" ); // This is the xHTML console date/time, date() or strftime() format + +define( "STRF_FMT_DATETIME", "%b. %e. %Y., %H:%M" ); // Strftime locale aware format for dates with times +define( "STRF_FMT_DATE", "%b. %e. %Y." ); // Strftime locale aware format for dates without times +define( "STRF_FMT_TIME", "%H:%m:%S" ); // Strftime locale aware format for times without dates + +define( "STRF_FMT_DATETIME_SHORT", "%y/%m/%d %H:%M:%S" ); // Strftime shorter format for dates with time +define( "STRF_FMT_DATETIME_SHORTER", "%m.%d. %H:%M:%S" ); // Strftime shorter format for dates with time, used where space is tight (events list) // Simple String Replacements $SLANG = array( '24BitColour' => 'Kolor (24 bity)', '32BitColour' => 'Kolor (32 bity)', // Added - 2011-06-15 - '8BitGrey' => 'Cz/b (8 bitw)', - 'Action' => 'Action', - 'Actual' => 'Aktualny', + '8BitGrey' => 'Cz/b (8 bitów)', + 'Action' => 'Działanie:', + 'Actual' => 'Domyślna', 'AddNewControl' => 'Add New Control', 'AddNewMonitor' => 'Dodaj nowy monitor', - 'AddNewUser' => 'Dodaj uytkownika', - 'AddNewZone' => 'Dodaj now stref', + 'AddNewUser' => 'Dodaj użytkownika', + 'AddNewZone' => 'Dodaj nową strefę', 'Alarm' => 'Alarm', 'AlarmBrFrames' => 'Ramki
alarmowe', 'AlarmFrame' => 'Ramka alarmowa', @@ -89,7 +104,7 @@ $SLANG = array( 'AlarmPx' => 'Alarm Px', 'AlarmRGBUnset' => 'You must set an alarm RGB colour', 'AlarmRefImageBlendPct'=> 'Alarm Reference Image Blend %ge', // Added - 2015-04-18 - 'Alert' => 'Gotowosc', + 'Alert' => 'Gotowość', 'All' => 'Wszystko', 'AnalysisFPS' => 'Analysis FPS', // Added - 2015-07-22 'AnalysisUpdateDelay' => 'Analysis Update Delay', // Added - 2015-07-23 @@ -97,36 +112,36 @@ $SLANG = array( 'ApplyingStateChange' => 'Zmieniam stan pracy', 'ArchArchived' => 'Tylko zarchiwizowane', 'ArchUnarchived' => 'Tylko niezarchiwizowane', - 'Archive' => 'Archiwum', - 'Archived' => 'Archived', - 'Area' => 'Area', - 'AreaUnits' => 'Area (px/%)', + 'Archive' => 'Dodaj do archiwum', + 'Archived' => 'Zarchiwizowane', + 'Area' => 'Obszar', + 'AreaUnits' => 'Obszar (px/%)', 'AttrAlarmFrames' => 'Ramki alarmowe', 'AttrArchiveStatus' => 'Status archiwum', - 'AttrAvgScore' => 'red. wynik', - 'AttrCause' => 'Cause', + 'AttrAvgScore' => 'Śred. wynik', + 'AttrCause' => 'Powód', 'AttrDate' => 'Data', 'AttrDateTime' => 'Data/Czas', 'AttrDiskBlocks' => 'Dysk Bloki', - 'AttrDiskPercent' => 'Dysk Procent', + 'AttrDiskPercent' => 'Procent zajętości', 'AttrDuration' => 'Czas trwania', - 'AttrFrames' => 'Ramek', + 'AttrFrames' => 'Klatki', 'AttrId' => 'Id', 'AttrMaxScore' => 'Maks. wynik', 'AttrMonitorId' => 'Nr monitora', 'AttrMonitorName' => 'Nazwa monitora', 'AttrName' => 'Nazwa', 'AttrNotes' => 'Notes', - 'AttrSystemLoad' => 'System Load', + 'AttrSystemLoad' => 'Obiążenie systemu', 'AttrTime' => 'Czas', - 'AttrTotalScore' => 'Cakowity wynik', - 'AttrWeekday' => 'Dzie roboczy', + 'AttrTotalScore' => 'Całkowity wynik', + 'AttrWeekday' => 'Dzień roboczy', 'Auto' => 'Auto', 'AutoStopTimeout' => 'Auto Stop Timeout', - 'Available' => 'Available', // Added - 2009-03-31 - 'AvgBrScore' => 'red.
wynik', - 'Background' => 'Background', - 'BackgroundFilter' => 'Run filter in background', + 'Available' => 'Dostępne', // Added - 2009-03-31 + 'AvgBrScore' => 'Śred.
wynik', + 'Background' => 'Działa w tle', + 'BackgroundFilter' => 'Uruchom filtr w tle', 'BadAlarmFrameCount' => 'Alarm frame count must be an integer of one or more', 'BadAlarmMaxFPS' => 'Alarm Maximum FPS must be a positive integer or floating point value', 'BadAnalysisFPS' => 'Analysis FPS must be a positive integer or floating point value', // Added - 2015-07-22 @@ -144,7 +159,7 @@ $SLANG = array( 'BadLabelY' => 'Label Y co-ordinate must be set to an integer of zero or more', 'BadMaxFPS' => 'Maximum FPS must be a positive integer or floating point value', 'BadMotionFrameSkip' => 'Motion Frame skip count must be an integer of zero or more', - 'BadNameChars' => 'Nazwy mog zawiera tylko litery, cyfry oraz mylnik i podkrelenie', + 'BadNameChars' => 'Nazwy mogą zawierać tylko litery, cyfry oraz myślnik i podkreślenie', 'BadPalette' => 'Palette must be set to a valid value', // Added - 2009-03-31 'BadPath' => 'Path must be set to a valid value', 'BadPort' => 'Port must be set to a valid number', @@ -157,13 +172,13 @@ $SLANG = array( 'BadWarmupCount' => 'Warmup frames must be an integer of zero or more', 'BadWebColour' => 'Web colour must be a valid web colour string', 'BadWidth' => 'Width must be set to a valid value', - 'Bandwidth' => 'przepustowo', - 'BandwidthHead' => 'Bandwidth', // This is the end of the bandwidth status on the top of the console, different in many language due to phrasing + 'Bandwidth' => 'Przepustowość', + 'BandwidthHead' => 'Przepustowość', // This is the end of the bandwidth status on the top of the console, different in many language due to phrasing 'BlobPx' => 'Plamka Px', 'BlobSizes' => 'Rozmiary plamek', 'Blobs' => 'Plamki', - 'Brightness' => 'Jaskrawo', - 'Buffer' => 'Buffer', // Added - 2015-04-18 + 'Brightness' => 'Jaskrawość', + 'Buffer' => 'Bufor', // Added - 2015-04-18 'Buffers' => 'Bufory', 'CSSDescription' => 'Change the default css for this computer', // Added - 2015-04-18 'CanAutoFocus' => 'Can Auto Focus', @@ -206,31 +221,31 @@ $SLANG = array( 'CanZoomRel' => 'Can Zoom Relative', 'Cancel' => 'Anuluj', 'CancelForcedAlarm' => 'Anuluj wymuszony alarm', - 'CaptureHeight' => 'Wysoko obrazu', - 'CaptureMethod' => 'Capture Method', // Added - 2009-02-08 - 'CapturePalette' => 'Paleta kolorw obrazu', + 'CaptureHeight' => 'Wysokość obrazu', + 'CaptureMethod' => 'Metoda przechwytywania', // Added - 2009-02-08 + 'CapturePalette' => 'Paleta kolorów obrazu', 'CaptureResolution' => 'Capture Resolution', // Added - 2015-04-18 - 'CaptureWidth' => 'Szeroko obrazu', - 'Cause' => 'Cause', + 'CaptureWidth' => 'Szerokość obrazu', + 'Cause' => 'Przyczyna', 'CheckMethod' => 'Metoda sprawdzenia alarmu', 'ChooseDetectedCamera' => 'Choose Detected Camera', // Added - 2009-03-31 'ChooseFilter' => 'Wybierz filtr', 'ChooseLogFormat' => 'Choose a log format', // Added - 2011-06-17 'ChooseLogSelection' => 'Choose a log selection', // Added - 2011-06-17 'ChoosePreset' => 'Choose Preset', - 'Clear' => 'Clear', // Added - 2011-06-16 + 'Clear' => 'Wyczyść', // Added - 2011-06-16 'Close' => 'Zamknij', 'Colour' => 'Nasycenie', - 'Command' => 'Command', - 'Component' => 'Component', // Added - 2011-06-16 + 'Command' => 'Polecenie', + 'Component' => 'Komponent', // Added - 2011-06-16 'Config' => 'Konfiguracja', 'ConfiguredFor' => 'Ustawiona', - 'ConfirmDeleteEvents' => 'Are you sure you wish to delete the selected events?', - 'ConfirmPassword' => 'Potwierd haso', + 'ConfirmDeleteEvents' => 'Jesteś pewien, że chcesz usunąć zaznaczone zdarzenia?', + 'ConfirmPassword' => 'PotwierdŹ hasło', 'ConjAnd' => 'i', 'ConjOr' => 'lub', 'Console' => 'Konsola', - 'ContactAdmin' => 'Skontaktuj si z Twoim adminstratorem w sprawie szczegw.', + 'ContactAdmin' => 'Skontaktuj się z Twoim adminstratorem w sprawie szczegółów.', 'Continue' => 'Continue', 'Contrast' => 'Kontrast', 'Control' => 'Control', @@ -240,35 +255,35 @@ $SLANG = array( 'ControlDevice' => 'Control Device', 'ControlType' => 'Control Type', 'Controllable' => 'Controllable', - 'Current' => 'Current', // Added - 2015-04-18 - 'Cycle' => 'Cycle', - 'CycleWatch' => 'Cykl podgldu', - 'DateTime' => 'Date/Time', // Added - 2011-06-16 - 'Day' => 'Dzie', + 'Current' => 'Obecny', // Added - 2015-04-18 + 'Cycle' => 'Cykl', + 'CycleWatch' => 'Cykl podglądu', + 'DateTime' => 'Data/Czas', // Added - 2011-06-16 + 'Day' => 'Dzień', 'Debug' => 'Debug', 'DefaultRate' => 'Default Rate', - 'DefaultScale' => 'Default Scale', - 'DefaultView' => 'Default View', - 'Deinterlacing' => 'Deinterlacing', // Added - 2015-04-18 - 'Delay' => 'Delay', // Added - 2015-04-18 - 'Delete' => 'Usu', - 'DeleteAndNext' => 'Usu & nastpny', - 'DeleteAndPrev' => 'Usu & poprzedni', - 'DeleteSavedFilter' => 'Usu zapisany filtr', + 'DefaultScale' => 'Skala domyślna', + 'DefaultView' => 'Widok domyślny', + 'Deinterlacing' => 'Usuwanie przeplotu', // Added - 2015-04-18 + 'Delay' => 'Opóźnienie', // Added - 2015-04-18 + 'Delete' => 'Usuń', + 'DeleteAndNext' => 'Usuń & następny', + 'DeleteAndPrev' => 'Usuń & poprzedni', + 'DeleteSavedFilter' => 'Usuń zapisany filtr', 'Description' => 'Opis', - 'DetectedCameras' => 'Detected Cameras', // Added - 2009-03-31 - 'DetectedProfiles' => 'Detected Profiles', // Added - 2015-04-18 - 'Device' => 'Device', // Added - 2009-02-08 - 'DeviceChannel' => 'Numer wejcia w urzdzeniu', + 'DetectedCameras' => 'Wykryte kamery', // Added - 2009-03-31 + 'DetectedProfiles' => 'Wykryte profile', // Added - 2015-04-18 + 'Device' => 'Urządzenie', // Added - 2009-02-08 + 'DeviceChannel' => 'Numer wejścia w urządzeniu', 'DeviceFormat' => 'System TV', - 'DeviceNumber' => 'Numer urzdzenia', - 'DevicePath' => 'Device Path', - 'Devices' => 'Devices', + 'DeviceNumber' => 'Numer urządzenia', + 'DevicePath' => 'Ścieżka urządzenia', + 'Devices' => 'Urządzenia', 'Dimensions' => 'Rozmiary', - 'DisableAlarms' => 'Disable Alarms', + 'DisableAlarms' => 'Wyłącz alarm', 'Disk' => 'Dysk', - 'Display' => 'Display', // Added - 2011-01-30 - 'Displaying' => 'Displaying', // Added - 2011-06-16 + 'Display' => 'Wygląd', // Added - 2011-01-30 + 'Displaying' => 'Wyświetlanie', // Added - 2011-06-16 'DoNativeMotionDetection'=> 'Do Native Motion Detection', 'Donate' => 'Please Donate', 'DonateAlready' => 'No, I\'ve already donated', @@ -279,40 +294,40 @@ $SLANG = array( 'DonateRemindNever' => 'No, I don\'t want to donate, never remind', 'DonateRemindWeek' => 'Not yet, remind again in 1 week', 'DonateYes' => 'Yes, I\'d like to donate now', - 'Download' => 'Download', + 'Download' => 'Pobierz', 'DuplicateMonitorName' => 'Duplicate Monitor Name', // Added - 2009-03-31 'Duration' => 'Czas trwania', 'Edit' => 'Edycja', 'Email' => 'Email', 'EnableAlarms' => 'Enable Alarms', - 'Enabled' => 'Zezwolono', - 'EnterNewFilterName' => 'Wpisz now nazw filtra', - 'Error' => 'Bd', - 'ErrorBrackets' => 'Bd, prosz sprawdzi ilo nawiasw otwierajcych i zamykajcych', - 'ErrorValidValue' => 'Bd, prosz sprawdzi czy wszystkie warunki maj poprawne wartoci', + 'Enabled' => 'Aktywny', + 'EnterNewFilterName' => 'Wpisz nową nazwę filtra', + 'Error' => 'Błąd', + 'ErrorBrackets' => 'Błąd, proszę sprawdzić ilość nawiasów otwierających i zamykających', + 'ErrorValidValue' => 'Błąd, proszę sprawdzić czy wszystkie warunki mają poprawne wartości', 'Etc' => 'itp', 'Event' => 'Zdarzenie', - 'EventFilter' => 'Filtr zdarze', + 'EventFilter' => 'Filtr zdarzeń', 'EventId' => 'Id zdarzenia', 'EventName' => 'Event Name', 'EventPrefix' => 'Event Prefix', 'Events' => 'Zdarzenia', 'Exclude' => 'Wyklucz', - 'Execute' => 'Execute', - 'Export' => 'Export', - 'ExportDetails' => 'Export Event Details', - 'ExportFailed' => 'Export Failed', - 'ExportFormat' => 'Export File Format', + 'Execute' => 'Wykonaj', + 'Export' => 'Eksport', + 'ExportDetails' => 'Eksport szczegółów zdarzenia', + 'ExportFailed' => 'Eksport nie powiódł się', + 'ExportFormat' => 'Rodzaj archiwum', 'ExportFormatTar' => 'Tar', 'ExportFormatZip' => 'Zip', - 'ExportFrames' => 'Export Frame Details', - 'ExportImageFiles' => 'Export Image Files', - 'ExportLog' => 'Export Log', // Added - 2011-06-17 - 'ExportMiscFiles' => 'Export Other Files (if present)', - 'ExportOptions' => 'Export Options', - 'ExportSucceeded' => 'Export Succeeded', // Added - 2009-02-08 - 'ExportVideoFiles' => 'Export Video Files (if present)', - 'Exporting' => 'Exporting', + 'ExportFrames' => 'Eksport szczgółów klatki', + 'ExportImageFiles' => 'Eksport plików obrazowych (klatek)', + 'ExportLog' => 'Eksport logów', // Added - 2011-06-17 + 'ExportMiscFiles' => 'Eksport innych plików (jeśli dostępne)', + 'ExportOptions' => 'Opcje eksportu', + 'ExportSucceeded' => 'Eksport zakończony pomyślnie', // Added - 2009-02-08 + 'ExportVideoFiles' => 'Eksport plików video (jeśli dostępne)', + 'Exporting' => 'Eksportowanie', 'FPS' => 'fps', 'FPSReportInterval' => 'Raport (ramek/s)', 'FTP' => 'FTP', @@ -320,22 +335,22 @@ $SLANG = array( 'FastForward' => 'Fast Forward', 'Feed' => 'Dostarcz', 'Ffmpeg' => 'Ffmpeg', // Added - 2009-02-08 - 'File' => 'File', + 'File' => 'Plik', 'Filter' => 'Filter', // Added - 2015-04-18 - 'FilterArchiveEvents' => 'Archiwizuj wszystkie pasujce', - 'FilterDeleteEvents' => 'Usuwaj wszystkie pasujce', - 'FilterEmailEvents' => 'Wysyaj poczt wszystkie pasujce', - 'FilterExecuteEvents' => 'Wywouj komend na wszystkie pasujce', - 'FilterLog' => 'Filter log', // Added - 2015-04-18 - 'FilterMessageEvents' => 'Wywietlaj komunikat na wszystkie pasujce', + 'FilterArchiveEvents' => 'Archiwizuj wszystkie pasujące', + 'FilterDeleteEvents' => 'Usuwaj wszystkie pasujące', + 'FilterEmailEvents' => 'Wysyłaj pocztą wszystkie pasujące', + 'FilterExecuteEvents' => 'Wywołuj komendę dla wszystkich pasujących', + 'FilterLog' => 'Filtr logów', // Added - 2015-04-18 + 'FilterMessageEvents' => 'Wyświetlaj komunikat na wszystkie pasujące', 'FilterPx' => 'Filtr Px', 'FilterUnset' => 'You must specify a filter width and height', - 'FilterUploadEvents' => 'Wysyaj wszystkie pasujce', - 'FilterVideoEvents' => 'Create video for all matches', - 'Filters' => 'Filters', + 'FilterUploadEvents' => 'Wysyłaj wszystkie pasujące', + 'FilterVideoEvents' => 'Utwórz nagranie dla zaznaczonych', + 'Filters' => 'Filtry', 'First' => 'Pierwszy', - 'FlippedHori' => 'Flipped Horizontally', - 'FlippedVert' => 'Flipped Vertically', + 'FlippedHori' => 'Odwróć poziomo', + 'FlippedVert' => 'Odwróć pionowo', 'FnMocord' => 'Mocord', // Added 2013.08.16. 'FnModect' => 'Modect', // Added 2013.08.16. 'FnMonitor' => 'Monitor', // Added 2013.08.16. @@ -343,23 +358,23 @@ $SLANG = array( 'FnNone' => 'None', // Added 2013.08.16. 'FnRecord' => 'Record', // Added 2013.08.16. 'Focus' => 'Focus', - 'ForceAlarm' => 'Wymu alarm', + 'ForceAlarm' => 'Wymuś alarm', 'Format' => 'Format', 'Frame' => 'Ramka', 'FrameId' => 'Nr ramki', 'FrameRate' => 'Tempo ramek', - 'FrameSkip' => 'Pomi ramk', - 'Frames' => 'Ramek', + 'FrameSkip' => 'Pomiń ramkę', + 'Frames' => 'Ramki', 'Func' => 'Funkcja', 'Function' => 'Funkcja', 'Gain' => 'Gain', 'General' => 'General', 'GenerateVideo' => 'Generowanie Video', - 'GeneratingVideo' => 'Generuj Video', - 'GoToZoneMinder' => 'Przejd na ZoneMinder.com', + 'GeneratingVideo' => 'Generuję Video', + 'GoToZoneMinder' => 'PrzejdŹ na ZoneMinder.com', 'Grey' => 'Cz/b', - 'Group' => 'Group', - 'Groups' => 'Groups', + 'Group' => 'Grupa', + 'Groups' => 'Grupy', 'HasFocusSpeed' => 'Has Focus Speed', 'HasGainSpeed' => 'Has Gain Speed', 'HasHomePreset' => 'Has Home Preset', @@ -375,38 +390,38 @@ $SLANG = array( 'HighBW' => 'Wys. prz.', 'Home' => 'Home', 'Hour' => 'Godzina', - 'Hue' => 'Odcie', + 'Hue' => 'Odcień', 'Id' => 'Nr', 'Idle' => 'Bezczynny', 'Ignore' => 'Ignoruj', 'Image' => 'Obraz', 'ImageBufferSize' => 'Rozmiar bufora obrazu (ramek)', - 'Images' => 'Images', + 'Images' => 'Obrazy', 'In' => 'In', - 'Include' => 'Docz', - 'Inverted' => 'Odwrcony', + 'Include' => 'Dołącz', + 'Inverted' => 'Odwrócony', 'Iris' => 'Iris', 'KeyString' => 'Key String', 'Label' => 'Label', - 'Language' => 'Jzyk', + 'Language' => 'Język', 'Last' => 'Ostatni', 'Layout' => 'Layout', // Added - 2009-02-08 'Level' => 'Level', // Added - 2011-06-16 'Libvlc' => 'Libvlc', - 'LimitResultsPost' => 'wynikw;', // This is used at the end of the phrase 'Limit to first N results only' - 'LimitResultsPre' => 'Ogranicz do pocztkowych', // This is used at the beginning of the phrase 'Limit to first N results only' - 'Line' => 'Line', // Added - 2011-06-16 - 'LinkedMonitors' => 'Linked Monitors', - 'List' => 'List', + 'LimitResultsPost' => 'wyników;', // This is used at the end of the phrase 'Limit to first N results only' + 'LimitResultsPre' => 'Ogranicz do początkowych', // This is used at the beginning of the phrase 'Limit to first N results only' + 'Line' => 'Linia', // Added - 2011-06-16 + 'LinkedMonitors' => 'Połączone monitory', + 'List' => 'Lista', 'Load' => 'Obc.', 'Local' => 'Lokalny', - 'Log' => 'Log', // Added - 2011-06-16 + 'Log' => 'Logi', // Added - 2011-06-16 'LoggedInAs' => 'Zalogowany jako', - 'Logging' => 'Logging', // Added - 2011-06-16 + 'Logging' => 'Logowanie', // Added - 2011-06-16 'LoggingIn' => 'Logowanie', 'Login' => 'Login', 'Logout' => 'Wyloguj', - 'Logs' => 'Logs', // Added - 2011-06-17 + 'Logs' => 'Logi', // Added - 2011-06-17 'Low' => 'niska', 'LowBW' => 'Nis. prz.', 'Main' => 'Main', @@ -438,15 +453,15 @@ $SLANG = array( 'MaxZoomSpeed' => 'Max Zoom Speed', 'MaxZoomStep' => 'Max Zoom Step', 'MaximumFPS' => 'Maks. FPS', - 'Medium' => 'rednia', - 'MediumBW' => 'red. prz.', - 'Message' => 'Message', // Added - 2011-06-16 + 'Medium' => 'średnia', + 'MediumBW' => 'Śred. prz.', + 'Message' => 'Treść', // Added - 2011-06-16 'MinAlarmAreaLtMax' => 'Minimum alarm area should be less than maximum', 'MinAlarmAreaUnset' => 'You must specify the minimum alarm pixel count', - 'MinBlobAreaLtMax' => 'Minimalny obszar plamki powinien by mniejszy od maksymalnego obszaru plamki', + 'MinBlobAreaLtMax' => 'Minimalny obszar plamki powinien być mniejszy od maksymalnego obszaru plamki', 'MinBlobAreaUnset' => 'You must specify the minimum blob pixel count', 'MinBlobLtMinFilter' => 'Minimum blob area should be less than or equal to minimum filter area', - 'MinBlobsLtMax' => 'Najmniejsze plamki powinny by mniejsze od najwikszych plamek' , + 'MinBlobsLtMax' => 'Najmniejsze plamki powinny być mniejsze od największych plamek' , 'MinBlobsUnset' => 'You must specify the minimum blob count', 'MinFilterAreaLtMax' => 'Minimum filter area should be less than maximum', 'MinFilterAreaUnset' => 'You must specify the minimum filter pixel count', @@ -463,7 +478,7 @@ $SLANG = array( 'MinPanRange' => 'Min Pan Range', 'MinPanSpeed' => 'Min Pan Speed', 'MinPanStep' => 'Min Pan Step', - 'MinPixelThresLtMax' => 'Najmniejsze progi pikseli powinny by mniejsze od najwikszych progw pikseli', + 'MinPixelThresLtMax' => 'Najmniejsze progi pikseli powinny być mniejsze od największych progów pikseli', 'MinPixelThresUnset' => 'You must specify a minimum pixel threshold', 'MinTiltRange' => 'Min Tilt Range', 'MinTiltSpeed' => 'Min Tilt Speed', @@ -475,17 +490,17 @@ $SLANG = array( 'MinZoomSpeed' => 'Min Zoom Speed', 'MinZoomStep' => 'Min Zoom Step', 'Misc' => 'Inne', - 'Mode' => 'Mode', // Added - 2015-04-18 + 'Mode' => 'Tryb', // Added - 2015-04-18 'Monitor' => 'Monitor', - 'MonitorIds' => 'Numery monitorw', - 'MonitorPreset' => 'Monitor Preset', + 'MonitorIds' => 'Numery monitorów', + 'MonitorPreset' => 'Ustawienia predefiniowane', 'MonitorPresetIntro' => 'Select an appropriate preset from the list below.

Please note that this may overwrite any values you already have configured for this monitor.

', 'MonitorProbe' => 'Monitor Probe', // Added - 2009-03-31 'MonitorProbeIntro' => 'The list below shows detected analog and network cameras and whether they are already being used or available for selection.

Select the desired entry from the list below.

Please note that not all cameras may be detected and that choosing a camera here may overwrite any values you already have configured for the current monitor.

', // Added - 2009-03-31 'Monitors' => 'Monitory', - 'Montage' => 'Monta', - 'Month' => 'Miesic', - 'More' => 'More', // Added - 2011-06-16 + 'Montage' => 'Montaż', + 'Month' => 'Miesiąc', + 'More' => 'Pokaż więcej', // Added - 2011-06-16 'MotionFrameSkip' => 'Motion Frame Skip', 'Move' => 'Move', 'Mtg2widgrd' => '2-wide grid', // Added 2013.08.15. @@ -493,78 +508,78 @@ $SLANG = array( 'Mtg3widgrx' => '3-wide grid, scaled, enlarge on alarm', // Added 2013.08.15. 'Mtg4widgrd' => '4-wide grid', // Added 2013.08.15. 'MtgDefault' => 'Default', // Added 2013.08.15. - 'MustBeGe' => 'musi by wiksze lub rwne od', - 'MustBeLe' => 'musi by mniejsze lub rwne od', - 'MustConfirmPassword' => 'Musisz potwierdzi haso', - 'MustSupplyPassword' => 'Musisz poda haso', - 'MustSupplyUsername' => 'Musisz poda nazw uytkownika', + 'MustBeGe' => 'musi być większe lub równe od', + 'MustBeLe' => 'musi być mniejsze lub równe od', + 'MustConfirmPassword' => 'Musisz potwierdzić hasło', + 'MustSupplyPassword' => 'Musisz podać hasło', + 'MustSupplyUsername' => 'Musisz podać nazwę użytkownika', 'Name' => 'Nazwa', 'Near' => 'Near', - 'Network' => 'Sie', + 'Network' => 'Sieć', 'New' => 'Nowy', - 'NewGroup' => 'New Group', - 'NewLabel' => 'New Label', - 'NewPassword' => 'Nowe haso', + 'NewGroup' => 'Nowa grupa', + 'NewLabel' => 'Nowa etykieta', + 'NewPassword' => 'Nowe hasło', 'NewState' => 'Nowy stan', 'NewUser' => 'nowy', - 'Next' => 'Nastpny', + 'Next' => 'Następny', 'No' => 'Nie', - 'NoDetectedCameras' => 'No Detected Cameras', // Added - 2009-03-31 + 'NoDetectedCameras' => 'Nie wykryto kamer', // Added - 2009-03-31 'NoFramesRecorded' => 'Brak zapisanych ramek dla tego zdarzenia', - 'NoGroup' => 'No Group', - 'NoSavedFilters' => 'BrakZapisanychFiltrw', + 'NoGroup' => 'Brak grupy', + 'NoSavedFilters' => 'BrakZapisanychFiltrów', 'NoStatisticsRecorded' => 'Brak zapisanych statystyk dla tego zdarzenia/ramki', 'None' => 'Brak', - 'NoneAvailable' => 'Niedostpne', + 'NoneAvailable' => 'Niedostępne', 'Normal' => 'Normalny', - 'Notes' => 'Notes', + 'Notes' => 'Uwagi', 'NumPresets' => 'Num Presets', 'Off' => 'Off', 'On' => 'On', 'OnvifCredentialsIntro'=> 'Please supply user name and password for the selected camera.
If no user has been created for the camera then the user given here will be created with the given password.

', // Added - 2015-04-18 'OnvifProbe' => 'ONVIF', // Added - 2015-04-18 'OnvifProbeIntro' => 'The list below shows detected ONVIF cameras and whether they are already being used or available for selection.

Select the desired entry from the list below.

Please note that not all cameras may be detected and that choosing a camera here may overwrite any values you already have configured for the current monitor.

', // Added - 2015-04-18 - 'OpEq' => 'rwny', - 'OpGt' => 'wiksze od', - 'OpGtEq' => 'wiksze lub rwne od', + 'OpEq' => 'równy', + 'OpGt' => 'większe od', + 'OpGtEq' => 'większe lub równe od', 'OpIn' => 'w zestawie', 'OpLt' => 'mniejsze od', - 'OpLtEq' => 'mniejsze lub rwne od', - 'OpMatches' => 'pasujce', - 'OpNe' => 'rne od', + 'OpLtEq' => 'mniejsze lub równe od', + 'OpMatches' => 'pasujące', + 'OpNe' => 'różne od', 'OpNotIn' => 'brak w zestawie', - 'OpNotMatches' => 'nie pasujce', - 'Open' => 'Open', + 'OpNotMatches' => 'nie pasujące', + 'Open' => 'Otwórz', 'OptionHelp' => 'OpcjePomoc', - 'OptionRestartWarning' => 'Te zmiany nie przynios natychmiastowego efektu\ndopki system pracuje. Kiedy zakoczysz robi zmiany\nprosz koniecznie zrestartowa ZoneMinder.', + 'OptionRestartWarning' => 'Te zmiany nie przyniosą natychmiastowego efektu\ndopóki system pracuje. Kiedy zakończysz robić zmiany\nproszę koniecznie zrestartować ZoneMinder.', 'Options' => 'Opcje', - 'OrEnterNewName' => 'lub wpisz now nazw', - 'Order' => 'Order', + 'OrEnterNewName' => 'lub wpisz nową nazwę', + 'Order' => 'Kolejność', 'Orientation' => 'Orientacja', 'Out' => 'Out', - 'OverwriteExisting' => 'Nadpisz istniejce', + 'OverwriteExisting' => 'Nadpisz istniejące', 'Paged' => 'Stronicowane', 'Pan' => 'Pan', 'PanLeft' => 'Pan Left', 'PanRight' => 'Pan Right', 'PanTilt' => 'Pan/Tilt', 'Parameter' => 'Parametr', - 'Password' => 'Haso', - 'PasswordsDifferent' => 'Hasa: nowe i potwierdzone s rne!', - 'Paths' => 'cieki', - 'Pause' => 'Pause', - 'Phone' => 'Phone', + 'Password' => 'Hasło', + 'PasswordsDifferent' => 'Hasła: nowe i potwierdzone są różne!', + 'Paths' => 'Ścieżki', + 'Pause' => 'Pauza', + 'Phone' => 'Telefon', 'PhoneBW' => 'Tel. prz.', 'Pid' => 'PID', // Added - 2011-06-16 'PixelDiff' => 'Pixel Diff', 'Pixels' => 'pikseli', - 'Play' => 'Play', + 'Play' => 'Odtwórz', 'PlayAll' => 'Play All', - 'PleaseWait' => 'Prosz czeka', + 'PleaseWait' => 'Proszę czekać', 'Plugins' => 'Plugins', 'Point' => 'Point', - 'PostEventImageBuffer' => 'Bufor obrazw po zdarzeniu', - 'PreEventImageBuffer' => 'Bufor obrazw przed zdarzeniem', + 'PostEventImageBuffer' => 'Bufor obrazów po zdarzeniu', + 'PreEventImageBuffer' => 'Bufor obrazów przed zdarzeniem', 'PreserveAspect' => 'Preserve Aspect Ratio', 'Preset' => 'Preset', 'Presets' => 'Presets', @@ -572,38 +587,38 @@ $SLANG = array( 'Probe' => 'Probe', // Added - 2009-03-31 'ProfileProbe' => 'Stream Probe', // Added - 2015-04-18 'ProfileProbeIntro' => 'The list below shows the existing stream profiles of the selected camera .

Select the desired entry from the list below.

Please note that ZoneMinder cannot configure additional profiles and that choosing a camera here may overwrite any values you already have configured for the current monitor.

', // Added - 2015-04-18 - 'Progress' => 'Progress', // Added - 2015-04-18 + 'Progress' => 'Postęp', // Added - 2015-04-18 'Protocol' => 'Protocol', 'Rate' => 'Tempo', 'Real' => 'Rzeczywiste', 'Record' => 'Zapis', 'RefImageBlendPct' => 'Miks z obrazem odniesienia', - 'Refresh' => 'Odwie', + 'Refresh' => 'Odśwież', 'Remote' => 'Zdalny', - 'RemoteHostName' => 'Nazwa zdalnego hosta', - 'RemoteHostPath' => 'Scieka zdalnego hosta', - 'RemoteHostPort' => 'Port zdalnego hosta', - 'RemoteHostSubPath' => 'Remote Host SubPath', // Added - 2009-02-08 - 'RemoteImageColours' => 'Kolory zdalnego obrazu', + 'RemoteHostName' => 'Nazwa hostu zdalnego', + 'RemoteHostPath' => 'Scieżka hostu zdalnego ', + 'RemoteHostPort' => 'Port hostu zdalnego ', + 'RemoteHostSubPath' => 'Podścieżka hostu zdalnego', // Added - 2009-02-08 + 'RemoteImageColours' => 'Kolory obrazu zdalnego', 'RemoteMethod' => 'Remote Method', // Added - 2009-02-08 'RemoteProtocol' => 'Remote Protocol', // Added - 2009-02-08 - 'Rename' => 'Zmie nazw', - 'Replay' => 'Replay', - 'ReplayAll' => 'All Events', - 'ReplayGapless' => 'Gapless Events', - 'ReplaySingle' => 'Single Event', + 'Rename' => 'Zmień nazwę', + 'Replay' => 'Odtwarzaj', + 'ReplayAll' => 'Wszystko', + 'ReplayGapless' => 'Wszystko i powtarzaj', + 'ReplaySingle' => 'Bieżące zdarzenie', 'Reset' => 'Reset', - 'ResetEventCounts' => 'Kasuj licznik zdarze', + 'ResetEventCounts' => 'Kasuj licznik zdarzeń', 'Restart' => 'Restart', - 'Restarting' => 'Restartuj', + 'Restarting' => 'Restartuję', 'RestrictedCameraIds' => 'Numery kamer', 'RestrictedMonitors' => 'Restricted Monitors', 'ReturnDelay' => 'Return Delay', 'ReturnLocation' => 'Return Location', - 'Rewind' => 'Rewind', - 'RotateLeft' => 'Obr w lewo', - 'RotateRight' => 'Obr w prawo', - 'RunLocalUpdate' => 'Please run zmupdate.pl to update', // Added - 2011-05-25 + 'Rewind' => 'Przewijanie', + 'RotateLeft' => 'Obróć w lewo', + 'RotateRight' => 'Obróć w prawo', + 'RunLocalUpdate' => 'Proszę uruchom skrypt zmupdate.pl w celu aktualizacji', // Added - 2011-05-25 'RunMode' => 'Tryb pracy', 'RunState' => 'Stan pracy', 'Running' => 'Pracuje', @@ -613,29 +628,29 @@ $SLANG = array( 'Scale' => 'Skala', 'Score' => 'Wynik', 'Secs' => 'Sekund', - 'Sectionlength' => 'Dugo sekcji', - 'Select' => 'Select', - 'SelectFormat' => 'Select Format', // Added - 2011-06-17 - 'SelectLog' => 'Select Log', // Added - 2011-06-17 + 'Sectionlength' => 'Długość sekcji', + 'Select' => 'Wybierz', + 'SelectFormat' => 'Wybierz format', // Added - 2011-06-17 + 'SelectLog' => 'Wybierz log', // Added - 2011-06-17 'SelectMonitors' => 'Select Monitors', 'SelfIntersecting' => 'Polygon edges must not intersect', 'Set' => 'Set', - 'SetNewBandwidth' => 'Ustaw now przepustowo', + 'SetNewBandwidth' => 'Ustaw nową przepustowość', 'SetPreset' => 'Set Preset', 'Settings' => 'Ustawienia', - 'ShowFilterWindow' => 'PokaOknoFiltru', - 'ShowTimeline' => 'Show Timeline', + 'ShowFilterWindow' => 'PokażOknoFiltru', + 'ShowTimeline' => 'Pokaż oś czasu', 'SignalCheckColour' => 'Signal Check Colour', - 'Size' => 'Size', + 'Size' => 'Rozmiar', 'SkinDescription' => 'Change the default skin for this computer', // Added - 2011-01-30 'Sleep' => 'Sleep', - 'SortAsc' => 'Nara.', + 'SortAsc' => 'rosnąco', 'SortBy' => 'Sortuj', - 'SortDesc' => 'Opad.', - 'Source' => 'rdo', + 'SortDesc' => 'malejąco', + 'Source' => 'Źródło', 'SourceColours' => 'Source Colours', // Added - 2009-02-08 'SourcePath' => 'Source Path', // Added - 2009-02-08 - 'SourceType' => 'Typ rda', + 'SourceType' => 'Typ Źródła', 'Speed' => 'Speed', 'SpeedHigh' => 'High Speed', 'SpeedLow' => 'Low Speed', @@ -645,102 +660,102 @@ $SLANG = array( 'State' => 'Stan', 'Stats' => 'Statystyki', 'Status' => 'Status', - 'Step' => 'Step', + 'Step' => 'Krok', 'StepBack' => 'Step Back', 'StepForward' => 'Step Forward', 'StepLarge' => 'Large Step', 'StepMedium' => 'Medium Step', 'StepNone' => 'No Step', 'StepSmall' => 'Small Step', - 'Stills' => 'Nieruchome', + 'Stills' => 'Podgląd klatek', 'Stop' => 'Stop', 'Stopped' => 'Zatrzymany', - 'Stream' => 'Ruchomy', + 'Stream' => 'Odtwarzacz', 'StreamReplayBuffer' => 'Stream Replay Image Buffer', - 'Submit' => 'Submit', + 'Submit' => 'Zatwierdź', 'System' => 'System', - 'SystemLog' => 'System Log', // Added - 2011-06-16 + 'SystemLog' => 'Logi systemu', // Added - 2011-06-16 'TargetColorspace' => 'Target colorspace', // Added - 2015-04-18 'Tele' => 'Tele', 'Thumbnail' => 'Thumbnail', 'Tilt' => 'Tilt', 'Time' => 'Czas', - 'TimeDelta' => 'Rnica czasu', - 'TimeStamp' => 'Piecz czasu', - 'Timeline' => 'Timeline', - 'TimelineTip1' => 'Pass your mouse over the graph to view a snapshot image and event details.', // Added 2013.08.15. - 'TimelineTip2' => 'Click on the coloured sections of the graph, or the image, to view the event.', // Added 2013.08.15. - 'TimelineTip3' => 'Click on the background to zoom in to a smaller time period based around your click.', // Added 2013.08.15. - 'TimelineTip4' => 'Use the controls below to zoom out or navigate back and forward through the time range.', // Added 2013.08.15. + 'TimeDelta' => 'Różnica czasu', + 'TimeStamp' => 'Znak czasu', + 'Timeline' => 'Oś czasu', + 'TimelineTip1' => 'Przeciągnij kursor myszki na wykresie, aby wyświetlić obraz migawki i szczegóły zdarzenia.', // Added 2013.08.15. + 'TimelineTip2' => 'Kliknij na kolorowe fragmenty wykresu, aby zobaczyć wydarzenie.', // Added 2013.08.15. + 'TimelineTip3' => 'Kliknij w tło, aby przybliżyć się do mniejszego okresu opartego wokół wykonanego kliknięcia..', // Added 2013.08.15. + 'TimelineTip4' => 'Użyj opcji poniżej, w celu nawigacji.', // Added 2013.08.15. 'Timestamp' => 'Czas', 'TimestampLabelFormat' => 'Format etykiety czasu', 'TimestampLabelX' => 'Wsp. X etykiety czasu', 'TimestampLabelY' => 'Wsp. Y etykiety czasu', - 'Today' => 'Today', - 'Tools' => 'Narzdzia', + 'Today' => 'Dziś', + 'Tools' => 'Narzędzia', 'Total' => 'Total', // Added - 2011-06-16 - 'TotalBrScore' => 'Cakowity
wynik', + 'TotalBrScore' => 'Całkowity
wynik', 'TrackDelay' => 'Track Delay', 'TrackMotion' => 'Track Motion', 'Triggers' => 'Wyzwalacze', 'TurboPanSpeed' => 'Turbo Pan Speed', 'TurboTiltSpeed' => 'Turbo Tilt Speed', 'Type' => 'Typ', - 'Unarchive' => 'Nie archiwizuj', + 'Unarchive' => 'Usuń z archiwum', 'Undefined' => 'Undefined', // Added - 2009-02-08 'Units' => 'Jednostki', 'Unknown' => 'Nieznany', 'Update' => 'Update', - 'UpdateAvailable' => 'Jest dostpne uaktualnienie ZoneMinder ', + 'UpdateAvailable' => 'Jest dostępne uaktualnienie ZoneMinder ', 'UpdateNotNecessary' => 'Nie jest wymagane uaktualnienie', 'Updated' => 'Updated', // Added - 2011-06-16 'Upload' => 'Upload', // Added - 2011-08-23 - 'UseFilter' => 'Uyj filtru', - 'UseFilterExprsPost' => ' wyraenie filtru', // This is used at the end of the phrase 'use N filter expressions' - 'UseFilterExprsPre' => 'Uyj ', // This is used at the beginning of the phrase 'use N filter expressions' + 'UseFilter' => 'Użyj filtru', + 'UseFilterExprsPost' => ' wyrażenie filtru', // This is used at the end of the phrase 'use N filter expressions' + 'UseFilterExprsPre' => 'Użyj ', // This is used at the beginning of the phrase 'use N filter expressions' 'UsedPlugins' => 'Used Plugins', - 'User' => 'Uytkownik', - 'Username' => 'Nazwa uytkownika', - 'Users' => 'Uytkownicy', + 'User' => 'Użytkownik', + 'Username' => 'Nazwa użytkownika', + 'Users' => 'Użytkownicy', 'V4L' => 'V4L', // Added - 2015-04-18 'V4LCapturesPerFrame' => 'Captures Per Frame', // Added - 2015-04-18 'V4LMultiBuffer' => 'Multi Buffering', // Added - 2015-04-18 - 'Value' => 'Warto', + 'Value' => 'Wartość', 'Version' => 'Wersja', - 'VersionIgnore' => 'Zignoruj t wersj', + 'VersionIgnore' => 'Zignoruj tą wersję', 'VersionRemindDay' => 'Przypomnij po 1 dniu', 'VersionRemindHour' => 'Przypomnij po 1 godzinie', 'VersionRemindNever' => 'Nie przypominaj o nowych wersjach', 'VersionRemindWeek' => 'Przypomnij po 1 tygodniu', - 'Video' => 'Video', - 'VideoFormat' => 'Video Format', - 'VideoGenFailed' => 'Generowanie filmu Video nie powiodo si!', - 'VideoGenFiles' => 'Existing Video Files', - 'VideoGenNoFiles' => 'No Video Files Found', + 'Video' => 'Eksport Video', + 'VideoFormat' => 'Format nagrania', + 'VideoGenFailed' => 'Generowanie filmu Video nie powiodło się!', + 'VideoGenFiles' => 'Lista wygenerowanych plików:', + 'VideoGenNoFiles' => 'Nie odnaleziono plików Video', 'VideoGenParms' => 'Parametery generowania filmu Video', - 'VideoGenSucceeded' => 'Video Generation Succeeded!', + 'VideoGenSucceeded' => 'Wygenerowano pomyślnie!', 'VideoSize' => 'Rozmiar filmu Video', - 'View' => 'Podgld', - 'ViewAll' => 'Poka wszystko', - 'ViewEvent' => 'View Event', - 'ViewPaged' => 'Poka stronami', + 'View' => 'Podgląd', + 'ViewAll' => 'Pokaż wszystko', + 'ViewEvent' => 'Pokaż zdarzenie', + 'ViewPaged' => 'Pokaż stronami', 'Wake' => 'Wake', 'WarmupFrames' => 'Ignorowane ramki', - 'Watch' => 'podgld', - 'Web' => 'Web', + 'Watch' => 'podgląd', + 'Web' => 'Sieć', 'WebColour' => 'Web Colour', - 'Week' => 'Tydzie', - 'White' => 'White', - 'WhiteBalance' => 'White Balance', + 'Week' => 'Tydzień', + 'White' => 'Biel', + 'WhiteBalance' => 'Balans bieli', 'Wide' => 'Wide', 'X' => 'X', 'X10' => 'X10', - 'X10ActivationString' => 'X10: acuch aktywujcy', - 'X10InputAlarmString' => 'X10: acuch wejcia alarmu', - 'X10OutputAlarmString' => 'X10: acuch wyjcia alarmu', + 'X10ActivationString' => 'X10: łańcuch aktywujący', + 'X10InputAlarmString' => 'X10: łańcuch wejścia alarmu', + 'X10OutputAlarmString' => 'X10: łańcuch wyjścia alarmu', 'Y' => 'Y', 'Yes' => 'Tak', - 'YouNoPerms' => 'Nie masz uprawnie na dostp do tego zasobu.', + 'YouNoPerms' => 'Nie masz uprawnień na dostęp do tego zasobu.', 'Zone' => 'Strefa', 'ZoneAlarmColour' => 'Kolor alarmu (Red/Green/Blue)', 'ZoneArea' => 'Zone Area', @@ -767,7 +782,7 @@ $CLANG = array( 'LatestRelease' => 'Najnowsza wersja to v%1$s, Ty posiadasz v%2$s.', 'MonitorCount' => '%1$s %2$s', 'MonitorFunction' => 'Monitor %1$s Funkcja', - 'RunningRecentVer' => 'Uruchomie najnowsz wersj ZoneMinder, v%s.', + 'RunningRecentVer' => 'Uruchomiłeś najnowszą wersję ZoneMinder, v%s.', 'VersionMismatch' => 'Version mismatch, system is version %1$s, database is %2$s.', // Added - 2011-05-25 ); @@ -805,8 +820,8 @@ $CLANG = array( // Variable arrays expressing plurality, see the zmVlang description above $VLANG = array( - 'Event' => array( 0=>'Zdarze', 1=>'Zdarzenie', 2=>'Zdarzenia'), - 'Monitor' => array( 0=>'Monitorw', 1=>'Monitor', 2=>'Monitory'), + 'Event' => array( 0=>'Zdarzeń', 1=>'Zdarzenie', 2=>'Zdarzenia'), + 'Monitor' => array( 0=>'Monitorów', 1=>'Monitor', 2=>'Monitory'), ); // You will need to choose or write a function that can correlate the plurality string arrays @@ -851,7 +866,7 @@ function zmVlang( $langVarArray, $count ) } } } - die( 'BD! zmVlang nie moe skorelowac acucha!' ); + die( 'BŁĄD! zmVlang nie może skorelowac łańcucha!' ); } // This is an example of how the function is used in the code which you can uncomment and From 574390730a169911682d848502463a3e767341c2 Mon Sep 17 00:00:00 2001 From: mdrush Date: Sat, 27 Aug 2016 13:10:39 -0700 Subject: [PATCH 25/48] added missing ssmtp support in sendMessage --- scripts/zmfilter.pl.in | 25 +++++++++++++++++++++++-- 1 file changed, 23 insertions(+), 2 deletions(-) diff --git a/scripts/zmfilter.pl.in b/scripts/zmfilter.pl.in index d8569e63b..f9a06e57a 100755 --- a/scripts/zmfilter.pl.in +++ b/scripts/zmfilter.pl.in @@ -914,8 +914,29 @@ sub sendMessage ); } ### Send the Message - MIME::Lite->send( "smtp", $Config{ZM_EMAIL_HOST}, Timeout=>60 ); - $mail->send(); + if ( $Config{ZM_SSMTP_MAIL} ){ + + my $ssmtp_location = $Config{ZM_SSMTP_PATH}; + + if( ! $ssmtp_location ){ + + $ssmtp_location = qx('which ssmtp'); + + if ( logDebugging() ) + { + Debug( "which ssmtp: $ssmtp_location - set ssmtp path in options to suppress this message\n" ); + } + + } + + $mail->send( 'sendmail', $ssmtp_location, $Config{ZM_MESSAGE_ADDRESS} ); + + }else{ + + MIME::Lite->send( "smtp", $Config{ZM_EMAIL_HOST}, Timeout=>60 ); + $mail->send(); + } + } else { From 52255e594e2ae740a3ef897e15aa6eef01f48371 Mon Sep 17 00:00:00 2001 From: mdrush Date: Sat, 27 Aug 2016 15:18:00 -0700 Subject: [PATCH 26/48] improved style, added fallback when ssmtp can't be found --- scripts/zmfilter.pl.in | 71 +++++++++++++++++++----------------------- 1 file changed, 32 insertions(+), 39 deletions(-) diff --git a/scripts/zmfilter.pl.in b/scripts/zmfilter.pl.in index f9a06e57a..ab60cb613 100755 --- a/scripts/zmfilter.pl.in +++ b/scripts/zmfilter.pl.in @@ -795,31 +795,27 @@ sub sendEmail Disposition => "attachment" ); } - if ( $Config{ZM_SSMTP_MAIL} ){ - + ### Send the Message + if ( $Config{ZM_SSMTP_MAIL} ) { my $ssmtp_location = $Config{ZM_SSMTP_PATH}; - - if( ! $ssmtp_location ){ - - $ssmtp_location = qx('which ssmtp'); - - if ( logDebugging() ) - { - Debug( "which ssmtp: $ssmtp_location - set ssmtp path in options to suppress this message\n" ); - } - + if( !$ssmtp_location ) { + if ( logDebugging() ) + Debug( "which ssmtp: $ssmtp_location - set ssmtp path in options to suppress this message\n" ); + + $ssmtp_location = qx('which ssmtp'); + if ( !$ssmtp_location ) { + Error( "Can't find ssmtp, trying MIME::Lite->send" ); + MIME::Lite->send( "smtp", $Config{ZM_EMAIL_HOST}, Timeout=>60 ); + $mail->send(); + } else { + ### Send using SSMTP + $mail->send( 'sendmail', $ssmtp_location, $Config{ZM_EMAIL_ADDRESS} ); + } } - - $mail->send( 'sendmail', $ssmtp_location, $Config{ZM_EMAIL_ADDRESS} ); - - }else{ - + } else { MIME::Lite->send( "smtp", $Config{ZM_EMAIL_HOST}, Timeout=>60 ); $mail->send(); } - ### Send the Message - #MIME::Lite->send( "smtp", $Config{ZM_EMAIL_HOST}, Timeout=>60 ); - #$mail->send(); } else { @@ -914,29 +910,26 @@ sub sendMessage ); } ### Send the Message - if ( $Config{ZM_SSMTP_MAIL} ){ - + if ( $Config{ZM_SSMTP_MAIL} ) { my $ssmtp_location = $Config{ZM_SSMTP_PATH}; - - if( ! $ssmtp_location ){ - - $ssmtp_location = qx('which ssmtp'); - - if ( logDebugging() ) - { - Debug( "which ssmtp: $ssmtp_location - set ssmtp path in options to suppress this message\n" ); - } - + if( !$ssmtp_location ) { + if ( logDebugging() ) + Debug( "which ssmtp: $ssmtp_location - set ssmtp path in options to suppress this message\n" ); + + $ssmtp_location = qx('which ssmtp'); + if ( !$ssmtp_location ) { + Error( "Can't find ssmtp, trying MIME::Lite->send" ); + MIME::Lite->send( "smtp", $Config{ZM_EMAIL_HOST}, Timeout=>60 ); + $mail->send(); + } else { + ### Send using SSMTP + $mail->send( 'sendmail', $ssmtp_location, $Config{ZM_MESSAGE_ADDRESS} ); + } } - - $mail->send( 'sendmail', $ssmtp_location, $Config{ZM_MESSAGE_ADDRESS} ); - - }else{ - + } else { MIME::Lite->send( "smtp", $Config{ZM_EMAIL_HOST}, Timeout=>60 ); $mail->send(); - } - + } } else { From 2d161924c00a058d93b189e2dc9272dbe3a51e14 Mon Sep 17 00:00:00 2001 From: mdrush Date: Sat, 27 Aug 2016 15:34:10 -0700 Subject: [PATCH 27/48] changed error message to debug message --- scripts/zmfilter.pl.in | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/zmfilter.pl.in b/scripts/zmfilter.pl.in index ab60cb613..b2a857a4a 100755 --- a/scripts/zmfilter.pl.in +++ b/scripts/zmfilter.pl.in @@ -804,7 +804,7 @@ sub sendEmail $ssmtp_location = qx('which ssmtp'); if ( !$ssmtp_location ) { - Error( "Can't find ssmtp, trying MIME::Lite->send" ); + Debug( "Can't find ssmtp, trying MIME::Lite->send" ); MIME::Lite->send( "smtp", $Config{ZM_EMAIL_HOST}, Timeout=>60 ); $mail->send(); } else { @@ -918,7 +918,7 @@ sub sendMessage $ssmtp_location = qx('which ssmtp'); if ( !$ssmtp_location ) { - Error( "Can't find ssmtp, trying MIME::Lite->send" ); + Debug( "Can't find ssmtp, trying MIME::Lite->send" ); MIME::Lite->send( "smtp", $Config{ZM_EMAIL_HOST}, Timeout=>60 ); $mail->send(); } else { From 16a9de3b1b0a58170f14ea64c5430e482e79c62c Mon Sep 17 00:00:00 2001 From: mdrush Date: Sat, 27 Aug 2016 15:39:04 -0700 Subject: [PATCH 28/48] added missing brackets --- scripts/zmfilter.pl.in | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/scripts/zmfilter.pl.in b/scripts/zmfilter.pl.in index b2a857a4a..33b4ab1a2 100755 --- a/scripts/zmfilter.pl.in +++ b/scripts/zmfilter.pl.in @@ -799,8 +799,9 @@ sub sendEmail if ( $Config{ZM_SSMTP_MAIL} ) { my $ssmtp_location = $Config{ZM_SSMTP_PATH}; if( !$ssmtp_location ) { - if ( logDebugging() ) + if ( logDebugging() ) { Debug( "which ssmtp: $ssmtp_location - set ssmtp path in options to suppress this message\n" ); + } $ssmtp_location = qx('which ssmtp'); if ( !$ssmtp_location ) { @@ -913,8 +914,9 @@ sub sendMessage if ( $Config{ZM_SSMTP_MAIL} ) { my $ssmtp_location = $Config{ZM_SSMTP_PATH}; if( !$ssmtp_location ) { - if ( logDebugging() ) + if ( logDebugging() ) { Debug( "which ssmtp: $ssmtp_location - set ssmtp path in options to suppress this message\n" ); + } $ssmtp_location = qx('which ssmtp'); if ( !$ssmtp_location ) { From 69a71b1a375c5c405ab9f8732a7c466e51041e07 Mon Sep 17 00:00:00 2001 From: mdrush Date: Sat, 27 Aug 2016 16:16:01 -0700 Subject: [PATCH 29/48] cleaned up logic --- scripts/zmfilter.pl.in | 38 ++++++++++++++++++-------------------- 1 file changed, 18 insertions(+), 20 deletions(-) diff --git a/scripts/zmfilter.pl.in b/scripts/zmfilter.pl.in index 33b4ab1a2..e2ee7597f 100755 --- a/scripts/zmfilter.pl.in +++ b/scripts/zmfilter.pl.in @@ -798,20 +798,19 @@ sub sendEmail ### Send the Message if ( $Config{ZM_SSMTP_MAIL} ) { my $ssmtp_location = $Config{ZM_SSMTP_PATH}; - if( !$ssmtp_location ) { + if ( !$ssmtp_location ) { if ( logDebugging() ) { Debug( "which ssmtp: $ssmtp_location - set ssmtp path in options to suppress this message\n" ); } - $ssmtp_location = qx('which ssmtp'); - if ( !$ssmtp_location ) { - Debug( "Can't find ssmtp, trying MIME::Lite->send" ); - MIME::Lite->send( "smtp", $Config{ZM_EMAIL_HOST}, Timeout=>60 ); - $mail->send(); - } else { - ### Send using SSMTP - $mail->send( 'sendmail', $ssmtp_location, $Config{ZM_EMAIL_ADDRESS} ); - } + } + if ( !$ssmtp_location ) { + Debug( "Can't find ssmtp, trying MIME::Lite->send" ); + MIME::Lite->send( "smtp", $Config{ZM_EMAIL_HOST}, Timeout=>60 ); + $mail->send(); + } else { + ### Send using SSMTP + $mail->send( 'sendmail', $ssmtp_location, $Config{ZM_EMAIL_ADDRESS} ); } } else { MIME::Lite->send( "smtp", $Config{ZM_EMAIL_HOST}, Timeout=>60 ); @@ -913,20 +912,19 @@ sub sendMessage ### Send the Message if ( $Config{ZM_SSMTP_MAIL} ) { my $ssmtp_location = $Config{ZM_SSMTP_PATH}; - if( !$ssmtp_location ) { + if ( !$ssmtp_location ) { if ( logDebugging() ) { Debug( "which ssmtp: $ssmtp_location - set ssmtp path in options to suppress this message\n" ); } - $ssmtp_location = qx('which ssmtp'); - if ( !$ssmtp_location ) { - Debug( "Can't find ssmtp, trying MIME::Lite->send" ); - MIME::Lite->send( "smtp", $Config{ZM_EMAIL_HOST}, Timeout=>60 ); - $mail->send(); - } else { - ### Send using SSMTP - $mail->send( 'sendmail', $ssmtp_location, $Config{ZM_MESSAGE_ADDRESS} ); - } + } + if ( !$ssmtp_location ) { + Debug( "Can't find ssmtp, trying MIME::Lite->send" ); + MIME::Lite->send( "smtp", $Config{ZM_EMAIL_HOST}, Timeout=>60 ); + $mail->send(); + } else { + ### Send using SSMTP + $mail->send( 'sendmail', $ssmtp_location, $Config{ZM_MESSAGE_ADDRESS} ); } } else { MIME::Lite->send( "smtp", $Config{ZM_EMAIL_HOST}, Timeout=>60 ); From 28b18066a9ab6ffb1170d750505300d5adadd739 Mon Sep 17 00:00:00 2001 From: Don Law Date: Mon, 29 Aug 2016 20:34:54 -0400 Subject: [PATCH 30/48] Fix name of OPT_USE_AUTH option in getting started guide. --- docs/userguide/gettingstarted.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/userguide/gettingstarted.rst b/docs/userguide/gettingstarted.rst index b2e92f63f..713a667b5 100644 --- a/docs/userguide/gettingstarted.rst +++ b/docs/userguide/gettingstarted.rst @@ -16,7 +16,7 @@ We strongly recommend enabling authentication right away. There are some situati .. image:: images/getting-started-enable-auth.png * The relevant portions to change are marked in red above -* Enable OPT_USE_ATH - this automatically switches to authentication mode with a default user (more on that later) +* Enable OPT_USE_AUTH - this automatically switches to authentication mode with a default user (more on that later) * Select a random string for AUTH_HASH_SECRET - this is used to make the authentication logic more secure, so please generate your own string and please don't use the same value in the example. * The other options highlighed above should already be set, but if not, please make sure they are From 4b6b28983e91639a92b4d775e57b2ce7522e3e5e Mon Sep 17 00:00:00 2001 From: Kyle Johnson Date: Tue, 30 Aug 2016 09:47:08 -0600 Subject: [PATCH 31/48] Correct spelling of 'Mageia' in readme --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 42a570cc1..460fe62ff 100644 --- a/README.md +++ b/README.md @@ -30,7 +30,7 @@ This is the recommended method to install ZoneMinder onto your system. ZoneMinde - RHEL/CentOS and clones via [zmrepo](http://zmrepo.zoneminder.com/) - Fedora via [zmrepo](http://zmrepo.zoneminder.com/) - OpenSuse via [third party repository](http://www.zoneminder.com/wiki/index.php/Installing_using_ZoneMinder_RPMs_for_SuSE) -- Maegia from their default repository +- Mageia from their default repository If a repository that hosts ZoneMinder packages is not available for your distro, then you are encouraged to build your own package, rather than build from source. While each distro is different in ways that set it apart from all the others, they are often similar enough to allow you to adapt another distro's package building instructions to your own. From 0950ecbcb9deff36c21224a9b9f7426dd5f6b579 Mon Sep 17 00:00:00 2001 From: Matt Durant Date: Wed, 31 Aug 2016 19:36:14 -0500 Subject: [PATCH 32/48] Replaced loops to create color tables during initialization with statically declared arrays. --- src/zm_image.cpp | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/src/zm_image.cpp b/src/zm_image.cpp index 8e5abe8cf..edf9b47aa 100644 --- a/src/zm_image.cpp +++ b/src/zm_image.cpp @@ -26,6 +26,18 @@ #include #include +static unsigned char y_table_global[] = {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 3, 4, 5, 6, 8, 9, 10, 11, 12, 13, 15, 16, 17, 18, 19, 20, 22, 23, 24, 25, 26, 27, 29, 30, 31, 32, 33, 34, 36, 37, 38, 39, 40, 41, 43, 44, 45, 46, 47, 48, 50, 51, 52, 53, 54, 55, 57, 58, 59, 60, 61, 62, 64, 65, 66, 67, 68, 69, 71, 72, 73, 74, 75, 76, 78, 79, 80, 81, 82, 83, 85, 86, 87, 88, 89, 90, 91, 93, 94, 95, 96, 97, 98, 100, 101, 102, 103, 104, 105, 107, 108, 109, 110, 111, 112, 114, 115, 116, 117, 118, 119, 121, 122, 123, 124, 125, 126, 128, 129, 130, 131, 132, 133, 135, 136, 137, 138, 139, 140, 142, 143, 144, 145, 146, 147, 149, 150, 151, 152, 153, 154, 156, 157, 158, 159, 160, 161, 163, 164, 165, 166, 167, 168, 170, 171, 172, 173, 174, 175, 176, 178, 179, 180, 181, 182, 183, 185, 186, 187, 188, 189, 190, 192, 193, 194, 195, 196, 197, 199, 200, 201, 202, 203, 204, 206, 207, 208, 209, 210, 211, 213, 214, 215, 216, 217, 218, 220, 221, 222, 223, 224, 225, 227, 228, 229, 230, 231, 232, 234, 235, 236, 237, 238, 239, 241, 242, 243, 244, 245, 246, 248, 249, 250, 251, 252, 253, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255}; + +static signed char uv_table_global[] = {-127, -127, -127, -127, -127, -127, -127, -127, -127, -127, -127, -127, -127, -127, -127, -127, -127, -125, -124, -123, -122, -121, -120, -119, -117, -116, -115, -114, -113, -112, -111, -109, -108, -107, -106, -105, -104, -103, -102, -100, -99, -98, -97, -96, -95, -94, -92, -91, -90, -89, -88, -87, -86, -85, -83, -82, -81, -80, -79, -78, -77, -75, -74, -73, -72, -71, -70, -69, -68, -66, -65, -64, -63, -62, -61, -60, -58, -57, -56, -55, -54, -53, -52, -51, -49, -48, -47, -46, -45, -44, -43, -41, -40, -39, -38, -37, -36, -35, -34, -32, -31, -30, -29, -28, -27, -26, -24, -23, -22, -21, -20, -19, -18, -17, -15, -14, -13, -12, -11, -10, -9, -7, -6, -5, -4, -3, -2, -1, 0, 1, 2, 3, 4, 5, 6, 7, 9, 10, 11, 12, 13, 14, 15, 17, 18, 19, 20, 21, 22, 23, 24, 26, 27, 28, 29, 30, 31, 32, 34, 35, 36, 37, 38, 39, 40, 41, 43, 44, 45, 46, 47, 48, 49, 51, 52, 53, 54, 55, 56, 57, 58, 60, 61, 62, 63, 64, 65, 66, 68, 69, 70, 71, 72, 73, 74, 75, 77, 78, 79, 80, 81, 82, 83, 85, 86, 87, 88, 89, 90, 91, 92, 94, 95, 96, 97, 98, 99, 100, 102, 103, 104, 105, 106, 107, 108, 109, 111, 112, 113, 114, 115, 116, 117, 119, 120, 121, 122, 123, 124, 125, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127}; + +static short r_v_table_global[] = {-179, -178, -176, -175, -173, -172, -171, -169, -168, -166, -165, -164, -162, -161, -159, -158, -157, -155, -154, -152, -151, -150, -148, -147, -145, -144, -143, -141, -140, -138, -137, -135, -134, -133, -131, -130, -128, -127, -126, -124, -123, -121, -120, -119, -117, -116, -114, -113, -112, -110, -109, -107, -106, -105, -103, -102, -100, -99, -98, -96, -95, -93, -92, -91, -89, -88, -86, -85, -84, -82, -81, -79, -78, -77, -75, -74, -72, -71, -70, -68, -67, -65, -64, -63, -61, -60, -58, -57, -56, -54, -53, -51, -50, -49, -47, -46, -44, -43, -42, -40, -39, -37, -36, -35, -33, -32, -30, -29, -28, -26, -25, -23, -22, -21, -19, -18, -16, -15, -14, -12, -11, -9, -8, -7, -5, -4, -2, -1, 0, 1, 2, 4, 5, 7, 8, 9, 11, 12, 14, 15, 16, 18, 19, 21, 22, 23, 25, 26, 28, 29, 30, 32, 33, 35, 36, 37, 39, 40, 42, 43, 44, 46, 47, 49, 50, 51, 53, 54, 56, 57, 58, 60, 61, 63, 64, 65, 67, 68, 70, 71, 72, 74, 75, 77, 78, 79, 81, 82, 84, 85, 86, 88, 89, 91, 92, 93, 95, 96, 98, 99, 100, 102, 103, 105, 106, 107, 109, 110, 112, 113, 114, 116, 117, 119, 120, 121, 123, 124, 126, 127, 128, 130, 131, 133, 134, 135, 137, 138, 140, 141, 143, 144, 145, 147, 148, 150, 151, 152, 154, 155, 157, 158, 159, 161, 162, 164, 165, 166, 168, 169, 171, 172, 173, 175, 176}; + +static short g_u_table_global[] = {-44, -43, -43, -43, -42, -42, -41, -41, -41, -40, -40, -40, -39, -39, -39, -38, -38, -38, -37, -37, -37, -36, -36, -36, -35, -35, -35, -34, -34, -34, -33, -33, -33, -32, -32, -31, -31, -31, -30, -30, -30, -29, -29, -29, -28, -28, -28, -27, -27, -27, -26, -26, -26, -25, -25, -25, -24, -24, -24, -23, -23, -23, -22, -22, -22, -21, -21, -20, -20, -20, -19, -19, -19, -18, -18, -18, -17, -17, -17, -16, -16, -16, -15, -15, -15, -14, -14, -14, -13, -13, -13, -12, -12, -12, -11, -11, -11, -10, -10, -9, -9, -9, -8, -8, -8, -7, -7, -7, -6, -6, -6, -5, -5, -5, -4, -4, -4, -3, -3, -3, -2, -2, -2, -1, -1, -1, 0, 0, 0, 0, 0, 1, 1, 1, 2, 2, 2, 3, 3, 3, 4, 4, 4, 5, 5, 5, 6, 6, 6, 7, 7, 7, 8, 8, 8, 9, 9, 9, 10, 10, 11, 11, 11, 12, 12, 12, 13, 13, 13, 14, 14, 14, 15, 15, 15, 16, 16, 16, 17, 17, 17, 18, 18, 18, 19, 19, 19, 20, 20, 20, 21, 21, 22, 22, 22, 23, 23, 23, 24, 24, 24, 25, 25, 25, 26, 26, 26, 27, 27, 27, 28, 28, 28, 29, 29, 29, 30, 30, 30, 31, 31, 31, 32, 32, 33, 33, 33, 34, 34, 34, 35, 35, 35, 36, 36, 36, 37, 37, 37, 38, 38, 38, 39, 39, 39, 40, 40, 40, 41, 41, 41, 42, 42, 43, 43}; + +static short g_v_table_global[] = {-91, -90, -89, -89, -88, -87, -87, -86, -85, -84, -84, -83, -82, -82, -81, -80, -79, -79, -78, -77, -77, -76, -75, -74, -74, -73, -72, -72, -71, -70, -69, -69, -68, -67, -67, -66, -65, -64, -64, -63, -62, -62, -61, -60, -59, -59, -58, -57, -57, -56, -55, -54, -54, -53, -52, -52, -51, -50, -49, -49, -48, -47, -47, -46, -45, -44, -44, -43, -42, -42, -41, -40, -39, -39, -38, -37, -37, -36, -35, -34, -34, -33, -32, -32, -31, -30, -29, -29, -28, -27, -27, -26, -25, -24, -24, -23, -22, -22, -21, -20, -19, -19, -18, -17, -17, -16, -15, -14, -14, -13, -12, -12, -11, -10, -9, -9, -8, -7, -7, -6, -5, -4, -4, -3, -2, -2, -1, 0, 0, 0, 1, 2, 2, 3, 4, 4, 5, 6, 7, 7, 8, 9, 9, 10, 11, 12, 12, 13, 14, 14, 15, 16, 17, 17, 18, 19, 19, 20, 21, 22, 22, 23, 24, 24, 25, 26, 27, 27, 28, 29, 29, 30, 31, 32, 32, 33, 34, 34, 35, 36, 37, 37, 38, 39, 39, 40, 41, 42, 42, 43, 44, 44, 45, 46, 47, 47, 48, 49, 49, 50, 51, 52, 52, 53, 54, 54, 55, 56, 57, 57, 58, 59, 59, 60, 61, 62, 62, 63, 64, 64, 65, 66, 67, 67, 68, 69, 69, 70, 71, 72, 72, 73, 74, 74, 75, 76, 77, 77, 78, 79, 79, 80, 81, 82, 82, 83, 84, 84, 85, 86, 87, 87, 88, 89, 89}; + +static short b_u_table_global[] = {-226, -225, -223, -221, -219, -217, -216, -214, -212, -210, -209, -207, -205, -203, -202, -200, -198, -196, -194, -193, -191, -189, -187, -186, -184, -182, -180, -178, -177, -175, -173, -171, -170, -168, -166, -164, -163, -161, -159, -157, -155, -154, -152, -150, -148, -147, -145, -143, -141, -139, -138, -136, -134, -132, -131, -129, -127, -125, -124, -122, -120, -118, -116, -115, -113, -111, -109, -108, -106, -104, -102, -101, -99, -97, -95, -93, -92, -90, -88, -86, -85, -83, -81, -79, -77, -76, -74, -72, -70, -69, -67, -65, -63, -62, -60, -58, -56, -54, -53, -51, -49, -47, -46, -44, -42, -40, -38, -37, -35, -33, -31, -30, -28, -26, -24, -23, -21, -19, -17, -15, -14, -12, -10, -8, -7, -5, -3, -1, 0, 1, 3, 5, 7, 8, 10, 12, 14, 15, 17, 19, 21, 23, 24, 26, 28, 30, 31, 33, 35, 37, 38, 40, 42, 44, 46, 47, 49, 51, 53, 54, 56, 58, 60, 62, 63, 65, 67, 69, 70, 72, 74, 76, 77, 79, 81, 83, 85, 86, 88, 90, 92, 93, 95, 97, 99, 101, 102, 104, 106, 108, 109, 111, 113, 115, 116, 118, 120, 122, 124, 125, 127, 129, 131, 132, 134, 136, 138, 139, 141, 143, 145, 147, 148, 150, 152, 154, 155, 157, 159, 161, 163, 164, 166, 168, 170, 171, 173, 175, 177, 178, 180, 182, 184, 186, 187, 189, 191, 193, 194, 196, 198, 200, 202, 203, 205, 207, 209, 210, 212, 214, 216, 217, 219, 221, 223}; + bool Image::initialised = false; static unsigned char *y_table; static signed char *uv_table; @@ -145,12 +157,14 @@ Image::~Image() DumpImgBuffer(); if ( initialised ) { + /* delete[] y_table; delete[] uv_table; delete[] r_v_table; delete[] g_v_table; delete[] g_u_table; delete[] b_u_table; + */ initialised = false; } if ( readjpg_dcinfo ) @@ -275,6 +289,13 @@ void Image::Initialise() /* Code below relocated from zm_local_camera */ Debug( 3, "Setting up static colour tables" ); + y_table = y_table_global; + uv_table = uv_table_global; + r_v_table = r_v_table_global; + g_v_table = g_v_table_global; + g_u_table = g_u_table_global; + b_u_table = b_u_table_global; + /* y_table = new unsigned char[256]; for ( int i = 0; i <= 255; i++ ) { @@ -310,6 +331,7 @@ void Image::Initialise() g_v_table[i] = (714*(i-128))/1000; b_u_table[i] = (1772*(i-128))/1000; } + */ initialised = true; } From 350352d9566b1ffb6cca71751aa3f4999f8ceb2e Mon Sep 17 00:00:00 2001 From: Matt Durant Date: Wed, 31 Aug 2016 20:56:30 -0500 Subject: [PATCH 33/48] Added check for SINGLE_IMAGE if ReadData() detects the socket closed by remote side to return 0 instead of -1. --- src/zm_remote_camera_http.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/zm_remote_camera_http.cpp b/src/zm_remote_camera_http.cpp index 9454b8d69..c8d49ca5b 100644 --- a/src/zm_remote_camera_http.cpp +++ b/src/zm_remote_camera_http.cpp @@ -192,6 +192,8 @@ int RemoteCameraHttp::ReadData( Buffer &buffer, int bytes_expected ) if ( total_bytes_to_read == 0 ) { + if( mode == SINGLE_IMAGE ) + return( 0 ); // If socket is closed locally, then select will fail, but if it is closed remotely // then we have an exception on our socket.. but no data. Debug( 3, "Socket closed remotely" ); From 55f5db55dd15e37f5d776b6ddc4b102b0e42af47 Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Thu, 1 Sep 2016 11:43:20 -0400 Subject: [PATCH 34/48] implement suggested code to stop the monitor when Function is set to None --- web/api/app/Controller/MonitorsController.php | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/web/api/app/Controller/MonitorsController.php b/web/api/app/Controller/MonitorsController.php index 7bf36de75..a0a4c8c6b 100644 --- a/web/api/app/Controller/MonitorsController.php +++ b/web/api/app/Controller/MonitorsController.php @@ -137,9 +137,18 @@ public function beforeFilter() { 'message' => $message, '_serialize' => array('message') )); - // - restart this monitor after change - // We don't pass the request data as the monitor object because it may be a subset of the full monitor array - $this->daemonControl( $this->Monitor->id, 'restart' ); + + // - restart or stop this monitor after change + $func = $this->Monitor->find('first', array( + 'fields' => array('Function'), + 'conditions' => array('Id' => $id) + ))['Monitor']['Function']; + // We don't pass the request data as the monitor object because it may be a subset of the full monitor array + if ( $func == 'None' ) { + $this->daemonControl( $this->Monitor->id, 'stop' ); + } else { + $this->daemonControl( $this->Monitor->id, 'restart' ); + } } /** From 9a4330eb59432c6448f9051ff438aa2b75b7de75 Mon Sep 17 00:00:00 2001 From: Pliable Pixels Date: Sat, 3 Sep 2016 14:46:47 -0400 Subject: [PATCH 35/48] #1537 Zones Controller not returning all zones --- web/api/app/Controller/ZonesController.php | 46 +++++++++++++++------- 1 file changed, 32 insertions(+), 14 deletions(-) diff --git a/web/api/app/Controller/ZonesController.php b/web/api/app/Controller/ZonesController.php index be80c57fc..d05fc8001 100644 --- a/web/api/app/Controller/ZonesController.php +++ b/web/api/app/Controller/ZonesController.php @@ -7,23 +7,41 @@ App::uses('AppController', 'Controller'); */ class ZonesController extends AppController { -// Find all zones which belong to a MonitorId - public function forMonitor($id = null) { - $this->loadModel('Monitor'); - if (!$this->Monitor->exists($id)) { - throw new NotFoundException(__('Invalid monitor')); - } +/** + * Components + * + * @var array + */ + public $components = array('RequestHandler'); - $this->Zone->recursive = -1; +public function beforeFilter() { + parent::beforeFilter(); + $canView = $this->Session->Read('monitorPermission'); + if ($canView =='None') + { + throw new UnauthorizedException(__('Insufficient Privileges')); + return; + } - $zones = $this->Zone->find('all', array( - 'conditions' => array('MonitorId' => $id) - )); - $this->set(array( - 'zones' => $zones, - '_serialize' => array('zones') - )); +} +public function index() { + $this->Zone->recursive = -1; + + $allowedMonitors=preg_split ('@,@', $this->Session->Read('allowedMonitors'),NULL, PREG_SPLIT_NO_EMPTY); + if (!empty($allowedMonitors)) + { + $mon_options = array('Zones.MonitorId' => $allowedMonitors); } + else + { + $mon_options=''; + } + $zones = $this->Zone->find('all',$mon_options); + $this->set(array( + 'zones' => $zones, + '_serialize' => array('zones') + )); +} /** * add method * From 7bf0b3c4234c9a3d30ad3be20e3a42fe9797e8e5 Mon Sep 17 00:00:00 2001 From: Pliable Pixels Date: Sat, 3 Sep 2016 14:51:24 -0400 Subject: [PATCH 36/48] readded forMonitor - removed by mistake --- web/api/app/Controller/ZonesController.php | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/web/api/app/Controller/ZonesController.php b/web/api/app/Controller/ZonesController.php index d05fc8001..aa54dbfdd 100644 --- a/web/api/app/Controller/ZonesController.php +++ b/web/api/app/Controller/ZonesController.php @@ -12,7 +12,7 @@ class ZonesController extends AppController { * * @var array */ - public $components = array('RequestHandler'); +public $components = array('RequestHandler'); public function beforeFilter() { parent::beforeFilter(); @@ -24,6 +24,22 @@ public function beforeFilter() { } } + +// Find all zones which belong to a MonitorId +public function forMonitor($id = null) { + $this->loadModel('Monitor'); + if (!$this->Monitor->exists($id)) { + throw new NotFoundException(__('Invalid monitor')); + } + $this->Zone->recursive = -1; + $zones = $this->Zone->find('all', array( + 'conditions' => array('MonitorId' => $id) + )); + $this->set(array( + 'zones' => $zones, + '_serialize' => array('zones') + )); +} public function index() { $this->Zone->recursive = -1; From 1440dd926563254500f42106c81b8a59c622870a Mon Sep 17 00:00:00 2001 From: Pliable Pixels Date: Sat, 3 Sep 2016 15:02:32 -0400 Subject: [PATCH 37/48] retab --- web/api/app/Controller/ZonesController.php | 178 ++++++++++----------- 1 file changed, 89 insertions(+), 89 deletions(-) diff --git a/web/api/app/Controller/ZonesController.php b/web/api/app/Controller/ZonesController.php index aa54dbfdd..5fbadc2ed 100644 --- a/web/api/app/Controller/ZonesController.php +++ b/web/api/app/Controller/ZonesController.php @@ -27,52 +27,52 @@ public function beforeFilter() { // Find all zones which belong to a MonitorId public function forMonitor($id = null) { - $this->loadModel('Monitor'); - if (!$this->Monitor->exists($id)) { - throw new NotFoundException(__('Invalid monitor')); - } - $this->Zone->recursive = -1; - $zones = $this->Zone->find('all', array( - 'conditions' => array('MonitorId' => $id) - )); - $this->set(array( - 'zones' => $zones, - '_serialize' => array('zones') - )); + $this->loadModel('Monitor'); + if (!$this->Monitor->exists($id)) { + throw new NotFoundException(__('Invalid monitor')); + } + $this->Zone->recursive = -1; + $zones = $this->Zone->find('all', array( + 'conditions' => array('MonitorId' => $id) + )); + $this->set(array( + 'zones' => $zones, + '_serialize' => array('zones') + )); } public function index() { - $this->Zone->recursive = -1; - - $allowedMonitors=preg_split ('@,@', $this->Session->Read('allowedMonitors'),NULL, PREG_SPLIT_NO_EMPTY); - if (!empty($allowedMonitors)) - { - $mon_options = array('Zones.MonitorId' => $allowedMonitors); - } - else - { - $mon_options=''; - } - $zones = $this->Zone->find('all',$mon_options); - $this->set(array( - 'zones' => $zones, - '_serialize' => array('zones') - )); + $this->Zone->recursive = -1; + + $allowedMonitors=preg_split ('@,@', $this->Session->Read('allowedMonitors'),NULL, PREG_SPLIT_NO_EMPTY); + if (!empty($allowedMonitors)) + { + $mon_options = array('Zones.MonitorId' => $allowedMonitors); + } + else + { + $mon_options=''; + } + $zones = $this->Zone->find('all',$mon_options); + $this->set(array( + 'zones' => $zones, + '_serialize' => array('zones') + )); } /** * add method * * @return void */ - public function add() { - if ($this->request->is('post')) { - $this->Zone->create(); - if ($this->Zone->save($this->request->data)) { - return $this->flash(__('The zone has been saved.'), array('action' => 'index')); - } - } - $monitors = $this->Zone->Monitor->find('list'); - $this->set(compact('monitors')); - } + public function add() { + if ($this->request->is('post')) { + $this->Zone->create(); + if ($this->Zone->save($this->request->data)) { + return $this->flash(__('The zone has been saved.'), array('action' => 'index')); + } + } + $monitors = $this->Zone->Monitor->find('list'); + $this->set(compact('monitors')); + } /** * edit method @@ -81,23 +81,23 @@ public function index() { * @param string $id * @return void */ - public function edit($id = null) { - $this->Zone->id = $id; + public function edit($id = null) { + $this->Zone->id = $id; - if (!$this->Zone->exists($id)) { - throw new NotFoundException(__('Invalid zone')); - } - if ($this->request->is(array('post', 'put'))) { - if ($this->Zone->save($this->request->data)) { - return $this->flash(__('The zone has been saved.'), array('action' => 'index')); - } - } else { - $options = array('conditions' => array('Zone.' . $this->Zone->primaryKey => $id)); - $this->request->data = $this->Zone->find('first', $options); - } - $monitors = $this->Zone->Monitor->find('list'); - $this->set(compact('monitors')); - } + if (!$this->Zone->exists($id)) { + throw new NotFoundException(__('Invalid zone')); + } + if ($this->request->is(array('post', 'put'))) { + if ($this->Zone->save($this->request->data)) { + return $this->flash(__('The zone has been saved.'), array('action' => 'index')); + } + } else { + $options = array('conditions' => array('Zone.' . $this->Zone->primaryKey => $id)); + $this->request->data = $this->Zone->find('first', $options); + } + $monitors = $this->Zone->Monitor->find('list'); + $this->set(compact('monitors')); + } /** * delete method @@ -106,49 +106,49 @@ public function index() { * @param string $id * @return void */ - public function delete($id = null) { - $this->Zone->id = $id; - if (!$this->Zone->exists()) { - throw new NotFoundException(__('Invalid zone')); - } - $this->request->allowMethod('post', 'delete'); - if ($this->Zone->delete()) { - return $this->flash(__('The zone has been deleted.'), array('action' => 'index')); - } else { - return $this->flash(__('The zone could not be deleted. Please, try again.'), array('action' => 'index')); - } - } + public function delete($id = null) { + $this->Zone->id = $id; + if (!$this->Zone->exists()) { + throw new NotFoundException(__('Invalid zone')); + } + $this->request->allowMethod('post', 'delete'); + if ($this->Zone->delete()) { + return $this->flash(__('The zone has been deleted.'), array('action' => 'index')); + } else { + return $this->flash(__('The zone could not be deleted. Please, try again.'), array('action' => 'index')); + } + } - public function createZoneImage( $id = null ) { - $this->loadModel('Monitor'); - $this->Monitor->id = $id; - if (!$this->Monitor->exists()) { - throw new NotFoundException(__('Invalid zone')); - } + public function createZoneImage( $id = null ) { + $this->loadModel('Monitor'); + $this->Monitor->id = $id; + if (!$this->Monitor->exists()) { + throw new NotFoundException(__('Invalid zone')); + } - $this->loadModel('Config'); - $zm_dir_images = $this->Config->find('list', array( - 'conditions' => array('Name' => 'ZM_DIR_IMAGES'), - 'fields' => array('Name', 'Value') - )); + $this->loadModel('Config'); + $zm_dir_images = $this->Config->find('list', array( + 'conditions' => array('Name' => 'ZM_DIR_IMAGES'), + 'fields' => array('Name', 'Value') + )); - $zm_dir_images = $zm_dir_images['ZM_DIR_IMAGES']; - $zm_path_web = Configure::read('ZM_PATH_WEB'); - $zm_path_bin = Configure::read('ZM_PATH_BIN'); - $images_path = "$zm_path_web/$zm_dir_images"; + $zm_dir_images = $zm_dir_images['ZM_DIR_IMAGES']; + $zm_path_web = Configure::read('ZM_PATH_WEB'); + $zm_path_bin = Configure::read('ZM_PATH_BIN'); + $images_path = "$zm_path_web/$zm_dir_images"; - chdir($images_path); + chdir($images_path); - $command = escapeshellcmd("$zm_path_bin/zmu -z -m $id"); - system( $command, $status ); + $command = escapeshellcmd("$zm_path_bin/zmu -z -m $id"); + system( $command, $status ); - $this->set(array( - 'status' => $status, - '_serialize' => array('status') - )); + $this->set(array( + 'status' => $status, + '_serialize' => array('status') + )); - } + } } From d017138550fc97507be0b86d87e90951dcd50c3d Mon Sep 17 00:00:00 2001 From: corax Date: Fri, 9 Sep 2016 11:25:12 +0200 Subject: [PATCH 38/48] Fix a 'false friend' in German translation --- web/lang/de_de.php | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/web/lang/de_de.php b/web/lang/de_de.php index 316c49e1d..2eb216f08 100644 --- a/web/lang/de_de.php +++ b/web/lang/de_de.php @@ -78,7 +78,7 @@ $SLANG = array( '8BitGrey' => '8-Bit-Grau', 'Action' => 'Aktion', 'Actual' => 'Original', - 'AddNewControl' => 'Neues Kontrollelement hinzufügen', + 'AddNewControl' => 'Neues Steuerelement hinzufügen', 'AddNewMonitor' => 'Neuer Monitor', 'AddNewUser' => 'Neuer Benutzer', 'AddNewZone' => 'Neue Zone', @@ -235,13 +235,13 @@ $SLANG = array( 'ContactAdmin' => 'Bitte kontaktieren Sie den Administrator für weitere Details', 'Continue' => 'Weiter', 'Contrast' => 'Kontrast', - 'Control' => 'Kontrolle', - 'ControlAddress' => 'Kontrolladresse', - 'ControlCap' => 'Kontrollmöglichkeit', - 'ControlCaps' => 'Kontrollmöglichkeiten', - 'ControlDevice' => 'Kontrollgerät', - 'ControlType' => 'Kontrolltyp', - 'Controllable' => 'Kontrollierbar', + 'Control' => 'Steuerung', + 'ControlAddress' => 'Steueradresse', + 'ControlCap' => 'Steuermöglichkeit', + 'ControlCaps' => 'Steuermöglichkeiten', + 'ControlDevice' => 'Steuergerät', + 'ControlType' => 'Steuertyp', + 'Controllable' => 'steuerbar', 'Current' => 'Aktuell', // Added - 2015-04-18 'Cycle' => 'Zyklus', 'CycleWatch' => 'Zeitzyklus', From 430ecd8e329ac9f3f335ab9f2ad8810327afd3ca Mon Sep 17 00:00:00 2001 From: corax Date: Fri, 9 Sep 2016 11:51:53 +0200 Subject: [PATCH 39/48] Fix some too direct translations into German --- web/lang/de_de.php | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/web/lang/de_de.php b/web/lang/de_de.php index 2eb216f08..aed7a2a99 100644 --- a/web/lang/de_de.php +++ b/web/lang/de_de.php @@ -105,7 +105,7 @@ $SLANG = array( 'AreaUnits' => 'Bereich (px/%)', 'AttrAlarmFrames' => 'Alarmbilder', 'AttrArchiveStatus' => 'Archivstatus', - 'AttrAvgScore' => 'Mittlere Punktzahl', + 'AttrAvgScore' => 'Mittlere Wertung', 'AttrCause' => 'Grund', 'AttrDate' => 'Datum', 'AttrDateTime' => 'Datum/Zeit', @@ -114,19 +114,19 @@ $SLANG = array( 'AttrDuration' => 'Dauer', 'AttrFrames' => 'Bilder', 'AttrId' => 'ID', - 'AttrMaxScore' => 'Maximale Punktzahl', + 'AttrMaxScore' => 'Maximale Wertung', 'AttrMonitorId' => 'Monitor-ID', 'AttrMonitorName' => 'Monitorname', 'AttrName' => 'Name', 'AttrNotes' => 'Bemerkungen', 'AttrSystemLoad' => 'Systemlast', 'AttrTime' => 'Zeit', - 'AttrTotalScore' => 'Totale Punktzahl', + 'AttrTotalScore' => 'Gesamtwertung', 'AttrWeekday' => 'Wochentag', 'Auto' => 'Auto', 'AutoStopTimeout' => 'Auto-Stopp-Zeitüberschreitung', 'Available' => 'Verfügbar', // Added - 2009-03-31 - 'AvgBrScore' => 'Mittlere
Punktzahl', + 'AvgBrScore' => 'Mittlere
Wertung', 'Background' => 'Hintergrund', 'BackgroundFilter' => 'Filter im Hintergrund laufen lassen', 'BadAlarmFrameCount' => 'Die Bildanzahl muss ganzzahlig 1 oder größer sein', @@ -167,7 +167,7 @@ $SLANG = array( 'Brightness' => 'Helligkeit', 'Buffer' => 'Buffer', // Added - 2015-04-18 'Buffers' => 'Buffer', - 'CSSDescription' => 'Ändere das standard CSS für diesen Computer.', // Added - 2015-04-18 + 'CSSDescription' => 'Ändere das standardmäßige CSS für diesen Computer.', // Added - 2015-04-18 'CanAutoFocus' => 'Kann Autofokus', 'CanAutoGain' => 'Kann Auto-Verstärkung', 'CanAutoIris' => 'Kann Auto-Blende', @@ -251,7 +251,7 @@ $SLANG = array( 'DefaultRate' => 'Standardrate', 'DefaultScale' => 'Standardskalierung', 'DefaultView' => 'Standardansicht', - 'Deinterlacing' => 'Deinterlacing', // Added - 2015-04-18 + 'Deinterlacing' => 'Zeilenentflechtung', // Added - 2015-04-18 'Delay' => 'Verzögerung', // Added - 2015-04-18 'Delete' => 'Löschen', 'DeleteAndNext' => 'Löschen & Nächstes', @@ -268,7 +268,7 @@ $SLANG = array( 'Devices' => 'Geräte', 'Dimensions' => 'Abmessungen', 'DisableAlarms' => 'Alarme abschalten', - 'Disk' => 'Disk', + 'Disk' => 'Platte', 'Display' => 'Anzeige', // Added - 2011-01-30 'Displaying' => 'Gezeigt', // Added - 2011-06-16 'DoNativeMotionDetection'=> 'Do Native Motion Detection', @@ -358,7 +358,7 @@ $SLANG = array( 'General' => 'Allgemeines', 'GenerateVideo' => 'Erzeuge Video', 'GeneratingVideo' => 'Erzeuge Video...', - 'GoToZoneMinder' => 'Gehe zu ZoneMinder.com', + 'GoToZoneMinder' => 'Besuche ZoneMinder.com', 'Grey' => 'Grau', 'Group' => 'Gruppe', 'Groups' => 'Gruppen', @@ -417,7 +417,7 @@ $SLANG = array( 'Mark' => 'Markieren', 'Max' => 'Max', 'MaxBandwidth' => 'Maximale Bandbreite', - 'MaxBrScore' => 'Maximale
Punktzahl', + 'MaxBrScore' => 'Maximale
Wertung', 'MaxFocusRange' => 'Maximaler Fokusbereich', 'MaxFocusSpeed' => 'Maximale Fokusgeschwindigkeit', 'MaxFocusStep' => 'Maximale Fokusstufe', @@ -482,7 +482,7 @@ $SLANG = array( 'MonitorIds' => 'Monitor-ID', 'MonitorPreset' => 'Monitor-Voreinstellung', 'MonitorPresetIntro' => 'Wählen Sie eine geeignete Voreinstellung aus der folgenden Liste.

Bitte beachten Sie, dass dies mögliche Einstellungen von Ihnen am Monitor überschreiben kann.

', - 'MonitorProbe' => 'Kamera suche', // Added - 2009-03-31 + 'MonitorProbe' => 'Kamerasuche', // Added - 2009-03-31 'MonitorProbeIntro' => 'Die nachfolgende Liste zeigt erkannte Analog- und Netzwerkkameras, ob sie bereits genutzt werden und ob sie zur Auswahl verfügbar sind.

Wähle den gewünschten Eintrag aus der folgenden Liste.

Bitte Beachten: Nicht alle Kameras können erkannt werden. Die Auswahl einer Kamera kann bereits eingetragene Werte im aktuellen Monitor überschreiben.

', // Added - 2009-03-31 'Monitors' => 'Monitore', 'Montage' => 'Montage', @@ -502,7 +502,7 @@ $SLANG = array( 'MustSupplyUsername' => 'Sie müssen einen Usernamen vergeben.', 'Name' => 'Name', 'Near' => 'Nah', - 'Network' => 'Netzwerk', + 'Network' => 'Netz', 'New' => 'Neu', 'NewGroup' => 'Neue Gruppe', 'NewLabel' => 'Neuer Bezeichner', @@ -613,7 +613,7 @@ $SLANG = array( 'SaveAs' => 'Speichere als', 'SaveFilter' => 'Speichere Filter', 'Scale' => 'Skalierung', - 'Score' => 'Punktzahl', + 'Score' => 'Wertung', 'Secs' => 'Sekunden', 'Sectionlength' => 'Sektionslänge', 'Select' => 'Auswahl', @@ -626,7 +626,7 @@ $SLANG = array( 'SetPreset' => 'Setze Voreinstellung', 'Settings' => 'Einstellungen', 'ShowFilterWindow' => 'Zeige Filterfenster', - 'ShowTimeline' => 'Zeige Zeitlinie', + 'ShowTimeline' => 'Zeige Zeitstrahl', 'SignalCheckColour' => 'Farbe des Signalchecks', 'Size' => 'Größe', 'SkinDescription' => 'Wähle den standard Skin für diesen Computer.', // Added - 2011-01-30 @@ -661,7 +661,7 @@ $SLANG = array( 'StreamReplayBuffer' => 'Stream-Wiedergabe-Bildpuffer', 'Submit' => 'Absenden', 'System' => 'System', - 'SystemLog' => 'System Log', // Added - 2011-06-16 + 'SystemLog' => 'System-Log', // Added - 2011-06-16 'TargetColorspace' => 'Zielfarbbereich', // Added - 2015-04-18 'Tele' => 'Tele', 'Thumbnail' => 'Miniaturbild', @@ -669,7 +669,7 @@ $SLANG = array( 'Time' => 'Zeit', 'TimeDelta' => 'Zeitdifferenz', 'TimeStamp' => 'Zeitstempel', - 'Timeline' => 'Zeitlinie', + 'Timeline' => 'Zeitstrahl', 'TimelineTip1' => 'Fahren Sie mit der Maus über die Grafik, um eine Momentaufnahme der Bild- und Ereignisdetails zusehen.', // Added 2013.08.15. 'TimelineTip2' => 'Klicken Sie auf den farbig markierten Bereichen der Grafik oder das Bild, um das Ereignis zu sehen.', // Added 2013.08.15. 'TimelineTip3' => 'Klicken Sie auf den Hintergrund, um in einen kleineren Zeitraum zu vergrößern.', // Added 2013.08.15. @@ -681,8 +681,8 @@ $SLANG = array( 'TimestampLabelSize' => 'Schriftgröße', 'Today' => 'Heute', 'Tools' => 'Werkzeuge', - 'Total' => 'Total', // Added - 2011-06-16 - 'TotalBrScore' => 'Totale
Punktzahl', + 'Total' => 'Insgesamt', // Added - 2011-06-16 + 'TotalBrScore' => 'Gesamt-
wertung', 'TrackDelay' => 'Nachführungsverzögerung', 'TrackMotion' => 'Bewegungs-Nachführung', 'Triggers' => 'Auslöser', From 4dc6fc03b38d2c6dbcf6584cd909b6bdd68381c8 Mon Sep 17 00:00:00 2001 From: corax Date: Fri, 9 Sep 2016 12:32:54 +0200 Subject: [PATCH 40/48] Add a missing translate()-call --- web/skins/classic/views/monitor.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/web/skins/classic/views/monitor.php b/web/skins/classic/views/monitor.php index 25a26799d..fff1b8f17 100644 --- a/web/skins/classic/views/monitor.php +++ b/web/skins/classic/views/monitor.php @@ -697,7 +697,7 @@ switch ( $tab ) foreach ( getEnumValues( 'Monitors', 'Function' ) as $optFunction ) { ?> - + From 6b18184e4af17af383df86c7dede43dcb79558ca Mon Sep 17 00:00:00 2001 From: corax Date: Fri, 9 Sep 2016 12:38:30 +0200 Subject: [PATCH 41/48] Remove confusing link to web console --- web/skins/classic/views/montagereview.php | 1 - 1 file changed, 1 deletion(-) diff --git a/web/skins/classic/views/montagereview.php b/web/skins/classic/views/montagereview.php index b9b5765fc..871b47e05 100644 --- a/web/skins/classic/views/montagereview.php +++ b/web/skins/classic/views/montagereview.php @@ -250,7 +250,6 @@ input[type=range]::-ms-tooltip {