Skip to content

Commit f0da3d4

Browse files
Merge pull request #49 from SylvainCorlay/class
Add semantic class
2 parents 1d21745 + 9f4ee1f commit f0da3d4

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

js/src/jupyter-threejs.js

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ define(["jupyter-js-widgets", "underscore", "three"],
1010
var Detector = require("./examples/js/Detector.js");
1111

1212
var RendererView = widgets.DOMWidgetView.extend({
13-
render : function(){
13+
render : function() {
1414
console.log('created renderer');
1515
this.on('displayed', this.show, this);
1616
var that = this;
@@ -32,6 +32,7 @@ define(["jupyter-js-widgets", "underscore", "three"],
3232
} else {
3333
this.renderer = new THREE.CanvasRenderer();
3434
}
35+
this.el.className = "jupyter-widget jupyter-threejs";
3536
this.$el.empty().append(this.renderer.domElement);
3637
var that = this;
3738
var view_promises = [];
@@ -108,7 +109,7 @@ define(["jupyter-js-widgets", "underscore", "three"],
108109
}
109110
},
110111

111-
update : function(){
112+
update: function() {
112113
var that = this;
113114
this.view_promises.then(function() {
114115
that.effectrenderer.setSize(that.model.get('width'), that.model.get('height'));
@@ -1516,8 +1517,8 @@ define(["jupyter-js-widgets", "underscore", "three"],
15161517
_view_name: 'ShaderMaterialView',
15171518
_model_name: 'ShaderMaterialModel',
15181519

1519-
fragmentShader: 'void main(){ }',
1520-
vertexShader: 'void main(){ }',
1520+
fragmentShader: 'void main() {}',
1521+
vertexShader: 'void main() {}',
15211522
morphTargets: false,
15221523
lights: false,
15231524
morphNormals: false,

0 commit comments

Comments
 (0)