PTZ_ControllerPopupWindowFactory

public class PTZ_ControllerPopupWindowFactory implements OnTouchListener

This Factory class provides you an interactive visual panel containing a set of buttons to be used as a GUI frontend for handling remote PTZ webcams. You need to pass a IPtzCommandReceiver interface to the factory method of this class, because it notifies to this interface all the GUI actions (e.g button clicks) Note that the created window implements the android.view.View.OnTouchListener interface, so you can move it to the desired position on the screen.

Constructors

PTZ_ControllerPopupWindowFactory

public PTZ_ControllerPopupWindowFactory(Context context, IPtzCommandReceiver ptzReceiver, boolean panTiltPanelVisible, boolean zoomPanelVisible, boolean snapShotVisible, int xPos, int yPos)

Creates a new floating popupWindow, containing a set of optional panels to be viewed

Parameters:
  • context – the context where to render the popup Window
  • ptzReceiver – the remote object to use as the target of all user notifications
  • panTiltPanelVisible – set the pan-tilt panel visible or not
  • zoomPanelVisible – set the zoom panel visible or not
  • snapShotVisible – set the snapshot button visible or not
  • xPos – the initial X position of the popupWindow
  • yPos – the initial y position of the popupWindow

Methods

getPopupWindow

public PopupWindow getPopupWindow()
Returns:the created popup Window

onTouch

public boolean onTouch(View v, MotionEvent event)

show

public void show()

Show the popupWindow at the current location