Перейти к содержанию
Fire Monkey от А до Я

Mohamed BEN AMMAR

Пользователи
  • Постов

    2
  • Зарегистрирован

  • Посещение

  • Победитель дней

    1

Весь контент Mohamed BEN AMMAR

  1. at this time you can use the ALCinoe Library it can provide you all you need take a look at my sample here. you should see this tuto here
  2. hello i'm using delphi fmx for building android App i have this code for Activating The WI-FI icon from android device: This could be found here . =========== code ================== uses Androidapi.Helpers, Androidapi.JNI.JavaTypes, Androidapi.JNI.GraphicsContentViewText, Androidapi.JNIBridge, Androidapi.JNI.WifiManager; procedure SetWifiEnabled (AEnable: Boolean); var Obj: JObject; WifiManager: JWifiManager; begin Obj: = SharedActivityContext.getSystemService (TJContext.JavaClass.WIFI_SERVICE); if Obj = nil then Exit; WifiManager: = TJWifiManager.Wrap ((Obj as ILocalObject) .GetObjectID); WifiManager.setWifiEnabled (AEnable); end; My question is About Activating Android location: Is it possible to activate the service location icon from android device programatically without using the Location or TLocationSensor component ....? however I know exactly that google has been Deactivate this API since android "4" just for security reasons ..... but i have seen many apps in playstore can activate the service without using this code here ask the user for activate the location manually .... procedure TForm1.GPSSettings; {$IFDEF ANDROID} var Intent: JIntent; {$ENDIF} begin {$IFDEF ANDROID} Intent := TJIntent.Create; Intent := TJIntent.JavaClass.init(TJSettings.JavaClass.ACTION_LOCATION_SOURCE_SETTINGS); TAndroidHelper.Activity.startActivity(Intent); {$ENDIF} end; in other versions like lolipopup can show just the Allow Permission system dialog timer ....( Asking the user for Allowing this App to Activate the service location ......) I have an android device with lolipopup version and i try to execute the location EMBARCADERO sample but this one can not activate the service location ICON even my device show me the Allow permission dialog where i choose yes allow with never ASK.... Finally , I like the WI-FI code above ..... and i'm wondering if someone here can do this task for me (i need a unit as the WI-FI code above which can offer me the option to activate the Service Location ICON ) I'm ready to paid for that task ..... Sincerelly: Brave.
×
×
  • Создать...