.. | .. |
---|
5 | 5 | import timeflow.data.db.DBUtils; |
---|
6 | 6 | import timeflow.data.time.*; |
---|
7 | 7 | import timeflow.model.*; |
---|
| 8 | + |
---|
8 | 9 | //import timeflow.views.CalendarView.CalendarPanel; |
---|
9 | 10 | //import timeflow.views.CalendarView.ScrollingCalendar; |
---|
10 | 11 | import timeflow.vis.Mouseover; |
---|
.. | .. |
---|
37 | 38 | return controls; |
---|
38 | 39 | } |
---|
39 | 40 | |
---|
40 | | - public TimelineView(TFModel model) |
---|
| 41 | + public TimelineView(TimeflowModel model) |
---|
41 | 42 | { |
---|
42 | 43 | super(model); |
---|
| 44 | + |
---|
43 | 45 | visuals = new TimelineVisuals(model); |
---|
44 | 46 | grid = new AxisRenderer(visuals); |
---|
45 | 47 | timeline = new TimelineRenderer(visuals); |
---|
.. | .. |
---|
55 | 57 | |
---|
56 | 58 | TimelineSlider slider = new TimelineSlider(visuals, 24 * 60 * 60 * 1000L, new Runnable() |
---|
57 | 59 | { |
---|
58 | | - |
---|
59 | 60 | @Override |
---|
60 | 61 | public void run() |
---|
61 | 62 | { |
---|
62 | 63 | redraw(); |
---|
63 | 64 | } |
---|
64 | 65 | }); |
---|
| 66 | + |
---|
65 | 67 | bottom.add(slider, BorderLayout.CENTER); |
---|
66 | 68 | |
---|
67 | 69 | controls = new JPanel(); |
---|
68 | | - controls.setBackground(Color.white); |
---|
| 70 | + controls.setBackground(Color.red); |
---|
69 | 71 | controls.setLayout(new BorderLayout());//new GridLayout(2,1)); |
---|
70 | 72 | |
---|
71 | 73 | // top part of grid: zoom buttons. |
---|
72 | 74 | ComponentCluster buttons = new ComponentCluster("Zoom"); |
---|
| 75 | + |
---|
73 | 76 | //ImageIcon zoomOutIcon = new ImageIcon("images/zoom_out.gif"); |
---|
74 | 77 | JButton zoomIn = new JButton("In 1/2X"); |
---|
75 | 78 | buttons.addContent(zoomIn); |
---|
.. | .. |
---|
123 | 126 | moveTime(visuals.getFitToVisibleRange()); |
---|
124 | 127 | }}); |
---|
125 | 128 | */ |
---|
126 | | - controls.add(buttons, BorderLayout.NORTH); |
---|
| 129 | + controls.add(buttons, BorderLayout.SOUTH); |
---|
127 | 130 | |
---|
128 | 131 | // ok, now do second part of grid: layout style buttons. |
---|
129 | 132 | ComponentCluster layoutPanel = new ComponentCluster("Layout"); |
---|
.. | .. |
---|
151 | 154 | graph.addActionListener(new LayoutSetter(TimelineVisuals.Layout.GRAPH)); |
---|
152 | 155 | layoutGroup.add(graph); |
---|
153 | 156 | |
---|
154 | | - controls.add(layoutPanel, BorderLayout.CENTER); |
---|
| 157 | + //controls.add(layoutPanel, BorderLayout.CENTER); |
---|
155 | 158 | } |
---|
156 | 159 | |
---|
157 | 160 | class LayoutSetter implements ActionListener |
---|
.. | .. |
---|
325 | 328 | |
---|
326 | 329 | class TimelinePanel extends AbstractVisualizationView |
---|
327 | 330 | { |
---|
328 | | - public TimelinePanel(TFModel model) |
---|
| 331 | + public TimelinePanel(TimeflowModel model) |
---|
329 | 332 | { |
---|
330 | 333 | super(model); |
---|
331 | 334 | |
---|