|
POST
|
How about the following: Scenario 1 - callout always visible: Callout is visible. [set Esri zoom listener to null -- e.g. map.setOnZoomListener(null);] Click Zoom Out on zoomcontrol Call should stay visible Scenario 2 - callout always closed: Callout is visible. [user closes callout] [re-initialize a new Esri zoom listener] Click Zoom Out on zoomcontrol the callout disappears. I haven't tried this but it sounds like it would work. What do you think? -Andy
... View more
05-24-2012
01:37 PM
|
0
|
0
|
1431
|
|
POST
|
Luke, a few questions related to the GetBufferLock error: 1) Have you verified with the Eclipse debugger that your app crashes as soon as you "step into" zoomToResolution()? 2) And, that happens 100% of the time? 3) Can you copy the entire crash sequence from Logcat and either paste or attach it? 4) What's the make/model of the device? 5) Android OS version? 6) ArcGIS SDK version? 7) Code snippet of the method where the error is happening? Thanks, -Andy
... View more
05-24-2012
12:09 PM
|
0
|
0
|
2344
|
|
POST
|
I'm just guessing that this has do with MapView when you serialize/deserialize it as a bitmap at the bytecode level. Did you try any patterns similar to this link: http://www.brighthub.com/mobile/google-android/articles/30676.aspx? -Andy
... View more
05-24-2012
12:01 PM
|
0
|
0
|
2805
|
|
POST
|
And, here's a code snippet showing the basic pattern: map.setOnSingleTapListener(new OnSingleTapListener() {
/**
*
*/
private static final long serialVersionUID = 1L;
@Override
public void onSingleTap(float x, float y) {
double _x = x;
double _y = y;
double scale = 500000;
Point pt = new Point(_x,_y);
map.centerAt(pt,true);
map.setScale(scale);
}
}); -Andy
... View more
05-24-2012
11:09 AM
|
0
|
0
|
2344
|
|
POST
|
Andrew, sorry I can't help with that. Serializing screen captures on any client is tricky because issues related to Class reflection. The usual best practice is to create a URL to an external web map. -Andy
... View more
05-24-2012
09:47 AM
|
0
|
0
|
2805
|
|
POST
|
You could do a two step process: 1) centerAt() 2) setScale() -Andy
... View more
05-24-2012
09:41 AM
|
0
|
0
|
2344
|
|
POST
|
Andrew, do you mean is there a way to control the default callout using my proposed workaround? I'm not sure what your workflow is, however here's some additional psuedo-code you can try out, and look at bolting some of it into the workaround if it meets your needs. In my app using a pattern like this, I was able to temporarily disable the default callout, and then it would come back the next time a user clicked on a graphic. Another option would be to create your own custom callout. That would be the best practice, but it would involve more coding. callout = map.getCallout();
callout.setStyle(R.xml.calloutstyle);
testButton = (ImageButton)findViewById(R.id.testbutton);
testButton.setOnClickListener(new OnClickListener() {
@Override
public void onClick(View v) {
if(callout != null){
callout.hide();
callout = null; //callout gets re-created when user clicks on Graphic
}
}
}); -Andy
... View more
05-24-2012
09:32 AM
|
0
|
0
|
1431
|
|
POST
|
Do you have any messages in the ArcGIS Server log? Here is a similar post with information that might help: http://forums.arcgis.com/threads/27763-Problem-with-Geoprocessing-Service -Andy
... View more
05-22-2012
11:47 AM
|
0
|
0
|
1535
|
|
POST
|
Aleksi, another suggestion for HTTP responses. A real quick way to verify if the request is being made is if you have access to your web server logs then run the refresh() and see if the HTTP request shows up in the log. -Andy
... View more
05-21-2012
01:08 PM
|
0
|
0
|
1536
|
|
POST
|
Aleksi, are you able to verify if there is a request/response when the refresh() method runs? And, did any errors show up in Logcat when the refresh() runs? If you don't know how to monitor HTTP requests for native Android apps, here's a blog post that should help: http://www.andygup.net/?p=695 -Andy
... View more
05-21-2012
01:03 PM
|
0
|
0
|
1536
|
|
POST
|
RE: debugging HTTP requests on Android here's a blog post that may help: http://www.andygup.net/?p=695 -Andy
... View more
05-21-2012
12:47 PM
|
0
|
0
|
1535
|
|
POST
|
@lcatania You may have already done this, did you compare the parameters set in your code with the parameters documented in your Geoprocessing Service REST endpoint? As a second suggestion, do you have another working sample that uses the same service that you can compare the HTTP request against? -Andy
... View more
05-21-2012
08:58 AM
|
0
|
0
|
3214
|
|
POST
|
Aleksi, can you clarify what the problem is? Typically if there is problem it will show up in Logcat when the app is loading/running. -Andy
... View more
05-17-2012
09:03 AM
|
0
|
0
|
1536
|
|
POST
|
Did you see any errors in the project or Logcat? Usually if an app doesn't load in the emulator there are either errors in the project, or errors that occurred during loading. -Andy
... View more
05-17-2012
08:58 AM
|
0
|
0
|
1376
|
|
POST
|
Ah, right, because we don't currently support ZoomControls directly in com.esri.android.map.MapView. You set up a stand-alone ZoomControl and that's why the listener is returning your zoomButton as the scope. Got it. So, I was able to reproduce the behavior. While it's not exactly clear what's causing the problem, I suspect it's related to the View.OnClickListener and we'd have to dig deeper. As a temporary workaround, by simply setting up an OnZoomListener I was able to modify the behavior of the callout. When I implemented this pattern the callout seems to always hide() when using the ZoomControl, which isn't 100% ideal . Maybe you can work with something related to this for now, and give it a try? In the meantime, I'll submit an enhancement request that we look into working side-by-side with ZoomControls. map.setOnZoomListener(new OnZoomListener() {
/**
*
*/
private static final long serialVersionUID = 1L;
@Override
public void preAction(float pivotX, float pivotY, double factor) {
// TODO Auto-generated method stub
}
@Override
public void postAction(float pivotX, float pivotY, double factor) {
Log.d("test","test of the OnZoomListener");
}
});
... View more
05-16-2012
10:28 AM
|
0
|
0
|
1431
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 4 weeks ago | |
| 1 | 03-26-2026 03:12 PM | |
| 2 | 02-21-2026 10:23 AM | |
| 2 | 08-01-2025 06:20 AM | |
| 1 | 05-27-2025 12:39 PM |
| Online Status |
Offline
|
| Date Last Visited |
2 weeks ago
|