Warning: session_start(): open(/var/lib/php/sessions/sess_eq63q3nh3rfo28v8flhgo0js0c, O_RDWR) failed: No space left on device (28) in /var/www/tb-usercake/models/config.php on line 51
Warning: session_start(): Failed to read session data: files (path: /var/lib/php/sessions) in /var/www/tb-usercake/models/config.php on line 51
sclass VolatileImageSurfaceDemo is Swingable {
new Timings timings;
JLabel lblTimings = jlabel();
JVolatileImageSurface surface;
settable Renderable renderable = (g, w, h) -> {
S mode = surface.volatileMode() ? " [vol]" : "";
timings.do("background" + mode, -> {
g.setColor(Color.green);
g.fillRect(0, 0, w, h);
});
timings.do("circle" + mode, ->
fillCircle(g, w/2, h/2, w/4, Color.blue));
};
visualize {
surface = new JVolatileImageSurface(renderable);
awtDoEvery(lblTimings, 1.0, -> lblTimings.setText(timings.toStringSingleLine()));
JCheckBox cbVolatileMode = jCheckBox(true, "Use volatile image");
onChangeAndNow(cbVolatileMode, -> surface.setVolatileMode(isChecked(cbVolatileMode)));
ret northCenterAndSouthWithMargin(
jcenteredline(cbVolatileMode),
surface,
lblTimings);
}
}