Removed FilterMode and swapped for const

This commit is contained in:
Richard Davey 2018-03-21 15:18:07 +00:00
parent a2352f2049
commit 63d2b49154
4 changed files with 10 additions and 15 deletions

View file

@ -372,7 +372,7 @@ var Texture = new Class({
* @method Phaser.Textures.Texture#setFilter
* @since 3.0.0
*
* @param {(Phaser.Textures.FilterMode.LINEAR|Phaser.Textures.FilterMode.NEAREST)} filterMode - The Filter Mode.
* @param {(Phaser.Textures.LINEAR|Phaser.Textures.NEAREST)} filterMode - The Filter Mode.
*/
setFilter: function (filterMode)
{

View file

@ -164,7 +164,7 @@ var TextureSource = new Class({
* @method Phaser.Textures.TextureSource#setFilter
* @since 3.0.0
*
* @param {(Phaser.Textures.FilterMode.LINEAR|Phaser.Textures.FilterMode.NEAREST)} filterMode - The Filter Mode.
* @param {(Phaser.Textures.LINEAR|Phaser.Textures.NEAREST)} filterMode - The Filter Mode.
*/
setFilter: function (filterMode)
{

View file

@ -4,26 +4,22 @@
* @license {@link https://github.com/photonstorm/phaser/blob/master/license.txt|MIT License}
*/
/**
* @namespace Phaser.Textures.FilterMode
*/
var CONST = {
/**
* CSV Map Type
* Linear filter type.
*
* @name Phaser.Textures.FilterMode.LINEAR
* @type {number}
* @name Phaser.Textures.LINEAR
* @type {integer}
* @since 3.0.0
*/
LINEAR: 0,
/**
* CSV Map Type
* Nearest neighbor filter type.
*
* @name Phaser.Textures.FilterMode.NEAREST
* @type {number}
* @name Phaser.Textures.NEAREST
* @type {integer}
* @since 3.0.0
*/
NEAREST: 1

View file

@ -4,7 +4,7 @@
* @license {@link https://github.com/photonstorm/phaser/blob/master/license.txt|MIT License}
*/
var FilterMode = require('./FilterMode');
var CONST = require('./const');
var Extend = require('../utils/object/Extend');
/**
@ -15,7 +15,6 @@ var Textures = {
Parsers: require('./parsers'),
FilterMode: require('./FilterMode'),
Frame: require('./Frame'),
Texture: require('./Texture'),
TextureManager: require('./TextureManager'),
@ -24,6 +23,6 @@ var Textures = {
};
// Merge in the consts
Textures = Extend(false, Textures, FilterMode);
Textures = Extend(false, Textures, CONST);
module.exports = Textures;