mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-23 09:52:26 +01:00
Created option to pass in static file for fallback for logo.
This commit is contained in:
parent
cec88cc9ac
commit
5168232481
BIN
app/images/icon-512.png
Normal file
BIN
app/images/icon-512.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 41 KiB |
@ -14,7 +14,9 @@ function Mascot () {
|
||||
pxNotRatio: true,
|
||||
width: 200,
|
||||
height: 200,
|
||||
staticImage: './images/icon-512.png'
|
||||
})
|
||||
debugger;
|
||||
if (!this.logo.webGLSupport) return
|
||||
this.refollowMouse = debounce(this.logo.setFollowMouse.bind(this.logo, true), 1000)
|
||||
this.unfollowMouse = this.logo.setFollowMouse.bind(this.logo, false)
|
||||
@ -46,12 +48,12 @@ Mascot.prototype.componentDidMount = function () {
|
||||
}
|
||||
|
||||
Mascot.prototype.componentWillUnmount = function () {
|
||||
if (!this.logo) return
|
||||
if (!this.logo.webGLSupport) return
|
||||
this.logo.canvas.remove()
|
||||
}
|
||||
|
||||
Mascot.prototype.handleAnimationEvents = function () {
|
||||
if (!this.logo) return
|
||||
if (!this.logo.webGLSupport) return
|
||||
// only setup listeners once
|
||||
if (this.animations) return
|
||||
this.animations = this.props.animationEventEmitter
|
||||
@ -60,7 +62,7 @@ Mascot.prototype.handleAnimationEvents = function () {
|
||||
}
|
||||
|
||||
Mascot.prototype.lookAt = function (target) {
|
||||
if (!this.logo) return
|
||||
if (!this.logo.webGLSupport) return
|
||||
this.unfollowMouse()
|
||||
this.logo.lookAt(target)
|
||||
this.refollowMouse()
|
||||
|
Loading…
x
Reference in New Issue
Block a user