<commit_before>package openfl.display;


import lime.graphics.cairo.Cairo;
import openfl._internal.renderer.opengl.GLRenderer;
import openfl._internal.renderer.RenderSession;
import openfl.events.AbstractViewEvent;
import openfl.geom.ColorTransform;
import openfl.geom.Matrix;

@:access(openfl.events.Event)
@:access(openfl.geom.ColorTransform)


class AbstractView extends DisplayObject {
	
	
	private var __renderEvent:AbstractViewEvent;
	
	
	public function new () {
		
		super ();
		
		__renderEvent = new AbstractViewEvent (null);
		
	}
	
	
	private override function __enterFrame (deltaTime:Int):Void {
		
		if (__renderable) {
			
			__setRenderDirty ();
			
		}
		
	}
	
	
	private override function __renderCairo (renderSession:RenderSession):Void {
		
		if (!__renderable) return;
		
		super.__renderCairo (renderSession);
		
		renderSession.blendModeManager.setBlendMode (__worldBlendMode);
		renderSession.maskManager.pushObject (this);
		
		__renderEvent.type = AbstractViewEvent.RENDER_CAIRO;
		__renderEvent.allowSmoothing = renderSession.allowSmoothing;
		__renderEvent.cairo = renderSession.cairo;
		__renderEvent.renderTransform.copyFrom (__renderTransform);
		__renderEvent.worldColorTransform.__copyFrom (__worldColorTransform);
		__renderEvent.worldTransform.copyFrom (__worldTransform);
		__renderEvent.__renderSession = renderSession;
		
		dispatchEvent (__renderEvent);
		
		renderSession.maskManager.popObject (this);
		__renderEvent.cairo = null;
		
	}
	
	
	private override function __renderCanvas (renderSession:RenderSession):Void {
		
		if (!__renderable) return;
		
		super.__renderCanvas (renderSession);
		
		renderSession.blendModeManager.setBlendMode (__worldBlendMode);
		renderSession.maskManager.pushObject (this);
		
		__renderEvent.type = AbstractViewEvent.RENDER_CANVAS;
		__renderEvent.allowSmoothing = renderSession.allowSmoothing;
		__renderEvent.context = renderSession.context;
		__renderEvent.renderTransform.copyFrom (__renderTransform);
		__renderEvent.worldColorTransform.__copyFrom (__worldColorTransform);
		__renderEvent.worldTransform.copyFrom (__worldTransform);
		__renderEvent.__renderSession = renderSession;
		
		dispatchEvent (__renderEvent);
		
		renderSession.maskManager.popObject (this);
		__renderEvent.context = null;
		
	}
	
	
	private override function __renderGL (renderSession:RenderSession):Void {
		
		if (!__renderable) return;
		
		super.__renderGL (renderSession);
		
		renderSession.blendModeManager.setBlendMode (__worldBlendMode);
		renderSession.maskManager.pushObject (this);
		renderSession.shaderManager.updateShader (null);
		<commit_msg>Fix setting shader<commit_after>package openfl.display;


import lime.graphics.cairo.Cairo;
import openfl._internal.renderer.opengl.GLRenderer;
import openfl._internal.renderer.RenderSession;
import openfl.events.AbstractViewEvent;
import openfl.geom.ColorTransform;
import openfl.geom.Matrix;

@:access(openfl.events.Event)
@:access(openfl.geom.ColorTransform)


class AbstractView extends DisplayObject {
	
	
	private var __renderEvent:AbstractViewEvent;
	
	
	public function new () {
		
		super ();
		
		__renderEvent = new AbstractViewEvent (null);
		
	}
	
	
	private override function __enterFrame (deltaTime:Int):Void {
		
		if (__renderable) {
			
			__setRenderDirty ();
			
		}
		
	}
	
	
	private override function __renderCairo (renderSession:RenderSession):Void {
		
		if (!__renderable) return;
		
		super.__renderCairo (renderSession);
		
		renderSession.blendModeManager.setBlendMode (__worldBlendMode);
		renderSession.maskManager.pushObject (this);
		
		__renderEvent.type = AbstractViewEvent.RENDER_CAIRO;
		__renderEvent.allowSmoothing = renderSession.allowSmoothing;
		__renderEvent.cairo = renderSession.cairo;
		__renderEvent.renderTransform.copyFrom (__renderTransform);
		__renderEvent.worldColorTransform.__copyFrom (__worldColorTransform);
		__renderEvent.worldTransform.copyFrom (__worldTransform);
		__renderEvent.__renderSession = renderSession;
		
		dispatchEvent (__renderEvent);
		
		renderSession.maskManager.popObject (this);
		__renderEvent.cairo = null;
		
	}
	
	
	private override function __renderCanvas (renderSession:RenderSession):Void {
		
		if (!__renderable) return;
		
		super.__renderCanvas (renderSession);
		
		renderSession.blendModeManager.setBlendMode (__worldBlendMode);
		renderSession.maskManager.pushObject (this);
		
		__renderEvent.type = AbstractViewEvent.RENDER_CANVAS;
		__renderEvent.allowSmoothing = renderSession.allowSmoothing;
		__renderEvent.context = renderSession.context;
		__renderEvent.renderTransform.copyFrom (__renderTransform);
		__renderEvent.worldColorTransform.__copyFrom (__worldColorTransform);
		__renderEvent.worldTransform.copyFrom (__worldTransform);
		__renderEvent.__renderSession = renderSession;
		
		dispatchEvent (__renderEvent);
		
		renderSession.maskManager.popObject (this);
		__renderEvent.context = null;
		
	}
	
	
	private override function __renderGL (renderSession:RenderSession):Void {
		
		if (!__renderable) return;
		
		super.__renderGL (renderSession);
		
		renderSession.blendModeManager.setBlendMode (__worldBlendMode);
		renderSession.maskManager.pushObject (this);
		renderSession.shaderManager.setShader (null);
		
{'fraction_non_alphanumeric': 0.085463563525372, 'fraction_numerical': 0.0, 'mean_word_length': 5.355151515151515, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '5696993', 'n_tokens_mistral': 1726, 'n_tokens_neox': 1479, 'n_words': 248}