Skip to content

Instantly share code, notes, and snippets.

Avatar
🔱

Akshay Chordiya AkshayChordiya

🔱
View GitHub Profile
@AkshayChordiya
AkshayChordiya / privacypolicy.html
Last active Feb 22, 2017
Jair Player Privacy Policy
View privacypolicy.html
<!DOCTYPE html><html><body><h2>Privacy Policy</h2><p>Akshay Chordiya built the Jair Player app as a free app. This SERVICE is provided by Akshay Chordiya at no cost and is intended for use as is.</p><p>This page is used to inform website visitors regarding my policies with the collection, use, and disclosure of Personal Information if anyone decided to use my Service.</p><p>If you choose to use my Service, then you agree to the collection and use of information in relation to this policy. The Personal Information that I collect are used for providing and improving the Service.I will not use or share your information with anyone except as described in this Privacy Policy.</p> <p>The terms used in this Privacy Policy have the same meanings as in our Terms and Conditions, which is accessible at Jair Player, unless otherwise defined in this Privacy Policy.</p><p><strong>Information Collection and Use</strong></p><p>For a better experience, while using our Service, I may require you to provide us with certain pers
@AkshayChordiya
AkshayChordiya / privacypolicy.html
Created Feb 22, 2017
Automaton Locker Privacy Policy
View privacypolicy.html
<!DOCTYPE html>
<html>
<body><h2>Privacy Policy</h2>
<p>Akshay Chordiya built the Automaton Locker app as a free app. This SERVICE is provided by Akshay
Chordiya at no cost and is intended for use as is.</p>
<p>This page is used to inform website visitors regarding my policies with the collection, use, and
disclosure of Personal Information if anyone decided to use my Service.</p>
<p>If you choose to use my Service, then you agree to the collection and use of information in
relation to this policy. The Personal Information that I collect are used for providing and
improving the Service.I will not use or share your information with anyone except as described
View init.coffee
# Your init script
#
# Atom will evaluate this file each time a new window is opened. It is run
# after packages are loaded/activated and after the previous editor state
# has been restored.
#
# An example hack to log to the console when each text editor is saved.
#
# atom.workspace.observeTextEditors (editor) ->
# editor.onDidSave ->
@AkshayChordiya
AkshayChordiya / MainActivity.java
Created Mar 22, 2017
Kotlin Article: MainActivity.java
View MainActivity.java
public class MainActivity extends AppCompatActivity {
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
}
}
@AkshayChordiya
AkshayChordiya / MainActivity.kt
Last active Mar 22, 2017
Kotlin Article: MainActivity.kt
View MainActivity.kt
class MainActivity : AppCompatActivity() {
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
setContentView(R.layout.activity_main)
}
}
@AkshayChordiya
AkshayChordiya / PrefUtils.kt
Created Mar 22, 2017
Kotlin Article: PrefUtils.kt
View PrefUtils.kt
fun getString(context: Context, key: String, defValue: String): String {
val pref = PreferenceManager.getDefaultSharedPreferences(context)
return pref.getString(key, defValue)
}
fun putString(context: Context, key: String, value: String) {
val pref = PreferenceManager.getDefaultSharedPreferences(context)
val editor = pref.edit()
editor.putString(key, value)
editor.apply()
@AkshayChordiya
AkshayChordiya / TimerUtils.kt
Created Mar 22, 2017
Kotlin Article: TimerUtils.kt
View TimerUtils.kt
val PREF_TIME_KEY = "Start_time"
fun didTimeStart(context: Context): Boolean {
when {
exists(context, PREF_TIME_KEY) -> return true
else -> return getStartTime(context) != 0L
}
}
fun removeStartTime(context: Context) {
@AkshayChordiya
AkshayChordiya / MainActivity.kt
Created Mar 22, 2017
Kotlin Article: MainActivity.kt with timer and views
View MainActivity.kt
class MainActivity : AppCompatActivity() {
var mTimer: CountDownTimer? = null
var toolbar: Toolbar? = null
var time_in: TextView? = null
var time_out: TextView? = null
var remaining_time: TextView? = null
var go_home_progress: CircularProgressBar? = null
@AkshayChordiya
AkshayChordiya / activity_main.xml
Created Apr 19, 2017
Kotlin Article: Main Activity Layout
View activity_main.xml
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/activity_main"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
tools:context=".MainActivity">
@AkshayChordiya
AkshayChordiya / MainActivity.kt
Last active Apr 20, 2017
Kotlin Article: MainActivity.kt with Views
View MainActivity.kt
class MainActivity : AppCompatActivity() {
var mToolbar: Toolbar? = null
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
setContentView(R.layout.activity_main)
bindViews()
setSupportActionBar(mToolbar)
}