Skip to content

Instantly share code, notes, and snippets.

View hasankucuk's full-sized avatar

Hasan Küçük hasankucuk

View GitHub Profile
@hasankucuk
hasankucuk / README.md
Created December 9, 2018 20:31 — forked from lopspower/README.md
Android Tools Attributes

Android Tools Attributes

Twitter

Android has a dedicated XML namespace intended for tools to be able to record information in XML files, and have that information stripped when the application is packaged such that there is no runtime or download size penalty. The namespace URI is http://schemas.android.com/tools and is usually bound to the tools: prefix:

<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:tools="http://schemas.android.com/tools"
 android:layout_width="match_parent"
@hasankucuk
hasankucuk / gist:1075778ff74a7e2a18128bcf84b106de
Created December 18, 2018 17:12 — forked from y-gagar1n/gist:8469484
DateTime format patterns
DateTime.ToString() Patterns
All the patterns:
0 MM/dd/yyyy 08/22/2006
1 dddd, dd MMMM yyyy Tuesday, 22 August 2006
2 dddd, dd MMMM yyyy HH:mm Tuesday, 22 August 2006 06:30
3 dddd, dd MMMM yyyy hh:mm tt Tuesday, 22 August 2006 06:30 AM
4 dddd, dd MMMM yyyy H:mm Tuesday, 22 August 2006 6:30
5 dddd, dd MMMM yyyy h:mm tt Tuesday, 22 August 2006 6:30 AM
@hasankucuk
hasankucuk / xx.java
Created January 3, 2019 10:47
Webservisler
rapidapi.com
@hasankucuk
hasankucuk / genymotionwithplay.txt
Created January 5, 2019 11:24 — forked from wbroek/genymotionwithplay.txt
Genymotion with Google Play Services for ARM
NOTE: Easier way is the X86 way, described on https://www.genymotion.com/help/desktop/faq/#google-play-services
Download the following ZIPs:
ARM Translation Installer v1.1 (http://www.mirrorcreator.com/files/0ZIO8PME/Genymotion-ARM-Translation_v1.1.zip_links)
Download the correct GApps for your Android version:
Google Apps for Android 6.0 (https://www.androidfilehost.com/?fid=24052804347835438 - benzo-gapps-M-20151011-signed-chroma-r3.zip)
Google Apps for Android 5.1 (https://www.androidfilehost.com/?fid=96042739161891406 - gapps-L-4-21-15.zip)
Google Apps for Android 5.0 (https://www.androidfilehost.com/?fid=95784891001614559 - gapps-lp-20141109-signed.zip)
@hasankucuk
hasankucuk / LoadMoreAdapter.java
Created January 5, 2019 13:17 — forked from talenguyen/LoadMoreAdapter.java
Implementation of Load More feature for RecyclerView
import android.support.v7.widget.RecyclerView;
import android.view.ViewGroup;
import java.util.ArrayList;
import java.util.List;
public abstract class LoadMoreAdapter<T>
extends RecyclerView.Adapter<RecyclerView.ViewHolder> {
public static final int VIEW_TYPE_LOAD_MORE = 1;
@hasankucuk
hasankucuk / FooAdapter.java
Created January 9, 2019 06:55 — forked from morgotth/FooAdapter.java
Recycled Pager Adapter inspired by RecyclerView
package com.example;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import com.example.Foo;
import com.example.RecycledPagerAdapter;
public class FooAdapter extends RecycledPagerAdapter<FooViewHolder> {
@hasankucuk
hasankucuk / abtract.java
Last active January 16, 2019 08:47
Best Example of Abstract class in Android
I want to complete Hiren Partel Answer with an example.
Abstract method of abstract class must be Override in Derived class
Non abstract method of abstract class always call method of Super class
If abstract class Implements an Interface it is possible to not to Implement methods and let the finally driven class to Implement the Interface methods
for example GOD controls his creature on Earth by implementing this interface ( :D) :
public interface َAliveCreature{
void breath();
@hasankucuk
hasankucuk / FirstLastItemSpacesDecoration.java
Created February 19, 2019 11:34 — forked from Miha-x64/FirstLastItemSpacesDecoration.java
RecyclerView decoration which adds indentation in the beginning and in the end of content.
package net.aquadc.commonandroid.lists;
import android.graphics.Rect;
import android.support.v7.widget.RecyclerView;
import android.view.View;
public class FirstLastItemSpacesDecoration extends RecyclerView.ItemDecoration {
private final int directSpace;
private final int reverseSpace;
@hasankucuk
hasankucuk / BaseActivity.java
Created March 14, 2019 08:28 — forked from sandeeptengale/BaseActivity.java
Sample code to create BaseActivity for Android
package com.vtuforum.android.views
import android.app.ProgressDialog
import android.os.Bundle
import android.support.design.widget.CoordinatorLayout
import android.support.v7.app.AppCompatActivity
import android.widget.FrameLayout
import android.widget.ImageButton
import android.widget.TextView
import com.vtuforum.vtustudies.R
@hasankucuk
hasankucuk / RoundedBottomSheetDialogFragment.kt
Created March 30, 2019 12:27 — forked from ArthurNagy/RoundedBottomSheetDialogFragment.kt
Rounded modal bottom sheet as seen in new Google products(Tasks, News, etc.), described in this article: https://medium.com/halcyon-mobile/implementing-googles-refreshed-modal-bottom-sheet-4e76cb5de65b
package com.your.package
import android.app.Dialog
import android.os.Bundle
import com.your.package.R
import com.google.android.material.bottomsheet.BottomSheetDialog
import com.google.android.material.bottomsheet.BottomSheetDialogFragment
/**
* BottomSheetDialog fragment that uses a custom