Martin Carlberg
bb58a206a8
Fixed: Removed all warnings of conflicting return and parameter types caused by the new compiler
2013-08-12 16:46:14 +02:00
Aparajita Fishman
afd5925499
Fixed: _CG and _CP macros were confusing and could degrade performance
...
Previously, Cappuccino was using preprocessor macros internally for the CGPoint/Size/Rect/Inset/Affine functions, as well as for CPRange. These macros had the same name as the corresponding function, but began with _. The functions were actually defined using the macros.
The motivation behind using macros was to increase performance by reducing function calls. However, there were a number of problems with this approach:
- There was an artificial dichotomy between _CG macros and the corresponding CG functions. We never completely replaced CG function calls with _CG macros. In fact, they were often mixed up in the same file. There was an extra burden on the programmer to remember to use the macro instead of the function.
- If a method call was passed as an argument to a macro, performance could actually be significantly *worse* than a function call. For example, _CGGetRectMakeCopy([view frame]) would expand to `{ origin:{ x:[view frame].origin.x, y:[view frame].origin.y }, size:{ width:[view frame].size.width, height:[view frame].size.height } }`. So instead of a single objj_msgSend and a single simple function call, we ended up with 4 objj_msgSend calls, which are way more expensive than simple function calls.
- Because of this expansion problem, to use macros efficiently required us to remember to use variables for all macro parameters. This didn't happen, and shouldn't have to happen.
- Finally, with modern Javascript engines, function call overhead is so small that it really isn't worth using the macros.
This commit eliminates the _CGGeometry, CGAffineTransformation and CPRange macros and replaces them with function calls.
BREAKING CHANGE:
The macros are no longer available. They could only be used with compiled code, but if there is any user code that used them, they will have to be replaced with the corresponding functions.
2013-03-13 12:22:10 -04:00
Alexander Ljungberg
5b05dc92a1
More dictionary literals.
2013-02-25 18:27:44 +00:00
Aparajita Fishman
4f377bcebe
Objj2 compiler fixes
...
Compiled all files individually:
- Added missing imports.
- Added @class/@global declarations to break circular dependencies.
- Misc. code cleanup.
Conflicts:
AppKit/CPWindow/_CPWindow.j
AppKit/Platform/DOM/CPPlatformWindow+DOM.j
2013-01-23 15:48:55 +07:00
Martin Carlberg
458fa9d02e
Fixed a lot of small bugs found by new warning message from compiler
2013-01-18 14:24:37 +01:00
Alexander Ljungberg
430a74735b
Fixed: CPSliders always became continuous when archived/unarchived through CPCoding.
2011-03-28 21:18:47 -04:00
Alexander Ljungberg
26003365bc
Fixed: CPSlider isContinuous disagreed with setContinuous.
2011-03-28 21:06:07 -04:00
Stephen Ierodiaconou
6a942630e4
Fixing spelling mistakes
2011-01-24 11:05:48 +02:00
Francisco Ryan Tolmasky I
52f7844aee
Made it so .h files are automatically included in AppKit (avoiding needing to manually include Platform.h, etc.).
...
Also changed a bunch of <AppKit/*> imports to "*" imports.
Reviewed by me.
2010-11-01 11:10:01 -07:00
Klaas Pieter Annema
6e9f82212b
rename CPView +themeClass to +defaultThemeClass
2010-10-25 14:15:22 +02:00
Alexander Ljungberg
0d15e59d0a
CPSlider code cleanup.
2010-09-30 23:51:12 -04:00
David Hess and Randall Luecke
ad33d1648c
Patch to CPSlider to invert its value in vertical mode so that max value is represented at the top of the track instead of the bottom.
2010-08-11 20:29:46 -05:00
Alexander Ljungberg
ed2c65dd6f
Merge branch 'master' of git://github.com/280north/cappuccino into bindings-merge
...
Conflicts:
AppKit/CPTableView.j
Foundation/CPArray+KVO.j
Foundation/CPArray.j
2010-05-26 19:05:04 -04:00
Francisco Ryan Tolmasky I
ae47509aa7
Add convinience methods for dealing with multiple objects and controls.
...
Reviewed by me.
2010-04-27 01:04:46 -07:00
Klaas Pieter Annema
6f0ca9d94c
Merge branch 'master' into bindings
...
Conflicts:
AppKit/CPTableView.j
AppKit/_CPCornerView.j
Foundation/CPArray.j
Foundation/CPKeyValueCoding.j
Foundation/CPKeyValueObserving.j
2010-04-15 10:57:46 +02:00
Francisco Ryan Tolmasky I
bc53288fca
Fix for failing CPAttributedString test.
...
Reviewed by me.
2010-02-13 16:14:18 -08:00
Ross Boucher
417b5c8b97
Merge branch 'master' into bindings
2009-09-20 18:14:17 -07:00
Francisco Ryan Tolmasky I
c752db905d
Fix for updating sliders visually when min/max values change.
...
Reviewed by me.
2009-09-15 21:39:20 -07:00
Francisco Ryan Tolmasky I
4ad2c2221f
Merge branch 'master' into bindings
...
Conflicts:
AppKit/CPControl.j
AppKit/CPSlider.j
Foundation/CPArray+KVO.j
2009-07-22 16:41:58 -07:00
Ross Boucher
850125b8ab
Add documentation groups
2009-05-18 15:43:36 -07:00
Ross Boucher
71200ca5f3
Update to the ciruclar slider images
2009-05-16 22:34:33 -07:00
Francisco Tolmasky
862af9cbae
First stab at fixing Themeing API.
...
Reviewed by me.
2009-05-10 13:04:02 -07:00
Francisco Tolmasky
586a1e347d
Fix for track no longer stretching in vertical sliders.
...
Closes #8 .
Reviewed by me.
2009-05-01 02:00:50 -07:00
Ross Boucher
f4e329f5de
CPSlider was going counter clockwise in circular mode
2009-04-16 20:02:34 -07:00
Francisco Tolmasky
0eb86fd4b6
Removed unecessary _sliderType ivar.
...
Reviewed by me.
2009-04-16 19:09:56 -07:00
Ross Boucher
a8317177c6
Typo
2009-04-16 18:07:00 -07:00
Ross Boucher
df7fab7e03
Add CPCircularSlider to CPSlider
2009-04-16 17:47:33 -07:00
Francisco Tolmasky
b4cf1ba041
Added altIncrementValue/setAltIncrementValue:.
...
Reviewed by me.
2009-03-16 18:07:20 -07:00
Francisco Tolmasky
4afed0067e
Fix for CPSlider not encoding/decoding its value correctly.
...
Reviewed by me.
2009-02-18 19:19:05 -08:00
Francisco Tolmasky
6ad037e469
Fix for major theme state bug.
...
Reviewed by me.
2009-02-18 02:22:10 -08:00
Francisco Tolmasky
50baf5fd50
Further improvements.
...
Reviewed by me.
2009-02-10 01:12:34 -08:00
Ross Boucher
c028425f14
More bindings fixes.
2009-02-09 17:35:25 -08:00
Francisco Tolmasky
abd86c676b
Theming for CPScroller.
...
Reviewed by me.
2009-02-07 18:38:34 -08:00
Francisco Tolmasky
df5f6c692f
Additional theme changes.
...
Reviewed by me.
2009-02-05 21:17:59 -08:00
Francisco Ryan Tolmasky I
e4b2988864
Added more customizability.
...
Reviewed by me.
2009-02-03 22:47:02 -08:00
Francisco Ryan Tolmasky I
63f813d8ad
Typo fixes, deprecating, minor fixes to CPSlider.
...
Reviewed by me.
2009-02-02 00:09:10 -08:00
Francisco Ryan Tolmasky I
e35c4b1461
Added setNeedsLayout and layoutSubviews. Changed CPSlider to use them.
...
Reviewed by me.
2009-02-01 17:36:22 -08:00
Francisco Ryan Tolmasky I
492f4b6480
First pass at themes in Cappuccino.
...
Reviewed by me.
2009-02-01 00:19:50 -08:00
Francisco Ryan Tolmasky I
8de321c780
Final fix for buttons not working when disabled.
...
[#188 state:resolved]
Reviewed by me.
2009-01-21 11:43:45 -08:00
Francisco Ryan Tolmasky I
d92fc8c4d0
Cleaned up old deprecated documentation stuff and added documentation to deploy.
...
Reviewed by me.
2008-12-10 15:57:31 -08:00
Tom Robinson
e8febcda15
Reverting to previous CPControl/CPSlider event system
2008-10-28 00:56:21 -07:00
Tom Robinson
a3ae869f1d
Removed CPLogs and an extra performSelectors, cleaned up rest of string literals.
2008-10-27 16:49:18 -07:00
Tom Robinson
7a3fab1d6d
Numerous improvements and nib2cib support for CPControl, CPSlider, CPTextField, CPWebView, etc.
...
Fixed broken @accessors preprocessing.
2008-10-27 04:54:43 -07:00
Francisco Ryan Tolmasky I
5144a5a579
Added @accessor support, @import, and fixed spacing bug with @selector.
...
Reviewed by ross.
2008-10-26 00:48:49 -07:00
Ross Boucher
f228934e54
Initial conversion to Doxygen style comments.
2008-10-12 15:57:01 -07:00
Tom Robinson
96b1dbdb60
Missing imports in AppKit.j, and misplaced comma in CPSlider
2008-09-18 23:47:50 -07:00
Ross Boucher
a40fbd7961
Add the first draft of documentation inline.
2008-09-10 15:11:37 -07:00
Francisco Ryan Tolmasky I
2c3ac4c1c3
Removed CPHUDSlider class. It is legacy code.
...
Reviewed by me.
2008-09-07 02:57:39 -07:00
Francisco Ryan Tolmasky I
a97bb72800
Initial commit.
...
Reviewed by francisco, ross and tom.
2008-09-04 03:52:20 -07:00