Skip to content

Instantly share code, notes, and snippets.

View Polyterative's full-sized avatar

Vlady Yakovenko Polyterative

View GitHub Profile
@passsy
passsy / ArrayAdapter.java
Last active August 15, 2021 10:05
ArrayAdapter for RecyclerView
package com.pascalwelsch.utils;
import android.support.annotation.Nullable;
import android.support.v7.util.DiffUtil;
import android.support.v7.widget.RecyclerView;
import java.util.ArrayList;
import java.util.Collections;
import java.util.Comparator;
import java.util.List;
@WesleyBatista
WesleyBatista / README.md
Last active November 1, 2021 14:51 — forked from antonydevanchi/README.md
Download all images from undraw.co/illustrations
ov = $0D ; == $FF, initial value for the overflow counter
* = $0304 - (end - scroll)
scroll: jsr $AAD7
loop: lda #$A0
sta $D3E0 - $80, x
sta $0400+40*24+39-$80+1, y ; incrementing rower, y finishes with value $80
sta $0400+40*24-$7B-1, x ; decrementing rower, x finishes with value $7b
@antonydevanchi
antonydevanchi / README.md
Last active March 6, 2022 04:56
Download all images from undraw.co/illustrations
// create a bookmark and use this code as the URL, you can now toggle the css on/off
// thanks+credit: https://dev.to/gajus/my-favorite-css-hack-32g3
javascript: (function() {
var styleEl = document.getElementById('css-layout-hack');
if (styleEl) {
styleEl.remove();
return;
}
styleEl = document.createElement('style');
styleEl.id = 'css-layout-hack';
@alphamu
alphamu / SharedPreferencesSingletonEnumKeyTemplate.java
Last active March 9, 2023 11:59
A SharedPreferences singleton that can be used to centralise and simplify reading and writing of SharedPerferences in your Android app. There are 2 versions, one that uses static String for Keys and an other that uses enums. Which one you use comes down to your preference, enums I feel provides better control when you have multiple programmers w…
#if (${PACKAGE_NAME} != "")package ${PACKAGE_NAME};#end
import android.content.Context;
import android.content.SharedPreferences;
/*
* A Singleton for managing your SharedPreferences.
*
* You should make sure to change the SETTINGS_NAME to what you want
* and choose the operating made that suits your needs, the default is
@AlejandroPerezMartin
AlejandroPerezMartin / button-focus-remover.ts
Last active April 11, 2023 15:18
Angular 9+ Directive to remove focus after clicking the specified selector/s
import { Directive, HostListener, ElementRef } from '@angular/core';
/**
* This directive removes focus from the selectors after clicking on them
*/
@Directive({
selector: 'button, a' // your selectors here!
})
export class FocusRemover {
constructor(private elRef: ElementRef) {}
@mahdi
mahdi / .gitignore
Created August 2, 2011 08:10
A .gitignore file for a .NET developer
#Junk Files
*.DS_Store
[Tt]humbs.db
#Visual Studio Files
[Oo]bj
[Bb]in
[Dd]ebug
[Bb]uild/
*.user
@BrandonSmith
BrandonSmith / AndroidManifest.xml
Last active July 19, 2023 19:11
Quick example of how to schedule a notification in the future using AlarmManager
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.cards.notification">
<uses-sdk
android:minSdkVersion="17"
android:targetSdkVersion="17" />
<application
android:allowBackup="true"
@pdesterlich
pdesterlich / cognomi.txt
Last active November 13, 2023 07:17
lista cognomi italiani
-- DISCLAIMER --
il presente elenco consiste in una raccolta di cognomi presenti sul territorio italiano (non necessariamente "italiani")
viene generato prendendo processando automaticamente uno o più archivi anagrafici e non è controllato in alcun modo
è pertanto altamente possibile che ci siano errori o refusi
non è ne pretende di essere un elenco omnicomprensivo di tutti i cognomi esistenti
----------------
abbondanza
abu
accadia