<commit_before>// ==========================================================================
// Project:   Flot.GraphView
// Copyright: ©2010 <NAME> <<EMAIL>>, Inc.
// ==========================================================================
/*globals Flot */

/** @class

  (Document Your View Here)

  @extends SC.View
*/
sc_require('core.js');
Flot.GraphView = SC.View.extend(
/** @scope Flot.GraphView.prototype */ {

  // TODO: Add your own code here.
	
	data: null ,	
	
	options: null , 
	
	concatenatedProperties: ['options'] ,
	
	render: function(context, firstTime) {
		sc_super() ;
		if(this.get('layer') && this.get('isVisibleInWindow')) {
			if((this.get('frame').width > 0) && (this.get('frame').height > 0)) {
				if(this.get('data')) {
					Flot.plot(this.get('layer'),
			    	  	  	  this.get('data').toArray(),
				  	  	  	  this.get('options')) ;
				//	console.log('render');
				}
			}
		}				
	} ,
				
	viewDidResize: function() {
		sc_super() ;
		this.setLayerNeedsUpdate() ;
	} ,	
	
	plotDataDidChange: function() {
		this.setLayerNeedsUpdate() ;
		//console.log('data changed');
	}.observes('.data','.data.[]'),
	
	plotOptionsDidChange: function() {
		this.setLayerNeedsUpdate() ;
		//console.log('options changed');	
	}.observes('.options'),
	
	visibilityDidChange: function() {
		if(this.get('isVisibleInWindow') && this.get('isVisible')) {
			console.log('visibility changed');
			this.setLayerNeedsUpdate() ;
		}		
	}.observes('isVisibleInWindow','isVisible'),
	<commit_msg>comment out console log<commit_after>// ==========================================================================
// Project:   Flot.GraphView
// Copyright: ©2010 <NAME> <<EMAIL>>, Inc.
// ==========================================================================
/*globals Flot */

/** @class

  (Document Your View Here)

  @extends SC.View
*/
sc_require('core.js');
Flot.GraphView = SC.View.extend(
/** @scope Flot.GraphView.prototype */ {

  // TODO: Add your own code here.
	
	data: null ,	
	
	options: null , 
	
	concatenatedProperties: ['options'] ,
	
	render: function(context, firstTime) {
		sc_super() ;
		if(this.get('layer') && this.get('isVisibleInWindow')) {
			if((this.get('frame').width > 0) && (this.get('frame').height > 0)) {
				if(this.get('data')) {
					Flot.plot(this.get('layer'),
			    	  	  	  this.get('data').toArray(),
				  	  	  	  this.get('options')) ;
				//	console.log('render');
				}
			}
		}				
	} ,
				
	viewDidResize: function() {
		sc_super() ;
		this.setLayerNeedsUpdate() ;
	} ,	
	
	plotDataDidChange: function() {
		this.setLayerNeedsUpdate() ;
		//console.log('data changed');
	}.observes('.data','.data.[]'),
	
	plotOptionsDidChange: function() {
		this.setLayerNeedsUpdate() ;
		//console.log('options changed');	
	}.observes('.options'),
	
	visibilityDidChange: function() {
		if(this.get('isVisibleInWindow') && this.get('isVisible')) {
			//console.log('visibility changed');
			this.setLayerNeedsUpdate() ;
		}		
	}.observes('isVisibleInWindow','isVisible'),
	
{'fraction_non_alphanumeric': 0.2771164021164021, 'fraction_numerical': 0.003968253968253968, 'mean_word_length': 3.7265625, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 13, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6952531', 'n_tokens_mistral': 1121, 'n_tokens_neox': 959, 'n_words': 149}