aboutsummaryrefslogtreecommitdiffstats
path: root/uitest/src/com/vaadin/tests/dd/VMyDropTarget.java
blob: 58bd326524ca0719cd53758227ae28e1ce2c7220 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
package com.vaadin.tests.dd;

import com.google.gwt.user.client.ui.Composite;
import com.vaadin.client.ApplicationConnection;
import com.vaadin.client.ComponentConnector;
import com.vaadin.client.ui.dd.VDragEvent;
import com.vaadin.client.ui.dd.VDropHandler;
import com.vaadin.client.ui.dd.VHasDropHandler;

public class VMyDropTarget extends Composite implements VHasDropHandler,
        VDropHandler {

    ApplicationConnection client;

    @Override
    public void dragEnter(VDragEvent drag) {
    }

    @Override
    public void dragLeave(VDragEvent drag) {
        // TODO Auto-generated method stub
    }

    @Override
    public void dragOver(VDragEvent currentDrag) {
        // TODO Auto-generated method stub
    }

    @Override
    public boolean drop(VDragEvent drag) {
        // TODO Auto-generated method stub
        // return true to tell DDManager do server visit
        return false;
    }

    @Override
    public VDropHandler getDropHandler() {
        // Drophandler implemented by widget itself
        return this;
    }

    @Override
    public ComponentConnector getConnector() {
        // TODO Auto-generated method stub
        return null;
    }

    @Override
    public ApplicationConnection getApplicationConnection() {
        return client;
    }

}