{
FileXML output;
// cause data to be stored directly in text
- output.set_shared_output(keyframe->get_data(), MESSAGESIZE);
+ output.set_shared_output(keyframe->xbuf);
// Store data
output.tag.set_title("DESCRATCH");
output.tag.set_property("THRESHOLD", config.threshold);
void DeScratchMain::read_data(KeyFrame *keyframe)
{
FileXML input;
- input.set_shared_input(keyframe->get_data(), strlen(keyframe->get_data()));
+ input.set_shared_input(keyframe->xbuf);
int result = 0;
DeScratchWindow::DeScratchWindow(DeScratchMain *plugin)
- : PluginClientWindow(plugin, 512, 256, 512, 256, 0)
+ : PluginClientWindow(plugin, 512, 270, 512, 270, 0)
{
this->plugin = plugin;
}
BC_Title *title;
add_tool(title = new BC_Title(x, y, _("DeScratch:")));
- y += title->get_h() + 5;
+
+ int w1 = DeScratchReset::calculate_w(this, _("Reset"));
+ add_tool(reset = new DeScratchReset(this, get_w()-w1-15, y));
+
+ y += title->get_h() + 15;
int x1 = x, x2 = get_w()/2;
add_tool(title = new BC_Title(x1=x, y, _("threshold:")));
x1 += title->get_w()+16;
add_tool(title = new BC_Title(x1=x, y, _("Mode:")));
x1 += title->get_w()+16;
add_tool(title = new BC_Title(x1, y, _("y:")));
- int w1 = title->get_w()+16;
+ w1 = title->get_w()+16;
add_tool(y_mode = new DeScratchMode(this, (x1+=w1), y, &config.mode_y));
y_mode->create_objects(); x1 += y_mode->get_w()+16;
add_tool(title = new BC_Title(x1, y, _("u:")));
x1 += mark->get_w() + 10;
add_tool(edge_only = new DeScratchEdgeOnly(this, x1, y));
- w1 = DeScratchReset::calculate_w(this, _("Reset"));
- int h1 = DeScratchReset::calculate_h();
- add_tool(reset = new DeScratchReset(this, get_w()-w1-15, get_h()-h1-15));
-
show_window();
}