This gist shows how to create a GIF screencast using only free OS X tools: QuickTime, ffmpeg, and gifsicle.
To capture the video (filesize: 19MB), using the free "QuickTime Player" application:
/* | |
* Copyright (C) 2014 The Android Open Source Project | |
* | |
* 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 |
You can use this class to realize a simple sectioned RecyclerView.Adapter
without changing your code.
The RecyclerView
should use a LinearLayoutManager
.
You can use this code also with the TwoWayView
with the ListLayoutManager
(https://github.com/lucasr/twoway-view)
This is a porting of the class SimpleSectionedListAdapter
provided by Google
Example:
/* | |
* Copyright 2014 Chris Banes | |
* | |
* 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 |
extension NSNetService { | |
func resolveWithTimeout(timeout: NSTimeInterval, success: () -> ()) { | |
class NetServiceDelegate: NSObject, NSNetServiceDelegate { | |
let oldDelegate: NSNetServiceDelegate? | |
let netService: NSNetService | |
let success: () -> () | |
var holdSelf: NetServiceDelegate? | |
init(netService: NSNetService, success: () -> ()) { | |
self.oldDelegate = netService.delegate |
I've moved this gist to https://github.com/phynet/iOS-Schemes please check it there ;)
Download, unzip and drag to your Applications directory.
https://www.iterm2.com/downloads.html
package com.? | |
import android.os.Build | |
import android.util.Log | |
import com.varvet.shipgaz.BuildConfig | |
import java.util.regex.Pattern | |
/** | |
* A logger to avoid logging in production. It will check if [BuildConfig.DEBUG] is true or not. | |
* If true then allow logging, otherwise don't. |
Author: Michael Zeng
#!/usr/bin/env kotlin -language-version 1.9 | |
// Make sure you run "brew install kotlin graphviz" first. | |
@file:Repository("https://repo.maven.apache.org/maven2/") | |
@file:Repository("https://dl.google.com/dl/android/maven2/") | |
@file:DependsOn("com.squareup.leakcanary:shark-android:3.0-alpha-8") | |
import java.io.File | |
import shark.ActualMatchingReferenceReaderFactory |