Mercurial > hg > svgui
comparison layer/TimeValueLayer.cpp @ 255:e175ade2d6b0
* double-click in navigate mode relocates the centre frame (closing #1734854)
author | Chris Cannam |
---|---|
date | Wed, 13 Jun 2007 09:19:33 +0000 |
parents | 28c8e8e3c537 |
children | 9dd432665059 |
comparison
equal
deleted
inserted
replaced
254:a2ae3d93c645 | 255:e175ade2d6b0 |
---|---|
1044 | 1044 |
1045 m_editingCommand = 0; | 1045 m_editingCommand = 0; |
1046 m_editing = false; | 1046 m_editing = false; |
1047 } | 1047 } |
1048 | 1048 |
1049 void | 1049 bool |
1050 TimeValueLayer::editOpen(View *v, QMouseEvent *e) | 1050 TimeValueLayer::editOpen(View *v, QMouseEvent *e) |
1051 { | 1051 { |
1052 if (!m_model) return; | 1052 if (!m_model) return false; |
1053 | 1053 |
1054 SparseTimeValueModel::PointList points = getLocalPoints(v, e->x()); | 1054 SparseTimeValueModel::PointList points = getLocalPoints(v, e->x()); |
1055 if (points.empty()) return; | 1055 if (points.empty()) return false; |
1056 | 1056 |
1057 SparseTimeValueModel::Point point = *points.begin(); | 1057 SparseTimeValueModel::Point point = *points.begin(); |
1058 | 1058 |
1059 ItemEditDialog *dialog = new ItemEditDialog | 1059 ItemEditDialog *dialog = new ItemEditDialog |
1060 (m_model->getSampleRate(), | 1060 (m_model->getSampleRate(), |
1080 command->addPoint(newPoint); | 1080 command->addPoint(newPoint); |
1081 command->finish(); | 1081 command->finish(); |
1082 } | 1082 } |
1083 | 1083 |
1084 delete dialog; | 1084 delete dialog; |
1085 return true; | |
1085 } | 1086 } |
1086 | 1087 |
1087 void | 1088 void |
1088 TimeValueLayer::moveSelection(Selection s, size_t newStartFrame) | 1089 TimeValueLayer::moveSelection(Selection s, size_t newStartFrame) |
1089 { | 1090 { |