This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public void checkGPS() { | |
locationRequest = LocationRequest.create(); | |
locationRequest.setInterval(1000); | |
LocationSettingsRequest.Builder builder = new LocationSettingsRequest.Builder() | |
.addLocationRequest(locationRequest) | |
.setAlwaysShow(true); | |
Task<LocationSettingsResponse> locationSettingsResponseTask = LocationServices.getSettingsClient(getApplicationContext()) | |
.checkLocationSettings(builder.build()); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.example.androidtogooglesheetdatabase.Post; | |
import android.app.ProgressDialog; | |
import android.os.AsyncTask; | |
import android.os.Bundle; | |
import android.util.Log; | |
import android.view.View; | |
import android.widget.Button; | |
import android.widget.EditText; | |
import android.widget.TextView; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function doGet(e) { | |
handleFunction(e); | |
} | |
function doPost(e) { | |
handleFunction(e); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ToggleButtons( | |
children: <Widget>[ | |
Icon(Icons.ac_unit), | |
Icon(Icons.call), | |
Icon(Icons.cake), | |
], | |
onPressed: (int index) { | |
setState(() { | |
isSelected[index] = !isSelected[index]; | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:http/http.dart';. | |
//dependency | |
http: ^0.13.4 | |
void getData() async { | |
//var url = Uri.parse("https://samples.openweathermap.org/data/2.5/weather?q=London&mode=html&appid=b6907d289e10d714a6e88b30761fae22"); | |
// http.Response response = await http.get(url); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//import | |
import 'package:geolocator/geolocator.dart'; | |
//dependency | |
geolocator: ^8.2.0 | |
//manifest file under direct tag of applicatioon after android 10 it is necessary to use background location | |
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" /> | |
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" /> | |
<uses-permission android:name="android.permission.ACCESS_BACKGROUND_LOCATION" /> | |