dfmuir / KINWebBrowser

A web browser module for your iOS apps.
Other
838 stars 167 forks source link

Subclassing issues #58

Open mamouneyya opened 8 years ago

mamouneyya commented 8 years ago

When subclassing the web browser view controller in Swift, the library seems to not access the resources anymore, making back / forward bar button images disappear.

mamouneyya commented 8 years ago

After a quick digging in the code, I can see that in line 408 in KINWebBrowserViewController.m you get the class of the bundle using self, which won't work when subclassing. Explicitly specifying the class name solves the issue: NSBundle *bundle = [NSBundle bundleForClass:[KINWebBrowserViewController class]]; instead of: NSBundle *bundle = [NSBundle bundleForClass:[self class]];

I can make a PR for you if you're okay.

wei commented 8 years ago

Duplicate of #57