The following commit has been merged in the master branch:
commit de8e46b275f083c3ea501655e7a303ba6c3afdb8
Merge: 403384491ad7b996f53bb37f0e5c24c5bafb3b0f
c4e465dbd83a03662979931d16a83ea45ed966bd
Author: Andrei Zavada <[email protected]>
Date: Sun Oct 7 02:26:35 2012 +0300
Merge branch 'master' of github.com:hmmr/aghermann
diff --combined src/ui/scoring-facility.cc
index 8d06f51,9fe17a1..83e0219
--- a/src/ui/scoring-facility.cc
+++ b/src/ui/scoring-facility.cc
@@@ -52,8 -52,7 +52,8 @@@ aghui::SScoringFacility:
SScoringFacility (agh::CSubject& J,
const string& D, const string& E,
aghui::SExpDesignUI& parent)
- : _p (parent),
+ : SScoringFacilityWidgets (parent),
+ _p (parent),
_csubject (J),
_session (D),
_sepisode (J.measurements.at(D)[E]),
@@@ -92,6 -91,19 +92,6 @@@
aghui::SBusyBlock bb (_p.wMainWindow);
// complete widget construction
- builder = gtk_builder_new();
- if ( !gtk_builder_add_from_resource( builder,
"/org/gtk/aghermann/sf.glade", NULL) ) {
- g_object_unref( (GObject*)builder);
- throw runtime_error( "SScoringFacility::SScoringFacility():
Failed to load GtkBuilder object");
- }
- if ( construct_widgets() ||
- find_dialog.construct_widgets() ||
- filters_dialog.construct_widgets() ||
- phasediff_dialog.construct_widgets() )
- throw runtime_error( "SScoringFacility::SScoringFacility():
Failed to construct own widgets");
- gtk_builder_connect_signals( builder, NULL);
- // we do it all mostly ourself, except for some delete-event binding
to gtk_true()
-
// histogram -> scores
get_hypnogram();
calculate_scored_percent();
@@@ -267,6 -279,10 +267,6 @@@ aghui::SScoringFacility:
// save montage
save_montage();
- // destroy widgets
- gtk_widget_destroy( (GtkWidget*)wScoringFacility);
- g_object_unref( (GObject*)builder);
-
// cause repopulate
redraw_ssubject_timeline();
@@@ -576,13 -592,11 +576,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