Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Comparing changes

Choose two branches to see what's changed or to start a new pull request. If you need to, you can also compare across forks.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also compare across forks.
base fork: oliy/sencha_video
base: 397f09164a
...
head fork: oliy/sencha_video
compare: bb67deeee7
Checking mergeability… Don't worry, you can still create the pull request.
  • 2 commits
  • 4 files changed
  • 0 commit comments
  • 1 contributor
View
30 public/app/view/FrameList.js
@@ -4,10 +4,15 @@ Ext.define('A.view.FrameList', {
itemSelector: 'div.thumb-wrap',
emptyText: 'No images available',
cls : 'horizontal-frame-list',
+ multiSelect : true,
initComponent : function() {
+ var me = this;
+
+ this.addEvents('frameSelect');
+
this.tpl = new Ext.XTemplate(
'<tpl for=".">',
- '<div data-frame="{frameNumber}" class="thumb-wrap">',
+ '<div class="thumb-wrap">',
'<img src="{img_src}" />',
'</div>',
'</tpl>',
@@ -22,7 +27,28 @@ Ext.define('A.view.FrameList', {
this.setWidth(this.store.getCount() * img_width);
this.callParent(arguments);
- }
+
+ this.on({
+ selectionchange : function(view, selections, eOpts) {
+// console.log(view);
+ console.log(selections);
+// console.log(eOpts);
+ var len = selections.length;
+ var frames = [];
+
+
+ for(var i = 0; i < len; i++) {
+ frames.push(selections[i].data.frameNumber);
+ }
+ frames.sort();
+ console.log(frames);
+ IO.Bus.fireEvent('frameSelect', frames);
+ }
+
+ });
+ },
+
+
});
View
21 public/app/view/FrameListContainer.js
@@ -0,0 +1,21 @@
+
+Ext.define('A.view.FrameListContainer', {
+ extend : 'Ext.panel.Panel',
+ alias : ['widget.frame-list-container'],
+ requires : [
+ 'A.view.FrameList'
+ ],
+ autoScroll : true,
+
+ initComponent : function() {
+ var me = this;
+
+ this.setHeight(85);
+ this.frameList = Ext.create('A.view.FrameList', {});
+ this.items = [this.frameList];
+ this.callParent(arguments);
+
+
+ }
+
+});
View
3  public/app/view/TimelinePanel.js
@@ -17,6 +17,9 @@ Ext.define('A.view.TimelinePanel', {
initComponent: function() {
var me = this;
+
+ me.items = [Ext.create('A.view.FrameListContainer', {})];
+
me.callParent(arguments);
}
});
View
10 public/resources/css/temp.css
@@ -1,13 +1,13 @@
@CHARSET "ISO-8859-1";
-.horizontal-frame-list {
- height : 100px;
-
-}
-
.thumb-wrap {
float: left;
+ border-top : 3px solid #fff;
}
.thumb-wrap img {
width: 75px;
}
+.thumb-wrap.x-item-selected {
+ border-top : 3px solid #0f0;
+
+}

No commit comments for this range

Something went wrong with that request. Please try again.