Skip to content

Instantly share code, notes, and snippets.

Avatar
🍊

Igor Solkin solkin

🍊
View GitHub Profile
View ActionBar
package ru.mail.im.ui;
import android.app.Activity;
import android.content.Context;
import android.util.AttributeSet;
import android.view.Gravity;
import android.view.View;
import android.view.ViewGroup;
import android.widget.TextView;
import org.androidannotations.annotations.AfterViews;
View EndlessListAdapter.java
import android.content.Context;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.BaseAdapter;
import com.tomclaw.mandarin.R;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
View SimpleCursorLoader.java
/*
* Copyright 2012 CodeSlap - Cristian Castiblanco
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
View Activity1.cs
using Android.App;
using Android.Text;
using Android.Text.Style;
using Android.Widget;
using Android.OS;
namespace MonoDroid.TextViewWithImages
{
[Activity(Label = "Text with Images", MainLauncher = true, Icon = "@drawable/icon")]
public class Activity1 : Activity
View FileStack.java
package com.tomclaw.stack;
import java.io.ByteArrayInputStream;
import java.io.ByteArrayOutputStream;
import java.io.EOFException;
import java.io.File;
import java.io.IOException;
import java.io.RandomAccessFile;
import java.util.ArrayList;
import java.util.EmptyStackException;
@solkin
solkin / HexHelper.java
Last active Aug 8, 2016
Java (also, Android) hexadecimal output formatter
View HexHelper.java
package com.tomclaw.utils;
import java.io.File;
import java.io.FileInputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.PrintStream;
/**
* Created by ivsolkin on 06.07.16.
@solkin
solkin / anim_download.xml
Last active Oct 11, 2016
Animated and static "download" vector drawable
View anim_download.xml
<?xml version="1.0" encoding="utf-8"?>
<animated-vector xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:aapt="http://schemas.android.com/aapt"
xmlns:tools="http://schemas.android.com/tools"
tools:ignore="MissingPrefix">
<aapt:attr name="android:drawable">
<vector
android:width="24dp"
android:height="24dp"
@solkin
solkin / ic_lock.xml
Last active Jun 6, 2017
Векторная иконка замка
View ic_lock.xml
<?xml version="1.0" encoding="utf-8"?>
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportHeight="24"
android:viewportWidth="24">
<path
android:fillColor="#000000"
android:pathData="M6,9c-1.1,0-2,0.9-2,2v10c0,1.1,0.9,2,2,2h12c1.1,0,2-0.9,2-2V11c0-1.1-0.9-2-2-2H6z
M12,18c-1.1,0-2-0.9-2-2s0.9-2,2-2 s2,0.9,2,2S13.1,18,12,18z" />
@solkin
solkin / ic_lock_static.xml
Last active Jun 6, 2017
Статическая версия векторного замка, обёрнутая в XML Bundle
View ic_lock_static.xml
<?xml version="1.0" encoding="utf-8"?>
<animated-vector xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:aapt="http://schemas.android.com/aapt">
<aapt:attr name="android:drawable">
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportHeight="24"
android:viewportWidth="24">
<path
@solkin
solkin / ic_lock_anim.xml
Created Jun 6, 2017
Анимированная версия векторного замка
View ic_lock_anim.xml
<?xml version="1.0" encoding="utf-8"?>
<animated-vector xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:aapt="http://schemas.android.com/aapt">
<aapt:attr name="android:drawable">
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportHeight="24"
android:viewportWidth="24">
<path