Djamana User

Bug:
'Load next page (Page X)'
Is not shown under when using 'Cam4 Optimiser' Script in Chrome

Problem:
Chrome don't support 'String.endsWith'

Fix:

put this into the script:
(the appropriate place should be somewhere around Line 270)

// =============================================================================
// ===  Userlist  ::  Global functions  ========================================
// =============================================================================

// Workaround as long as Chrome done supports '"blah".startsWith'
if (typeof String.prototype.startsWith != 'function') {
  String.prototype.startsWith = function( str ) {
    return this.slice( 0, str.length ) == str;
  };
}
if (typeof String.prototype.endsWith != 'function') {
  String.prototype.endsWith = function( str ) {
    return this.slice( -str.length ) == str;
  };
}


function getCurrentPageInfo() {

Note:The rest is not part needed for the bugfix !

Suggestion:
Well to improve robustness of the code conside make more use of try catch like this (somewhere around Line 500):

try {
optimizeUserList();
} catch (e) {
    debugger; console.error ("CAM4opti::optimizeUserList() FAILED!!!");
}

try {
optimizePager();
} catch (e) {
    debugger; console.error ("CAM4opti::optimizePager() FAILED!!!");
}
 

However the first level function of the modules should all wrapped into try catch blocks in the same matter, so in case one fails the others following still get a chance to run.

Thanks reading - and creating Cam4 Optimiser.

Hint #1: To enable Cam4-Multicam just start an transmission
And maybe it's nice to add a status Text like this:
'NO Transmission !!! - (Just went on Air to Make 'Multicam' working)'

Hint #2: to record Stream: Use 'Applian_Replay_Media_Capture'
http://solidfiles.com/d/96df1bc767/Applian_Replay_Media_Capture_5.0.1.24Dec2013__NoReg_Patch_MPT_cw2k.zip

Hint #3: Streams/Files that are on recording can be opened at the same time with the VLC. Now you can do Multi- and Offline Cam'ing and even FastForward( press Num+ ) or Rewind (Shift+Cursor left).