- (void)wxMessageBox( "wxScroll demo II\n"
- "Robert Roebling (c) 1998",
- "About wxScroll II Demo", wxICON_INFORMATION | wxOK );
+ (void)wxMessageBox( "wxPlotWindow Demo\n"
+ "Robert Roebling (c) 1999,2000",
+ "About wxPlotWindow Demo", wxICON_INFORMATION | wxOK );
+}
+
+void MyFrame::OnPlotClick( wxPlotEvent &event )
+{
+ double x = event.GetPosition() * m_plot->GetUnitsPerValue();
+ double y = event.GetCurve()->GetY( event.GetPosition() );
+ wxLogMessage( "Clicked on curve at x coordinate: %f, value: %f", x, y );
+}
+
+void MyFrame::OnPlotDClick( wxPlotEvent &event )
+{
+ double x = event.GetPosition() * m_plot->GetUnitsPerValue();
+ double y = event.GetCurve()->GetY( event.GetPosition() );
+ wxLogMessage( "Double clicked on curve at x coordinate: %f, value: %f", x, y );