Commit 223fad93 authored by Xavier de Blas's avatar Xavier de Blas

race encoder displays image after capture on analyze tab

parent 9ad69234
......@@ -1875,6 +1875,9 @@
<placeholder/>
</child>
<child>
<placeholder/>
</child>
<child>
<widget class="GtkLabel" id="label_start_selector_jumps">
<property name="visible">True</property>
<property name="can_focus">False</property>
......@@ -20473,9 +20476,6 @@ Concentric</property>
<placeholder/>
</child>
<child>
<placeholder/>
</child>
<child>
<widget class="GtkCheckButton" id="checkbutton_force_sensor_ai_b">
<property name="width_request">30</property>
<property name="visible">True</property>
......@@ -20645,6 +20645,12 @@ Concentric</property>
<child>
<placeholder/>
</child>
<child>
<placeholder/>
</child>
<child>
<placeholder/>
</child>
</widget>
<packing>
<property name="expand">False</property>
......@@ -20808,6 +20814,78 @@ Concentric</property>
<property name="type">tab</property>
</packing>
</child>
<child>
<widget class="GtkVBox" id="vbox138">
<property name="visible">True</property>
<property name="can_focus">False</property>
<child>
<widget class="GtkLabel" id="label394">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label">race encoder</property>
</widget>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
<property name="position">0</property>
</packing>
</child>
<child>
<widget class="GtkScrolledWindow" id="scrolledwindow9">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="hscrollbar_policy">automatic</property>
<property name="vscrollbar_policy">automatic</property>
<property name="shadow_type">in</property>
<child>
<widget class="GtkViewport" id="viewport_race_encoder_graph">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="shadow_type">none</property>
<child>
<widget class="GtkVBox" id="vbox139">
<property name="visible">True</property>
<property name="can_focus">False</property>
<child>
<widget class="GtkImage" id="image_race_encoder_graph">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="stock">gtk-missing-image</property>
</widget>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
</widget>
</child>
</widget>
</child>
</widget>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
</widget>
<packing>
<property name="position">4</property>
</packing>
</child>
<child>
<widget class="GtkLabel" id="label393">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label">raceencoder</property>
</widget>
<packing>
<property name="position">4</property>
<property name="tab_fill">False</property>
<property name="type">tab</property>
</packing>
</child>
</widget>
<packing>
<property name="position">1</property>
......@@ -29157,6 +29235,9 @@ then click this button.</property>
<child>
<placeholder/>
</child>
<child>
<placeholder/>
</child>
</widget>
<packing>
<property name="expand">False</property>
......@@ -476,7 +476,7 @@ public partial class ChronoJumpWindow
private string progVersion;
private string progName;
private enum notebook_analyze_pages { STATISTICS, JUMPSPROFILE, SPRINT, FORCESENSOR }
private enum notebook_analyze_pages { STATISTICS, JUMPSPROFILE, SPRINT, FORCESENSOR, RACEENCODER }
private string runningFileName; //useful for knowing if there are two chronojump instances
......@@ -3369,7 +3369,7 @@ public partial class ChronoJumpWindow
// on_extra_window_reaction_times_test_changed(new object(), new EventArgs());
//notebook_capture_analyze.ShowTabs = false; //only capture tab is shown (only valid for "OTHER" tests)
hbox_contacts_sup_capture_analyze_two_buttons.Visible = false;
hbox_contacts_sup_capture_analyze_two_buttons.Visible = true;
button_threshold.Visible = false;
button_force_sensor_adjust.Visible = false;
//notebook_capture_analyze.GetNthPage(2).Hide(); //hide jumpsProfile on other tests
......@@ -7033,10 +7033,12 @@ LogB.Debug("mc finished 5");
}
else if(current_menuitem_mode == Constants.Menuitem_modes.FORCESENSOR)
notebook_analyze.CurrentPage = Convert.ToInt32(notebook_analyze_pages.FORCESENSOR);
else if(current_menuitem_mode == Constants.Menuitem_modes.RUNSENCODER)
notebook_analyze.CurrentPage = Convert.ToInt32(notebook_analyze_pages.RACEENCODER);
else
notebook_analyze.CurrentPage = Convert.ToInt32(notebook_analyze_pages.STATISTICS);
notebook_capture_analyze.CurrentPage = Convert.ToInt32(notebook_analyze_pages.JUMPSPROFILE);
notebook_capture_analyze.CurrentPage = 1;
}
private void on_radio_mode_contacts_general_toggled (object o, EventArgs args)
......
......@@ -34,6 +34,7 @@ public partial class ChronoJumpWindow
{
[Widget] Gtk.SpinButton race_analyzer_spinbutton_distance;
[Widget] Gtk.SpinButton race_analyzer_spinbutton_temperature;
[Widget] Gtk.Image image_race_encoder_graph;
int race_analyzer_distance;
int race_analyzer_temperature;
......@@ -463,6 +464,10 @@ LogB.Information(" fc C finish");
event_execute_label_message.Text = "Saved." + captureEndedMessage;
Thread.Sleep (250); //Wait a bit to ensure is copied
runEncoderAnalyzeOpenImage();
notebook_analyze.CurrentPage = Convert.ToInt32(notebook_analyze_pages.RACEENCODER);
notebook_capture_analyze.CurrentPage = 1;
/*
fscPoints.InitRealWidthHeight();
forceSensorDoSignalGraphPlot();
......@@ -571,4 +576,12 @@ LogB.Information(" fc R ");
hbox_chronopics_and_more.Sensitive = sensitive;
}
void runEncoderAnalyzeOpenImage()
{
string imagePath = UtilEncoder.GetSprintEncoderImage();
image_race_encoder_graph = UtilGtk.OpenImageSafe(
imagePath,
image_race_encoder_graph);
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment