Cut core/ui and core/audio comment bloat ~60% (comments only, zero code change)

This commit is contained in:
2026-07-29 20:49:02 -04:00
parent 1f24c4b095
commit 3d3415f943
29 changed files with 527 additions and 1225 deletions
+6 -9
View File
@@ -1,4 +1,4 @@
// drag_out — pure implementation. See drag_out.h. NO REAPER / SWELL / OS / vendor.
// drag_out — pure implementation. See drag_out.h.
#include "core/ui/drag_out.h"
@@ -8,7 +8,6 @@ namespace reasampler::ui {
namespace {
// Half-open point-in-rect (matches the panel's other hit-tests: [x, x+w) x [y, y+h)).
bool insideClient(int px, int py, const PanelClientRect& c) {
return px >= c.x && px < c.x + c.width &&
py >= c.y && py < c.y + c.height;
@@ -20,10 +19,8 @@ DragGesture decideGesture(int px, int py, const PanelClientRect& client,
const DragState& state) {
if (!state.dragging || !state.hasArmedSamples) return DragGesture::None;
if (insideClient(px, py, client)) return DragGesture::Internal;
// Outside the client rect (M11 boundary), refined by S17: a SINGLE-capture drag that is
// still over REAPER's own UI is an instrument drop (heading for a track's FX button);
// anything else (a multi-capture payload, or the pointer off REAPER entirely) is the
// unchanged M11 OS drag-out.
// Outside the client: a single-capture drag still over REAPER's own UI is an instrument
// drop; anything else (multi-capture, or pointer off REAPER entirely) is an OS drag-out.
if (state.singleCapture && state.overReaperUi) return DragGesture::InstrumentDrop;
return DragGesture::OsDrag;
}
@@ -34,15 +31,15 @@ PathList assemblePathList(const std::vector<ResolvedSample>& resolved) {
seen.reserve(resolved.size());
for (const ResolvedSample& s : resolved) {
if (s.absolutePath.empty()) { // shell could not resolve it
if (s.absolutePath.empty()) {
++out.skippedUnresolved;
continue;
}
if (!s.fileExists) { // stale index entry, file gone
if (!s.fileExists) {
++out.skippedMissing;
continue;
}
if (!seen.insert(s.absolutePath).second) { // already emitted this path
if (!seen.insert(s.absolutePath).second) {
++out.skippedDuplicate;
continue;
}