Skip to content

Commit

Permalink
make hasCloseButton configurable in model
Browse files Browse the repository at this point in the history
  • Loading branch information
syt123450 committed Feb 19, 2019
1 parent d20c565 commit 1c5f695
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/configure/ModelConfiguration.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ function ModelConfiguration( config ) {
this.minOpacity = 0.4;
this.predictDataShapes = undefined;
this.feedInputs = undefined;
this.hasCloseButton = true;
this.color = {

background: 0x000000,
Expand Down Expand Up @@ -171,6 +172,12 @@ function ModelConfiguration( config ) {
this.feedInputs = config.feedInputs;

}

if ( config.hasCloseButton !== undefined ) {

this.hasCloseButton = config.hasCloseButton;

}

if ( config.color !== undefined ) {

Expand Down
6 changes: 6 additions & 0 deletions src/layer/abstract/Layer.js
Original file line number Diff line number Diff line change
Expand Up @@ -422,6 +422,12 @@ Layer.prototype = {
this.separateTime = modelConfig.animeTime / 2;

}

if ( modelConfig.hasCloseButton !== undefined ) {

this.hasCloseButton = modelConfig.hasCloseButton;

}

},

Expand Down

0 comments on commit 1c5f695

Please # to comment.