GithubHelp home page GithubHelp logo

flextool / flex Goto Github PK

View Code? Open in Web Editor NEW
13.9K 382.0 1.7K 30.61 MB

An in-app debugging and exploration tool for iOS

License: Other

Objective-C 97.26% Ruby 0.17% Objective-C++ 0.74% C 1.01% Swift 0.48% Python 0.17% Shell 0.16%

flex's Introduction

FLEX

CocoaPods CocoaPods CocoaPods Twitter: @ryanolsonk Build Status Carthage compatible

FLEX (Flipboard Explorer) is a set of in-app debugging and exploration tools for iOS development. When presented, FLEX shows a toolbar that lives in a window above your application. From this toolbar, you can view and modify nearly every piece of state in your running application.

Demo

Give Yourself Debugging Superpowers

  • Inspect and modify views in the hierarchy.
  • See the properties and ivars on any object.
  • Dynamically modify many properties and ivars.
  • Dynamically call instance and class methods.
  • Observe detailed network request history with timing, headers, and full responses.
  • Add your own simulator keyboard shortcuts.
  • View system log messages (e.g. from NSLog).
  • Access any live object via a scan of the heap.
  • View the file system within your app's sandbox.
  • Browse SQLite/Realm databases in the file system.
  • Trigger 3D touch in the simulator using the control, shift, and command keys.
  • Explore all classes in your app and linked systems frameworks (public and private).
  • Quickly access useful objects such as [UIApplication sharedApplication], the app delegate, the root view controller on the key window, and more.
  • Dynamically view and modify NSUserDefaults values.

Unlike many other debugging tools, FLEX runs entirely inside your app, so you don't need to be connected to LLDB/Xcode or a different remote debugging server. It works well in the simulator and on physical devices.

Usage

In the iOS simulator, you can use keyboard shortcuts to activate FLEX. f will toggle the FLEX toolbar. Hit the ? key for a full list of shortcuts. You can also show FLEX programmatically:

Short version:

// Objective-C
[[FLEXManager sharedManager] showExplorer];
// Swift
FLEXManager.shared.showExplorer()

More complete version:

#if DEBUG
#import "FLEXManager.h"
#endif

...

- (void)handleSixFingerQuadrupleTap:(UITapGestureRecognizer *)tapRecognizer
{
#if DEBUG
    if (tapRecognizer.state == UIGestureRecognizerStateRecognized) {
        // This could also live in a handler for a keyboard shortcut, debug menu item, etc.
        [[FLEXManager sharedManager] showExplorer];
    }
#endif
}

Aside: tvOS

FLEX itself does not support tvOS out of the box. However, others have taken it upon themselves to port FLEX to tvOS. If you need tvOS support, seek out one of these forks. Here is one such fork.

Feature Examples

Modify Views

Once a view is selected, you can tap on the info bar below the toolbar to present more details about the view. From there, you can modify properties and call methods.

Modify Views

Network History

When enabled, network debugging allows you to view all requests made using NSURLConnection or NSURLSession. Settings allow you to adjust what kind of response bodies get cached and the maximum size limit of the response cache. You can choose to have network debugging enabled automatically on app launch. This setting is persisted across launches.

Network History

All Objects on the Heap

FLEX queries malloc for all the live allocated memory blocks and searches for ones that look like objects. You can see everything from here.

Heap/Live Objects Explorer

Explore-at-address

If you get your hands on an arbitrary address, you can try explore the object at that address, and FLEX will open it if it can verify the address points to a valid object. If FLEX isn't sure, it'll warn you and refuse to dereference the pointer. If you know better, however, you can choose to explore it anyway by choosing "Unsafe Explore"

Address Explorer

Simulator Keyboard Shortcuts

Default keyboard shortcuts allow you to activate the FLEX tools, scroll with the arrow keys, and close modals using the escape key. You can also add custom keyboard shortcuts via -[FLEXManager registerSimulatorShortcutWithKey:modifiers:action:description]

Simulator Keyboard Shortcuts

File Browser

View the file system within your app's bundle or sandbox container. FLEX shows file sizes, image previews, and pretty prints .json and .plist files. You can rename and delete files and folders. You can "share" any file if you want to inspect them outside of your app.

File Browser

SQLite Browser

SQLite database files (with either .db or .sqlite extensions), or Realm database files can be explored using FLEX. The database browser lets you view all tables, and individual tables can be sorted by tapping column headers.

SQLite Browser

3D Touch in the Simulator

Using a combination of the command, control, and shift keys, you can simulate different levels of 3D touch pressure in the simulator. Each key contributes 1/3 of maximum possible force. Note that you need to move the touch slightly to get pressure updates.

Simulator 3D Touch

Explore Loaded Libraries

Go digging for all things public and private. To learn more about a class, you can create an instance of it and explore its default state. You can also type in a class name to jump to that class directly if you know which class you're looking for.

Loaded Libraries Exploration

NSUserDefaults Editing

FLEX allows you to edit defaults that are any combination of strings, numbers, arrays, and dictionaries. The input is parsed as JSON. If other kinds of objects are set for a defaults key (i.e. NSDate), you can view them but not edit them.

NSUserDefaults Editing

Learning from Other Apps

The code injection is left as an exercise for the reader. 😇

Springboard Lock Screen Springboard Home Screen

Installation

FLEX requires an app that targets iOS 9 or higher. To run the Example project, open a Terminal window in the Example/ folder and run pod install, then open the generated workspace.

CocoaPods

FLEX is available on CocoaPods. Simply add the following line to your podfile:

pod 'FLEX', :configurations => ['Debug']

Carthage

Add the following to your Cartfile:

github "flipboard/FLEX"

Buck

If you're using Buck, you may want to silence some of the warnings emitted by FLEX. You will need to build FLEX as an apple_library and pass the -Wno-unsupported-availability-guard flag, as well as the other warning flags below to disable any other warnings FLEX may have.

Manual

Manually add the files in Classes/ to your Xcode project, or just drag in the entire FLEX/ folder. Be sure to exclude FLEX from Release builds or your app will be rejected.

Silencing warnings

Add the following flags to to Other Warnings Flags in Build Settings:

  • -Wno-deprecated-declarations
  • -Wno-strict-prototypes
  • -Wno-unsupported-availability-guard

Swift Package Manager

Include the dependency in the depdendencies value of your Package.swift

dependencies: [
    .package(url: "https://github.com/FLEXTool/FLEX.git", .upToNextMajor(from: "4.3.0"))
]

Next, include the library in your target:

.target(
    name: "YourDependency",
    dependencies: [
        "FLEX"
    ]
)

Excluding FLEX from Release (App Store) Builds

FLEX makes it easy to explore the internals of your app, so it is not something you should expose to your users. Fortunately, it is easy to exclude FLEX files from Release builds. The strategies differ depending on how you integrated FLEX in your project, and are described below.

Wrap the places in your code where you integrate FLEX with an #if DEBUG statement to ensure the tool is only accessible in your Debug builds and to avoid errors in your Release builds. For more help with integrating FLEX, see the example project.

CocoaPods

CocoaPods automatically excludes FLEX from release builds if you only specify the Debug configuration for FLEX in your Podfile:

pod 'FLEX', :configurations => ['Debug']

Carthage

  1. Do NOT add FLEX.framework to the embedded binaries of your target, as it would otherwise be included in all builds (therefore also in release ones).

  2. Instead, add $(PROJECT_DIR)/Carthage/Build/iOS to your target Framework Search Paths (this setting might already be present if you already included other frameworks with Carthage). This makes it possible to import the FLEX framework from your source files. It does not harm if this setting is added for all configurations, but it should at least be added for the debug one.

  3. Add a Run Script Phase to your target (inserting it after the existing Link Binary with Libraries phase, for example), and which will embed FLEX.framework in debug builds only:

    if [ "$CONFIGURATION" == "Debug" ]; then
      /usr/local/bin/carthage copy-frameworks
    fi

    Finally, add $(SRCROOT)/Carthage/Build/iOS/FLEX.framework as input file of this script phase.

Swift Package Manager

In Xcode, navigate to Build Settings > Build Options > Excluded Source File Names. For your Release configuration, set it to FLEX* like this to exclude all files with the FLEX prefix:

FLEX files added manually to a project

In Xcode, navigate to Build Settings > Build Options > Excluded Source File Names. For your Release configuration, set it to FLEX* like this to exclude all files with the FLEX prefix:

Additional Notes

  • When setting fields of type id or values in NSUserDefaults, FLEX attempts to parse the input string as JSON. This allows you to use a combination of strings, numbers, arrays, and dictionaries. If you want to set a string value, it must be wrapped in quotes. For ivars or properties that are explicitly typed as NSStrings, quotes are not required.
  • You may want to disable the exception breakpoint while using FLEX. Certain functions that FLEX uses throw exceptions when they get input they can't handle (i.e. NSGetSizeAndAlignment()). FLEX catches these to avoid crashing, but your breakpoint will get hit if it is active.

Thanks & Credits

FLEX builds on ideas and inspiration from open source tools that came before it. The following resources have been particularly helpful:

  • MirrorKit: an Objective-C wrapper around the Objective-C runtime.
  • DCIntrospect: view hierarchy debugging for the iOS simulator.
  • PonyDebugger: network, core data, and view hierarchy debugging using the Chrome Developer Tools interface.
  • Mike Ash: well written, informative blog posts on all things obj-c and more. The links below were very useful for this project:
  • MAObjCRuntime
  • Let's Build Key Value Coding
  • ARM64 and You
  • RHObjectiveBeagle: a tool for scanning the heap for live objects. It should be noted that the source code of RHObjectiveBeagle was not consulted due to licensing concerns.
  • heap_find.cpp: an example of enumerating malloc blocks for finding objects on the heap.
  • Gist from @samdmarshall: another example of enumerating malloc blocks.
  • Non-pointer isa: an explanation of changes to the isa field on iOS for ARM64 and mention of the useful objc_debug_isa_class_mask variable.
  • GZIP: A library for compressing/decompressing data on iOS using libz.
  • FMDB: This is an Objective-C wrapper around SQLite.
  • InAppViewDebugger: The inspiration and reference implementation for FLEX 4's 3D view explorer, by @indragiek.

Contributing

Please see our Contributing Guide.

TODO

  • Swift runtime introspection (swift classes, swift objects on the heap, etc.)
  • Add new NSUserDefault key/value pairs on the fly

flex's People

Contributors

bdotdub avatar betteray avatar canius avatar cntrump avatar colinhumber avatar daidoujichen avatar defagos avatar dlo avatar drodriguez avatar euanchan avatar gregheo avatar hossamghareeb avatar javisoto avatar jnavarrom avatar kikeenrique avatar magauran avatar matrush avatar modnovolyk avatar nsexceptional avatar revolter avatar robinsonrc avatar ryanolsonk avatar shepting avatar studentdeng avatar tikoyes94 avatar timoliver avatar tinder-tannerbennett avatar tttpeng avatar wanghengheng avatar weiminghuaa avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

flex's Issues

Linker error

When I declare Flex instance in my application delegate file that gave me an error.

"(use -v to see invocation)"

Why [explorerWindow addSubview] ?

Hi, in FLEXManager

- (FLEXWindow *)explorerWindow
{
    NSAssert([NSThread isMainThread], @"You must use %@ from the main thread only.", NSStringFromClass([self class]));

    if (!_explorerWindow) {
        _explorerWindow = [[FLEXWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
        _explorerWindow.eventDelegate = self;

        _explorerWindow.rootViewController = self.explorerViewController;
        [_explorerWindow addSubview:self.explorerViewController.view];
    }

    return _explorerWindow;
}

I think set rootViewController is enough, why addSubView?

Is there way to learn button method name ?

Hi all! I'm using FLEX over the last two weeks and like it. But i run into a bit missing feature. I created UIButton manually after that I added "addTarget:action:forControlEvents" method. Here we go. I wanted to see which method called specific UIButton object but i didn't see anything about UIButton target - action. In brief, is there way to see which method called when I tapped to UIButton?

searchbars behavior

Hello @ryanolsonk,

in common use FLEX scenario, i prefer press 'Search' button on the keyboard to finish search rather than scroll the tableview. if you also like it, i will send a pull request to you, thank you. 😊

Does this require a jailbroken device?

Not an issue, but a question (and I couldn't find another way to ask it).

Is the ability to look @ the Apple Home Screen (Springboard) accomplished via jailbreak?

Add Device Log

It'd be great and really useful if we could see all the device's logs. e.g. NSLogs etc.

the action sheets cover the explorerWindow

The action sheets cover the explorerWindow, So I can't touch the explorerWindow.
image

I think it should be

  self.explorerWindow.windowLevel = UIWindowLevelAlert * 2;

Thanks.

Running FLEX in system apps

I love FLEX, and have seen that you have an example of FLEX running in system apps, presumably via a jailbreak. I have 2 jailbroken iOS 7.0.6 devices and a jailbroken iOS 8.1 device.

I understand that FLEX is not made for jailbroken development, but I would really like to learn how Apple have laid out a couple of their internal apps that I am struggling to emulate, e.g., the "Friends" tab of Game Center seemingly being a UISplitViewController inside a UITabBarController. I feel FLEX would be a great learning experience for me, but I have very little knowledge with jailbreak development, nevermind injecting the code in to a system app.

If you can provide any help/pointers, it would be much appreciated, but I understand that you likely cannot (potentially legally) help me.

Network request logging

I'm thinking about implementing this myself. I believe having a UI where you can check which requests have recently happened and some info about them (status code, headers, etc) would be incredible.

The obvious approach would be to use an NSURLProtocol to capture all HTTP(s) requests, store the info about each request in disk / memory, but then return that request back to NSURLConnection so that it happens normally.

The tricky thing is that only one NSURLProtocol will get to capture any given HTTP request. As soon as one returns YES from -canInitWithRequest:, the other registered ones won't be consulted (Or so I believe. I'm starting to doubt myself right now)

I have an implementation that I could open source of a generic NSURLProtocol that lets multiple peers hook into requests (or simply get notified of them) with a middleware type of API (the header is already available on gist: https://gist.github.com/JaviSoto/66763cfacac897d0d27f)

The problem is that if we added this to FLEX, and people add FLEX to their app with an already existent NSURLProtocol, either FLEX's request logging wouldn't work, or we would make the 3rd party's app NSURLProtocol stop working.

Posible Solution

The request logging could be opt-in. FLEXManager could have a -enableRequestLogging API, that when called, installs the NSURLProtocol. Then we could document that the feature wouldn't work in the cases mentioned above.

What do you think about this? Did you have any ideas about how to implement this feature?
Thanks!

Can't turn off shouldEnableOnLaunch

FLEX is really helpful, thanks for your brilliant work!

But I believe the @YES in following code should be shouldEnableOnLaunch, right?

+ (void)setShouldEnableOnLaunch:(BOOL)shouldEnableOnLaunch
{
    [[NSUserDefaults standardUserDefaults] setObject:@YES forKey:kFLEXNetworkObserverEnableOnLaunchDefaultsKey];
}

Crashed at UIDevice information

Open the menu , chooice the [UIDevice currentDevice] row , change the segment to Include Inheritance , then scroll the UITableView to bottom , the app will be crashed at row fourth IVARS(4) section .

The code at FLEXRuntimeUtility.m , line 210 .

self    Class   FLEXRuntimeUtility  0x0000000100e3dbf0
ivar    Ivar    0x198114a68 0x0000000198114a68
object  UIDevice *  0x170228740 0x0000000170228740
NSObject    NSObject        
isa Class   UIDevice    0x000061a5952bf5b3
_numDeviceOrientationObservers  long long   3   3
_batteryLevel   float   1   1
value   id  0x0 0x0000000000000000
[0] id      
type    const char *    "#" 0x00000001939abc00
*type   const char  '#' '#'

I was tested by my iPhone 5s , mode A1533 .

Crasher in FLEXNetworkObserver

I encountered an exception coming out of +[FLEXNetworkObserver injectDidFinishLoadingIntoDelegateClass].

It seemed like my code managed to cause the NSURLConnection to release before the connectionDidFinishLoading:delegate: was called. As a result, sniffWithoutDuplicationForObject:selector:sniffingBlock: attempted to set an associated object on nil.

image

Digging deeper, I noticed that my connection is nil as early as the call to the implementationBlock, which is swizzled in for connectionDidFinishLoading:. I'm not entirely unsurprised that my connection was released so early, as this connection represents a "fire and forget" analytics call.

image

This is my current workaround, but I suspect someone who knows more about FLEX might be able to find an appropriate way for FLEX to hook in and hold a reference to the NSURLConnection:

diff --git i/Classes/Network/PonyDebugger/FLEXNetworkObserver.m w/Classes/Network/PonyDebugger/FLEXNetworkObserver.m
index 1dca18f..61eb2a4 100644
--- i/Classes/Network/PonyDebugger/FLEXNetworkObserver.m
+++ w/Classes/Network/PonyDebugger/FLEXNetworkObserver.m
@@ -680,11 +680,13 @@ didBecomeDownloadTask:(NSURLSessionDownloadTask *)downloadTask delegate:(id <NSU
     };

     NSURLConnectionDidFinishLoadingBlock implementationBlock = ^(id <NSURLConnectionDelegate> slf, NSURLConnection *connection) {
-        [self sniffWithoutDuplicationForObject:connection selector:selector sniffingBlock:^{
-            undefinedBlock(slf, connection);
-        } originalImplementationBlock:^{
-            ((void(*)(id, SEL, id))objc_msgSend)(slf, swizzledSelector, connection);
-        }];
+        if (connection) {
+            [self sniffWithoutDuplicationForObject:connection selector:selector sniffingBlock:^{
+                undefinedBlock(slf, connection);
+            } originalImplementationBlock:^{
+                ((void(*)(id, SEL, id))objc_msgSend)(slf, swizzledSelector, connection);
+            }];
+        }
     };

     [self replaceImplementationOfSelector:selector withSelector:swizzledSelector forClass:cls withMethodDescription:methodDescription implementationBlock:implementationBlock undefinedBlock:undefinedBlock];

Thanks!

Insert nil object into NSArray

In FLEXNetworkTransactionTableViewCell.m around line 130 there is a nil date being inserted into an NSArray.
It turns out self.transaction is nil (the setter is never called). This happens on iOS 9.0.2, not on iOS 8.

  • (NSString *)transactionDetailsLabelText
    {
    NSMutableArray *detailComponents = [NSMutableArray array];

    NSString *timestamp = [[self class] timestampStringFromRequestDate:self.transaction.startTime];
    [detailComponents addObject:timestamp];

.....

[Question] how rotation works

relate to #59 .

Could you explain why we should care about status bar and

our window shouldn't be the key window when this view controller is asked about the status bar ?

I think FLEX Windows is just a Floating Window.

Errors

I have 2 errors and are the same errors, any idea how to fix it?
Either one of these "Fix-it" options eventually crash my application (_Bridge.. option)
Have the latest version.
screenshot 2014-08-01 16 58 22

Why i'm always getting the same ViewController in "Globals"?

In my base UIViewController i have added this with the purpose of having the debugger enabled in all VC when needed:

- (void)viewDidLoad
{
    [super viewDidLoad];
#if DEBUG
    UITapGestureRecognizer *tapRecognizer = [[UITapGestureRecognizer alloc]  initWithTarget:self action:@selector(showFlexDebugger:)];

    tapRecognizer.numberOfTapsRequired = 3;

    [self.view addGestureRecognizer:tapRecognizer];
#endif
}

But instead of debugging the current VC i always have the reference of the first VC instantiated by the AppDelegate, it's not the appropriate pattern for achieve this?

type encoding issue

Hello @ryanolsonk,

I found some type encoding is @?. Than the method readableTypeForEncoding in FLEXRuntimeUtility.m convert this to (? *) like
ios simulator screen shot 2015 3 13 11 31 35

I am not sure but maybe all of them just id type?

crash due to KVO

crash reason:
Fatal Exception: NSRangeException
Cannot remove an observer for the key path "frame" from because it is not registered as an observer.

Here is trace:
Thread : Fatal Exception: NSRangeException
0 CoreFoundation 6490509128 exceptionPreprocess
1 libobjc.A.dylib 6838321024 objc_exception_throw
2 CoreFoundation 6490508944 -[NSException initWithCoder:]
3 Foundation 6505732568 -[NSObject(NSKeyValueObserverRegistration) _removeObserver:forProperty:]
4 Foundation 6505731252 -[NSObject(NSKeyValueObserverRegistration) removeObserver:forKeyPath:]
5 TutorTeacher 4297117164 -FLEXExplorerViewController stopObservingView:
6 TutorTeacher 4297114184 -FLEXExplorerViewController setViewsAtTapPoint:
7 TutorTeacher 4297127036 -FLEXExplorerViewController updateOutlineViewsForSelectionPoint:
8 TutorTeacher 4297126852 -FLEXExplorerViewController handleSelectionTap:
9 UIKit 6585987888 _UIGestureRecognizerSendTargetActions
10 UIKit 6581963612 _UIGestureRecognizerSendActions
11 UIKit 6580447324 -[UIGestureRecognizer _updateGestureWithEvent:buttonEvent:]
12 UIKit 6585992972 ___UIGestureRecognizerUpdate_block_invoke898
13 UIKit 6580181176 _UIGestureRecognizerRemoveObjectsFromArrayAndApplyBlocks
14 UIKit 6580168252 _UIGestureRecognizerUpdate
15 UIKit 6580438732 -[UIWindow _sendGesturesForEvent:]
16 UIKit 6580436168 -[UIWindow sendEvent:]
17 UIKit 6580241572 -[UIApplication sendEvent:]
18 UIKit 6580234092 _UIApplicationHandleEventQueue
19 CoreFoundation 6490211652 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION

20 CoreFoundation 6490210264 __CFRunLoopDoSources0
21 CoreFoundation 6490201304 __CFRunLoopRun
22 CoreFoundation 6489345184 CFRunLoopRunSpecific
23 GraphicsServices 6676234376 GSEventRunModal
24 UIKit 6580670460 UIApplicationMain
25 TutorTeacher 4297150244 main (main.m:14)
26 libdyld.dylib 6847031480 start

iOS 8.3 endless recursive call on [FLEXExplorerViewController supportedInterfaceOrientations]

This behaviour happens on real phone and simulator. but only on iOS 8.3.

Steps to reproduce:

  • Enable Flex
  • Test an ActionsSheet or AlertView (no crash)
  • Test an ActionsSheet or AlertView (crash)

Observations:
[UIApplication sharedApplication] keyWindow] is changed after the first iteration.

2015-05-12 14:33:57.028 UICatalog[50167:7492923] keyWindow: <UIWindow: 0x7fbc5171de80; frame = (0 0; 320 568); gestureRecognizers = <NSArray: 0x7fbc5171cd60>; layer = <UIWindowLayer: 0x7fbc5171ca70>>


2015-05-12 14:34:04.365 UICatalog[50167:7492923] keyWindow: <_UIAlertControllerShimPresenterWindow: 0x7fbc517238e0; frame = (0 0; 320 568); opaque = NO; gestureRecognizers = <NSArray: 0x7fbc5171a6f0>; layer = <UIWindowLayer: 0x7fbc51710700>>

screen shot 2015-05-12 at 2 04 17 pm

Killswitch

To toggle it on/off in all apps at once

Pausing on C++ Exception Breakpoint in FLEXToolbarItem

Turn on Exception Breakpoint
Here is the Stack Trace (FLEX 1.1.1 and FLEX 2.0.3)

* thread #1: tid = 0x130106, 0x00000001967453f0 libc++abi.dylib`__cxa_throw, queue = 'com.apple.main-thread', stop reason = breakpoint 1.1
    frame #0: 0x00000001967453f0 libc++abi.dylib`__cxa_throw
    frame #1: 0x000000018dd22d48 libFontParser.dylib`TFileDescriptorContext::TFileDescriptorContext(char const*) + 172
    frame #2: 0x000000018dd22ae8 libFontParser.dylib`TFileDataReference::TFileDataReference(char const*) + 116
    frame #3: 0x000000018dd22914 libFontParser.dylib`TFileDataSurrogate::TFileDataSurrogate(char const*, bool) + 144
    frame #4: 0x000000018dd2131c libFontParser.dylib`TFont::CreateFontEntitiesForFile(char const*, bool, TSimpleArray<TFont*>&, bool, short, char const*) + 1220
    frame #5: 0x000000018dd209c0 libFontParser.dylib`FPFontCreateFontsWithPath + 192
    frame #6: 0x0000000185b20e24 libCGXType.A.dylib`create_private_data_with_path + 24
    frame #7: 0x00000001859a1e74 CoreGraphics`CGFontCreateFontsWithPath + 44
    frame #8: 0x00000001859fc40c CoreGraphics`CGFontCreateFontsWithURL + 376
    frame #9: 0x000000018ee1e94c GraphicsServices`AddFontsFromURLOrPath + 120
    frame #10: 0x000000018ee22f74 GraphicsServices`__Initialize_block_invoke + 992
    frame #11: 0x00000001011ccf94 libdispatch.dylib`_dispatch_client_callout + 16
    frame #12: 0x00000001011cdea0 libdispatch.dylib`dispatch_once_f + 148
    frame #13: 0x000000018ee1e058 GraphicsServices`Initialize + 224
    frame #14: 0x0000000196f5cbd0 libobjc.A.dylib`_class_initialize + 744
    frame #15: 0x0000000196f649ac libobjc.A.dylib`lookUpImpOrForward + 348
    frame #16: 0x0000000196f6fdb8 libobjc.A.dylib`_objc_msgSend_uncached_impcache + 56
    frame #17: 0x000000018a1e7db0 UIKit`-[UIButton initWithFrame:] + 540
  * frame #18: 0x0000000100228754 MyApp`-[FLEXToolbarItem initWithFrame:](self=0x0000000000000000, _cmd=0x000000018a94880c, frame=(origin = (x = 0, y = 0), size = (width = 0, height = 0))) + 108 at FLEXToolbarItem.m:23
    frame #19: 0x000000018a1e86f8 UIKit`+[UIButton buttonWithType:] + 424
    frame #20: 0x0000000100228950 MyApp`+[FLEXToolbarItem toolbarItemWithTitle:image:](self=0x0000000100ae4a70, _cmd=0x0000000100886c96, title=0x00000001009e63d0, image=0x0000000170082f30) + 112 at FLEXToolbarItem.m:34
    frame #21: 0x00000001001f9224 MyApp`-[FLEXExplorerToolbar initWithFrame:](self=0x0000000101351730, _cmd=0x000000018a94880c, frame=(origin = (x = 0, y = 0), size = (width = 0, height = 0))) + 864 at FLEXExplorerToolbar.m:50
    frame #22: 0x00000001001fbcd8 MyApp`-[FLEXExplorerViewController viewDidLoad](self=0x000000010142f2a0, _cmd=0x000000018a978be0) + 128 at FLEXExplorerViewController.m:95
    frame #23: 0x000000018a170c84 UIKit`-[UIViewController loadViewIfRequired] + 692
    frame #24: 0x000000018a170994 UIKit`-[UIViewController view] + 32
    frame #25: 0x00000001002175c0 MyApp`-[FLEXManager explorerWindow](self=0x0000000170237200, _cmd=0x000000010088890e) + 780 at FLEXManager.m:55
    frame #26: 0x000000010021771c MyApp`-[FLEXManager showExplorer](self=0x0000000170237200, _cmd=0x000000010086a7dc) + 40 at FLEXManager.m:73

Path to selected view

Is it possible - through the view inspector to get the "path" to the selected view?

I can see the hierarchy through the "views" option, but not sure how I would retrieve a private view in code (would I need to result to recursive subviews comparing class name?).

For instance if selected a label in a navigation controller:

[[[UIViewController:xxxxxx navigationController] navigationBar] private instance of some subview] ... more views in the way... particular view I selected in the viewer...]
Hope the question is clear.

Fix the status bar style on apps that use a light one

Our app uses a light status bar cause all the navigation bars are dark. This is probably tricky to fix because not all apps use View Controller based status bar styling.

Not asking you guys to fix this, I will probably give it a shot myself, but I wanted to create this issue to track this :)

Cocoapods and staging builds

I have two targets in my Xcode project: MyApp and MyApp Staging.

What is the recommended way of installing FLEX for the staging version only, via Cocoapods? I've tried this

platform :ios, '7.0'
pod 'AFNetworking'
pod 'MBProgressHUD'
target 'MyApp Staging' do
    pod 'FLEX'
end

.. but i got various 'duplicate symbol' erros when building.

Android support

This is not really an issue, but rather a question: Is there a FLEX version for Android? Or another tool that you know of for Android?

update FLEXExplorerViewController.m

i used pod 'FLEX', '~> 2.0', :configurations => ['Debug']

at method supportedInterfaceOrientations
it will be show a warn about conflict return type
it returns UIInterfaceOrientationMask but uiviewcontroller return NSUInteger,this is the reason

a Obsessive-compulsive disorder person's isses,3q

Slowing down UI

Hi,

First of all: THANK YOU! This is very helpful for developing the next big thing ;).
But what I found is that if you have #import "FLEXManager.h" in your code the app's UI slows down a lot. Especially reloading table views gets very slow. I do think this is a bug because it lead me to think I just made a mistake building my table view :). If it is possible it would be great if this gets fixed.

Bests,
Philip

FlexWindow toolbar on top of the keyboard

I'm creating a sort of accessibility control and since I like the FlexWindow approach, I'm using a similar technique. Thank you very much for sharing.

A problem arises when the window control (the explorer toolbar) is moved over the area that will be used to display the keyboard. The latter is displayed under the toolbar.

Is this the correct behavior? Thank you in advance.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.