frankus / meterview Goto Github PK
View Code? Open in Web Editor NEWDashboard-style gauges for iOS
Dashboard-style gauges for iOS
First of all: great job.
I had some EXC_BAD_ACCESS releasing the object.
I solved with the following code
(void)dealloc {
needleLayer.delegate = nil;
[needleLayer release];
[needle_ release];
[textLabel_ release];
[super dealloc];
}
I understand this is nine years old (how the heck did 2011 become 9 years ago, i still think 2001 was nine years ago!), and anyway, I am having all sorts of issues when trying to get this to work for modern objc project. Is it possible to make this display as a subview in a storyboard view?
Even the demo project won't work and i am willing to invest in the time to get it to work as i think this is the nicest looking speedometer gauge in objective c. LMGauge isn't as pretty but works out of the box...
Even if it builds, it won't run on the simulator.
Failed to install the requested application
Domain: NSPOSIXErrorDomain
Code: 22
Failure Reason: The bundle identifier of the application could not be determined.
Recovery Suggestion: Ensure that the application's Info.plist contains a value for CFBundleIdentifier.
User Info: {
bundleURL = "file:///Users/jweinraub/Library/Developer/Xcode/DerivedData/MeterView-djdloospfradzfgzfzgtdhdivraf/Build/Products/Debug-iphonesimulator/meterview.app/";
}
--
Grate work! Thanks for your control.
I have found an issue - a MeterNeedle not rescaled when main MeterView has been rescaled.
I solved with next fix.
in method drawLayer: inContext: for MeterView change
and add next method into MeterView
-(void)setFrame:(CGRect)frame
{
[super setFrame:frame];
needleLayer.bounds = CGRectMake(0.0f, 0.0f, frame.size.width, frame.size.height);
needleLayer.position = CGPointMake(needleLayer.bounds.size.width / 2.0, needleLayer.bounds.size.height / 2.0);
}
2016-09-06 11:38:15.080 MeterView[787:345998] *** Assertion failure in -[UIApplication _runWithMainScene:transitionContext:completion:], /BuildRoot/Library/Caches/com.apple.xbs/Sources/UIKit/UIKit-3512.60.12/UIApplication.m:3401
2016-09-06 11:38:28.177 MeterView[787:345998] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Application windows are expected to have a root view controller at the end of application launch'
*** First throw call stack:
(0x225b9b0b 0x21d76dff 0x225b99e1 0x22da073b 0x26e3c799 0x26e50811 0x26e39767 0x23c87bf7 0x23c87aa7 0x23c87da5 0x2257b9e7 0x2257b5d7 0x2257993f 0x224c81c9 0x224c7fbd 0x26c07f37 0x26c02435 0xdee67 0x22174873)
libc++abi.dylib: terminating with uncaught exception of type NSException
(lldb)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.