flutter_background_geolocation icon indicating copy to clipboard operation
flutter_background_geolocation copied to clipboard

getCurrentPosition

Open ivangoluuk opened this issue 4 years ago • 1 comments

Hi, is there a way to avoid calling the "OnLocation" listener when I call the "getCurrentPosition" method... I just want the coords

Your Environment

  • Plugin version:
  • Platform: iOS or Android
  • OS version:
  • Device manufacturer / model:
  • Flutter info (flutter doctor):
  • Plugin config:
PASTE_YOUR_CODE_HERE

Expected Behavior

Actual Behavior

Steps to Reproduce

1. 2. 3. 4.

Context

Debug logs

Logs
PASTE_YOUR_LOGS_HERE

ivangoluuk avatar Oct 07 '22 20:10 ivangoluuk

is there a way to avoid calling the "OnLocation" listener when I call the "getCurrentPosition" method

no. Add a flag to extras (Eg: getCurrentPosition: true and add logic to onLocation to ignore as desired.

christocracy avatar Oct 07 '22 20:10 christocracy