--- nono/wx/wxmonitor.cpp 2026/04/29 17:05:16 1.1.1.8 +++ nono/wx/wxmonitor.cpp 2026/04/29 17:05:31 1.1.1.9 @@ -10,6 +10,7 @@ #include "wxmonitor.h" #include "wxmainframe.h" +#include "monitor.h" // // モニターパネル @@ -21,8 +22,8 @@ wxBEGIN_EVENT_TABLE(WXMonitorPanel, inhe wxEND_EVENT_TABLE() // コンストラクタ -WXMonitorPanel::WXMonitorPanel(wxWindow *parent, Monitor& monitor_) - : inherited(parent, monitor_.GetSize()) +WXMonitorPanel::WXMonitorPanel(wxWindow *parent, Monitor *monitor_) + : inherited(parent, monitor_->GetSize()) , monitor(monitor_) { timer.SetOwner(this); @@ -78,7 +79,7 @@ WXMonitorPanel::SetRate(int hz) // コンストラクタ WXMonitorWindow::WXMonitorWindow(wxWindow *parent, const wxString& name, - Monitor& monitor_) + Monitor *monitor_) : inherited(parent, wxID_ANY, name) { // モニタパネル @@ -103,7 +104,7 @@ wxEND_EVENT_TABLE() // コンストラクタ WXScrollMonitorWindow::WXScrollMonitorWindow(wxWindow *parent, - const wxString& name, Monitor& monitor_) + const wxString& name, Monitor *monitor_) : inherited(parent, wxID_ANY, name, DEFAULT_STYLE | wxRESIZE_BORDER) { // → @@ -163,7 +164,7 @@ WXScrollMonitorWindow::OnSize(wxSizeEven // スクロールバーを再設定 int pos = (int)monpanel->GetUserData(); int thumbsize = monpanel->GetRow() - HEADLINES; - int range = monpanel->GetMonitor().GetMaxHeight() - HEADLINES; + int range = monpanel->GetMonitor()->GetMaxHeight() - HEADLINES; int pagesize = thumbsize - 1; if (pos > range - thumbsize) { pos = range - thumbsize;