Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
382 views
in Technique[技术] by (71.8m points)

swift - Pushpins not visible on iOS devices with rounded corners, the home indicator

I'm struggling with pushpins not showing on devices with rounded corners, the home indicator (iPhone 12 Pro Max for instance). Every other devices including iPads are displaying my pushpins (truck/flag...). See by yourself below The map is centered on them.

This is driving me crazy.

pseudo code:

// Vehicles
vehiclelayer = new Microsoft.Maps.Layer();
vehiclelayer.setZIndex(3);
this.map.layers.insert(vehiclelayer);
...
var pushpin;
var pushpinOptions;

pushpinOptions = {
   icon: imageBase64,
   title: label,
   visible: true,
   anchor: anchor,
  };
var location = new Microsoft.Maps.Location(latitude, longitude);
pushpin = new Microsoft.Maps.Pushpin(location, pushpinOptions);
vehiclelayer.add(pushpin, index);

The results:

iPad

enter image description here

iPhone 12 Pro Max

enter image description here

What could be the root cause of this problem?


EDIT I've been able to reproduce the problem with a simple Xcode project taking the pushpin sample from the SDK test website.

https://github.com/omatrot/wkwebview/tree/main/wkwebview

question from:https://stackoverflow.com/questions/65898073/pushpins-not-visible-on-ios-devices-with-rounded-corners-the-home-indicator

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)
Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

2.1m questions

2.1m answers

60 comments

57.0k users

...