public class ResectionBearingDialog
extends java.lang.Object
implements android.view.View.OnClickListener, android.view.View.OnTouchListener
Modifier and Type | Class and Description |
---|---|
static interface |
ResectionBearingDialog.Callback |
Constructor and Description |
---|
ResectionBearingDialog(MapView mapView) |
Modifier and Type | Method and Description |
---|---|
protected double |
getDefaultBearing()
Get the default bearing displayed to the user
|
java.lang.Object |
getTag()
Get dialog tag
|
GeoPoint |
getTargetPoint() |
double |
getTrueBearing()
Get the current set bearing in true degrees
|
void |
onClick(android.view.View v) |
boolean |
onTouch(android.view.View v,
android.view.MotionEvent event)
Used for dragging the bearing line
|
void |
setTag(java.lang.Object tag)
Set a tag associated with this dialog (for use in the callback)
|
void |
setTargetPoint(GeoPoint point)
Set the target point used for obtaining default bearing
If not set then the default bearing is the device's current heading
|
void |
setTitle(java.lang.String title)
Set the title of the dialog
|
void |
show(boolean showMag,
ResectionBearingDialog.Callback cb) |
void |
show(double bearingTrue,
boolean showMag,
ResectionBearingDialog.Callback cb)
Show the dialog
|
void |
show(double bearingTrue,
ResectionBearingDialog.Callback cb) |
void |
show(ResectionBearingDialog.Callback cb) |
public ResectionBearingDialog(MapView mapView)
public void setTargetPoint(GeoPoint point)
point
- Target pointpublic GeoPoint getTargetPoint()
public void setTitle(java.lang.String title)
title
- Title to be displayed at the top of the dialogpublic double getTrueBearing()
public void setTag(java.lang.Object tag)
tag
- Tag objectpublic java.lang.Object getTag()
public void show(double bearingTrue, boolean showMag, ResectionBearingDialog.Callback cb)
bearingTrue
- The initial bearing in degrees true northshowMag
- True to display the bearing in magnetic northcb
- Callback to fire once user selects "OK"public void show(double bearingTrue, ResectionBearingDialog.Callback cb)
public void show(boolean showMag, ResectionBearingDialog.Callback cb)
public void show(ResectionBearingDialog.Callback cb)
protected double getDefaultBearing()
public void onClick(android.view.View v)
onClick
in interface android.view.View.OnClickListener
public boolean onTouch(android.view.View v, android.view.MotionEvent event)
onTouch
in interface android.view.View.OnTouchListener