2 // Armadillo File Manager
3 // Copyright (c) 2010-2011, Robert Sesek <http://www.bluestatic.org>
5 // This program is free software: you can redistribute it and/or modify it under
6 // the terms of the GNU General Public License as published by the Free Software
7 // Foundation, either version 3 of the License, or any later version.
10 $.namespace('armadillo.TVRenamer');
13 * Creates a helper to rename a file in a pretty format for TV episodes.
16 armadillo
.TVRenamer
= function(file
) {
19 * @type {armadillo.File}
25 * Performs the information lookup and renames the file if the lookup is
28 armadillo
.TVRenamer
.prototype.run
= function() {
29 var file
= this.file_
;
30 var callback
= function(data
, stauts
, xhr
) {
32 file
.move(data
['path']);
34 app
.sendRequest('tv_rename', {'path':this.file_
.getFullPath()},