Posts

Showing posts from February, 2020

Passing data to component using Modal Controller in ionic 4

Here we can see how to pass the data from angular page to component using ModalController in ionic 4 Invoking the modal popup: //invoking modal with data async invokeAirportModal( title ){ const popover = await this.modalController.create({ component: ModalComponent , componentProps: { value : title } , showBackdrop: true }); //open the modal popup await popover.present(); //Receive data from component when dismiss the modal popup const event: any = await popover.onDidDismiss(); console.log(JSON.stringify(event)) const data: any = event.data; if(data != null) { // Do your code } } Component: We need to use @Input Decorator to receive the data from page @Component({ selector: 'ModalComponent', templateUrl: './ModalComponent.component.html', styleUrls: [ './ModalComponent.component.css' ] }) export class ModalComponent { @Input() value: any; ngOnInit()

Internet validation for android developeme

After some detailed analysis, this is what I could conclude for android internet validation //To check internet validation for kotlin // To Check for Internet connection for Java

Android Dangerous Permissions

From API level 23, an android team derived the dangerous permission Normal Permission: ACCESS_LOCATION_EXTRA_COMMANDS ACCESS_NETWORK_STATE ACCESS_NOTIFICATION_POLICY ACCESS_WIFI_STATE BLUETOOTH BLUETOOTH_ADMIN BROADCAST_STICKY CHANGE_NETWORK_STATE CHANGE_WIFI_MULTICAST_STATE CHANGE_WIFI_STATE DISABLE_KEYGUARD EXPAND_STATUS_BAR GET_PACKAGE_SIZE INSTALL_SHORTCUT INTERNET KILL_BACKGROUND_PROCESSES MODIFY_AUDIO_SETTINGS NFC READ_SYNC_SETTINGS READ_SYNC_STATS RECEIVE_BOOT_COMPLETED REORDER_TASKS REQUEST_IGNORE_BATTERY_OPTIMIZATIONS REQUEST_INSTALL_PACKAGES SET_ALARM SET_TIME_ZONE SET_WALLPAPER SET_WALLPAPER_HINTS TRANSMIT_IR UNINSTALL_SHORTCUT USE_FINGERPRINT VIBRATE WAKE_LOCK WRITE_SYNC_SETTINGS Dangerous Permission: READ_CALENDAR WRITE_CALENDAR CAMERA READ_CONTACTS WRITE_CONTACTS GET_ACCOUNTS ACCESS_FINE_LOCATION ACCESS_COARSE_LOCATION RECORD_AUDIO READ_PHONE_STATE READ_PHONE_NUMBERS  CALL_PHONE ANSWER_PHONE_CALLS  READ_CALL_LOG

Media files download from firebase using android service

File download from firebase storage using android service

Progress notification for download service in android

Image
Download progress notification for android service Demo screenshot: