13
0
Commit Graph

273 Commits

Author SHA1 Message Date
Julien ROGER
1fbe4253aa Fix 6609: Right-click in active track name box crashes
When right-clicking in the text entry, popup menu grabs focus. Consequently, the "focus out" handler is called, destroys the text entry and replaces it by the label name of the track.
When menu pops up, it tries to access to a widget no longer available.
2016-02-13 12:30:31 +10:00
b074ff0dd5 Remove GhostRegion::CatchDeletion signal to reduce session close times
Currently when a GhostRegion is deleted by its "parent" RegionView it emits the
static GhostRegion::CatchDeletion signal which is connected to the
RegionView::remove_ghost method of every RegionView instance.

With a static GhostRegion::CatchDeletion signal a particular test session
causes 31 Million calls of RegionView::remove_ghost on Session deletion and the
session takes 70 seconds to close with a debug build.

The lifetime of a ghost region is tied to both the TimeAxisView(TAV) and
RegionView(RV) in that when a RegionView is deleted all GhostRegion instances
associated with the RegionView should be deleted or when a TimeAxisView is
deleted all ghost regions that are contained in the view should be deleted.

This means that there needs to be notification between GhostRegion and both
classes. Instead of using a signal for this as we know there are only two
listeners and GhostRegion already holds a reference to the TimeAxisView, also
take a reference to the parent RegionView in the GhostRegion constructor and
use it to notify the RegionView when GhostRegion destructor is called so it can
drop any references it holds.

Using a direct function call in the GhostRegion destructor to notify the
TimeAxisView and RegionView "parents" brings the unload/close time down for the
test session from 70 seconds to 4.5 seconds.

The GhostRegion also references canvas items that are added to the TimeAxisView
canvas group or at least a canvas group that it manages. So when the
TimeAxisView is destroyed and the canvas group that is the parent of those
items is destroyed, the GhostRegion's canvas items will also be
deleted/destroyed by the parent canvas item/group. This means the GhostRegions
must be destroyed when the TimeAxisView they are contained in is destroyed or
there will be dangling references to canvas items that have already been
deleted and trying to delete them again will be bad.
2015-10-22 11:51:03 -04:00
22b07e0233 NOOP, remove trailing tabs/whitespace. 2015-10-05 16:17:49 +02:00
4dc63966f0 globally remove all trailing whitespace from ardour code base.
Paul Davis was responsible for introducing almost all of this.
2015-10-04 14:51:05 -04:00
1d42ed077e Use ARDOUR_UI_UTILS::set_tooltip rather than via ARDOUR_UI::set_tip
This removes the direct dependence on ARDOUR_UI/Gtk_UI for setting
tooltips. Removes inclusion of ardour_ui.h from 16 files.
2015-09-16 16:55:17 -04:00
6b019a4953 Move UIConfiguration Singleton into UIConfiguration header
This removes the direct dependence on ardour_ui.h from 39 files
2015-09-16 16:55:17 -04:00
45d487f16e Move ARDOUR_UI::ui_scale into UIConfiguration class 2015-09-16 16:55:17 -04:00
fc1e7dbb55 Move DPIReset and ColorsChanged signals into UIConfiguration 2015-09-16 16:55:17 -04:00
9c6a821c67 prevent crash when using WM close button on "new route name contains bad chars" dialog.
The dialog would be created twice, once because the user hit enter etc. to indicate they were done editing,
and once because focus left the name text entry, also indicate the end of editing. We now note that we're
already processing the end of a name edit, and do nothing in that case
2015-05-27 19:34:11 -04:00
b38ab89d92 clean up GUI scaling 2015-04-22 21:40:43 +02:00
0c468dc379 add more contexts for SLA. 2015-04-05 00:44:03 +02:00
f1ce87a699 add API to select TAV height mode.
preparation for further Summary and Number of visible
track count fixes.

* “Only Self”: don’t resize child-views (old default)
* “Total Height”: distribute height equally among 
   all visible child [automation] lanes
* “Height per Lane”: given height should be applied
   to all sub-views.
2015-03-19 21:47:34 +01:00
11cfdd4c6d remove use of TimeRectangle 2015-02-11 21:59:38 -05:00
9e0cd98ad4 fix select-all-regions-within (it used to select everything overlapped) 2015-01-09 12:21:10 -06:00
c14f6c59db apply font-scale to overall layout (rulers, track-header) - fixes #6088 2014-12-28 15:01:49 +01:00
21f5859981 fix double-free/crash at session close 2014-12-19 21:30:22 +01:00
2145fd2973 next 2 modifiers 2014-12-15 10:46:15 -05:00
56ca52651e fix up requested color names everywhere.
Thank <deity> for emacs ... space-uncamelcase-word-at-point FTW
2014-12-14 16:15:38 -05:00
48a7a11974 initial pass to replace all UIConfiguration::get_XXXXXX() calls with UIConfiguration::color(name).
IMPORTANT: names have not been downcased and spaced yet, so many colors are not found
2014-12-14 12:27:07 -05:00
89be7ae58c Fix crash on quit when in a non-route time axis. 2014-12-06 22:43:06 -05:00
09bd88c9df Fix crash when resizing a track quickly.
Triggered by resize drag an automation track very quickly upwards to shrink it
to the minimum.  Caused by unsigned integer underflow.
2014-12-06 22:43:06 -05:00
6b3a8915f3 add abort() to non-reached code
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-11-14 11:30:08 +01:00
4260d0ca0e use new canvas colors header as necessary 2014-11-07 14:24:27 -05:00
555ceba876 various positional fixes for TimeAxisView, including moving the separator line to the bottom, and keeping it in the same coordinate space as the TAV group 2014-11-05 19:45:23 -05:00
f1e6b28ab7 use ArdourCanvas::TimeRectangle for regions, notes, markers 2014-11-03 21:48:08 -05:00
90825340c9 move start of a time axis view back to 0.0 on the x-axis, not 1.0 2014-11-03 21:48:08 -05:00
45b7a03b7b retain selection on track-height change 2014-11-01 16:54:52 +01:00
ba4d1cd1c1 remove "canvasvar_" from all functions related to obtaining values from ARDOUR_UI::config() 2014-10-21 22:58:58 -04:00
ff5b658bc2 fix TAV text-entry size.
for now: no round corners, gtk-entry + its frame
packing messes things up
2014-09-09 00:05:14 +02:00
b9f0751438 Move Scroomer out of Track Selection Box:
* no horiz space between Piano-Roll & Track
* 1:1 mapping of note's vertical space (no border)
2014-09-08 18:43:08 +02:00
1bb6fd752c special case track-header buttons 2014-09-07 20:23:49 +02:00
4912409a8d gtk style related fixes:
* remove some old/unused styles
* fix plugin-ui button (hover color when active)
* consistent style for route buttons
  (and related ArdourButton updates)
2014-09-06 12:49:57 +02:00
028346d412 Revert "use a gloabl size group for track-header ctrl buttons"
This reverts commit 86eb72955c.
2014-09-06 03:36:01 +02:00
4c12a01b62 re-order TAV widget packing:
allow to resize automation tracks on the indent handle, too
2014-09-05 00:13:53 +02:00
86eb72955c use a gloabl size group for track-header ctrl buttons 2014-09-04 23:21:05 +02:00
2651bc7e10 NOOP, fix indent 2014-09-04 21:12:50 +02:00
4dbfbb6edb fix c4be8c2a67 2014-09-04 21:03:07 +02:00
dc02625b56 further tweaks pertaining the track-number height 2014-09-04 20:11:44 +02:00
c4be8c2a67 when track selection changes, cancel any and all name editing 2014-09-04 13:57:05 -04:00
795451a697 Trick 17: share separator + border:
This effectively adds a line after the last track.
2014-09-04 18:08:45 +02:00
cb05e3a21d dedicated TAV separator line 2014-09-04 17:01:28 +02:00
70358639de Revert "cont'd work on automation-track headers (amend ba53af1c5)"
This reverts commit beb5e3e777.
2014-09-04 16:14:01 +02:00
dea4b27ca6 update number label geometry
the number label can be significantly wider than other
ctrl buttons and does not lend itself or be 'square'.
2014-09-04 03:09:38 +02:00
beb5e3e777 cont'd work on automation-track headers (amend ba53af1c5)
now that the separator line is at the top,
offset region-contents y0 by 1px.
2014-09-03 20:48:20 +02:00
ba53af1c50 quick mockup of indented automation-track headers
XXX: If we keep this approach, TimeAxisView::show_at()
needs to be fixed.
TimeAxisView::_canvas_display should draw the separator
line at the top, and regions inside moved down 1px.
2014-09-03 15:03:35 +02:00
b184df3286 static global definition for track-header width
the track-header minimum width is defined by
the name-label (IFF the 2nd row fader is not visible,
but the fader is rather small by default and and grows)

track-header width in almost all cases is:
   name-label width
 + width of three button (1 char each)
 + max size of all meters (if visible)
 + width of MIDI scroomer (if visible)
 + 2px table cellspacing (per column)
2014-09-02 18:12:39 +02:00
88df9c28a6 fix static initialization of Gtk::SizeGroup 2014-09-02 05:14:26 +02:00
423f6e3445 fix track-header hide/show 2014-08-31 22:24:26 +02:00
154621978a track-header fader tweaks:
* align height to button-height.
* align width to label text-entry
* increase min width
2014-08-31 21:32:22 +02:00
0b1ee476ed proper 1px track separator 2014-08-31 20:08:38 +02:00