CC-1960: Internationalize Airtime / Support translations

-added gettext wrapper to all strings in models
This commit is contained in:
denise 2012-11-15 15:52:51 -05:00
parent d7495c6937
commit ef626a71b1
9 changed files with 102 additions and 101 deletions

View file

@ -754,7 +754,7 @@ SQL;
try {
if (is_null($cueIn) && is_null($cueOut)) {
$errArray["error"] = "Cue in and cue out are null.";
$errArray["error"] = _("Cue in and cue out are null.");
return $errArray;
}
@ -789,7 +789,7 @@ SQL;
);
$result = Application_Common_Database::prepareAndExecute($sql, $params, 'column');
if ($result) {
$errArray["error"] = "Can't set cue out to be greater than file length.";
$errArray["error"] = _("Can't set cue out to be greater than file length.");
return $errArray;
}
@ -800,7 +800,7 @@ SQL;
);
$result = Application_Common_Database::prepareAndExecute($sql, $params, 'column');
if ($result) {
$errArray["error"] = "Can't set cue in to be larger than cue out.";
$errArray["error"] = _("Can't set cue in to be larger than cue out.");
return $errArray;
}
@ -821,7 +821,7 @@ SQL;
);
$result = Application_Common_Database::prepareAndExecute($sql, $params, 'column');
if ($result) {
$errArray["error"] = "Can't set cue in to be larger than cue out.";
$errArray["error"] = _("Can't set cue in to be larger than cue out.");
return $errArray;
}
@ -845,7 +845,7 @@ SQL;
);
$result = Application_Common_Database::prepareAndExecute($sql, $params, 'column');
if ($result) {
$errArray["error"] = "Can't set cue out to be greater than file length.";
$errArray["error"] = _("Can't set cue out to be greater than file length.");
return $errArray;
}
@ -856,7 +856,7 @@ SQL;
);
$result = Application_Common_Database::prepareAndExecute($sql, $params, 'column');
if ($result) {
$errArray["error"] = "Can't set cue out to be smaller than cue in.";
$errArray["error"] = _("Can't set cue out to be smaller than cue in.");
return $errArray;
}
@ -1204,32 +1204,32 @@ SQL;
public function getCriteria()
{
$criteriaOptions = array(
0 => "Select criteria",
"album_title" => "Album",
"bit_rate" => "Bit Rate (Kbps)",
"bpm" => "BPM",
"composer" => "Composer",
"conductor" => "Conductor",
"copyright" => "Copyright",
"artist_name" => "Creator",
"encoded_by" => "Encoded By",
"genre" => "Genre",
"isrc_number" => "ISRC",
"label" => "Label",
"language" => "Language",
"mtime" => "Last Modified",
"lptime" => "Last Played",
"length" => "Length",
"mime" => "Mime",
"mood" => "Mood",
"owner_id" => "Owner",
"replay_gain" => "Replay Gain",
"sample_rate" => "Sample Rate (kHz)",
"track_title" => "Title",
"track_number" => "Track Number",
"utime" => "Uploaded",
"info_url" => "Website",
"year" => "Year"
0 => _("Select criteria"),
"album_title" => _("Album"),
"bit_rate" => _("Bit Rate (Kbps)"),
"bpm" => _("BPM"),
"composer" => _("Composer"),
"conductor" => _("Conductor"),
"copyright" => _("Copyright"),
"artist_name" => _("Creator"),
"encoded_by" => _("Encoded By"),
"genre" => _("Genre"),
"isrc_number" => _("ISRC"),
"label" => _("Label"),
"language" => _("Language"),
"mtime" => _("Last Modified"),
"lptime" => _("Last Played"),
"length" => _("Length"),
"mime" => _("Mime"),
"mood" => _("Mood"),
"owner_id" => _("Owner"),
"replay_gain" => _("Replay Gain"),
"sample_rate" => _("Sample Rate (kHz)"),
"track_title" => _("Title"),
"track_number" => _("Track Number"),
"utime" => _("Uploaded"),
"info_url" => _("Website"),
"year" => _("Year")
);
// Load criteria from db