Skip to content

Instantly share code, notes, and snippets.

@thebnich
thebnich / Game.java
Created May 12, 2015 23:39
box2lights rendering issue
package com.thebnich.samplegame;
import box2dLight.PointLight;
import box2dLight.RayHandler;
import com.badlogic.gdx.ApplicationAdapter;
import com.badlogic.gdx.Gdx;
import com.badlogic.gdx.graphics.Color;
import com.badlogic.gdx.graphics.GL20;
import com.badlogic.gdx.graphics.glutils.ShapeRenderer;
import com.badlogic.gdx.math.Vector2;
@thebnich
thebnich / patch.diff
Created July 23, 2015 21:15
Autocomplete flicker fix
diff --git a/Client/Frontend/Widgets/AutocompleteTextField.swift b/Client/Frontend/Widgets/AutocompleteTextField.swift
index 5ca98a8..0ad478a 100644
--- a/Client/Frontend/Widgets/AutocompleteTextField.swift
+++ b/Client/Frontend/Widgets/AutocompleteTextField.swift
@@ -133,10 +133,24 @@ class AutocompleteTextField: UITextField, UITextFieldDelegate {
}
override func insertText(text: String) {
+ // Before replacing the string, cache the existing autocompletion so we can reuse it
+ // immediately if the user continues the same string.
diff --git a/Client/Frontend/Browser/BrowserViewController.swift b/Client/Frontend/Browser/BrowserViewController.swift
index 83ae092..4b2001c 100644
--- a/Client/Frontend/Browser/BrowserViewController.swift
+++ b/Client/Frontend/Browser/BrowserViewController.swift
@@ -144,7 +144,6 @@ class BrowserViewController: UIViewController {
override func willTransitionToTraitCollection(newCollection: UITraitCollection, withTransitionCoordinator coordinator: UIViewControllerTransitionCoordinator) {
super.willTransitionToTraitCollection(newCollection, withTransitionCoordinator: coordinator)
- updateToolbarStateForTraitCollection(newCollection)
diff --git a/Client/Frontend/Browser/Browser.swift b/Client/Frontend/Browser/Browser.swift
index a657460..2704656 100644
--- a/Client/Frontend/Browser/Browser.swift
+++ b/Client/Frontend/Browser/Browser.swift
@@ -41,7 +41,6 @@ class Browser: NSObject {
private(set) var screenshot: UIImage?
var screenshotUUID: NSUUID?
var showDialog = false
- var disableDialog = false
diff --git a/Client/Frontend/Browser/BrowserViewController.swift b/Client/Frontend/Browser/BrowserViewController.swift
index 2800e0e..a39b03e 100644
--- a/Client/Frontend/Browser/BrowserViewController.swift
+++ b/Client/Frontend/Browser/BrowserViewController.swift
@@ -439,24 +439,7 @@ class BrowserViewController: UIViewController {
self.view.alpha = (profile.prefs.intForKey(IntroViewControllerSeenProfileKey) != nil) ? 1.0 : 0.0
}
- if activeCrashReporter?.previouslyCrashed ?? false {
- log.debug("Previously crashed.")
diff --git a/Client/Frontend/Widgets/TwoLineCell.swift b/Client/Frontend/Widgets/TwoLineCell.swift
index 34580dc..c7223f1 100644
--- a/Client/Frontend/Widgets/TwoLineCell.swift
+++ b/Client/Frontend/Widgets/TwoLineCell.swift
@@ -14,6 +14,7 @@ private let DetailTextTopMargin = CGFloat(5)
class TwoLineTableViewCell: UITableViewCell {
private let twoLineHelper = TwoLineCellHelper()
+ private let borderView = UIView()
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
import Foundation
// These are taken from the Places docs
// http://mxr.mozilla.org/mozilla-central/source/toolkit/components/places/nsINavHistoryService.idl#1187
@objc public enum _VisitType: Int {
case unknown = 0
#!/usr/bin/env sh
set -e
if [ "$#" -ne 1 ]
then
echo "Wrong number of arguments. Should be 1, was $#";
exit 1;
fi
git push -f thebnich $1:$1
git config receive.denyCurrentBranch updateInstead