زمانی که دکمه موقعیت مکانی من کلیک شود، تماس گرفته می شود.
روش های عمومی
بولین انتزاعی عمومیonMyLocationButtonClick()
زمانی که دکمه موقعیت مکانی من کلیک شود، تماس گرفته می شود.
این در رشته رابط کاربری اندروید نامیده می شود.
اگر میخواهید مکان فعلی کاربر را به دست آورید، از com.google.android.gms.location.FusedLocationProviderApi استفاده کنید.
برمی گرداند
true اگر شنونده رویداد را مصرف کرده باشد (یعنی رفتار پیش فرض نباید رخ دهد). false در غیر این صورت (یعنی رفتار پیش فرض باید رخ دهد). رفتار پیشفرض برای حرکت دوربین به گونهای است که بر روی مکان کاربر متمرکز شود.
تاریخ آخرین بهروزرسانی 2025-04-26 بهوقت ساعت هماهنگ جهانی.
[[["درک آسان","easyToUnderstand","thumb-up"],["مشکلم را برطرف کرد","solvedMyProblem","thumb-up"],["غیره","otherUp","thumb-up"]],[["اطلاعاتی که نیاز دارم وجود ندارد","missingTheInformationINeed","thumb-down"],["بیشازحد پیچیده/ مراحل بسیار زیاد","tooComplicatedTooManySteps","thumb-down"],["قدیمی","outOfDate","thumb-down"],["مشکل ترجمه","translationIssue","thumb-down"],["مشکل کد / نمونهها","samplesCodeIssue","thumb-down"],["غیره","otherDown","thumb-down"]],["تاریخ آخرین بهروزرسانی 2025-04-26 بهوقت ساعت هماهنگ جهانی."],[[["`GoogleMap.OnMyLocationButtonClickListener` is an interface used to handle clicks on the \"My Location\" button within a Google Map."],["The primary method, `onMyLocationButtonClick()`, is called when the button is clicked and allows custom actions to be performed before or instead of the default camera movement."],["Returning `true` from `onMyLocationButtonClick()` prevents the default behavior (centering the camera on the user's location), while returning `false` allows it."]]],["The `GoogleMap.OnMyLocationButtonClickListener` interface triggers the `onMyLocationButtonClick()` method when the \"My Location\" button is pressed. This method, executed on the UI thread, allows developers to handle the event. Returning `true` prevents the default camera movement to the user's location, while `false` allows it. For retrieving the user's location, the `FusedLocationProviderApi` is recommended.\n"]]