forked from phaserjs/phaser
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathAlignIn.js
More file actions
20 lines (16 loc) · 745 Bytes
/
Copy pathAlignIn.js
File metadata and controls
20 lines (16 loc) · 745 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
var CONST = require('./const');
var AlignInMap = [];
AlignInMap[CONST.BOTTOM_CENTER] = require('./InBottomCenter');
AlignInMap[CONST.BOTTOM_LEFT] = require('./InBottomLeft');
AlignInMap[CONST.BOTTOM_RIGHT] = require('./InBottomRight');
AlignInMap[CONST.CENTER] = require('./InCenter');
AlignInMap[CONST.LEFT_CENTER] = require('./InLeftCenter');
AlignInMap[CONST.RIGHT_CENTER] = require('./InRightCenter');
AlignInMap[CONST.TOP_CENTER] = require('./InTopCenter');
AlignInMap[CONST.TOP_LEFT] = require('./InTopLeft');
AlignInMap[CONST.TOP_RIGHT] = require('./InTopRight');
var AlignIn = function (child, container, position, offsetX, offsetY)
{
return AlignInMap[position](child, container, offsetX, offsetY);
};
module.exports = AlignIn;