Separate SIMULATOR_PANEL from SIMULATOR_FRAME.

This is primarily to allow wxFormBuilder to create the panel without
the dangerous hack of passing a wxWindow ID into KIWAY_PLAYER's ctor.
This commit is contained in:
Jeff Young 2023-06-15 13:39:04 +01:00
parent 5c4ca9f092
commit abc0c19d64
11 changed files with 3019 additions and 2771 deletions

View File

@ -226,7 +226,8 @@ set( EESCHEMA_SIM_SRCS
sim/ngspice_circuit_model.cpp sim/ngspice_circuit_model.cpp
sim/ngspice.cpp sim/ngspice.cpp
sim/simulator_frame.cpp sim/simulator_frame.cpp
sim/simulator_frame_base.cpp sim/simulator_panel.cpp
sim/simulator_panel_base.cpp
sim/sim_plot_colors.cpp sim/sim_plot_colors.cpp
sim/sim_plot_panel_base.cpp sim/sim_plot_panel_base.cpp
sim/sim_plot_panel.cpp sim/sim_plot_panel.cpp

File diff suppressed because it is too large Load Diff

View File

@ -29,7 +29,7 @@
#define SIMULATOR_FRAME_H #define SIMULATOR_FRAME_H
#include <sim/simulator_frame_base.h> #include <sim/simulator_panel_base.h>
#include <sim/sim_types.h> #include <sim/sim_types.h>
#include <kiway_player.h> #include <kiway_player.h>
@ -43,17 +43,9 @@
class SCH_EDIT_FRAME; class SCH_EDIT_FRAME;
class SCH_SYMBOL; class SCH_SYMBOL;
class SIMULATOR_PANEL;
class SPICE_SIMULATOR;
class SPICE_SIMULATOR_SETTINGS;
class NGSPICE_CIRCUIT_MODEL;
#include <sim/sim_plot_panel.h>
#include <sim/sim_plot_panel_base.h>
#include "widgets/sim_notebook.h"
class SIM_THREAD_REPORTER; class SIM_THREAD_REPORTER;
class TUNER_SLIDER; class ACTION_TOOLBAR;
/** /**
@ -75,7 +67,7 @@ class TUNER_SLIDER;
*/ */
class SIMULATOR_FRAME : public SIMULATOR_FRAME_BASE class SIMULATOR_FRAME : public KIWAY_PLAYER
{ {
public: public:
SIMULATOR_FRAME( KIWAY* aKiway, wxWindow* aParent ); SIMULATOR_FRAME( KIWAY* aKiway, wxWindow* aParent );
@ -94,9 +86,8 @@ public:
* *
* @param aSimCommand is requested simulation command. * @param aSimCommand is requested simulation command.
* @param aSimOptions netlisting options * @param aSimOptions netlisting options
* @return The new plot panel.
*/ */
SIM_PLOT_PANEL_BASE* NewPlotPanel( const wxString& aSimCommand, int aSimOptions ); void NewPlotPanel( const wxString& aSimCommand, int aSimOptions );
/** /**
* Shows a dialog for editing the current tab's simulation command, or creating a new tab * Shows a dialog for editing the current tab's simulation command, or creating a new tab
@ -104,9 +95,10 @@ public:
*/ */
bool EditSimCommand(); bool EditSimCommand();
const std::vector<wxString>& Signals() { return m_signals; } const std::vector<wxString>& Signals();
const std::map<int, wxString>& UserDefinedSignals();
const std::map<int, wxString>& UserDefinedSignals() { return m_userDefinedSignals; }
void SetUserDefinedSignals( const std::map<int, wxString>& aSignals ); void SetUserDefinedSignals( const std::map<int, wxString>& aSignals );
/** /**
@ -124,75 +116,16 @@ public:
*/ */
void AddCurrentTrace( const wxString& aDeviceName ); void AddCurrentTrace( const wxString& aDeviceName );
/**
* Get/Set the number of significant digits and the range for formatting a cursor value.
* @param aValueCol 0 indicates the X value column; 1 the Y value.
*/
SPICE_VALUE_FORMAT GetCursorFormat( int aCursorId, int aValueCol ) const
{
return m_cursorFormats[ aCursorId ][ aValueCol ];
}
void SetCursorFormat( int aCursorId, int aValueCol, const SPICE_VALUE_FORMAT& aFormat )
{
m_cursorFormats[ aCursorId ][ aValueCol ] = aFormat;
wxCommandEvent dummy;
onCursorUpdate( dummy );
}
/** /**
* Add a tuner for a symbol. * Add a tuner for a symbol.
*/ */
void AddTuner( const SCH_SHEET_PATH& aSheetPath, SCH_SYMBOL* aSymbol ); void AddTuner( const SCH_SHEET_PATH& aSheetPath, SCH_SYMBOL* aSymbol );
/**
* Remove an existing tuner.
*/
void RemoveTuner( TUNER_SLIDER* aTuner );
/**
* Safely update a field of the associated symbol without dereferencing
* the symbol.
*
* @param aSymbol id of the symbol needing updating
* @param aId id of the symbol field
* @param aValue new value of the symbol field
*/
void UpdateTunerValue( const SCH_SHEET_PATH& aSheetPath, const KIID& aSymbol,
const wxString& aRef, const wxString& aValue );
/**
* Add a measurement to the measurements grid.
*/
void AddMeasurement( const wxString& aCmd );
/**
* Delete a row from the measurements grid.
*/
void DeleteMeasurement( int aRow );
/**
* Get/Set the format of a value in the measurements grid.
*/
SPICE_VALUE_FORMAT GetMeasureFormat( int aRow ) const;
void SetMeasureFormat( int aRow, const SPICE_VALUE_FORMAT& aFormat );
/**
* Update a measurement in the measurements grid.
*/
void UpdateMeasurement( int aRow );
/** /**
* Return the current tab (or NULL if there is none). * Return the current tab (or NULL if there is none).
*/ */
SIM_PLOT_PANEL* GetCurrentPlot() const; SIM_PLOT_PANEL* GetCurrentPlot() const;
/**
* Return the netlist exporter object used for simulations.
*/
const NGSPICE_CIRCUIT_MODEL* GetExporter() const;
/** /**
* Toggle dark-mode of the plot tabs. * Toggle dark-mode of the plot tabs.
*/ */
@ -224,25 +157,20 @@ public:
std::shared_ptr<SPICE_SIMULATOR> GetSimulator() const { return m_simulator; } std::shared_ptr<SPICE_SIMULATOR> GetSimulator() const { return m_simulator; }
wxString GetCurrentSimCommand() const wxString GetCurrentSimCommand() const;
{ SIM_TYPE GetCurrentSimType() const;
if( getCurrentPlotWindow() ) int GetCurrentOptions() const;
return getCurrentPlotWindow()->GetSimCommand();
else
return m_circuitModel->GetSchTextSimCommand();
}
int GetCurrentOptions() const bool SimFinished() const { return m_simFinished; }
{
if( getCurrentPlotWindow() )
return getCurrentPlotWindow()->GetSimOptions();
else
return m_circuitModel->GetSimOptions();
}
// Simulator doesn't host a canvas // Simulator doesn't host a canvas
wxWindow* GetToolCanvas() const override { return nullptr; } wxWindow* GetToolCanvas() const override { return nullptr; }
/**
* Set the main window title bar text.
*/
void UpdateTitle();
void OnModify() override; void OnModify() override;
DECLARE_EVENT_TABLE() DECLARE_EVENT_TABLE()
@ -253,107 +181,9 @@ private:
void setupUIConditions() override; void setupUIConditions() override;
/**
* Load the currently active workbook stored in the project settings. If there is none,
* generate a filename for the currently active workbook and store it in the project settings.
*/
void initWorkbook();
/**
* Set the main window title bar text.
*/
void updateTitle();
/**
* Add a new trace to the current plot.
*
* @param aName is the device/net name.
* @param aType describes the type of trace.
*/
void doAddTrace( const wxString& aName, SIM_TRACE_TYPE aType );
/**
* Get the simulator output vector name for a given signal name and type.
*/
wxString vectorNameFromSignalName( const wxString& aSignalName, int* aTraceType );
/**
* Update a trace in a particular SIM_PLOT_PANEL. If the panel does not contain the given
* trace, then add it.
*
* @param aVectorName is the SPICE vector name, such as "I(Net-C1-Pad1)".
* @param aTraceType describes the type of plot.
* @param aPlotPanel is the panel that should receive the update.
*/
void updateTrace( const wxString& aVectorName, int aTraceType, SIM_PLOT_PANEL* aPlotPanel );
/**
* Rebuild the list of signals available from the netlist.
*
* Note: this is not the filtered list. See rebuildSignalsGrid() for that.
*/
void rebuildSignalsList();
/**
* Rebuild the filtered list of signals in the signals grid.
*/
void rebuildSignalsGrid( wxString aFilter );
/**
* Update the values in the signals grid.
*/
void updateSignalsGrid();
/**
* Update the cursor values (in the grid) and graphics (in the plot window).
*/
void updateCursors();
/**
* Apply user-defined signals to the SPICE session.
*/
void applyUserDefinedSignals();
/**
* Apply component values specified using tuner sliders to the current netlist.
*/
void applyTuners();
/**
* Return the currently opened plot panel (or NULL if there is none).
*/
SIM_PLOT_PANEL_BASE* getCurrentPlotWindow() const
{
return dynamic_cast<SIM_PLOT_PANEL_BASE*>( m_plotNotebook->GetCurrentPage() );
}
/**
* Return X axis for a given simulation type.
*/
SIM_TRACE_TYPE getXAxisType( SIM_TYPE aType ) const;
void parseTraceParams( SIM_PLOT_PANEL* aPlotPanel, TRACE* aTrace, const wxString& aSignalName,
const wxString& aParams );
// Event handlers
void onPlotClose( wxAuiNotebookEvent& event ) override;
void onPlotClosed( wxAuiNotebookEvent& event ) override;
void onPlotChanged( wxAuiNotebookEvent& event ) override;
void onPlotDragged( wxAuiNotebookEvent& event ) override;
void OnFilterText( wxCommandEvent& aEvent ) override;
void OnFilterMouseMoved( wxMouseEvent& aEvent ) override;
void onSignalsGridCellChanged( wxGridEvent& aEvent ) override;
void onCursorsGridCellChanged( wxGridEvent& aEvent ) override;
void onMeasurementsGridCellChanged( wxGridEvent& aEvent ) override;
void onNotebookModified( wxCommandEvent& event );
bool canCloseWindow( wxCloseEvent& aEvent ) override; bool canCloseWindow( wxCloseEvent& aEvent ) override;
void doCloseWindow() override; void doCloseWindow() override;
void onCursorUpdate( wxCommandEvent& aEvent );
void onSimUpdate( wxCommandEvent& aEvent ); void onSimUpdate( wxCommandEvent& aEvent );
void onSimReport( wxCommandEvent& aEvent ); void onSimReport( wxCommandEvent& aEvent );
void onSimStarted( wxCommandEvent& aEvent ); void onSimStarted( wxCommandEvent& aEvent );
@ -361,43 +191,16 @@ private:
void onExit( wxCommandEvent& event ); void onExit( wxCommandEvent& event );
// adjust the sash dimension of splitter windows after reading
// the config settings
// must be called after the config settings are read, and once the
// frame is initialized (end of the Ctor)
void setSubWindowsSashSize();
public:
int m_SuppressGridEvents;
private: private:
SCH_EDIT_FRAME* m_schematicFrame; SCH_EDIT_FRAME* m_schematicFrame;
std::shared_ptr<NGSPICE_CIRCUIT_MODEL> m_circuitModel; ACTION_TOOLBAR* m_toolBar;
SIMULATOR_PANEL* m_panel;
std::shared_ptr<SPICE_SIMULATOR> m_simulator; std::shared_ptr<SPICE_SIMULATOR> m_simulator;
SIM_THREAD_REPORTER* m_reporter; SIM_THREAD_REPORTER* m_reporter;
std::shared_ptr<NGSPICE_CIRCUIT_MODEL> m_circuitModel;
std::vector<wxString> m_signals;
std::map<int, wxString> m_userDefinedSignals;
std::list<TUNER_SLIDER*> m_tuners;
///< SPICE expressions need quoted versions of the netnames since KiCad allows '-' and '/'
///< in netnames.
std::map<wxString, wxString> m_quotedNetnames;
///< Panel that was used as the most recent one for simulations
SIM_PLOT_PANEL_BASE* m_lastSimPlot; SIM_PLOT_PANEL_BASE* m_lastSimPlot;
SPICE_VALUE_FORMAT m_cursorFormats[3][2];
// Variables for temporary storage:
int m_splitterLeftRightSashPosition;
int m_splitterPlotAndConsoleSashPosition;
int m_splitterSignalsSashPosition;
int m_splitterCursorsSashPosition;
int m_splitterTuneValuesSashPosition;
bool m_darkMode;
unsigned int m_plotNumber;
bool m_simFinished; bool m_simFinished;
bool m_workbookModified; bool m_workbookModified;
}; };

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,336 @@
/*
* This program source code file is part of KiCad, a free EDA CAD application.
*
* Copyright (C) 2016-2023 CERN
* Copyright (C) 2017-2023 KiCad Developers, see AUTHORS.txt for contributors.
*
* @author Tomasz Wlostowski <tomasz.wlostowski@cern.ch>
* @author Maciej Suminski <maciej.suminski@cern.ch>
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 3
* of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, you may find one here:
* https://www.gnu.org/licenses/gpl-3.0.html
* or you may search the http://www.gnu.org website for the version 3 license,
* or you may write to the Free Software Foundation, Inc.,
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
*/
#ifndef SIMULATOR_PANEL_H
#define SIMULATOR_PANEL_H
#include <sim/simulator_panel_base.h>
#include <sim/sim_types.h>
#include <kiway_player.h>
#include <dialogs/dialog_sim_command.h>
#include <wx/event.h>
#include <list>
#include <memory>
#include <map>
class SCH_EDIT_FRAME;
class SCH_SYMBOL;
class SPICE_SIMULATOR;
class SPICE_SIMULATOR_SETTINGS;
class EESCHEMA_SETTINGS;
class NGSPICE_CIRCUIT_MODEL;
#include <sim/sim_plot_panel.h>
#include <sim/sim_plot_panel_base.h>
#include "widgets/sim_notebook.h"
class SIM_THREAD_REPORTER;
class TUNER_SLIDER;
/**
*
* The SIMULATOR_PANEL holds the main user-interface for running simulations.
*
* It contains a workbook with multiple tabs, each tab holding a SIM_PLOT_PANEL, a specific
* simulation command (.TRAN, .AC, etc.), and simulation settings (save all currents, etc.).
*
* Each plot can have multiple TRACEs. While internally each TRACE can have multiple cursors,
* the GUI supports only two cursors (and a differential cursor) for each plot.
*
* TRACEs are identified by a signal (V(OUT), I(R2), etc.) and a type (SPT_VOLTAGE, SPT_AC_PHASE,
* etc.).
*
* The simulator outputs simple signals in a vector of the same name. Complex signals (such as
* V(OUT) / V(IN)) are stored in vectors of the format "user%d".
*
*/
class SIMULATOR_PANEL : public SIMULATOR_PANEL_BASE
{
public:
SIMULATOR_PANEL( SIMULATOR_FRAME* aSimulatorFrame, SCH_EDIT_FRAME* aSchematicFrame );
~SIMULATOR_PANEL();
/**
* Create a new plot tab for a given simulation type.
*
* @param aSimCommand is requested simulation command.
* @param aSimOptions netlisting options
* @return The new plot panel.
*/
SIM_PLOT_PANEL_BASE* NewPlotPanel( const wxString& aSimCommand, int aSimOptions );
const std::vector<wxString>& Signals() { return m_signals; }
const std::map<int, wxString>& UserDefinedSignals() { return m_userDefinedSignals; }
void SetUserDefinedSignals( const std::map<int, wxString>& aSignals );
/**
* Add a new trace to the current plot.
*
* @param aName is the device/net name.
* @param aType describes the type of trace.
*/
void AddTrace( const wxString& aName, SIM_TRACE_TYPE aType );
/**
* Get/Set the number of significant digits and the range for formatting a cursor value.
* @param aValueCol 0 indicates the X value column; 1 the Y value.
*/
SPICE_VALUE_FORMAT GetCursorFormat( int aCursorId, int aValueCol ) const
{
return m_cursorFormats[ aCursorId ][ aValueCol ];
}
void SetCursorFormat( int aCursorId, int aValueCol, const SPICE_VALUE_FORMAT& aFormat )
{
m_cursorFormats[ aCursorId ][ aValueCol ] = aFormat;
wxCommandEvent dummy;
onPlotCursorUpdate( dummy );
}
/**
* Add a tuner for a symbol.
*/
void AddTuner( const SCH_SHEET_PATH& aSheetPath, SCH_SYMBOL* aSymbol );
/**
* Remove an existing tuner.
*/
void RemoveTuner( TUNER_SLIDER* aTuner );
/**
* Safely update a field of the associated symbol without dereferencing
* the symbol.
*
* @param aSymbol id of the symbol needing updating
* @param aId id of the symbol field
* @param aValue new value of the symbol field
*/
void UpdateTunerValue( const SCH_SHEET_PATH& aSheetPath, const KIID& aSymbol,
const wxString& aRef, const wxString& aValue );
/**
* Add a measurement to the measurements grid.
*/
void AddMeasurement( const wxString& aCmd );
/**
* Delete a row from the measurements grid.
*/
void DeleteMeasurement( int aRow );
/**
* Get/Set the format of a value in the measurements grid.
*/
SPICE_VALUE_FORMAT GetMeasureFormat( int aRow ) const;
void SetMeasureFormat( int aRow, const SPICE_VALUE_FORMAT& aFormat );
/**
* Update a measurement in the measurements grid.
*/
void UpdateMeasurement( int aRow );
/**
* Return the netlist exporter object used for simulations.
*/
const NGSPICE_CIRCUIT_MODEL* GetExporter() const;
bool DarkModePlots() const { return m_darkMode; }
void ToggleDarkModePlots();
void ShowChangedLanguage();
/**
* Load the currently active workbook stored in the project settings. If there is none,
* generate a filename for the currently active workbook and store it in the project settings.
*/
void InitWorkbook();
/**
* Load plot, signal, cursor, measurement, etc. settings from a file.
*/
bool LoadWorkbook( const wxString& aPath );
/**
* Save plot, signal, cursor, measurement, etc. settings to a file.
*/
bool SaveWorkbook( const wxString& aPath );
void LoadSettings( EESCHEMA_SETTINGS* aCfg );
void SaveSettings( EESCHEMA_SETTINGS* aCfg );
// adjust the sash dimension of splitter windows after reading
// the config settings
// must be called after the config settings are read, and once the
// frame is initialized (end of the Ctor)
void SetSubWindowsSashSize();
/**
* Return the currently opened plot panel (or NULL if there is none).
*/
SIM_PLOT_PANEL_BASE* GetCurrentPlotWindow() const
{
return dynamic_cast<SIM_PLOT_PANEL_BASE*>( m_plotNotebook->GetCurrentPage() );
}
/**
* Return the current tab (or NULL if there is none).
*/
SIM_PLOT_PANEL* GetCurrentPlot() const
{
SIM_PLOT_PANEL_BASE* plotWindow = GetCurrentPlotWindow();
if( !plotWindow )
return nullptr;
return plotWindow->GetType() == ST_UNKNOWN ? nullptr
: dynamic_cast<SIM_PLOT_PANEL*>( plotWindow );
}
int GetPlotIndex( SIM_PLOT_PANEL_BASE* aPlot ) const
{
return m_plotNotebook->GetPageIndex( aPlot );
}
void OnSimUpdate();
void OnSimReport( const wxString& aMsg );
void OnSimFinished();
private:
/**
* Get the simulator output vector name for a given signal name and type.
*/
wxString vectorNameFromSignalName( const wxString& aSignalName, int* aTraceType );
/**
* Update a trace in a particular SIM_PLOT_PANEL. If the panel does not contain the given
* trace, then add it.
*
* @param aVectorName is the SPICE vector name, such as "I(Net-C1-Pad1)".
* @param aTraceType describes the type of plot.
* @param aPlotPanel is the panel that should receive the update.
*/
void updateTrace( const wxString& aVectorName, int aTraceType, SIM_PLOT_PANEL* aPlotPanel );
/**
* Rebuild the list of signals available from the netlist.
*
* Note: this is not the filtered list. See rebuildSignalsGrid() for that.
*/
void rebuildSignalsList();
/**
* Rebuild the filtered list of signals in the signals grid.
*/
void rebuildSignalsGrid( wxString aFilter );
/**
* Update the values in the signals grid.
*/
void updateSignalsGrid();
/**
* Update the cursor values (in the grid) and graphics (in the plot window).
*/
void updatePlotCursors();
/**
* Apply user-defined signals to the SPICE session.
*/
void applyUserDefinedSignals();
/**
* Apply component values specified using tuner sliders to the current netlist.
*/
void applyTuners();
/**
* Return X axis for a given simulation type.
*/
SIM_TRACE_TYPE getXAxisType( SIM_TYPE aType ) const;
void parseTraceParams( SIM_PLOT_PANEL* aPlotPanel, TRACE* aTrace, const wxString& aSignalName,
const wxString& aParams );
std::shared_ptr<SPICE_SIMULATOR> simulator() const;
std::shared_ptr<NGSPICE_CIRCUIT_MODEL> circuitModel() const;
// Event handlers
void onPlotClose( wxAuiNotebookEvent& event ) override;
void onPlotClosed( wxAuiNotebookEvent& event ) override;
void onPlotChanged( wxAuiNotebookEvent& event ) override;
void onPlotDragged( wxAuiNotebookEvent& event ) override;
void OnFilterText( wxCommandEvent& aEvent ) override;
void OnFilterMouseMoved( wxMouseEvent& aEvent ) override;
void onSignalsGridCellChanged( wxGridEvent& aEvent ) override;
void onCursorsGridCellChanged( wxGridEvent& aEvent ) override;
void onMeasurementsGridCellChanged( wxGridEvent& aEvent ) override;
void onNotebookModified( wxCommandEvent& event );
void onPlotCursorUpdate( wxCommandEvent& aEvent );
public:
int m_SuppressGridEvents;
private:
SIMULATOR_FRAME* m_simulatorFrame;
SCH_EDIT_FRAME* m_schematicFrame;
std::vector<wxString> m_signals;
std::map<int, wxString> m_userDefinedSignals;
std::list<TUNER_SLIDER*> m_tuners;
///< SPICE expressions need quoted versions of the netnames since KiCad allows '-' and '/'
///< in netnames.
std::map<wxString, wxString> m_quotedNetnames;
SPICE_VALUE_FORMAT m_cursorFormats[3][2];
// Variables for temporary storage:
int m_splitterLeftRightSashPosition;
int m_splitterPlotAndConsoleSashPosition;
int m_splitterSignalsSashPosition;
int m_splitterCursorsSashPosition;
int m_splitterTuneValuesSashPosition;
bool m_darkMode;
unsigned int m_plotNumber;
};
#endif // SIMULATOR_PANEL_H

View File

@ -5,27 +5,20 @@
// PLEASE DO *NOT* EDIT THIS FILE! // PLEASE DO *NOT* EDIT THIS FILE!
/////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////
#include "tool/action_toolbar.h"
#include "widgets/wx_grid.h" #include "widgets/wx_grid.h"
#include "simulator_frame_base.h" #include "simulator_panel_base.h"
/////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////
SIMULATOR_FRAME_BASE::SIMULATOR_FRAME_BASE( wxWindow* parent, wxWindowID id, const wxString& title, const wxPoint& pos, const wxSize& size, long style, const wxString& name ) : KIWAY_PLAYER( parent, id, title, pos, size, style, name ) SIMULATOR_PANEL_BASE::SIMULATOR_PANEL_BASE( wxWindow* parent, wxWindowID id, const wxPoint& pos, const wxSize& size, long style, const wxString& name ) : wxPanel( parent, id, pos, size, style, name )
{ {
this->SetSizeHints( wxSize( -1,-1 ), wxDefaultSize ); wxBoxSizer* sizerMain;
sizerMain = new wxBoxSizer( wxVERTICAL );
m_sizerMain = new wxBoxSizer( wxVERTICAL );
m_toolBar = new ACTION_TOOLBAR( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxAUI_TB_DEFAULT_STYLE|wxAUI_TB_HORZ_LAYOUT|wxAUI_TB_PLAIN_BACKGROUND );
m_toolBar->Realize();
m_sizerMain->Add( m_toolBar, 0, wxEXPAND, 5 );
m_splitterLeftRight = new wxSplitterWindow( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxSP_3DSASH|wxSP_LIVE_UPDATE|wxBORDER_NONE ); m_splitterLeftRight = new wxSplitterWindow( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxSP_3DSASH|wxSP_LIVE_UPDATE|wxBORDER_NONE );
m_splitterLeftRight->SetSashGravity( 0.7 ); m_splitterLeftRight->SetSashGravity( 0.7 );
m_splitterLeftRight->Connect( wxEVT_IDLE, wxIdleEventHandler( SIMULATOR_FRAME_BASE::m_splitterLeftRightOnIdle ), NULL, this ); m_splitterLeftRight->Connect( wxEVT_IDLE, wxIdleEventHandler( SIMULATOR_PANEL_BASE::m_splitterLeftRightOnIdle ), NULL, this );
m_splitterLeftRight->SetMinimumPaneSize( 50 ); m_splitterLeftRight->SetMinimumPaneSize( 50 );
m_panelLeft = new wxPanel( m_splitterLeftRight, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL ); m_panelLeft = new wxPanel( m_splitterLeftRight, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL );
@ -35,7 +28,7 @@ SIMULATOR_FRAME_BASE::SIMULATOR_FRAME_BASE( wxWindow* parent, wxWindowID id, con
m_splitterPlotAndConsole = new wxSplitterWindow( m_panelLeft, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxSP_3DSASH|wxSP_LIVE_UPDATE ); m_splitterPlotAndConsole = new wxSplitterWindow( m_panelLeft, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxSP_3DSASH|wxSP_LIVE_UPDATE );
m_splitterPlotAndConsole->SetSashGravity( 0.8 ); m_splitterPlotAndConsole->SetSashGravity( 0.8 );
m_splitterPlotAndConsole->Connect( wxEVT_IDLE, wxIdleEventHandler( SIMULATOR_FRAME_BASE::m_splitterPlotAndConsoleOnIdle ), NULL, this ); m_splitterPlotAndConsole->Connect( wxEVT_IDLE, wxIdleEventHandler( SIMULATOR_PANEL_BASE::m_splitterPlotAndConsoleOnIdle ), NULL, this );
m_splitterPlotAndConsole->SetMinimumPaneSize( 50 ); m_splitterPlotAndConsole->SetMinimumPaneSize( 50 );
m_plotPanel = new wxPanel( m_splitterPlotAndConsole, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL ); m_plotPanel = new wxPanel( m_splitterPlotAndConsole, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL );
@ -82,7 +75,7 @@ SIMULATOR_FRAME_BASE::SIMULATOR_FRAME_BASE( wxWindow* parent, wxWindowID id, con
m_splitterSignals = new wxSplitterWindow( m_sidePanel, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxSP_3DSASH|wxSP_LIVE_UPDATE ); m_splitterSignals = new wxSplitterWindow( m_sidePanel, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxSP_3DSASH|wxSP_LIVE_UPDATE );
m_splitterSignals->SetSashGravity( 0.5 ); m_splitterSignals->SetSashGravity( 0.5 );
m_splitterSignals->Connect( wxEVT_IDLE, wxIdleEventHandler( SIMULATOR_FRAME_BASE::m_splitterSignalsOnIdle ), NULL, this ); m_splitterSignals->Connect( wxEVT_IDLE, wxIdleEventHandler( SIMULATOR_PANEL_BASE::m_splitterSignalsOnIdle ), NULL, this );
m_splitterSignals->SetMinimumPaneSize( 20 ); m_splitterSignals->SetMinimumPaneSize( 20 );
m_panelSignals = new wxPanel( m_splitterSignals, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL ); m_panelSignals = new wxPanel( m_splitterSignals, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL );
@ -146,7 +139,7 @@ SIMULATOR_FRAME_BASE::SIMULATOR_FRAME_BASE( wxWindow* parent, wxWindowID id, con
m_splitterCursors = new wxSplitterWindow( m_panelCMT, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxSP_3DSASH|wxSP_LIVE_UPDATE|wxBORDER_NONE ); m_splitterCursors = new wxSplitterWindow( m_panelCMT, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxSP_3DSASH|wxSP_LIVE_UPDATE|wxBORDER_NONE );
m_splitterCursors->SetSashGravity( 0.2 ); m_splitterCursors->SetSashGravity( 0.2 );
m_splitterCursors->Connect( wxEVT_IDLE, wxIdleEventHandler( SIMULATOR_FRAME_BASE::m_splitterCursorsOnIdle ), NULL, this ); m_splitterCursors->Connect( wxEVT_IDLE, wxIdleEventHandler( SIMULATOR_PANEL_BASE::m_splitterCursorsOnIdle ), NULL, this );
m_splitterCursors->SetMinimumPaneSize( 20 ); m_splitterCursors->SetMinimumPaneSize( 20 );
m_panelCursors = new wxPanel( m_splitterCursors, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL ); m_panelCursors = new wxPanel( m_splitterCursors, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL );
@ -201,7 +194,7 @@ SIMULATOR_FRAME_BASE::SIMULATOR_FRAME_BASE( wxWindow* parent, wxWindowID id, con
m_splitterMeasurements = new wxSplitterWindow( m_panelMT, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxSP_3DSASH|wxSP_LIVE_UPDATE|wxBORDER_NONE ); m_splitterMeasurements = new wxSplitterWindow( m_panelMT, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxSP_3DSASH|wxSP_LIVE_UPDATE|wxBORDER_NONE );
m_splitterMeasurements->SetSashGravity( 0.2 ); m_splitterMeasurements->SetSashGravity( 0.2 );
m_splitterMeasurements->Connect( wxEVT_IDLE, wxIdleEventHandler( SIMULATOR_FRAME_BASE::m_splitterMeasurementsOnIdle ), NULL, this ); m_splitterMeasurements->Connect( wxEVT_IDLE, wxIdleEventHandler( SIMULATOR_PANEL_BASE::m_splitterMeasurementsOnIdle ), NULL, this );
m_splitterMeasurements->SetMinimumPaneSize( 20 ); m_splitterMeasurements->SetMinimumPaneSize( 20 );
m_panelMeasurements = new wxPanel( m_splitterMeasurements, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL ); m_panelMeasurements = new wxPanel( m_splitterMeasurements, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL );
@ -277,38 +270,36 @@ SIMULATOR_FRAME_BASE::SIMULATOR_FRAME_BASE( wxWindow* parent, wxWindowID id, con
m_sidePanel->Layout(); m_sidePanel->Layout();
m_sideSizer->Fit( m_sidePanel ); m_sideSizer->Fit( m_sidePanel );
m_splitterLeftRight->SplitVertically( m_panelLeft, m_sidePanel, 700 ); m_splitterLeftRight->SplitVertically( m_panelLeft, m_sidePanel, 700 );
m_sizerMain->Add( m_splitterLeftRight, 1, wxEXPAND, 5 ); sizerMain->Add( m_splitterLeftRight, 1, wxEXPAND, 5 );
this->SetSizer( m_sizerMain ); this->SetSizer( sizerMain );
this->Layout(); this->Layout();
m_sizerMain->Fit( this ); sizerMain->Fit( this );
this->Centre( wxBOTH );
// Connect Events // Connect Events
m_plotNotebook->Connect( wxEVT_COMMAND_AUINOTEBOOK_END_DRAG, wxAuiNotebookEventHandler( SIMULATOR_FRAME_BASE::onPlotDragged ), NULL, this ); m_plotNotebook->Connect( wxEVT_COMMAND_AUINOTEBOOK_END_DRAG, wxAuiNotebookEventHandler( SIMULATOR_PANEL_BASE::onPlotDragged ), NULL, this );
m_plotNotebook->Connect( wxEVT_COMMAND_AUINOTEBOOK_PAGE_CHANGED, wxAuiNotebookEventHandler( SIMULATOR_FRAME_BASE::onPlotChanged ), NULL, this ); m_plotNotebook->Connect( wxEVT_COMMAND_AUINOTEBOOK_PAGE_CHANGED, wxAuiNotebookEventHandler( SIMULATOR_PANEL_BASE::onPlotChanged ), NULL, this );
m_plotNotebook->Connect( wxEVT_COMMAND_AUINOTEBOOK_PAGE_CLOSE, wxAuiNotebookEventHandler( SIMULATOR_FRAME_BASE::onPlotClose ), NULL, this ); m_plotNotebook->Connect( wxEVT_COMMAND_AUINOTEBOOK_PAGE_CLOSE, wxAuiNotebookEventHandler( SIMULATOR_PANEL_BASE::onPlotClose ), NULL, this );
m_plotNotebook->Connect( wxEVT_COMMAND_AUINOTEBOOK_PAGE_CLOSED, wxAuiNotebookEventHandler( SIMULATOR_FRAME_BASE::onPlotClosed ), NULL, this ); m_plotNotebook->Connect( wxEVT_COMMAND_AUINOTEBOOK_PAGE_CLOSED, wxAuiNotebookEventHandler( SIMULATOR_PANEL_BASE::onPlotClosed ), NULL, this );
m_filter->Connect( wxEVT_MOTION, wxMouseEventHandler( SIMULATOR_FRAME_BASE::OnFilterMouseMoved ), NULL, this ); m_filter->Connect( wxEVT_MOTION, wxMouseEventHandler( SIMULATOR_PANEL_BASE::OnFilterMouseMoved ), NULL, this );
m_filter->Connect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( SIMULATOR_FRAME_BASE::OnFilterText ), NULL, this ); m_filter->Connect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( SIMULATOR_PANEL_BASE::OnFilterText ), NULL, this );
m_signalsGrid->Connect( wxEVT_GRID_CELL_CHANGED, wxGridEventHandler( SIMULATOR_FRAME_BASE::onSignalsGridCellChanged ), NULL, this ); m_signalsGrid->Connect( wxEVT_GRID_CELL_CHANGED, wxGridEventHandler( SIMULATOR_PANEL_BASE::onSignalsGridCellChanged ), NULL, this );
m_cursorsGrid->Connect( wxEVT_GRID_CELL_CHANGED, wxGridEventHandler( SIMULATOR_FRAME_BASE::onCursorsGridCellChanged ), NULL, this ); m_cursorsGrid->Connect( wxEVT_GRID_CELL_CHANGED, wxGridEventHandler( SIMULATOR_PANEL_BASE::onCursorsGridCellChanged ), NULL, this );
m_measurementsGrid->Connect( wxEVT_GRID_CELL_CHANGED, wxGridEventHandler( SIMULATOR_FRAME_BASE::onMeasurementsGridCellChanged ), NULL, this ); m_measurementsGrid->Connect( wxEVT_GRID_CELL_CHANGED, wxGridEventHandler( SIMULATOR_PANEL_BASE::onMeasurementsGridCellChanged ), NULL, this );
} }
SIMULATOR_FRAME_BASE::~SIMULATOR_FRAME_BASE() SIMULATOR_PANEL_BASE::~SIMULATOR_PANEL_BASE()
{ {
// Disconnect Events // Disconnect Events
m_plotNotebook->Disconnect( wxEVT_COMMAND_AUINOTEBOOK_END_DRAG, wxAuiNotebookEventHandler( SIMULATOR_FRAME_BASE::onPlotDragged ), NULL, this ); m_plotNotebook->Disconnect( wxEVT_COMMAND_AUINOTEBOOK_END_DRAG, wxAuiNotebookEventHandler( SIMULATOR_PANEL_BASE::onPlotDragged ), NULL, this );
m_plotNotebook->Disconnect( wxEVT_COMMAND_AUINOTEBOOK_PAGE_CHANGED, wxAuiNotebookEventHandler( SIMULATOR_FRAME_BASE::onPlotChanged ), NULL, this ); m_plotNotebook->Disconnect( wxEVT_COMMAND_AUINOTEBOOK_PAGE_CHANGED, wxAuiNotebookEventHandler( SIMULATOR_PANEL_BASE::onPlotChanged ), NULL, this );
m_plotNotebook->Disconnect( wxEVT_COMMAND_AUINOTEBOOK_PAGE_CLOSE, wxAuiNotebookEventHandler( SIMULATOR_FRAME_BASE::onPlotClose ), NULL, this ); m_plotNotebook->Disconnect( wxEVT_COMMAND_AUINOTEBOOK_PAGE_CLOSE, wxAuiNotebookEventHandler( SIMULATOR_PANEL_BASE::onPlotClose ), NULL, this );
m_plotNotebook->Disconnect( wxEVT_COMMAND_AUINOTEBOOK_PAGE_CLOSED, wxAuiNotebookEventHandler( SIMULATOR_FRAME_BASE::onPlotClosed ), NULL, this ); m_plotNotebook->Disconnect( wxEVT_COMMAND_AUINOTEBOOK_PAGE_CLOSED, wxAuiNotebookEventHandler( SIMULATOR_PANEL_BASE::onPlotClosed ), NULL, this );
m_filter->Disconnect( wxEVT_MOTION, wxMouseEventHandler( SIMULATOR_FRAME_BASE::OnFilterMouseMoved ), NULL, this ); m_filter->Disconnect( wxEVT_MOTION, wxMouseEventHandler( SIMULATOR_PANEL_BASE::OnFilterMouseMoved ), NULL, this );
m_filter->Disconnect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( SIMULATOR_FRAME_BASE::OnFilterText ), NULL, this ); m_filter->Disconnect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( SIMULATOR_PANEL_BASE::OnFilterText ), NULL, this );
m_signalsGrid->Disconnect( wxEVT_GRID_CELL_CHANGED, wxGridEventHandler( SIMULATOR_FRAME_BASE::onSignalsGridCellChanged ), NULL, this ); m_signalsGrid->Disconnect( wxEVT_GRID_CELL_CHANGED, wxGridEventHandler( SIMULATOR_PANEL_BASE::onSignalsGridCellChanged ), NULL, this );
m_cursorsGrid->Disconnect( wxEVT_GRID_CELL_CHANGED, wxGridEventHandler( SIMULATOR_FRAME_BASE::onCursorsGridCellChanged ), NULL, this ); m_cursorsGrid->Disconnect( wxEVT_GRID_CELL_CHANGED, wxGridEventHandler( SIMULATOR_PANEL_BASE::onCursorsGridCellChanged ), NULL, this );
m_measurementsGrid->Disconnect( wxEVT_GRID_CELL_CHANGED, wxGridEventHandler( SIMULATOR_FRAME_BASE::onMeasurementsGridCellChanged ), NULL, this ); m_measurementsGrid->Disconnect( wxEVT_GRID_CELL_CHANGED, wxGridEventHandler( SIMULATOR_PANEL_BASE::onMeasurementsGridCellChanged ), NULL, this );
} }

View File

@ -11,13 +11,13 @@
<property name="embedded_files_path">.</property> <property name="embedded_files_path">.</property>
<property name="encoding">UTF-8</property> <property name="encoding">UTF-8</property>
<property name="event_generation">connect</property> <property name="event_generation">connect</property>
<property name="file">simulator_frame_base</property> <property name="file">simulator_panel_base</property>
<property name="first_id">1000</property> <property name="first_id">1000</property>
<property name="help_provider">none</property> <property name="help_provider">none</property>
<property name="image_path_wrapper_function_name"></property> <property name="image_path_wrapper_function_name"></property>
<property name="indent_with_spaces"></property> <property name="indent_with_spaces"></property>
<property name="internationalize">1</property> <property name="internationalize">1</property>
<property name="name">SIMULATOR_FRAME_BASE</property> <property name="name">SIMULATOR_PANEL_BASE</property>
<property name="namespace"></property> <property name="namespace"></property>
<property name="path">.</property> <property name="path">.</property>
<property name="precompiled_header"></property> <property name="precompiled_header"></property>
@ -29,104 +29,34 @@
<property name="use_array_enum">0</property> <property name="use_array_enum">0</property>
<property name="use_enum">0</property> <property name="use_enum">0</property>
<property name="use_microsoft_bom">0</property> <property name="use_microsoft_bom">0</property>
<object class="Frame" expanded="1"> <object class="Panel" expanded="1">
<property name="aui_managed">0</property> <property name="aui_managed">0</property>
<property name="aui_manager_style">wxAUI_MGR_DEFAULT</property> <property name="aui_manager_style">wxAUI_MGR_DEFAULT</property>
<property name="bg"></property> <property name="bg"></property>
<property name="center">wxBOTH</property>
<property name="context_help"></property> <property name="context_help"></property>
<property name="context_menu">1</property> <property name="context_menu">1</property>
<property name="enabled">1</property> <property name="enabled">1</property>
<property name="event_handler">impl_virtual</property> <property name="event_handler">impl_virtual</property>
<property name="extra_style"></property>
<property name="fg"></property> <property name="fg"></property>
<property name="font"></property> <property name="font"></property>
<property name="hidden">0</property> <property name="hidden">0</property>
<property name="id">wxID_ANY</property> <property name="id">wxID_ANY</property>
<property name="maximum_size"></property> <property name="maximum_size"></property>
<property name="minimum_size">-1,-1</property> <property name="minimum_size"></property>
<property name="name">SIMULATOR_FRAME_BASE</property> <property name="name">SIMULATOR_PANEL_BASE</property>
<property name="pos"></property> <property name="pos"></property>
<property name="size">-1,-1</property> <property name="size">-1,-1</property>
<property name="style">wxDEFAULT_FRAME_STYLE</property> <property name="subclass">; ; forward_declare</property>
<property name="subclass">KIWAY_PLAYER; kiway_player.h</property>
<property name="title">Spice Simulator</property>
<property name="tooltip"></property> <property name="tooltip"></property>
<property name="two_step_creation">0</property> <property name="two_step_creation">0</property>
<property name="window_extra_style"></property> <property name="window_extra_style"></property>
<property name="window_name">SIM_PLOT_FRAME</property> <property name="window_name"></property>
<property name="window_style">wxTAB_TRAVERSAL</property> <property name="window_style">wxTAB_TRAVERSAL</property>
<property name="xrc_skip_sizer">1</property>
<object class="wxBoxSizer" expanded="1"> <object class="wxBoxSizer" expanded="1">
<property name="minimum_size"></property> <property name="minimum_size"></property>
<property name="name">m_sizerMain</property> <property name="name">sizerMain</property>
<property name="orient">wxVERTICAL</property> <property name="orient">wxVERTICAL</property>
<property name="permission">protected</property> <property name="permission">none</property>
<object class="sizeritem" expanded="1">
<property name="border">5</property>
<property name="flag">wxEXPAND</property>
<property name="proportion">0</property>
<object class="wxAuiToolBar" expanded="1">
<property name="BottomDockable">1</property>
<property name="LeftDockable">1</property>
<property name="RightDockable">1</property>
<property name="TopDockable">1</property>
<property name="aui_layer"></property>
<property name="aui_name"></property>
<property name="aui_position"></property>
<property name="aui_row"></property>
<property name="best_size"></property>
<property name="bg"></property>
<property name="bitmapsize"></property>
<property name="caption"></property>
<property name="caption_visible">1</property>
<property name="center_pane">0</property>
<property name="close_button">1</property>
<property name="context_help"></property>
<property name="context_menu">1</property>
<property name="default_pane">0</property>
<property name="dock">Dock</property>
<property name="dock_fixed">0</property>
<property name="docking">Left</property>
<property name="enabled">1</property>
<property name="fg"></property>
<property name="floatable">1</property>
<property name="font"></property>
<property name="gripper">0</property>
<property name="hidden">0</property>
<property name="id">wxID_ANY</property>
<property name="label_visible">0</property>
<property name="margins"></property>
<property name="max_size"></property>
<property name="maximize_button">0</property>
<property name="maximum_size"></property>
<property name="min_size"></property>
<property name="minimize_button">0</property>
<property name="minimum_size"></property>
<property name="moveable">1</property>
<property name="name">m_toolBar</property>
<property name="packing">1</property>
<property name="pane_border">1</property>
<property name="pane_position"></property>
<property name="pane_size"></property>
<property name="permission">protected</property>
<property name="pin_button">1</property>
<property name="pos"></property>
<property name="resize">Resizable</property>
<property name="separation">5</property>
<property name="show">1</property>
<property name="size"></property>
<property name="style">wxAUI_TB_DEFAULT_STYLE|wxAUI_TB_HORZ_LAYOUT|wxAUI_TB_PLAIN_BACKGROUND</property>
<property name="subclass">ACTION_TOOLBAR; tool/action_toolbar.h; forward_declare</property>
<property name="toolbar_label">label</property>
<property name="toolbar_pane">0</property>
<property name="tooltip"></property>
<property name="use_explicit_ids">0</property>
<property name="window_extra_style"></property>
<property name="window_name"></property>
<property name="window_style"></property>
</object>
</object>
<object class="sizeritem" expanded="1"> <object class="sizeritem" expanded="1">
<property name="border">5</property> <property name="border">5</property>
<property name="flag">wxEXPAND</property> <property name="flag">wxEXPAND</property>
@ -188,8 +118,8 @@
<property name="window_extra_style"></property> <property name="window_extra_style"></property>
<property name="window_name"></property> <property name="window_name"></property>
<property name="window_style">wxBORDER_NONE</property> <property name="window_style">wxBORDER_NONE</property>
<object class="splitteritem" expanded="1"> <object class="splitteritem" expanded="0">
<object class="wxPanel" expanded="1"> <object class="wxPanel" expanded="0">
<property name="BottomDockable">1</property> <property name="BottomDockable">1</property>
<property name="LeftDockable">1</property> <property name="LeftDockable">1</property>
<property name="RightDockable">1</property> <property name="RightDockable">1</property>
@ -240,16 +170,16 @@
<property name="window_extra_style"></property> <property name="window_extra_style"></property>
<property name="window_name"></property> <property name="window_name"></property>
<property name="window_style">wxTAB_TRAVERSAL</property> <property name="window_style">wxTAB_TRAVERSAL</property>
<object class="wxBoxSizer" expanded="1"> <object class="wxBoxSizer" expanded="0">
<property name="minimum_size">-1,-1</property> <property name="minimum_size">-1,-1</property>
<property name="name">m_sizer11</property> <property name="name">m_sizer11</property>
<property name="orient">wxVERTICAL</property> <property name="orient">wxVERTICAL</property>
<property name="permission">protected</property> <property name="permission">protected</property>
<object class="sizeritem" expanded="1"> <object class="sizeritem" expanded="0">
<property name="border">5</property> <property name="border">5</property>
<property name="flag">wxEXPAND</property> <property name="flag">wxEXPAND</property>
<property name="proportion">1</property> <property name="proportion">1</property>
<object class="wxSplitterWindow" expanded="1"> <object class="wxSplitterWindow" expanded="0">
<property name="BottomDockable">1</property> <property name="BottomDockable">1</property>
<property name="LeftDockable">1</property> <property name="LeftDockable">1</property>
<property name="RightDockable">1</property> <property name="RightDockable">1</property>
@ -306,8 +236,8 @@
<property name="window_extra_style"></property> <property name="window_extra_style"></property>
<property name="window_name"></property> <property name="window_name"></property>
<property name="window_style"></property> <property name="window_style"></property>
<object class="splitteritem" expanded="1"> <object class="splitteritem" expanded="0">
<object class="wxPanel" expanded="1"> <object class="wxPanel" expanded="0">
<property name="BottomDockable">1</property> <property name="BottomDockable">1</property>
<property name="LeftDockable">1</property> <property name="LeftDockable">1</property>
<property name="RightDockable">1</property> <property name="RightDockable">1</property>
@ -358,7 +288,7 @@
<property name="window_extra_style"></property> <property name="window_extra_style"></property>
<property name="window_name"></property> <property name="window_name"></property>
<property name="window_style">wxTAB_TRAVERSAL</property> <property name="window_style">wxTAB_TRAVERSAL</property>
<object class="wxBoxSizer" expanded="1"> <object class="wxBoxSizer" expanded="0">
<property name="minimum_size"></property> <property name="minimum_size"></property>
<property name="name">m_sizerPlot</property> <property name="name">m_sizerPlot</property>
<property name="orient">wxHORIZONTAL</property> <property name="orient">wxHORIZONTAL</property>
@ -430,8 +360,8 @@
</object> </object>
</object> </object>
</object> </object>
<object class="splitteritem" expanded="1"> <object class="splitteritem" expanded="0">
<object class="wxPanel" expanded="1"> <object class="wxPanel" expanded="0">
<property name="BottomDockable">1</property> <property name="BottomDockable">1</property>
<property name="LeftDockable">1</property> <property name="LeftDockable">1</property>
<property name="RightDockable">1</property> <property name="RightDockable">1</property>
@ -482,7 +412,7 @@
<property name="window_extra_style"></property> <property name="window_extra_style"></property>
<property name="window_name"></property> <property name="window_name"></property>
<property name="window_style">wxTAB_TRAVERSAL</property> <property name="window_style">wxTAB_TRAVERSAL</property>
<object class="wxBoxSizer" expanded="1"> <object class="wxBoxSizer" expanded="0">
<property name="minimum_size"></property> <property name="minimum_size"></property>
<property name="name">m_sizerConsole</property> <property name="name">m_sizerConsole</property>
<property name="orient">wxVERTICAL</property> <property name="orient">wxVERTICAL</property>
@ -559,8 +489,8 @@
</object> </object>
</object> </object>
</object> </object>
<object class="splitteritem" expanded="1"> <object class="splitteritem" expanded="0">
<object class="wxPanel" expanded="1"> <object class="wxPanel" expanded="0">
<property name="BottomDockable">1</property> <property name="BottomDockable">1</property>
<property name="LeftDockable">1</property> <property name="LeftDockable">1</property>
<property name="RightDockable">1</property> <property name="RightDockable">1</property>
@ -611,16 +541,16 @@
<property name="window_extra_style"></property> <property name="window_extra_style"></property>
<property name="window_name"></property> <property name="window_name"></property>
<property name="window_style">wxTAB_TRAVERSAL</property> <property name="window_style">wxTAB_TRAVERSAL</property>
<object class="wxBoxSizer" expanded="1"> <object class="wxBoxSizer" expanded="0">
<property name="minimum_size"></property> <property name="minimum_size"></property>
<property name="name">m_sideSizer</property> <property name="name">m_sideSizer</property>
<property name="orient">wxVERTICAL</property> <property name="orient">wxVERTICAL</property>
<property name="permission">protected</property> <property name="permission">protected</property>
<object class="sizeritem" expanded="1"> <object class="sizeritem" expanded="0">
<property name="border">5</property> <property name="border">5</property>
<property name="flag">wxEXPAND</property> <property name="flag">wxEXPAND</property>
<property name="proportion">1</property> <property name="proportion">1</property>
<object class="wxSplitterWindow" expanded="1"> <object class="wxSplitterWindow" expanded="0">
<property name="BottomDockable">1</property> <property name="BottomDockable">1</property>
<property name="LeftDockable">1</property> <property name="LeftDockable">1</property>
<property name="RightDockable">1</property> <property name="RightDockable">1</property>
@ -677,8 +607,8 @@
<property name="window_extra_style"></property> <property name="window_extra_style"></property>
<property name="window_name"></property> <property name="window_name"></property>
<property name="window_style"></property> <property name="window_style"></property>
<object class="splitteritem" expanded="1"> <object class="splitteritem" expanded="0">
<object class="wxPanel" expanded="1"> <object class="wxPanel" expanded="0">
<property name="BottomDockable">1</property> <property name="BottomDockable">1</property>
<property name="LeftDockable">1</property> <property name="LeftDockable">1</property>
<property name="RightDockable">1</property> <property name="RightDockable">1</property>
@ -729,16 +659,16 @@
<property name="window_extra_style"></property> <property name="window_extra_style"></property>
<property name="window_name"></property> <property name="window_name"></property>
<property name="window_style">wxTAB_TRAVERSAL</property> <property name="window_style">wxTAB_TRAVERSAL</property>
<object class="wxBoxSizer" expanded="1"> <object class="wxBoxSizer" expanded="0">
<property name="minimum_size"></property> <property name="minimum_size"></property>
<property name="name">bSizerSignals</property> <property name="name">bSizerSignals</property>
<property name="orient">wxVERTICAL</property> <property name="orient">wxVERTICAL</property>
<property name="permission">none</property> <property name="permission">none</property>
<object class="sizeritem" expanded="1"> <object class="sizeritem" expanded="0">
<property name="border">5</property> <property name="border">5</property>
<property name="flag">wxEXPAND</property> <property name="flag">wxEXPAND</property>
<property name="proportion">0</property> <property name="proportion">0</property>
<object class="wxSearchCtrl" expanded="1"> <object class="wxSearchCtrl" expanded="0">
<property name="BottomDockable">1</property> <property name="BottomDockable">1</property>
<property name="LeftDockable">1</property> <property name="LeftDockable">1</property>
<property name="RightDockable">1</property> <property name="RightDockable">1</property>
@ -801,11 +731,11 @@
<event name="OnText">OnFilterText</event> <event name="OnText">OnFilterText</event>
</object> </object>
</object> </object>
<object class="sizeritem" expanded="1"> <object class="sizeritem" expanded="0">
<property name="border">5</property> <property name="border">5</property>
<property name="flag">wxEXPAND</property> <property name="flag">wxEXPAND</property>
<property name="proportion">1</property> <property name="proportion">1</property>
<object class="wxGrid" expanded="1"> <object class="wxGrid" expanded="0">
<property name="BottomDockable">1</property> <property name="BottomDockable">1</property>
<property name="LeftDockable">1</property> <property name="LeftDockable">1</property>
<property name="RightDockable">1</property> <property name="RightDockable">1</property>
@ -893,8 +823,8 @@
</object> </object>
</object> </object>
</object> </object>
<object class="splitteritem" expanded="1"> <object class="splitteritem" expanded="0">
<object class="wxPanel" expanded="1"> <object class="wxPanel" expanded="0">
<property name="BottomDockable">1</property> <property name="BottomDockable">1</property>
<property name="LeftDockable">1</property> <property name="LeftDockable">1</property>
<property name="RightDockable">1</property> <property name="RightDockable">1</property>
@ -945,16 +875,16 @@
<property name="window_extra_style"></property> <property name="window_extra_style"></property>
<property name="window_name"></property> <property name="window_name"></property>
<property name="window_style">wxTAB_TRAVERSAL</property> <property name="window_style">wxTAB_TRAVERSAL</property>
<object class="wxBoxSizer" expanded="1"> <object class="wxBoxSizer" expanded="0">
<property name="minimum_size"></property> <property name="minimum_size"></property>
<property name="name">bSizerCMT</property> <property name="name">bSizerCMT</property>
<property name="orient">wxVERTICAL</property> <property name="orient">wxVERTICAL</property>
<property name="permission">none</property> <property name="permission">none</property>
<object class="sizeritem" expanded="1"> <object class="sizeritem" expanded="0">
<property name="border">5</property> <property name="border">5</property>
<property name="flag">wxEXPAND</property> <property name="flag">wxEXPAND</property>
<property name="proportion">1</property> <property name="proportion">1</property>
<object class="wxSplitterWindow" expanded="1"> <object class="wxSplitterWindow" expanded="0">
<property name="BottomDockable">1</property> <property name="BottomDockable">1</property>
<property name="LeftDockable">1</property> <property name="LeftDockable">1</property>
<property name="RightDockable">1</property> <property name="RightDockable">1</property>
@ -1011,8 +941,8 @@
<property name="window_extra_style"></property> <property name="window_extra_style"></property>
<property name="window_name"></property> <property name="window_name"></property>
<property name="window_style">wxBORDER_NONE</property> <property name="window_style">wxBORDER_NONE</property>
<object class="splitteritem" expanded="1"> <object class="splitteritem" expanded="0">
<object class="wxPanel" expanded="1"> <object class="wxPanel" expanded="0">
<property name="BottomDockable">1</property> <property name="BottomDockable">1</property>
<property name="LeftDockable">1</property> <property name="LeftDockable">1</property>
<property name="RightDockable">1</property> <property name="RightDockable">1</property>
@ -1063,16 +993,16 @@
<property name="window_extra_style"></property> <property name="window_extra_style"></property>
<property name="window_name"></property> <property name="window_name"></property>
<property name="window_style">wxTAB_TRAVERSAL</property> <property name="window_style">wxTAB_TRAVERSAL</property>
<object class="wxBoxSizer" expanded="1"> <object class="wxBoxSizer" expanded="0">
<property name="minimum_size"></property> <property name="minimum_size"></property>
<property name="name">bSizerCursors</property> <property name="name">bSizerCursors</property>
<property name="orient">wxVERTICAL</property> <property name="orient">wxVERTICAL</property>
<property name="permission">none</property> <property name="permission">none</property>
<object class="sizeritem" expanded="1"> <object class="sizeritem" expanded="0">
<property name="border">5</property> <property name="border">5</property>
<property name="flag">wxEXPAND</property> <property name="flag">wxEXPAND</property>
<property name="proportion">1</property> <property name="proportion">1</property>
<object class="wxGrid" expanded="1"> <object class="wxGrid" expanded="0">
<property name="BottomDockable">1</property> <property name="BottomDockable">1</property>
<property name="LeftDockable">1</property> <property name="LeftDockable">1</property>
<property name="RightDockable">1</property> <property name="RightDockable">1</property>
@ -1160,8 +1090,8 @@
</object> </object>
</object> </object>
</object> </object>
<object class="splitteritem" expanded="1"> <object class="splitteritem" expanded="0">
<object class="wxPanel" expanded="1"> <object class="wxPanel" expanded="0">
<property name="BottomDockable">1</property> <property name="BottomDockable">1</property>
<property name="LeftDockable">1</property> <property name="LeftDockable">1</property>
<property name="RightDockable">1</property> <property name="RightDockable">1</property>
@ -1212,16 +1142,16 @@
<property name="window_extra_style"></property> <property name="window_extra_style"></property>
<property name="window_name"></property> <property name="window_name"></property>
<property name="window_style">wxTAB_TRAVERSAL</property> <property name="window_style">wxTAB_TRAVERSAL</property>
<object class="wxBoxSizer" expanded="1"> <object class="wxBoxSizer" expanded="0">
<property name="minimum_size"></property> <property name="minimum_size"></property>
<property name="name">bSizerMT</property> <property name="name">bSizerMT</property>
<property name="orient">wxVERTICAL</property> <property name="orient">wxVERTICAL</property>
<property name="permission">none</property> <property name="permission">none</property>
<object class="sizeritem" expanded="1"> <object class="sizeritem" expanded="0">
<property name="border">5</property> <property name="border">5</property>
<property name="flag">wxEXPAND</property> <property name="flag">wxEXPAND</property>
<property name="proportion">1</property> <property name="proportion">1</property>
<object class="wxSplitterWindow" expanded="1"> <object class="wxSplitterWindow" expanded="0">
<property name="BottomDockable">1</property> <property name="BottomDockable">1</property>
<property name="LeftDockable">1</property> <property name="LeftDockable">1</property>
<property name="RightDockable">1</property> <property name="RightDockable">1</property>
@ -1278,8 +1208,8 @@
<property name="window_extra_style"></property> <property name="window_extra_style"></property>
<property name="window_name"></property> <property name="window_name"></property>
<property name="window_style">wxBORDER_NONE</property> <property name="window_style">wxBORDER_NONE</property>
<object class="splitteritem" expanded="1"> <object class="splitteritem" expanded="0">
<object class="wxPanel" expanded="1"> <object class="wxPanel" expanded="0">
<property name="BottomDockable">1</property> <property name="BottomDockable">1</property>
<property name="LeftDockable">1</property> <property name="LeftDockable">1</property>
<property name="RightDockable">1</property> <property name="RightDockable">1</property>
@ -1330,16 +1260,16 @@
<property name="window_extra_style"></property> <property name="window_extra_style"></property>
<property name="window_name"></property> <property name="window_name"></property>
<property name="window_style">wxTAB_TRAVERSAL</property> <property name="window_style">wxTAB_TRAVERSAL</property>
<object class="wxBoxSizer" expanded="1"> <object class="wxBoxSizer" expanded="0">
<property name="minimum_size"></property> <property name="minimum_size"></property>
<property name="name">bSizerMeasurements</property> <property name="name">bSizerMeasurements</property>
<property name="orient">wxVERTICAL</property> <property name="orient">wxVERTICAL</property>
<property name="permission">none</property> <property name="permission">none</property>
<object class="sizeritem" expanded="1"> <object class="sizeritem" expanded="0">
<property name="border">5</property> <property name="border">5</property>
<property name="flag">wxEXPAND</property> <property name="flag">wxEXPAND</property>
<property name="proportion">1</property> <property name="proportion">1</property>
<object class="wxGrid" expanded="1"> <object class="wxGrid" expanded="0">
<property name="BottomDockable">1</property> <property name="BottomDockable">1</property>
<property name="LeftDockable">1</property> <property name="LeftDockable">1</property>
<property name="RightDockable">1</property> <property name="RightDockable">1</property>
@ -1427,8 +1357,8 @@
</object> </object>
</object> </object>
</object> </object>
<object class="splitteritem" expanded="1"> <object class="splitteritem" expanded="0">
<object class="wxPanel" expanded="1"> <object class="wxPanel" expanded="0">
<property name="BottomDockable">1</property> <property name="BottomDockable">1</property>
<property name="LeftDockable">1</property> <property name="LeftDockable">1</property>
<property name="RightDockable">1</property> <property name="RightDockable">1</property>

View File

@ -10,40 +10,33 @@
#include <wx/artprov.h> #include <wx/artprov.h>
#include <wx/xrc/xmlres.h> #include <wx/xrc/xmlres.h>
#include <wx/intl.h> #include <wx/intl.h>
class ACTION_TOOLBAR;
class WX_GRID; class WX_GRID;
#include "sim_notebook.h" #include "sim_notebook.h"
#include "kiway_player.h"
#include <wx/gdicmn.h> #include <wx/gdicmn.h>
#include <wx/aui/aui.h> #include <wx/aui/auibook.h>
#include <wx/aui/auibar.h>
#include <wx/font.h> #include <wx/font.h>
#include <wx/colour.h> #include <wx/colour.h>
#include <wx/settings.h> #include <wx/settings.h>
#include <wx/string.h> #include <wx/string.h>
#include <wx/aui/auibook.h>
#include <wx/sizer.h> #include <wx/sizer.h>
#include <wx/panel.h> #include <wx/panel.h>
#include <wx/textctrl.h> #include <wx/textctrl.h>
#include <wx/splitter.h> #include <wx/splitter.h>
#include <wx/srchctrl.h> #include <wx/srchctrl.h>
#include <wx/grid.h> #include <wx/grid.h>
#include <wx/frame.h>
/////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////
/// Class SIMULATOR_FRAME_BASE /// Class SIMULATOR_PANEL_BASE
/////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////
class SIMULATOR_FRAME_BASE : public KIWAY_PLAYER class SIMULATOR_PANEL_BASE : public wxPanel
{ {
private: private:
protected: protected:
wxBoxSizer* m_sizerMain;
ACTION_TOOLBAR* m_toolBar;
wxSplitterWindow* m_splitterLeftRight; wxSplitterWindow* m_splitterLeftRight;
wxPanel* m_panelLeft; wxPanel* m_panelLeft;
wxBoxSizer* m_sizer11; wxBoxSizer* m_sizer11;
@ -85,38 +78,38 @@ class SIMULATOR_FRAME_BASE : public KIWAY_PLAYER
public: public:
SIMULATOR_FRAME_BASE( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("Spice Simulator"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( -1,-1 ), long style = wxDEFAULT_FRAME_STYLE|wxTAB_TRAVERSAL, const wxString& name = wxT("SIM_PLOT_FRAME") ); SIMULATOR_PANEL_BASE( wxWindow* parent, wxWindowID id = wxID_ANY, const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( -1,-1 ), long style = wxTAB_TRAVERSAL, const wxString& name = wxEmptyString );
~SIMULATOR_FRAME_BASE(); ~SIMULATOR_PANEL_BASE();
void m_splitterLeftRightOnIdle( wxIdleEvent& ) void m_splitterLeftRightOnIdle( wxIdleEvent& )
{ {
m_splitterLeftRight->SetSashPosition( 700 ); m_splitterLeftRight->SetSashPosition( 700 );
m_splitterLeftRight->Disconnect( wxEVT_IDLE, wxIdleEventHandler( SIMULATOR_FRAME_BASE::m_splitterLeftRightOnIdle ), NULL, this ); m_splitterLeftRight->Disconnect( wxEVT_IDLE, wxIdleEventHandler( SIMULATOR_PANEL_BASE::m_splitterLeftRightOnIdle ), NULL, this );
} }
void m_splitterPlotAndConsoleOnIdle( wxIdleEvent& ) void m_splitterPlotAndConsoleOnIdle( wxIdleEvent& )
{ {
m_splitterPlotAndConsole->SetSashPosition( 500 ); m_splitterPlotAndConsole->SetSashPosition( 500 );
m_splitterPlotAndConsole->Disconnect( wxEVT_IDLE, wxIdleEventHandler( SIMULATOR_FRAME_BASE::m_splitterPlotAndConsoleOnIdle ), NULL, this ); m_splitterPlotAndConsole->Disconnect( wxEVT_IDLE, wxIdleEventHandler( SIMULATOR_PANEL_BASE::m_splitterPlotAndConsoleOnIdle ), NULL, this );
} }
void m_splitterSignalsOnIdle( wxIdleEvent& ) void m_splitterSignalsOnIdle( wxIdleEvent& )
{ {
m_splitterSignals->SetSashPosition( 0 ); m_splitterSignals->SetSashPosition( 0 );
m_splitterSignals->Disconnect( wxEVT_IDLE, wxIdleEventHandler( SIMULATOR_FRAME_BASE::m_splitterSignalsOnIdle ), NULL, this ); m_splitterSignals->Disconnect( wxEVT_IDLE, wxIdleEventHandler( SIMULATOR_PANEL_BASE::m_splitterSignalsOnIdle ), NULL, this );
} }
void m_splitterCursorsOnIdle( wxIdleEvent& ) void m_splitterCursorsOnIdle( wxIdleEvent& )
{ {
m_splitterCursors->SetSashPosition( 0 ); m_splitterCursors->SetSashPosition( 0 );
m_splitterCursors->Disconnect( wxEVT_IDLE, wxIdleEventHandler( SIMULATOR_FRAME_BASE::m_splitterCursorsOnIdle ), NULL, this ); m_splitterCursors->Disconnect( wxEVT_IDLE, wxIdleEventHandler( SIMULATOR_PANEL_BASE::m_splitterCursorsOnIdle ), NULL, this );
} }
void m_splitterMeasurementsOnIdle( wxIdleEvent& ) void m_splitterMeasurementsOnIdle( wxIdleEvent& )
{ {
m_splitterMeasurements->SetSashPosition( 0 ); m_splitterMeasurements->SetSashPosition( 0 );
m_splitterMeasurements->Disconnect( wxEVT_IDLE, wxIdleEventHandler( SIMULATOR_FRAME_BASE::m_splitterMeasurementsOnIdle ), NULL, this ); m_splitterMeasurements->Disconnect( wxEVT_IDLE, wxIdleEventHandler( SIMULATOR_PANEL_BASE::m_splitterMeasurementsOnIdle ), NULL, this );
} }
}; };

View File

@ -25,6 +25,7 @@
*/ */
#include <sim/simulator_panel.h>
#include <sim/simulator_frame.h> #include <sim/simulator_frame.h>
#include <sch_symbol.h> #include <sch_symbol.h>
#include <template_fieldnames.h> #include <template_fieldnames.h>
@ -38,7 +39,7 @@
#include "tuner_slider.h" #include "tuner_slider.h"
#include "core/kicad_algo.h" #include "core/kicad_algo.h"
TUNER_SLIDER::TUNER_SLIDER( SIMULATOR_FRAME* aFrame, wxWindow* aParent, TUNER_SLIDER::TUNER_SLIDER( SIMULATOR_PANEL* aPanel, wxWindow* aParent,
const SCH_SHEET_PATH& aSheetPath, SCH_SYMBOL* aSymbol ) : const SCH_SHEET_PATH& aSheetPath, SCH_SYMBOL* aSymbol ) :
TUNER_SLIDER_BASE( aParent ), TUNER_SLIDER_BASE( aParent ),
m_symbol( aSymbol->m_Uuid ), m_symbol( aSymbol->m_Uuid ),
@ -47,9 +48,9 @@ TUNER_SLIDER::TUNER_SLIDER( SIMULATOR_FRAME* aFrame, wxWindow* aParent,
m_min( 0.0 ), m_min( 0.0 ),
m_max( 0.0 ), m_max( 0.0 ),
m_value( 0.0 ), m_value( 0.0 ),
m_frame ( aFrame ) m_panel( aPanel )
{ {
const SPICE_ITEM* item = aFrame->GetExporter()->FindItem( std::string( m_ref.ToUTF8() ) ); const SPICE_ITEM* item = m_panel->GetExporter()->FindItem( std::string( m_ref.ToUTF8() ) );
if( !item ) if( !item )
throw KI_PARAM_ERROR( wxString::Format( _( "%s not found" ), m_ref ) ); throw KI_PARAM_ERROR( wxString::Format( _( "%s not found" ), m_ref ) );
@ -190,7 +191,7 @@ bool TUNER_SLIDER::SetMax( const SPICE_VALUE& aVal )
void TUNER_SLIDER::updateComponentValue() void TUNER_SLIDER::updateComponentValue()
{ {
wxQueueEvent( m_frame, new wxCommandEvent( EVT_SIM_UPDATE ) ); wxQueueEvent( m_panel, new wxCommandEvent( EVT_SIM_UPDATE ) );
} }
@ -333,13 +334,13 @@ void TUNER_SLIDER::updateMin()
void TUNER_SLIDER::onClose( wxCommandEvent& event ) void TUNER_SLIDER::onClose( wxCommandEvent& event )
{ {
m_frame->RemoveTuner( this ); m_panel->RemoveTuner( this );
} }
void TUNER_SLIDER::onSave( wxCommandEvent& event ) void TUNER_SLIDER::onSave( wxCommandEvent& event )
{ {
m_frame->UpdateTunerValue( m_sheetPath, m_symbol, GetSymbolRef(), m_value.ToOrigString() ); m_panel->UpdateTunerValue( m_sheetPath, m_symbol, GetSymbolRef(), m_value.ToOrigString() );
} }

View File

@ -34,7 +34,7 @@
#include <wx/timer.h> #include <wx/timer.h>
class SIMULATOR_FRAME; class SIMULATOR_PANEL;
class SCH_SYMBOL; class SCH_SYMBOL;
/** /**
@ -43,7 +43,7 @@ class SCH_SYMBOL;
class TUNER_SLIDER : public TUNER_SLIDER_BASE class TUNER_SLIDER : public TUNER_SLIDER_BASE
{ {
public: public:
TUNER_SLIDER( SIMULATOR_FRAME *aFrame, wxWindow* aParent, const SCH_SHEET_PATH& aSheetPath, TUNER_SLIDER( SIMULATOR_PANEL *aPanel, wxWindow* aParent, const SCH_SHEET_PATH& aSheetPath,
SCH_SYMBOL* aSymbol ); SCH_SYMBOL* aSymbol );
wxString GetSymbolRef() const wxString GetSymbolRef() const
@ -110,7 +110,7 @@ private:
SPICE_VALUE m_max; SPICE_VALUE m_max;
SPICE_VALUE m_value; SPICE_VALUE m_value;
SIMULATOR_FRAME* m_frame; SIMULATOR_PANEL* m_panel;
}; };
#endif /* TUNER_SLIDER_H */ #endif /* TUNER_SLIDER_H */

View File

@ -178,7 +178,6 @@ public:
private: private:
friend class BM2CMP_FRAME_BASE; friend class BM2CMP_FRAME_BASE;
friend class SIMULATOR_FRAME_BASE;
/// Don't use this one, only wxformbuilder uses it, and it must be augmented with correcting /// Don't use this one, only wxformbuilder uses it, and it must be augmented with correcting
/// m_ident and calling a SetKiway() early in derived constructor. /// m_ident and calling a SetKiway() early in derived constructor.