Mercurial > hg > svgui
comparison widgets/Pane.cpp @ 82:82482231b6b1
* Add file open/save operations to main toolbar
* Allow opening any sort of file from toolbar file open function
* First cut at on-disc cacheing for decoded mp3/ogg files
* Permit un-snapped selection by holding Shift
author | Chris Cannam |
---|---|
date | Thu, 27 Apr 2006 17:29:19 +0000 |
parents | fd348f36c0d3 |
children | 803830f186ef |
comparison
equal
deleted
inserted
replaced
81:b9f71b8ae21e | 82:82482231b6b1 |
---|---|
523 int mouseFrame = getFrameForX(e->x()); | 523 int mouseFrame = getFrameForX(e->x()); |
524 size_t resolution = 1; | 524 size_t resolution = 1; |
525 int snapFrame = mouseFrame; | 525 int snapFrame = mouseFrame; |
526 | 526 |
527 Layer *layer = getSelectedLayer(); | 527 Layer *layer = getSelectedLayer(); |
528 if (layer) { | 528 if (layer && !m_shiftPressed) { |
529 layer->snapToFeatureFrame(this, snapFrame, | 529 layer->snapToFeatureFrame(this, snapFrame, |
530 resolution, Layer::SnapLeft); | 530 resolution, Layer::SnapLeft); |
531 } | 531 } |
532 | 532 |
533 if (snapFrame < 0) snapFrame = 0; | 533 if (snapFrame < 0) snapFrame = 0; |
738 size_t resolution = 1; | 738 size_t resolution = 1; |
739 int snapFrameLeft = mouseFrame; | 739 int snapFrameLeft = mouseFrame; |
740 int snapFrameRight = mouseFrame; | 740 int snapFrameRight = mouseFrame; |
741 | 741 |
742 Layer *layer = getSelectedLayer(); | 742 Layer *layer = getSelectedLayer(); |
743 if (layer) { | 743 if (layer && !m_shiftPressed) { |
744 layer->snapToFeatureFrame(this, snapFrameLeft, | 744 layer->snapToFeatureFrame(this, snapFrameLeft, |
745 resolution, Layer::SnapLeft); | 745 resolution, Layer::SnapLeft); |
746 layer->snapToFeatureFrame(this, snapFrameRight, | 746 layer->snapToFeatureFrame(this, snapFrameRight, |
747 resolution, Layer::SnapRight); | 747 resolution, Layer::SnapRight); |
748 } | 748 } |