function actionSelection (message, primaryCallback, secondaryCallback, title, primaryActionTitle, secondaryActionTitle)
{
  if (!title) title = 'TimeCard';

  //Set the title and message
  $('#selectionTitle').html(title);
  $('#selectionMessage').html(message);

  if (primaryActionTitle) {
    $('.inptsbt', '#actionSelection').val(primaryActionTitle);
  }

  if (secondaryActionTitle) {
    $('.inptgri', '#actionSelection').val(secondaryActionTitle);
  }

  $('.inptsbt', '#actionSelection').click(function (e) {
    e.preventDefault();

    // Clear listeners
    $('.inptsbt', '#actionSelection').off('click');
    $('.inptgri', '#actionSelection').off('click');
    $('#actionSelection').hide();
    primaryCallback();
  });

  $('.inptgri', '#actionSelection').click(function (e) {
    e.preventDefault();

    // Clear listeners
    $('.inptsbt', '#actionSelection').off('click');
    $('.inptgri', '#actionSelection').off('click');
    $('#actionSelection').hide();
    secondaryCallback();
  });

  //Dsiplay overlay
  $('#actionSelection').show();

  //Position the overlay
  $(".trndvds").css({left:($(window).width()-$(".trndvds").width())/2});
}
/**
 * Shows an action selection overlay with title @title and message @message.
 * It also has a primary and secondary buttons.
 */
Shows an action selection overlay with title @title and message @message.
It also has a primary and secondary buttons.
Shows an action selection overlay with title @title and message @message . It also has a primary and secondary buttons .
function actionSelection (message, primaryCallback, secondaryCallback, title, primaryActionTitle, secondaryActionTitle)
{
  if (!title) title = 'TimeCard';
  $('#selectionTitle').html(title);
  $('#selectionMessage').html(message);
  if (primaryActionTitle) {
    $('.inptsbt', '#actionSelection').val(primaryActionTitle);
  }
  if (secondaryActionTitle) {
    $('.inptgri', '#actionSelection').val(secondaryActionTitle);
  }
  $('.inptsbt', '#actionSelection').click(function (e) {
    e.preventDefault();
    $('.inptsbt', '#actionSelection').off('click');
    $('.inptgri', '#actionSelection').off('click');
    $('#actionSelection').hide();
    primaryCallback();
  });
  $('.inptgri', '#actionSelection').click(function (e) {
    e.preventDefault();
    $('.inptsbt', '#actionSelection').off('click');
    $('.inptgri', '#actionSelection').off('click');
    $('#actionSelection').hide();
    secondaryCallback();
  });
  $('#actionSelection').show();
  $(".trndvds").css({left:($(window).width()-$(".trndvds").width())/2});
}
function actionSelection ( message , primaryCallback , secondaryCallback , title , primaryActionTitle , secondaryActionTitle ) { if ( ! title ) title = 'TimeCard' ; $ ( '#selectionTitle' ) . html ( title ) ; $ ( '#selectionMessage' ) . html ( message ) ; if ( primaryActionTitle ) { $ ( '.inptsbt' , '#actionSelection' ) . val ( primaryActionTitle ) ; } if ( secondaryActionTitle ) { $ ( '.inptgri' , '#actionSelection' ) . val ( secondaryActionTitle ) ; } $ ( '.inptsbt' , '#actionSelection' ) . click ( function ( e ) { e . preventDefault ( ) ; $ ( '.inptsbt' , '#actionSelection' ) . off ( 'click' ) ; $ ( '.inptgri' , '#actionSelection' ) . off ( 'click' ) ; $ ( '#actionSelection' ) . hide ( ) ; primaryCallback ( ) ; } ) ; $ ( '.inptgri' , '#actionSelection' ) . click ( function ( e ) { e . preventDefault ( ) ; $ ( '.inptsbt' , '#actionSelection' ) . off ( 'click' ) ; $ ( '.inptgri' , '#actionSelection' ) . off ( 'click' ) ; $ ( '#actionSelection' ) . hide ( ) ; secondaryCallback ( ) ; } ) ; $ ( '#actionSelection' ) . show ( ) ; $ ( ".trndvds" ) . css ( { left : ( $ ( window ) . width ( ) - $ ( ".trndvds" ) . width ( ) ) / 2 } ) ; }
Shows an action selection overlay with title @title and message @message.
Shows an action selection overlay with title @title and message @message .
//Set the title and message // Clear listeners // Clear listeners //Dsiplay overlay //Position the overlay