Compare commits
No commits in common. "bef3107f38dba542e985d2375443f21656e8021d" and "3849d4d9514f99dff3871417b7a53b03235dcb41" have entirely different histories.
bef3107f38
...
3849d4d951
@ -498,27 +498,9 @@ namespace GUI
|
|||||||
}
|
}
|
||||||
public List<ChildBufRowCol> LoadScoutField()
|
public List<ChildBufRowCol> LoadScoutField()
|
||||||
{
|
{
|
||||||
// [기존 보존 2026-06-19] selectedIndexNo(GUI 캐시) 기반. 하위 호환용으로 남겨둠.
|
|
||||||
return DB.RecipeFieldScan.Instance.GetPageFieldScan(
|
return DB.RecipeFieldScan.Instance.GetPageFieldScan(
|
||||||
DB.RecipeFieldScan.Instance.GetAutoPageName(selectedIndexNo));
|
DB.RecipeFieldScan.Instance.GetAutoPageName(selectedIndexNo));
|
||||||
}
|
}
|
||||||
// [추가 2026-06-19] 페이지 인덱스를 명시 지정해 스카우트 필드 로드 (시퀀스 PageIndex 주입용)
|
|
||||||
public List<ChildBufRowCol> LoadScoutField(int pageIndex)
|
|
||||||
{
|
|
||||||
return DB.RecipeFieldScan.Instance.GetPageFieldScan(
|
|
||||||
DB.RecipeFieldScan.Instance.GetAutoPageName(pageIndex));
|
|
||||||
}
|
|
||||||
// [추가 2026-06-19] 현재 화면에 표시 중인 페이지 인덱스(라이브). 콤보박스 우선, 없으면 ActiveLayer.No.
|
|
||||||
// 로드 키를 stale 캐시(selectedIndexNo) 대신 라이브 값으로 얻기 위함.
|
|
||||||
public int GetCurrentPageIndex()
|
|
||||||
{
|
|
||||||
int idx = toolStripComboBoxPage.SelectedIndex;
|
|
||||||
if (idx < 0) {
|
|
||||||
var active = ScannerCanvasCtrlTeaching?.Model?.ActiveLayer;
|
|
||||||
idx = active != null ? active.No : 0;
|
|
||||||
}
|
|
||||||
return idx;
|
|
||||||
}
|
|
||||||
void SaveAndLoadFieldScanFromLasaDb(string inputStr = null)
|
void SaveAndLoadFieldScanFromLasaDb(string inputStr = null)
|
||||||
{
|
{
|
||||||
string fullpath = inputStr == null ? DB.Dao.SystemRecipe.WorkRecipeFile : inputStr;
|
string fullpath = inputStr == null ? DB.Dao.SystemRecipe.WorkRecipeFile : inputStr;
|
||||||
|
|||||||
@ -148,13 +148,7 @@ namespace WeldingCommon.Sequences
|
|||||||
//CamConfig의 PosIndex 순서로 ScoutNoList를 파싱해서 사용하도록 함
|
//CamConfig의 PosIndex 순서로 ScoutNoList를 파싱해서 사용하도록 함
|
||||||
//_ChildBufRowCols = _CamConfig.ChildImage.ChildBufRowCols;
|
//_ChildBufRowCols = _CamConfig.ChildImage.ChildBufRowCols;
|
||||||
var mainPage = CommonHelper.GetMainPage();
|
var mainPage = CommonHelper.GetMainPage();
|
||||||
// [기존 2026-06-19 주석처리] GUI 전역 상태(selectedIndexNo)에 의존 → 페이지 정합성 버그
|
_ChildBufRowCols = mainPage.LoadScoutField();
|
||||||
//_ChildBufRowCols = mainPage.LoadScoutField();
|
|
||||||
// [변경 2026-06-19] InitParam 으로 전달된 페이지 인덱스로 명시 로드
|
|
||||||
// 폴백: 해당 페이지가 없으면(인덱스 초과 등) selectedIndexNo 기반 로드, 그래도 null이면 빈 리스트로 NRE 방지.
|
|
||||||
_ChildBufRowCols = mainPage.LoadScoutField(_InitParam.PageIndex)
|
|
||||||
?? mainPage.LoadScoutField()
|
|
||||||
?? new List<ChildBufRowCol>();
|
|
||||||
_ScoutNoList = GenerateSortedScoutNoList(_ChildBufRowCols);
|
_ScoutNoList = GenerateSortedScoutNoList(_ChildBufRowCols);
|
||||||
_ScoutNo = 0;
|
_ScoutNo = 0;
|
||||||
|
|
||||||
@ -381,10 +375,6 @@ namespace WeldingCommon.Sequences
|
|||||||
public bool IsRealTimeScout { get; set; }
|
public bool IsRealTimeScout { get; set; }
|
||||||
public ScoutSeqParams ScoutSeqParams { get; set; }
|
public ScoutSeqParams ScoutSeqParams { get; set; }
|
||||||
|
|
||||||
// [추가 2026-06-19] 스카우트 필드를 불러올 페이지 인덱스(0-base).
|
|
||||||
// 기존: SeqScoutNormal 이 MainPage.selectedIndexNo(GUI 전역 상태)에만 의존 → 페이지 이동/자동운전 시 stale.
|
|
||||||
// 변경: 호출부가 "현재 처리/표시 중인 페이지 번호"를 명시 주입.
|
|
||||||
public int PageIndex { get; set; } = 0;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public class SeqScoutNormal_OutParam : OutParam
|
public class SeqScoutNormal_OutParam : OutParam
|
||||||
|
|||||||
@ -251,8 +251,6 @@ namespace WeldingCommon.Views
|
|||||||
var param = new SeqScoutNormal_InitParam() {
|
var param = new SeqScoutNormal_InitParam() {
|
||||||
IsRealTimeScout = false,
|
IsRealTimeScout = false,
|
||||||
ScoutSeqParams = scoutSeqParams,
|
ScoutSeqParams = scoutSeqParams,
|
||||||
// [추가 2026-06-19] 현재 표시 중인 페이지의 스카우트 필드를 사용하도록 명시 주입
|
|
||||||
PageIndex = CommonHelper.GetMainPage().GetCurrentPageIndex(),
|
|
||||||
};
|
};
|
||||||
|
|
||||||
PopupSequenceDiagram(ref _WinSequenceDiagramScoutNormal, CommonSequenceIds.SeqScoutNormal, param);
|
PopupSequenceDiagram(ref _WinSequenceDiagramScoutNormal, CommonSequenceIds.SeqScoutNormal, param);
|
||||||
|
|||||||
@ -361,8 +361,6 @@ namespace WeldingCommon.Views
|
|||||||
var param = new SeqScoutNormal_InitParam() {
|
var param = new SeqScoutNormal_InitParam() {
|
||||||
IsRealTimeScout = false,
|
IsRealTimeScout = false,
|
||||||
ScoutSeqParams = new ScoutSeqParams(VisionRecipeManager.GetFovInfos()[0], eDisplayType.Machine_B),
|
ScoutSeqParams = new ScoutSeqParams(VisionRecipeManager.GetFovInfos()[0], eDisplayType.Machine_B),
|
||||||
// [추가 2026-06-19] 현재 표시 중인 페이지 인덱스 주입
|
|
||||||
PageIndex = CommonHelper.GetMainPage().GetCurrentPageIndex(),
|
|
||||||
};
|
};
|
||||||
|
|
||||||
IsSequenceRunning_SeqScoutNormal = true;
|
IsSequenceRunning_SeqScoutNormal = true;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user