mirror of
https://github.com/publiclab/image-sequencer.git
synced 2025-12-13 11:50:02 +01:00
Ui refactor and drag to crop (#245)
* Drag to crop rebase step (#244) * 1.1.0 * 1.2.0 * added plugin Signed-off-by: tech4GT <varun.gupta1798@gmail.com> * drag to crop enabled Signed-off-by: tech4GT <varun.gupta1798@gmail.com> * fix Signed-off-by: tech4GT <varun.gupta1798@gmail.com> * improvement Signed-off-by: tech4GT <varun.gupta1798@gmail.com> * done dragToCrop Signed-off-by: tech4GT <varun.gupta1798@gmail.com> * done with updated ui Signed-off-by: tech4GT <varun.gupta1798@gmail.com> * solved bug for multiple consecutive crops Signed-off-by: tech4GT <varun.gupta1798@gmail.com> * fixed and updated Signed-off-by: tech4GT <varun.gupta1798@gmail.com> * externalized image area select code * major refactoring of crop drag and demo ui modules * work on crop module and ui refactor * completed Step drag ui refactor * revert unbuilt to rebase * built and version bump * various fixes
This commit is contained in:
@@ -1,30 +1,30 @@
|
||||
// add steps to the sequencer
|
||||
function AddStep(ref, image, name, o) {
|
||||
function AddStep(_sequencer, image, name, o) {
|
||||
|
||||
function addStep(image, name, o_) {
|
||||
var moduleInfo = ref.modules[name][1];
|
||||
var moduleInfo = _sequencer.modules[name][1];
|
||||
|
||||
var o = ref.copy(o_);
|
||||
o.number = ref.options.sequencerCounter++; // gives a unique ID to each step
|
||||
var o = _sequencer.copy(o_);
|
||||
o.number = _sequencer.options.sequencerCounter++; // gives a unique ID to each step
|
||||
o.name = o_.name || name || moduleInfo.name;
|
||||
o.description = o_.description || moduleInfo.description;
|
||||
o.selector = o_.selector || 'ismod-' + name;
|
||||
o.container = o_.container || ref.options.selector;
|
||||
o.container = o_.container || _sequencer.options.selector;
|
||||
o.image = image;
|
||||
o.inBrowser = ref.options.inBrowser;
|
||||
o.inBrowser = _sequencer.options.inBrowser;
|
||||
|
||||
o.step = {
|
||||
name: o.name,
|
||||
description: o.description,
|
||||
ID: o.number,
|
||||
imageName: o.image,
|
||||
inBrowser: ref.options.inBrowser,
|
||||
ui: ref.options.ui,
|
||||
inBrowser: _sequencer.options.inBrowser,
|
||||
ui: _sequencer.options.ui,
|
||||
options: o
|
||||
};
|
||||
var UI = ref.events;
|
||||
var module = ref.modules[name][0](o,UI);
|
||||
ref.images[image].steps.push(module);
|
||||
var UI = _sequencer.events;
|
||||
var module = _sequencer.modules[name][0](o,UI);
|
||||
_sequencer.images[image].steps.push(module);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user