Image selector #123

Closed
wants to merge 8 commits into
from

Conversation

Projects
None yet
2 participants
Contributor

Pomax commented Aug 1, 2012

update for the image selecting component

@toolness toolness commented on the diff Aug 2, 2012

js/fc/ui/preview-to-editor-mapping.js
@@ -55,9 +56,15 @@ define(["jquery", "./mark-tracker"], function($, MarkTracker) {
return result;
}
- function PreviewToEditorMapping(livePreview, codeMirrorAreas) {
- var codeMirror = livePreview.codeMirror;
- var marks = MarkTracker(codeMirror);
+ function PreviewToEditorMapping(options) {
+ var livePreview = options.livePreview,
+ codeMirrorAreas = options.codeMirrorAreas,
+ codeMirror = livePreview.codeMirror,
+ marks = MarkTracker(codeMirror);
+
+ var self = {};
@toolness

toolness Aug 2, 2012

Contributor

You mentioned on IRC that you weren't a fan of this, but I don't mind it--the PreviewToEditorMapping function was designed to be a constructor that returned an object like all the other CamelCased functions in Thimble, we just didn't have any methods/properties to put on it until now, since all its functionality was activated by attaching events to its dependencies.

Pomax closed this Dec 18, 2013

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment