File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -212,6 +212,23 @@ Phaser.Loader.prototype = {
212212
213213 } ,
214214
215+ /**
216+ * Called automatically by ScaleManager when the game resizes in RESIZE scalemode.
217+ * We use this to adjust the height of the preloading sprite, if set.
218+ *
219+ * @method Phaser.Loader#resize
220+ * @param {number } width - The new width of the game in pixels.
221+ * @param {number } height - The new height of the game in pixels.
222+ */
223+ resize : function ( ) {
224+
225+ if ( this . preloadSprite && this . preloadSprite . height !== this . preloadSprite . sprite . height )
226+ {
227+ this . preloadSprite . rect . height = this . preloadSprite . sprite . height ;
228+ }
229+
230+ } ,
231+
215232 /**
216233 * Check whether asset exists with a specific key.
217234 * Use Phaser.Cache to access loaded assets, e.g. Phaser.Cache#checkImageKey
You can’t perform that action at this time.
0 commit comments