summaryrefslogtreecommitdiff
path: root/gtk2_ardour/selection.cc
AgeCommit message (Collapse)Author
2014-12-18Add editor selection state to session history via a SelectionMemento, whichnick_m
combines selection related editor properties with the current editor selection. The related editor properties are: mouse mode, zoom setting, left frame of the canvas, y origin of the canvas. Selection state now includes region views (storing the underlying region id) and time. This patch also fixes a region mute undo bug.
2014-12-01Replace half-baked param metadata with descriptor.David Robillard
Among other things, this means that automation controls/lists have the actual min/max/normal/toggled of parameters, and not those inferred from the Parameter ID, which is not correct for things like plugin parameters. Pushing things down to the Evoral::ParmeterDescriptor may be useful in the future to have lists do smarter things based on parameter range, but currently I have just pushed down the above-mentioned currently used attributes.
2014-11-16Support cut/copy/paste of several regions and lines at once.David Robillard
The idea here is to do the reasonable thing, and copy objects of some type (e.g. MIDI region, gain line) to tracks with a matching type. The user can override this with a track selection, which will be used straight-up. Lost: ability to copy/paste lines across types, e.g. gain to pan. This is often questionable, but sometimes useful, so we will need to implement some sort of "greedy mode" to make it possible. Implementation simple, but not sure what to do. Perhaps this should only be possible if one automation track is explicitly (i.e. via track selection) involved, and the types are at least compatible-ish?
2014-11-14add abort() to non-reached codeRobin Gareus
This cleans up a lot of false-positives in static analysis and also helps compilers to optimize code paths in general. (tagging the fatal stingstream operator as ‘noreturn’ is far less trivial)
2014-09-03selecting a track in the mixer, with synced selection, will now clear any ↵Ben Loftis
objects selected
2014-07-07fix copy paste error in selectionBen Loftis
2014-07-07remove leftover cruft from link-region-and-track removalBen Loftis
2014-07-06remove some cruft with previous commits. remove option ↵Ben Loftis
link-region-and-track-selection since they are now exclusive, and rename select-all-regions to select-all-objects to match the implementation
2014-07-05new approach to selections which will help rationalize Split and similar ↵Ben Loftis
functions. Object and Track selections are now mutually exclusive. a split will happen at (a) selection->regions (b) the intersection of edit_point and selection->tracks or (c) the region under the mouse, IFF nothing else is selected.
2014-02-26severe rationalization (still incomplete) of behaviour of cut + copy.Paul Davis
Quite a bit more to do here to make this as intuitive as it ought to be.
2014-02-25ensure that track selection operations call ::set_selected() for tracks, ↵Paul Davis
allowing faster lookups of selected status during drags
2013-01-02various fixes for moving markers, fixes a crash reported by tim blechmann ↵Paul Davis
and also likely #5232 and #5241 git-svn-id: svn://localhost/ardour2/branches/3.0@13754 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-12-19do NOT deselect markers when clearing object selection - markers are outside ↵Paul Davis
of the main canvas, do not belong to timeaxisviews and thus are not objects in the sense that this method is intended for git-svn-id: svn://localhost/ardour2/branches/3.0@13686 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-12-13fix more range selection issuesPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@13662 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-12-13make sure we never use ID of zero for range selections, fixing a very minor ↵Paul Davis
glitch in deleting a specific range selection from several git-svn-id: svn://localhost/ardour2/branches/3.0@13661 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-12-13various fixes for "advanced" operations on range selections. ctrl-drags now ↵Paul Davis
add a new range selection, allowing discontiguous selections as in ardour2, shift-click extends an existing range selection to the clicked position, alt-drag on a range selection moves it, and to do a so-called "separation drag" now use ctrl-alt-drag (or ctrl-alt-click) git-svn-id: svn://localhost/ardour2/branches/3.0@13660 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-11-26explicitly enforce selection rules to avoid some corner cases and avoid user ↵Ben Loftis
confusion git-svn-id: svn://localhost/ardour2/branches/3.0@13549 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-11-18fix O(N^M) behaviour of control point selection (N = number of control ↵Paul Davis
points, M = number of automatable parameters) git-svn-id: svn://localhost/ardour2/branches/3.0@13525 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-05-31Slightly unpleasant hack to stop control points beingCarl Hetherington
unselected when you ctrl-drag a selected point in order to do a push drag. git-svn-id: svn://localhost/ardour2/branches/3.0@12502 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-05-17Deselect other control points on normal selection.Carl Hetherington
git-svn-id: svn://localhost/ardour2/branches/3.0@12323 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-04-25remove the apparently unnecessary "ui_bind()" macro from entire source basePaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@12088 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-04-22Use a list of ControlPoints to hold the automation selection,Carl Hetherington
rather than a time range. This makes more sense now that we display every point on an automation line, rather than just a subset. Makes the code a fair bit simpler, and should fix some unexpected behaviours, especially when cutting automation points. git-svn-id: svn://localhost/ardour2/branches/3.0@12054 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-02-05clear marker selection as part of Selection::clear(); fixes "error" that ↵Paul Davis
prevents click from creating a new midi region because there appears to be a marker selection git-svn-id: svn://localhost/ardour2/branches/3.0@11449 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-01-30many changes, large and small, related to smart mode editing, range/region ↵Paul Davis
selection, and behaviour of playhead when always-play-range is enabled. could be buggy, but probably in subtle (or even very subtle) ways rather than obvious git-svn-id: svn://localhost/ardour2/branches/3.0@11394 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-01-27Don't add markers to the selection multiple times when adding a list.Carl Hetherington
git-svn-id: svn://localhost/ardour2/branches/3.0@11357 d708f5d6-7413-0410-9779-e7cbd77b26cf
2011-12-05fix minor logic error with linked region & track selectionsPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@10905 d708f5d6-7413-0410-9779-e7cbd77b26cf
2011-11-15provide link-editor-and-mixer-selection option. gui implementation is ↵Paul Davis
slightly hacky because of the implicit endless loop that the link creates git-svn-id: svn://localhost/ardour2/branches/3.0@10624 d708f5d6-7413-0410-9779-e7cbd77b26cf
2011-10-20Save marker selection state in instant.xml (#4203).Carl Hetherington
git-svn-id: svn://localhost/ardour2/branches/3.0@10245 d708f5d6-7413-0410-9779-e7cbd77b26cf
2011-06-01Delete trailing whitespaceDavid Robillard
git-svn-id: svn://localhost/ardour2/branches/3.0@9656 d708f5d6-7413-0410-9779-e7cbd77b26cf
2011-04-23Prevent the point selection straying -ve when control points are positioned ↵Carl Hetherington
close to 0 (should fix #3861). git-svn-id: svn://localhost/ardour2/branches/3.0@9412 d708f5d6-7413-0410-9779-e7cbd77b26cf
2011-04-17Remove extend-range-to-{start,end}-of-region and replace with ↵Carl Hetherington
move-range-{start,end}-to-{previous,next}-region boundary after discussions with Chris. Seems to make more sense, and works without the need for a region selection, which is fiddly to adjust when one is in range mode. git-svn-id: svn://localhost/ardour2/branches/3.0@9360 d708f5d6-7413-0410-9779-e7cbd77b26cf
2011-03-22Fix crash on getting state of selected MIDI region automation tracks (fixes ↵Carl Hetherington
#3860). git-svn-id: svn://localhost/ardour2/branches/3.0@9187 d708f5d6-7413-0410-9779-e7cbd77b26cf
2011-01-04Unselect regions on tracks when the tracks are hidden. Fixes #3653.Carl Hetherington
git-svn-id: svn://localhost/ardour2/branches/3.0@8426 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-12-03Remove all use of nframes_t.Carl Hetherington
git-svn-id: svn://localhost/ardour2/branches/3.0@8166 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-09-17megaopus commit: (1) add __STD_(LIMIT|FORMAT)_MACROS to command line flags ↵Paul Davis
for cc and c++ builds, remove them from source (2) add new Property::midi_data used by MidiRegion to signal that its (MIDI) contents have changed (3) massive switch from nframes_t to framepos_t/framecnt_t including removal of ARDOUR::max_frames (replaced by ARDOUR::max_frame{pos,cnt} (lots more to do but this set was driven by changes to the Diskstream API to use framepos_t git-svn-id: svn://localhost/ardour2/branches/3.0@7791 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-09-15fix crash caused when deleting a region without a playlist PLUS make it ↵Paul Davis
impossible to select a region without a playlist (i.e. part of an unfinished capture pass). fixes #1502 git-svn-id: svn://localhost/ardour2/branches/3.0@7779 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-09-14Fix another assertion failure if a saved selection doesn't correspond to the ↵Carl Hetherington
things that are actually present in the session file. git-svn-id: svn://localhost/ardour2/branches/3.0@7769 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-09-06Cleanup of region drag code to be a bit more efficient and shorter. Fixes ↵Carl Hetherington
crashes when dragging regions to the wrong track type. git-svn-id: svn://localhost/ardour2/branches/3.0@7744 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-08-30Fix another crash on session creation if the stored selection no longer ↵Carl Hetherington
exists in the session. git-svn-id: svn://localhost/ardour2/branches/3.0@7711 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-08-30Respect link of region and track selection when setting via a list of ↵Carl Hetherington
Selectables. Should fix #2153. git-svn-id: svn://localhost/ardour2/branches/3.0@7710 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-08-24fix load+save of plugin parameter automationPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@7678 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-08-20Fix my broken logic for control point selection.Carl Hetherington
git-svn-id: svn://localhost/ardour2/branches/3.0@7663 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-08-18First go at saving window visibility and position state across saves.Carl Hetherington
git-svn-id: svn://localhost/ardour2/branches/3.0@7644 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-08-11Hopefully fix up automation control point selection (finally).Carl Hetherington
git-svn-id: svn://localhost/ardour2/branches/3.0@7592 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-03-30handle deletion of UI objects between the time that a callback is queued ↵Paul Davis
with the UI event loop and the execution of the callback (intrusive, big) git-svn-id: svn://localhost/ardour2/branches/3.0@6807 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-01-05Fixes to permit drags of multiply-selected automation control points.Carl Hetherington
git-svn-id: svn://localhost/ardour2/branches/3.0@6450 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-12-25rationalize destruction pathway (some more); tidy-ify some ImageFrame codePaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@6398 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-12-22cleanup up cleanup at session destruction; clarify the meaning of 3 signals ↵Paul Davis
(DropReferences & Destroyed in libardour ; CatchDeletion in the GTK UI); clarify ownership of objects (session no longer pays attention to DropReferences for objects that it is considered to own, such as routes, sources, etc); fix up MIDI parsing and a couple of other places by correcting syntax for return of values from a boost::signals2::signal (possible danger elsewhere to be checked) git-svn-id: svn://localhost/ardour2/branches/3.0@6389 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-12-21fully implement and deploy explicit x-thread signal connection syntax ↵Paul Davis
(testing comes next) git-svn-id: svn://localhost/ardour2/branches/3.0@6379 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-12-19use new syntax for connecting to backend signals that enforces explicit ↵Paul Davis
connection scope, plus a few other related matters git-svn-id: svn://localhost/ardour2/branches/3.0@6376 d708f5d6-7413-0410-9779-e7cbd77b26cf