summaryrefslogtreecommitdiffstats
path: root/assets/js/sample-editor.js
diff options
context:
space:
mode:
authorTeddy Wing2013-11-09 15:48:40 -0500
committerTeddy Wing2013-11-09 15:48:40 -0500
commit26ddd8e6ca882d30e1545ab84fa8e8b505e0b79d (patch)
tree1854571b3cd782609464e3e3b1003875a483e8db /assets/js/sample-editor.js
parentcab4fc2e272a119ccd5ca07818c34b5dfb07790e (diff)
downloadclip-play-26ddd8e6ca882d30e1545ab84fa8e8b505e0b79d.tar.bz2
Set up progress bar and clip chooser
Initial setup for a progress bar and basic interface for choosing a sample clip. Includes a bar with two draggable lines to set a range within the bar.
Diffstat (limited to 'assets/js/sample-editor.js')
-rw-r--r--assets/js/sample-editor.js19
1 files changed, 19 insertions, 0 deletions
diff --git a/assets/js/sample-editor.js b/assets/js/sample-editor.js
new file mode 100644
index 0000000..10f5a08
--- /dev/null
+++ b/assets/js/sample-editor.js
@@ -0,0 +1,19 @@
+var SampleEditor = SampleEditor || {};
+
+(function($) {
+ SampleEditor = function() {
+ this.initialize = function() {
+ var $clip_line = $('.js-clip-line');
+
+ $clip_line.draggable({
+ axis: 'x',
+ handle: '.js-drag-handle',
+ scroll: false,
+ containment: $clip_line.parents('.progress-bar')
+ });
+ };
+
+
+ return this;
+ };
+})(jQuery); \ No newline at end of file