for (var option in armadillo.Actor.options_) {
var tile = goog.dom.createDom('div', 'tile');
var value = armadillo.Actor.options_[option];
+ // Cannot open non-directory files.
+ if (value == armadillo.Actor.options_.OPEN && !this.file_.isDirectory()) {
+ continue;
+ }
var title = goog.dom.createDom('span', 'title',
armadillo.Actor.optionStrings_[value]);
goog.dom.appendChild(tile, title);
return this.name_;
};
+/**
+ * Returns whether or not this is a directory.
+ * @returns boolean
+ */
+armadillo.File.prototype.isDirectory = function() {
+ return this.isDirectory_;
+};
+
/**
* Constructs the Elements that make up the UI.
* @returns {Element} An element ready for insertion into DOM.