processing / processing/processing4
dispose handlers not called when stop button pressed
未关闭
还没有人认领这个 Issue。
opengl
- 主要语言
- Java
- 星标
- 494
- 派生
- 183
- 平均合并
- 4 小时 39 分钟
- 30 天内合并 PR
- 3
描述
Created by: jdf
In the following sketch, the dispose handler is called when the escape key is pressed, but not when the stop button is pressed.
dispose_bug
SampleLibrary s;
void setup() {
size(200, 200, P3D);
s = new SampleLibrary(this);
}
void draw() {
background(255);
fill(0);
text("" + millis(), 20, 20);
}
SampleLibrary.java
import processing.core.*;
public class SampleLibrary {
public SampleLibrary(PApplet parent) {
parent.registerMethod("dispose", this);
}
public void dispose() {
System.err.println("disposed!");
}
}
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
调研方向
首先在 Processing 中运行提供的 dispose_bug sketch,并比较按下 Escape 与按下停止按钮的情况。跟踪停止按钮的关闭路径以及 SampleLibrary.java 中显示的已注册 dispose 处理器;当以这两种方式停止 sketch 时处理器都会被调用,即表示完成。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- java
- 领域
- desktop
- Issue 类型
- 缺陷
- 难度
- 3/5
- 预计耗时
- 1-2 天
- 活跃度
- 停滞
- 描述清晰度
- 基本清楚
- 新手友好度
- 35/100