The following commit has been merged in the master branch:
commit c4e465dbd83a03662979931d16a83ea45ed966bd
Author: andrei zavada <[email protected]>
Date: Fri Oct 5 09:09:54 2012 +0000
fix channel_near
diff --git a/src/ui/scoring-facility.cc b/src/ui/scoring-facility.cc
index c1d505b..9fe17a1 100644
--- a/src/ui/scoring-facility.cc
+++ b/src/ui/scoring-facility.cc
@@ -592,13 +592,11 @@ channel_near( int y)
for ( auto &H : channels ) {
if ( H.hidden )
continue;
- thisy = y - H.zeroy;
- if ( thisy < 0 ) {
- if ( -thisy < nearest )
- return &const_cast<SChannel&>(H);
- else
- return nearest_h;
- }
+ thisy = (y > H.zeroy) ? y - H.zeroy : H.zeroy - y;
+ // if ( thisy < nearest )
+ // return &const_cast<SChannel&>(H);
+ // else
+ // return nearest_h;
if ( thisy < nearest ) {
nearest = thisy;
nearest_h = &H;
--
Sleep experiment manager
_______________________________________________
debian-med-commit mailing list
[email protected]
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/debian-med-commit