mirror of
https://github.com/cappuccino/cappuccino.git
synced 2026-11-10 00:48:45 +00:00
Correct performKeyEquivalent documentation
This commit is contained in:
1 parent
4cdefcc2c7
commit
b3a427ba18
3 files changed
+27
-7
No files matched your search
+12
-5
@@ -231,11 +231,18 @@ CPDeleteForwardKeyCode = 46;
|
||||
[_nextResponder performSelector:_cmd withObject:anEvent];
|
||||
}
|
||||
|
||||
/*
|
||||
FIXME This description is bad.
|
||||
Based on \c anEvent, the receiver should simulate the event.
|
||||
@param anEvent the event to simulate
|
||||
@return \c YES if the event receiver simulated the event
|
||||
/*!
|
||||
Overridden by subclasses to handle a key equivalent.
|
||||
|
||||
If the character code or codes in \c anEvent match the receiver’s key equivalent,
|
||||
the receiver should respond to the event and return \c YES. The default implementation
|
||||
does nothing and returns \c NO.
|
||||
|
||||
You should extract the characters for a key equivalent using
|
||||
\ref CPEvent::charactersIgnoringModifiers "[anEvent charactersIgnoringModifiers]".
|
||||
|
||||
@param anEvent An event object that represents the key equivalent pressed
|
||||
@return \c YES if theEvent is a key equivalent that the receiver handled, \c NO if it is not a key equivalent that it should handle.
|
||||
*/
|
||||
- (BOOL)performKeyEquivalent:(CPEvent)anEvent
|
||||
{
|
||||
|
||||
@@ -2129,6 +2129,20 @@ setBoundsOrigin:
|
||||
|
||||
@implementation CPView (KeyView)
|
||||
|
||||
/*!
|
||||
Overridden by subclasses to handle a key equivalent.
|
||||
|
||||
If the receiver’s key equivalent is the same as the characters of the key-down event theEvent,
|
||||
as returned by \ref CPEvent::charactersIgnoringModifiers "[anEvent charactersIgnoringModifiers]",
|
||||
the receiver should take the appropriate action and return \c YES. Otherwise, it should return
|
||||
the result of invoking super’s implementation. The default implementation of this method simply
|
||||
passes the message down the view hierarchy (from superviews to subviews)
|
||||
and returns \c NO if none of the receiver’s subviews responds \c YES.
|
||||
|
||||
@param anEvent An event object that represents the key equivalent pressed
|
||||
@return \c YES if theEvent is a key equivalent that the receiver handled,
|
||||
\c NO if it is not a key equivalent that it should handle.
|
||||
*/
|
||||
- (BOOL)performKeyEquivalent:(CPEvent)anEvent
|
||||
{
|
||||
var count = [_subviews count];
|
||||
|
||||
@@ -35,8 +35,7 @@ var buildDir = "Build";
|
||||
// Do not edit! (unless you know what you are doing)
|
||||
//===========================================================
|
||||
|
||||
var productName = "__project.nameasidentifier__"
|
||||
stream = require("narwhal/term").stream,
|
||||
var stream = require("narwhal/term").stream,
|
||||
JAKE = require("jake"),
|
||||
task = JAKE.task,
|
||||
CLEAN = require("jake/clean").CLEAN,
|
||||
|
||||
Reference in new issue
Block a user