summaryrefslogtreecommitdiff
path: root/shader-gif.html
diff options
context:
space:
mode:
Diffstat (limited to 'shader-gif.html')
-rw-r--r--shader-gif.html10
1 files changed, 6 insertions, 4 deletions
diff --git a/shader-gif.html b/shader-gif.html
index f99aaba..e5c4884 100644
--- a/shader-gif.html
+++ b/shader-gif.html
@@ -6,10 +6,10 @@
#url { width: 100px; }
#width,#height,#frames,#delay {width: 30px; }
#shader { width: 400px; height: 247px; font-family: fixed; }
-#frames { width: 400px; height: 100px; }
+#frames { width: 450px; height: 100px; }
#controls { width: 450px; }
-#frames div { padding: 1px; }
-#frames .remove { position: absolute; top: 5px; right: 5px; color: #f00; }
+#frames div { padding: 1px; position: relative; }
+#frames .remove { position: absolute; top: 5px; right: 5px; color: #f00; padding: 3px; border: 0;background: white; font-size: 10px; line-height: 10px; }
div { float: left; padding: 10px;}
</style>
</head>
@@ -64,6 +64,7 @@ function init(){
start: function(){ dragging = true },
stop: function(){ dragging = false }
});
+ $(document).on("click","#frames .remove",remove_frame)
$("#frames").disableSelection();
demo('#first')
load()
@@ -153,10 +154,11 @@ function add_frame(){
$("#frames").append($el)
}
function remove_frame(){
+ $(this).closest("div").remove()
}
</script>
<script type="text/html" id="frame-template">
-<span class="remove"></span>
+<button class="remove">x</button>
<span class="frame"></span>
</script>
<script type="text/javascript-shader" id="first">