Commit 517ea151 authored by yoshiki@chromium.org's avatar yoshiki@chromium.org

[Cleanup] Files.app: Adds missing periods at the end of the descriptions.

Closure linter checks if descriptions end with valid punctuation such as a period. This patch adds periods.

BUG=175657
TEST=none
TBR=mtomasz@chromium.org, haruki@chromium.org

Review URL: https://codereview.chromium.org/12262003

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@182217 0039d316-1c4b-4281-b951-d872f2087c98
parent 2d8dc2d0
......@@ -265,8 +265,8 @@ Command.prototype.revertView = function(canvas, imageView) {
*
* @param {Document} document Document to create canvas in.
* @param {HTMLCanvasElement} srcCanvas to copy optional dimensions from.
* @param {int} opt_width new canvas width;
* @param {int} opt_height new canvas height;
* @param {int} opt_width new canvas width.
* @param {int} opt_height new canvas height.
* @return {HTMLCanvasElement} Newly created canvas.
* @private
*/
......@@ -281,7 +281,7 @@ Command.prototype.createCanvas_ = function(
/**
* Rotate command
* @param {number} rotate90 Rotation angle in 90 degree increments (signed)
* @param {number} rotate90 Rotation angle in 90 degree increments (signed).
* @constructor
* @extends {Command}
*/
......@@ -351,9 +351,9 @@ Command.Crop.prototype.revertView = function(canvas, imageView) {
/**
* Filter command.
*
* @param {string} name Command name
* @param {function(ImageData,ImageData,number,number)} filter Filter function
* @param {string} message Message to display when done
* @param {string} name Command name.
* @param {function(ImageData,ImageData,number,number)} filter Filter function.
* @param {string} message Message to display when done.
* @constructor
* @extends {Command}
*/
......
......@@ -78,8 +78,8 @@ ExifEncoder.prototype.setImageData = function(canvas) {
/**
* @param {HTMLCanvasElement} canvas Thumbnail canvas
* @param {number} quality (0..1] Thumbnail encoding quality
* @param {HTMLCanvasElement} canvas Thumbnail canvas.
* @param {number} quality (0..1] Thumbnail encoding quality.
*/
ExifEncoder.prototype.setThumbnailData = function(canvas, quality) {
// Empirical formula with reasonable behavior:
......@@ -437,7 +437,7 @@ ByteWriter.BIG_ENDIAN = 1;
/**
* Set the byte ordering for future writes.
* @param {number} order ByteOrder to use {ByteWriter.LITTLE_ENDIAN}
* or {ByteWriter.BIG_ENDIAN}
* or {ByteWriter.BIG_ENDIAN}.
*/
ByteWriter.prototype.setByteOrder = function(order) {
this.littleEndian_ = (order == ByteWriter.LITTLE_ENDIAN);
......
......@@ -124,7 +124,7 @@ filter.getHistogram = function(source) {
*
* @param {number} maxArg Maximum argument value (inclusive).
* @param {function(number): number} func Function to precompute.
* @return {Uint8Array} Computed results
* @return {Uint8Array} Computed results.
*/
filter.precompute = function(maxArg, func) {
var results = new Uint8Array(maxArg + 1);
......@@ -281,7 +281,7 @@ filter.convolve5x5 = function(weights, dst, src, offsetX, offsetY) {
/**
* Compute the average color for the image.
*
* @param {ImageData} imageData Image data to analyze
* @param {ImageData} imageData Image data to analyze.
* @return {{r: number, g: number, b: number}} average color.
*/
filter.getAverageColor = function(imageData) {
......@@ -309,7 +309,7 @@ filter.getAverageColor = function(imageData) {
/**
* Compute the average color with more weight given to pixes at the center.
*
* @param {ImageData} imageData Image data to analyze
* @param {ImageData} imageData Image data to analyze.
* @return {{r: number, g: number, b: number}} weighted average color.
*/
filter.getWeightedAverageColor = function(imageData) {
......
......@@ -375,7 +375,7 @@ ImageEditor.Mode.OneClick = function(name, command) {
ImageEditor.Mode.OneClick.prototype = {__proto__: ImageEditor.Mode.prototype};
/**
* @return {Command} command
* @return {Command} command.
*/
ImageEditor.Mode.OneClick.prototype.getCommand = function() {
return this.command_;
......
......@@ -20,7 +20,7 @@ ImageEncoder.registerMetadataEncoder = function(constructor, mimeType) {
*
* The encoder will own and modify a copy of the original metadata.
*
* @param {Object} metadata Original metadata
* @param {Object} metadata Original metadata.
* @return {ImageEncoder.MetadataEncoder} Created metadata encoder.
*/
ImageEncoder.createMetadataEncoder = function(metadata) {
......@@ -34,9 +34,9 @@ ImageEncoder.createMetadataEncoder = function(metadata) {
* Create a metadata encoder object holding a copy of metadata
* modified according to the properties of the supplied image.
*
* @param {Object} metadata Original metadata
* @param {Object} metadata Original metadata.
* @param {HTMLCanvasElement} canvas Canvas to use for metadata.
* @param {number} quality Encoding quality (defaults to 1)
* @param {number} quality Encoding quality (defaults to 1).
* @return {ImageEncoder.MetadataEncoder} Encoder with encoded metadata.
*/
ImageEncoder.encodeMetadata = function(metadata, canvas, quality) {
......@@ -120,7 +120,7 @@ ImageEncoder.decodeDataURL = function(dataURL) {
* @param {HTMLCanvasElement} canvas Original image.
* @param {number} opt_shrinkage Thumbnail should be at least this much smaller
* than the original image (in each dimension).
* @return {HTMLCanvasElement} Thumbnail canvas
* @return {HTMLCanvasElement} Thumbnail canvas.
*/
ImageEncoder.createThumbnail = function(canvas, opt_shrinkage) {
var MAX_THUMBNAIL_DIMENSION = 320;
......@@ -193,7 +193,7 @@ ImageEncoder.MetadataEncoder.prototype.setThumbnailData =
/**
* Return a range where the metadata is (or should be) located.
* @param {string} encodedImage //TODO(JSDOC)
* @param {string} encodedImage //TODO(JSDOC).
* @return {Object} An object with from and to properties.
*/
ImageEncoder.MetadataEncoder.prototype.
......@@ -202,7 +202,7 @@ ImageEncoder.MetadataEncoder.prototype.
/**
* Return serialized metadata ready to write to an image file.
* The return type is optimized for passing to Blob.append.
* @return {ArrayBuffer} //TODO(JSDOC)
* @return {ArrayBuffer} //TODO(JSDOC).
*/
ImageEncoder.MetadataEncoder.prototype.encode = function() {
return new Uint8Array(0).buffer;
......
......@@ -67,7 +67,7 @@ ImageUtil.clamp = function(min, value, max) {
* @param {number} min Minimum value.
* @param {number} value Value to check.
* @param {number} max Maximum value.
* @return {boolean} True if value is between
* @return {boolean} True if value is between.
*/
ImageUtil.between = function(min, value, max) {
return (value - min) * (value - max) <= 0;
......@@ -358,7 +358,7 @@ Circle.prototype.inside = function(x, y) {
* @param {HTMLCanvasElement|HTMLImageElement} src Source.
* @param {number} scaleX Y scale transformation.
* @param {number} scaleY X scale transformation.
* @param {number} angle (in radians)
* @param {number} angle (in radians).
*/
ImageUtil.drawImageTransformed = function(dst, src, scaleX, scaleY, angle) {
var context = dst.getContext('2d');
......@@ -437,7 +437,7 @@ ImageUtil.ImageLoader.isTooLarge = function(image) {
/**
* @param {string} url Image URL.
* @param {function(function(object))} transformFetcher function to get
* the image transform (which we need for the image orientation)
* the image transform (which we need for the image orientation).
* @param {function(HTMLCanvasElement)} callback To be called when loaded.
* @param {number} opt_delay Load delay in milliseconds, useful to let the
* animations play out before the computation heavy image loading starts.
......
......@@ -97,7 +97,7 @@ ImageView.prototype = {__proto__: ImageBuffer.Overlay.prototype};
/**
* Draw below overlays with the default zIndex.
* @return {number} Z-index
* @return {number} Z-index.
*/
ImageView.prototype.getZIndex = function() { return -1 };
......@@ -231,7 +231,7 @@ ImageView.prototype.paintDeviceRect = function(deviceRect, canvas, imageRect) {
* Create an overlay canvas with properties similar to the screen canvas.
* Useful for showing quick feedback when editing.
*
* @return {HTMLCanvasElement} Overlay canvas
* @return {HTMLCanvasElement} Overlay canvas.
*/
ImageView.prototype.createOverlayCanvas = function() {
var canvas = this.document_.createElement('canvas');
......
......@@ -77,7 +77,7 @@ Viewport.prototype.sizeByFrameAndFit = function(frame) {
};
/**
* @return {number} Scale
* @return {number} Scale.
*/
Viewport.prototype.getScale = function() { return this.scale_ };
......@@ -198,7 +198,7 @@ Viewport.prototype.getScreenClipped = function() { return this.screenClipped_ };
* A counter that is incremented with each viewport state change.
* Clients that cache anything that depends on the viewport state should keep
* track of this counter.
* @return {number} counter
* @return {number} counter.
*/
Viewport.prototype.getCacheGeneration = function() { return this.generation_ };
......
......@@ -198,7 +198,7 @@ AudioPlayer.prototype.load = function(playlist) {
/**
* Load metadata for a track.
* @param {number} track Track number
* @param {number} track Track number.
* @private
*/
AudioPlayer.prototype.loadMetadata_ = function(track) {
......
......@@ -202,7 +202,7 @@ MediaControls.prototype.displayProgress_ = function(current, duration) {
};
/**
* @param {number} value Progress [0..1]
* @param {number} value Progress [0..1].
* @private
*/
MediaControls.prototype.onProgressChange_ = function(value) {
......@@ -271,7 +271,7 @@ MediaControls.prototype.onSoundButtonClick_ = function() {
};
/**
* @param {number} value Volume [0..1]
* @param {number} value Volume [0..1].
* @return {number} The rough level [0..3] used to pick an icon.
* @private
*/
......@@ -602,7 +602,7 @@ MediaControls.Slider.prototype.getValue = function() {
};
/**
* @param {number} value [0..1]
* @param {number} value [0..1].
*/
MediaControls.Slider.prototype.setValue = function(value) {
this.value_ = value;
......@@ -612,7 +612,7 @@ MediaControls.Slider.prototype.setValue = function(value) {
/**
* Fill the given proportion the slider bar (from the left).
*
* @param {number} proportion [0..1]
* @param {number} proportion [0..1].
* @private
*/
MediaControls.Slider.prototype.setFilled_ = function(proportion) {
......@@ -622,7 +622,7 @@ MediaControls.Slider.prototype.setFilled_ = function(proportion) {
/**
* Get the value from the input element.
*
* @return {number} Value [0..1]
* @return {number} Value [0..1].
* @private
*/
MediaControls.Slider.prototype.getValueFromUI_ = function() {
......@@ -632,7 +632,7 @@ MediaControls.Slider.prototype.getValueFromUI_ = function() {
/**
* Update the UI with the current value.
*
* @param {number} value [0..1]
* @param {number} value [0..1].
* @private
*/
MediaControls.Slider.prototype.setValueToUI_ = function(value) {
......@@ -709,7 +709,7 @@ MediaControls.AnimatedSlider.STEPS = 10;
MediaControls.AnimatedSlider.DURATION = 100;
/**
* @param {number} value [0..1]
* @param {number} value [0..1].
* @private
*/
MediaControls.AnimatedSlider.prototype.setValueToUI_ = function(value) {
......
......@@ -91,7 +91,7 @@ ThumbnailLoader.LoaderType = {
* the image itself as a thumbnail. If the image is too large it hurts
* the performance a lot so we allow it only for moderately sized files.
*
* @param {Object} metadata Metadata object
* @param {Object} metadata Metadata object.
* @return {boolean} Whether it is OK to use the image url for a preview.
* @private
*/
......
......@@ -93,7 +93,7 @@ var playerTestAPI = {
/**
* Change volume.
* @param {number} volume Volume [0..100]
* @param {number} volume Volume [0..100].
*/
setVolume: function(volume) {
this.respond_(this.getControls_().onVolumeChange_(volume / 100));
......
......@@ -67,7 +67,7 @@ MouseInactivityWatcher.prototype.showTools = function(on) {
};
/**
* @param {Element} element DOM element
* @param {Element} element DOM element.
* @return {boolean} True if the element is a tool. Tools should never be hidden
* while the mouse is over one of them.
*/
......
......@@ -353,8 +353,8 @@ ExifParser.ROTATE90 = [0, 0, 0, 0, 1, 1, 1, 1];
* Transform exif-encoded orientation into a set of parameters compatible with
* CSS and canvas transforms (scaleX, scaleY, rotation).
*
* @param {Object} ifd exif property dictionary (image or thumbnail)
* @return {Object} //TODO(JSDOC)
* @param {Object} ifd exif property dictionary (image or thumbnail).
* @return {Object} //TODO(JSDOC).
*/
ExifParser.prototype.parseOrientation = function(ifd) {
if (ifd[EXIF_TAG_ORIENTATION]) {
......
......@@ -6,9 +6,9 @@
* @constructor
* @class FunctionSequence to invoke steps in sequence
*
* @param steps array of functions to invoke in parallel
* @param callback callback to invoke on success
* @param failureCallback callback to invoke on failure
* @param steps array of functions to invoke in parallel.
* @param callback callback to invoke on success.
* @param failureCallback callback to invoke on failure.
*/
function FunctionParallel(name, steps, logger, callback, failureCallback) {
// Private variables hidden in closure
......@@ -31,7 +31,7 @@ function FunctionParallel(name, steps, logger, callback, failureCallback) {
/**
* Error handling function, which fires error callback.
*
* @param err error message
* @param err error message.
*/
FunctionParallel.prototype.onError_ = function(err) {
if (!this.failed_) {
......
......@@ -6,10 +6,10 @@
* @constructor
* @class FunctionSequence to invoke steps in sequence
*
* @param {Array} steps array of functions to invoke in sequence
* @param {Object} logger logger
* @param {Function} [callback] callback to invoke on success
* @param {Function} [failureCallback] callback to invoke on failure
* @param {Array} steps array of functions to invoke in sequence.
* @param {Object} logger logger.
* @param {Function} [callback] callback to invoke on success.
* @param {Function} [failureCallback] callback to invoke on failure.
*/
function FunctionSequence(name, steps, logger, callback, failureCallback) {
// Private variables hidden in closure
......@@ -30,7 +30,7 @@ function FunctionSequence(name, steps, logger, callback, failureCallback) {
/**
* Sets new callback
*
* @param {Function} callback new callback to call on succeed
* @param {Function} callback new callback to call on succeed.
*/
FunctionSequence.prototype.setCallback = function(callback) {
this.callback_ = callback;
......@@ -39,7 +39,7 @@ FunctionSequence.prototype.setCallback = function(callback) {
/**
* Sets new error callback
*
* @param {Function} failureCallback new callback to call on failure
* @param {Function} failureCallback new callback to call on failure.
*/
FunctionSequence.prototype.setFailureCallback = function(failureCallback) {
this.failureCallback_ = failureCallback;
......@@ -50,7 +50,7 @@ FunctionSequence.prototype.setFailureCallback = function(failureCallback) {
* Error handling function, which traces current error step, stops sequence
* advancing and fires error callback.
*
* @param err error message
* @param err error message.
*/
FunctionSequence.prototype.onError_ = function(err) {
this.logger.vlog('Failed step: ' + this.steps_[this.currentStepIdx_].name
......
......@@ -15,8 +15,8 @@ Id3Parser.prototype = {__proto__: MetadataParser.prototype};
* Reads synchsafe integer.
* 'SynchSafe' term is taken from id3 documentation.
*
* @param {ByteReader} reader - reader to use
* @param {int} length - bytes to read
* @param {ByteReader} reader - reader to use.
* @param {int} length - bytes to read.
* @return {int}
*/
Id3Parser.readSynchSafe_ = function(reader, length) {
......@@ -39,7 +39,7 @@ Id3Parser.readSynchSafe_ = function(reader, length) {
/**
* Reads 3bytes integer.
*
* @param {ByteReader} reader - reader to use
* @param {ByteReader} reader - reader to use.
* @return {int}
*/
Id3Parser.readUInt24_ = function(reader) {
......@@ -49,7 +49,7 @@ Id3Parser.readUInt24_ = function(reader) {
/**
* Reads string from reader with specified encoding
*
* @param {ByteReader} reader reader to use
* @param {ByteReader} reader reader to use.
* @param {int} encoding string encoding.
* @param {int} size maximum string size. Actual result may be shorter.
*
......@@ -80,10 +80,10 @@ Id3Parser.prototype.readString_ = function(reader, encoding, size) {
/**
* Reads text frame from reader.
*
* @param {ByteReader} reader reader to use
* @param {int} majorVersion major id3 version to use
* @param {Object} frame frame so store data at
* @param {int} end frame end position in reader
* @param {ByteReader} reader reader to use.
* @param {int} majorVersion major id3 version to use.
* @param {Object} frame frame so store data at.
* @param {int} end frame end position in reader.
*/
Id3Parser.prototype.readTextFrame_ = function(reader,
majorVersion,
......@@ -96,10 +96,10 @@ Id3Parser.prototype.readTextFrame_ = function(reader,
/**
* Reads user defined text frame from reader.
*
* @param {ByteReader} reader reader to use
* @param {int} majorVersion major id3 version to use
* @param {Object} frame frame so store data at
* @param {int} end frame end position in reader
* @param {ByteReader} reader reader to use.
* @param {int} majorVersion major id3 version to use.
* @param {Object} frame frame so store data at.
* @param {int} end frame end position in reader.
*/
Id3Parser.prototype.readUserDefinedTextFrame_ = function(reader,
majorVersion,
......@@ -154,8 +154,8 @@ Id3Parser.prototype.readAPIC_ = function(reader, majorVersion, frame, end) {
/**
* Reads string from reader with specified encoding
*
* @param {ByteReader} reader reader to use
* @return {Object} frame read
* @param {ByteReader} reader reader to use.
* @return {Object} frame read.
*/
Id3Parser.prototype.readFrame_ = function(reader, majorVersion) {
if (reader.eof())
......@@ -283,7 +283,7 @@ Id3Parser.prototype.parse = function (file, metadata, callback, onError) {
/**
* Check if passed array of 10 bytes contains ID3 header.
* @param file to check and continue reading if ID3 metadata found
* @param file to check and continue reading if ID3 metadata found.
* @param {ByteReader} reader reader to fill with stream bytes.
*/
function checkId3v2(file, reader) {
......
......@@ -18,7 +18,7 @@ function MetadataParser(parent, type, urlFilter) {
/**
* Output an error message.
* @param {Object...} var_args Arguments
* @param {Object...} var_args Arguments.
*/
MetadataParser.prototype.error = function(var_args) {
this.parent_.error.apply(this.parent_, arguments);
......@@ -26,7 +26,7 @@ MetadataParser.prototype.error = function(var_args) {
/**
* Output a log message.
* @param {Object...} var_args Arguments
* @param {Object...} var_args Arguments.
*/
MetadataParser.prototype.log = function(var_args) {
this.parent_.log.apply(this.parent_, arguments);
......@@ -34,7 +34,7 @@ MetadataParser.prototype.log = function(var_args) {
/**
* Output a log message if |verbose| flag is on.
* @param {Object...} var_args Arguments
* @param {Object...} var_args Arguments.
*/
MetadataParser.prototype.vlog = function(var_args) {
if (this.verbose)
......
......@@ -38,7 +38,7 @@ function unload(opt_exiting) { Gallery.instance.onUnload(opt_exiting) }
* {Array.<Object>} shareActions
* {string} readonlyDirName Directory name for readonly warning or null.
* {DirEntry} saveDirEntry Directory to save to.
* {function(string)} displayStringFunction
* {function(string)} displayStringFunction.
* @class
* @constructor
*/
......@@ -790,7 +790,7 @@ Gallery.prototype.onFilenameEditKeydown_ = function() {
};
/**
* @return {boolean} True if file renaming is currently in progress
* @return {boolean} True if file renaming is currently in progress.
* @private
*/
Gallery.prototype.isRenaming_ = function() {
......
......@@ -324,7 +324,7 @@ Ribbon.prototype.renderThumbnail_ = function(index) {
/**
* Set the thumbnail image.
*
* @param {Element} thumbnail Thumbnail element
* @param {Element} thumbnail Thumbnail element.
* @param {string} url Image url.
* @param {Object} metadata Metadata.
* @private
......
......@@ -120,7 +120,7 @@ SelectAlbumDialog.prototype.renderItem = function(item) {
* Shows dialog.
*
* @param {string} message Message in dialog caption.
* @param {Array} items Albums to render in list
* @param {Array} items Albums to render in list.
* @param {string} defaultNewName Default name of the new album.
* @param {string} okCaption Text on the ok button.
* @param {function} onOk Callback function.
......
......@@ -68,7 +68,7 @@ SlideMode.editorModes = [
];
/**
* @return {string} Mode name
* @return {string} Mode name.
*/
SlideMode.prototype.getName = function() { return 'slide' };
......@@ -368,7 +368,7 @@ SlideMode.prototype.getSelectedImageRect = function() {
};
/**
* @return {Gallery.Item} Selected item
* @return {Gallery.Item} Selected item.
*/
SlideMode.prototype.getSelectedItem = function() {
return this.getItem(this.getSelectedIndex());
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment