private void gesture_DragStarted(object sender, DragStartedGestureEventArgs e) { var point = e.GetPosition(ContentPanel); message.Text = string.Format("drag started at ({0},{1}) in the {2} direction ", point.X, point.Y, e.Direction); flickMessage.Text = null; }
private void GestureListener_DragStarted(object sender, DragStartedGestureEventArgs e) { if (!IsDragItem) { IsDragList = true; } }
private void GestureListener_DragStarted(object sender, DragStartedGestureEventArgs e) { Rectangle rect = sender as Rectangle; _isDrag = true; rect.CaptureMouse(); }
/// <summary> /// Handles started drags on the root. /// </summary> /// <param name="sender">The event sender.</param> /// <param name="e">The event information.</param> private void DragStartedHandler(object sender, DragStartedGestureEventArgs e) { e.Handled = true; _isDragging = true; _dragTranslation = Translation; ChangeVisualState(true); Translation = _dragTranslation; }
private void GestureListener_DragStarted(object sender, DragStartedGestureEventArgs e) { _selecteditem = pagelist.SelectedItem as Page; if (_sendertemp != null) { FrameworkElement fe = _sendertemp as FrameworkElement; SwipeMenu.MenuBounceBack(fe); } _sendertemp = sender; }
void listener_DragStarted(object sender, DragStartedGestureEventArgs e) { //Debug.WriteLine("listener_DragStarted"); if (e.Direction == Orientation.Vertical) { _state = State.Dragging; e.Handled = true; _selectedItem = null; if (!IsExpanded) { IsExpanded = true; } _dragTarget = _panningTransform.Y; UpdateItemState(); } }
private void Pushpin_OnDragStarted(object sender, DragStartedGestureEventArgs e) { MyMap.IsEnabled = false; // prevents the map from dragging w/ pushpin} #region 更前のコード /* * Pushpin draggingPin = sender as Pushpin; * * //MessageBox.Show(draggingPin.Parent.ToString()); * * Point p = MyMap.LocationToViewportPoint(draggingPin.Location); * PushPin_Point.X = p.X; * PushPin_Point.Y = p.Y; * * var pins = from pin in PushPinViewModel.PushPins * where pin.Location == (sender as Pushpin).Location * select pin; * if (pins.Count() != 0) * { * pin = pins.First(); * } */ #endregion //これをnewしておくと、ピンがかさなっていても一緒に動かない。 //ただし、移動量は相変わらず重なっているピンの数に比例して2倍、3倍となる。 PushPin_Point = new Point(); PushPin_GeoCoordinate = new GeoCoordinate(); DraggingPin = new PushPinModel(); DraggingPin = (sender as Pushpin).DataContext as PushPinModel; //DraggingPin.Selected = true; PinName = DraggingPin.Name; Point p = MyMap.LocationToViewportPoint(DraggingPin.Location); PushPin_Point.X = p.X + 80; PushPin_Point.Y = p.Y - 120; }
private void OnDragStarted(object sender, DragStartedGestureEventArgs e) { _direction = e.Direction; }
private void OnDragStarted(object sender, DragStartedGestureEventArgs e) { border.Background = greenBrush; }
void listener_DragStarted(object sender, DragStartedGestureEventArgs e) { //Debug.WriteLine("listener_DragStarted"); if (e.Direction == Orientation.Horizontal) { _state = State.Dragging; e.Handled = true; _selectedItem = null; if (!IsExpanded) { IsExpanded = true; } _dragTarget = _panningTransform.X; UpdateItemState(); } }
private void OnDragStarted(object sender, DragStartedGestureEventArgs e) { CutImage.Opacity = 0.3; }
private void GestureListener_DragStarted(object sender, DragStartedGestureEventArgs e) { firstPos = e.GetPosition(LayoutRoot); }
private void GestureListener_DragStarted(object sender, DragStartedGestureEventArgs e) { ReportGesture("Drag Started"); }
void gestureListener_DragStarted(object sender, DragStartedGestureEventArgs e) { this.CancelHighlight(); }
/// <summary> /// Handles started drags on the root. /// </summary> /// <param name="sender">The event sender.</param> /// <param name="e">The event information.</param> private void DragStartedHandler(object sender, DragStartedGestureEventArgs e) { e.Handled = true; _isDragging = true; _dragTranslation = Translation; ChangeVisualState(true); Translation = _dragTranslation; }
void OnGestureListenerDragStarted(object sender, DragStartedGestureEventArgs args) { isDragging = args.OriginalSource == image; }
private void OnDragStarted(object sender, DragStartedGestureEventArgs e) { //flickData.Text = string.Format("{0} OnDragStarted", // e.Direction); }
//private void ContentPanel_ManipulationStarted(object sender, ManipulationStartedEventArgs e) //{ // initialpoint = new Point(e.ManipulationOrigin.X, e.ManipulationOrigin.Y); //} //private void ContentPanel_ManipulationDelta(object sender, ManipulationDeltaEventArgs e) //{ // //if(e.IsInertial) // //{ // // Point currentpoint = new Point(e.ManipulationOrigin.X, e.ManipulationOrigin.Y); // // if (currentpoint.X > initialpoint.X) // // { // // NavigationService.Navigate(new Uri("/MainPage.xaml?Select_Item=" + ((TextBlock)sender).Text + "&Index=1", UriKind.Relative)); // // } // //} //} //private void ContentPanel_ManipulationCompleted(object sender, ManipulationCompletedEventArgs e) //{ // Point currentpoint = new Point(e.ManipulationOrigin.X, e.ManipulationOrigin.Y); // if (currentpoint.X > initialpoint.X) // { // NavigationService.Navigate(new Uri("/MainPage.xaml?Select_Item=" + ((TextBlock)sender).Text + "&Index=1", UriKind.Relative)); // } //} private void GestureListener_DragStarted(object sender, DragStartedGestureEventArgs e) { int d = 0; }