ScatterViewItem의 위치 (가운데 속성)를 캡처하는 쉬운 방법에 대해 알고있는 사람이라면 누구나 쉽게 모멘텀을 잃고 화면을 가로 질러 깜박이면 멈출 수 있습니까? 나는 "hotspot"영역을 설정했는데 항목이 그 범위 내에서 멈추게되면 파일 전송을 시작하려고합니다.Surface SDK의 ScatterViewItem 위치 변경 이벤트 처리기?
지금까지 내가 성공하지으로하여 PropertyChanged 알림을 시도했다 :
---OvelayWrapper.xaml.cs---
---------------------------
public event PropertyChangedEventHandler PropertyChanged;
public Point CurrentLocation
{
get
{
return _CurrentLocation;
}
set
{
_CurrentLocation = value;
OnPropertyChanged("CurrentLocation");
}
}
protected void OnPropertyChanged(string newLoc)
{
PropertyChangedEventHandler handler = PropertyChanged;
if (handler != null)
{
handler(this, new PropertyChangedEventArgs(newLoc));
}
Console.WriteLine("New Location Recorded");
}
---OverlayWrapper.xaml---
-------------------------
<s:ScatterViewItem Center="{Binding Path=CurrentLocation}">
<Label Content="Test" />
</s:ScatterViewItem>
ScatterViewItems 내가 스케일링을 추적하는 데 사용하는 SizedChanged 이벤트 핸들러를 가지고 있지만, 그것은 이해가되지 않는다는 TranslationChanged 이벤트 핸들러 존재하지 않을 것이다.
또한 ScatterViewItem에 ManipulationStarting/Delta/Completed 이벤트를 사용할 수 없습니다.
미리 감사합니다, 위치, 크기에 대한
-Z
델타가 변경되지 추적 작업을해라. ** BackgroundWorker ** 클래스 구현이 끝났습니다. 비효율적이지만, 모션 중에 ScatterViewItems의 위치를 추적하는 유일한 방법 인 것 같습니다. 앞으로는 ScatterViewItems를 내 자신의 객체로 바꾸면 Affine2DInteriaCompleted 이벤트를 활용할 것입니다. – CountZachula