Skip to content

Instantly share code, notes, and snippets.

@wabzqem
wabzqem / AnimationTestActivity.java
Created June 15, 2012 01:11
ListView Animation bug
package net.whatsbeef.animationtest;
import android.animation.Animator;
import android.animation.Animator.AnimatorListener;
import android.animation.AnimatorInflater;
import android.animation.AnimatorSet;
import android.app.Activity;
import android.os.Bundle;
import android.view.View;
import android.widget.ArrayAdapter;
- (void)viewDidLoad
{
[super viewDidLoad];
CollectionHorizontalListViewController *cat1 = [[CollectionHorizontalListViewController alloc] initWithNibName:@"CollectionHorizontalListViewController" bundle:nil];
[self addChildViewController:cat1];
[_category1Container addSubview:cat1.view]; //crashes here, cat1.view is nil
[cat1 didMoveToParentViewController:self];
diff --git a/picasso/src/main/java/com/squareup/picasso/BitmapHunter.java b/picasso/src/main/java/com/squareup/picasso/BitmapHunter.java
index 4a10575..b571590 100644
--- a/picasso/src/main/java/com/squareup/picasso/BitmapHunter.java
+++ b/picasso/src/main/java/com/squareup/picasso/BitmapHunter.java
@@ -21,6 +21,8 @@ import android.graphics.BitmapFactory;
import android.graphics.Matrix;
import android.net.NetworkInfo;
import android.net.Uri;
+import android.os.Build;
+import android.provider.DocumentsContract;
sqlite> select * FROM ZENCOUNTER WHERE Z_PK > 225;
226|1|1||0.0|609674900.519855|0.0|||App started|
227|1|1||0.0|609674900.532348|0.0|||Scanning started|
228|1|1||0.0|609674900.559534|0.0|||App entered foreground|
229|1|1|1|-57.0|609674900.766709|12.0|iPhone 6s|iPhone XS Max|<redacted>|AU_DTA
230|1|1|1|-53.0|609674902.399689|12.0|iPhone XS Max|iPhone 6s|<redacted>|AU_DTA
231|1|1||0.0|609674911.477912|0.0|||Scanning stopped|
232|1|1||0.0|609674926.049821|0.0|||App entered background|
233|1|1||0.0|609675035.919336|0.0|||Scanning started|
234|1|1|1|-84.0|609675036.107311|12.0|iPhone XS Max|iPhone 6s|<redacted>|AU_DTA
sqlite> .schema ZENCOUNTER
CREATE TABLE ZENCOUNTER (
Z_PK INTEGER PRIMARY KEY, Z_ENT INTEGER,
Z_OPT INTEGER, ZV INTEGER, ZRSSI FLOAT,
ZTIMESTAMP TIMESTAMP, ZTXPOWER FLOAT,
ZMODELC VARCHAR, ZMODELP VARCHAR,
ZMSG VARCHAR, ZORG VARCHAR
)
default 16:29:02.135404+1000 bluetoothd Stop scanning for process sharingd (68) with scan request of type 7, blob: {length = 0, bytes = 0x}, mask {length = 0, bytes = 0x}, active: 0, duplicates: 0, screen on: No Scan, screen off: No Scan, locked: 1, rssi: -90, peers: (
) nearby scan mode: 10, adv buf: 0, advbuf mode: 4
default 16:29:02.135592+1000 bluetoothd Removing scan request scan request of type 7, blob: {length = 0, bytes = 0x}, mask {length = 0, bytes = 0x}, active: 0, duplicates: 0, screen on: No Scan, screen off: No Scan, locked: 1, rssi: -90, peers: (
) nearby scan mode: 10, adv buf: 0, advbuf mode: 4 for client 749762CA-5342-4759-A54D-65C18B24174D
default 16:29:02.137482+1000 bluetoothd Passively scanning for devices of types: 18 15 5 (Window: 30/Interval: 300)
default 16:29:02.137968+1000 bluetoothd About to scan for type: 18 - rssi: -100 - range: 0 - payload: {length = 22, bytes = 0x00000000000000000000000000000000000000000000} - mask: {length = 22, bytes = 0x00000000000000000000000000000000000
default 16:56:57.404645+1000 bluetoothd ShouldScan=1 AnyValidScanRequests=1 anyValidScanRequestInPaused=0 fObserverState=Active
default 16:56:57.405077+1000 bluetoothd ScanParams:AD:0 AS:0 MSL:4 (30/300) PSV:0 [com.apple.sharingd-central-68-107 SO:0 AP:0 AD:0(30/300) AS:0 RAS:0 DMN:1 FG:0 ADVBF:0] | AD:0 AS:0 MSL:4 (30/300) PSV:0 [com.apple.bluetoothd-central-85-0 SO:0 AP:0 AD:0(30/300) AS:0 RAS:0 DMN:1 FG:0 ADVBF:0] | AD:0 AS:0 MSL:4 (30/300) PSV:0 [au.gov.health.covidsafe-central-774-105 SO:0 AP:0 AD:0(0/0) AS:0 RAS:0 DMN:0 FG:0 ADVBF:0] |
default 16:56:57.405322+1000 bluetoothd Returning scan parameters: Main:30.00ms/300.00ms LP:0.00ms/300.00ms(unsupported) Dm:(m:30/300) Cond:0:1:0 Sc:1:0 (passive) Dupfilter:Enabled minScanLevel:4
default 16:56:57.405570+1000 bluetoothd needToRestart=0
default 16:57:59.586122+1000 bluetoothd ShouldScan=1 AnyValidScanRequests=1 anyValidScanRequestInPaused=0 fObserverState=Active
default 16:57:59.586411+1000 bluetoothd ScanParams:AD:0 AS:0 MSL:4 (30/300) PSV:0 [com.apple.sha
function launchInfoViewController() {
ObjC.schedule(ObjC.mainQueue, function() {
var application = ObjC.classes.UIApplication.sharedApplication();
var viewController = application.keyWindow().rootViewController();
viewController.presentedViewController().performSegueWithIdentifier_sender_("HomeToDebugSegue", NULL);
});
}
// Sloppy and good enough. Wait for the Main VC to be presented.
setTimeout(launchInfoViewController, 7000);
@wabzqem
wabzqem / gist:e4673da2d9da0de95cd1924511e21811
Last active December 5, 2020 05:08
Slack feature flags
var classname = "Slack.FeatureFlagManager";
var classmethod = "- isFeatureEnabled:";
var methodsignature = "(bool) - isFeatureEnabled:(pointer)";
try {
var hook = ObjC.classes['Slack.FeatureFlagManager']['- isFeatureEnabled:'];
//(bool) - isFeatureEnabled:(pointer)
Interceptor.attach(hook.implementation, {
onEnter: function (args) {
send("[Call_Stack]\nClass: " + classname + "\nMethod: " + methodsignature + "\n");
<?xml version='1.0' encoding='UTF-8'?>
<!-- Copyright 2019 Oath Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. -->
<services version="1.0">
<admin version='2.0'>
<adminserver hostalias="admin0"/>
<configservers>
<configserver hostalias="admin0"/>
</configservers>
</admin>