mapView Double-click Event Monitoring

public class MyMapView extends MapView (

private long lastTouchTime = -1;

public MyMapView (Context context, AttributeSet attrs) (

super (context, attrs);
)

@ Override
public boolean onInterceptTouchEvent (MotionEvent ev) (

if (ev.getAction () == MotionEvent.ACTION_DOWN) (

long thisTime = System.currentTimeMillis ();
if (thisTime - lastTouchTime <250) (

/ / Double tap
this.getController (). zoomInFixing ((int) ev.getX (), (int) ev.getY ());
lastTouchTime = -1;

) Else (

/ / Too slow
lastTouchTime = thisTime;
)
)

return super.onInterceptTouchEvent (ev);
)

分类:Mobile 时间:2010-08-22 人气:180
分享到:
blog comments powered by Disqus

相关文章

  • Double-click pop-up window, right-rightclickmanager shielding flex right 2010-10-23

    A similar line on the rightclickmanager right flex custom countless articles. But the choice of words. Also need to operate according to each user to choose a way to use it. Such as the Flex shield and customize the right mouse button menu Is the peo

  • With the timer delay to achieve the mouse double click event events, click and double-click events independently of each other! 2010-03-29

    import java.awt.event.MouseAdapter; import java.awt.event.MouseEvent; import java.util.Date; import java.util.Timer; /** * Use the timer delay click event implements mouse double-click event , Click and double-click event from interfering with each o

  • Double-click the production of hands-on experience running jar package 2009-09-14

    University of the past few days to help students graduating from a girlfriend to do a design, what kind of an inventory system what. Other estimates are not very familiar with the java command line, in order to display a lot of what fitted the eclips

  • JavaScript can achieve double-click to edit text 2009-10-22

    <! DOCTYPE html PUBLIC "- / / W3C / / DTD XHTML 1.0 Transitional / / EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv=&quo

  • Double-click to edit 2009-07-24

    <%@ page language="java" import="java.util.*" pageEncoding="utf-8"%> <%@taglib prefix="s" uri="/struts-tags"%> <% String path = request.getContextPath(); String basePath = request.getScheme(

  • Double-click solution program appears to open way 2010-04-06

    Double-click solution program appears to open way <! - Advertising -> 1, by modifying the registry to restore the EXE file association: First Windows directory under the Registry Editor "Regedit.exe" to "Regedit.com", then run; F

  • Double-click on the NavigatorView open the question editor 2010-04-21

    My implementation code is : IWorkbenchWindow window= getPlugin().getWorkbench().getActiveWorkbenchWindow(); window.getActivePage().openEditor(new REditorInput(), REditor.class.getName()); But each time the double-click time is always opened two edito

  • Double-click to start image 2010-05-04

    main.jsp <c:set var="showpage" value="${requestScope.showpage}"/> <c:if test="${empty showpage}"> <c:set var="showpage" value="welcome.jsp"/> </c:if> <table border="0"

  • Flex changes to achieve double-click DataGrid 2010-05-11

    package { import flash.events.MouseEvent; import mx.controls.DataGrid; import mx.controls.dataGridClasses.DataGridColumn; import mx.controls.listClasses.IDropInListItemRenderer; import mx.controls.listClasses.IListItemRenderer; import mx.core.EventPr

  • Double-click does not select the text (compatible with firefox) 2010-06-22

    When doing a datatable, bound to each line of a double-time, but if you double-click to the text when the text will be selected. If you double-click the next page, in IE, it will select all the text. Solution: In the body tag add an event: <body onse

iOS 开发

Android 开发

Python 开发

JAVA 开发

开发语言

PHP 开发

Ruby 开发

搜索

前端开发

数据库

开发工具

开放平台

Javascript 开发

.NET 开发

云计算

服务器

Copyright (C) codeweblog.com, All Rights Reserved.

CodeWeblog.com 版权所有 黔ICP备15002463号-1

processed in 0.076 (s). 12 q(s)